/[gentoo-x86]/net-misc/tor/tor-0.2.0.31-r1.ebuild
Gentoo

Contents of /net-misc/tor/tor-0.2.0.31-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.4 - (show annotations) (download)
Wed Dec 10 07:02:37 2008 UTC (5 years, 7 months ago) by fauli
Branch: MAIN
CVS Tags: HEAD
Changes since 1.3: +1 -1 lines
FILE REMOVED
clean up
(Portage version: 2.1.4.5)

1 # Copyright 1999-2008 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/net-misc/tor/tor-0.2.0.31-r1.ebuild,v 1.3 2008/11/22 17:05:22 opfer Exp $
4
5 inherit eutils
6
7 DESCRIPTION="Anonymizing overlay network for TCP"
8 HOMEPAGE="http://tor.eff.org"
9 MY_PV=${PV/_/-}
10 SRC_URI="http://tor.eff.org/dist/${PN}-${MY_PV}.tar.gz"
11 S="${WORKDIR}/${PN}-${MY_PV}"
12
13 LICENSE="BSD"
14 SLOT="0"
15 KEYWORDS="amd64 ppc ppc64 sparc x86 ~x86-fbsd"
16 IUSE="debug logrotate"
17
18 DEPEND="dev-libs/openssl
19 >=dev-libs/libevent-1.2"
20 RDEPEND="${DEPEND}
21 net-proxy/tsocks"
22
23 pkg_setup() {
24 enewgroup tor
25 enewuser tor -1 -1 /var/lib/tor tor
26 }
27
28 src_unpack() {
29 unpack ${A}
30 cd "${S}"
31 epatch "${FILESDIR}"/torrc.sample-0.1.2.6.patch
32 epatch "${FILESDIR}"/${PN}-0.2.0.30-logrotate.patch
33 epatch "${FILESDIR}"/${PN}-0.2.0.31-sparc.patch
34 }
35
36 src_compile() {
37 econf $(use_enable debug)
38 emake || die
39 }
40
41 src_install() {
42 newinitd "${FILESDIR}"/tor.initd-r4 tor
43 emake DESTDIR="${D}" install || die
44 keepdir /var/{lib,log,run}/tor
45
46 dodoc README ChangeLog AUTHORS ReleaseNotes \
47 doc/{HACKING,TODO} \
48 doc/spec/*.txt
49
50 fperms 750 /var/lib/tor /var/log/tor
51 fperms 755 /var/run/tor
52 fowners tor:tor /var/lib/tor /var/log/tor /var/run/tor
53
54 if use logrotate; then
55 sed -e "s:/lib::" \
56 -e "s:/rc.d::" \
57 -e "s:\\*:\\*.:" \
58 -e "s:sharedscripts:create 0640 tor tor\n\tsharedscripts:" -i contrib/tor.logrotate || die
59 insinto /etc/logrotate.d
60 newins contrib/tor.logrotate tor
61 fi
62 }
63
64 pkg_postinst() {
65 elog "You must create /etc/tor/torrc, you can use the sample that is in that directory"
66 elog "To have privoxy and tor working together you must add:"
67 elog "forward-socks4a / localhost:9050 ."
68 elog "(notice the . at the end of the line)"
69 elog "to /etc/privoxy/config"
70 }

  ViewVC Help
Powered by ViewVC 1.1.20