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

Contents of /net-misc/tor/tor-0.2.0.32.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.7 - (show annotations) (download)
Mon Jan 26 22:49:53 2009 UTC (5 years, 10 months ago) by fauli
Branch: MAIN
CVS Tags: HEAD
Changes since 1.6: +1 -1 lines
FILE REMOVED
clean up
(Portage version: 2.1.6.4/cvs/Linux 2.6.27-gentoo-r8 i686)

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.32.ebuild,v 1.6 2008/12/09 19:56:28 bluebird 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 }
34
35 src_compile() {
36 econf $(use_enable debug)
37 emake || die
38 }
39
40 src_install() {
41 newinitd "${FILESDIR}"/tor.initd-r4 tor
42 emake DESTDIR="${D}" install || die
43 keepdir /var/{lib,log,run}/tor
44
45 dodoc README ChangeLog AUTHORS ReleaseNotes \
46 doc/{HACKING,TODO} \
47 doc/spec/*.txt
48
49 fperms 750 /var/lib/tor /var/log/tor
50 fperms 755 /var/run/tor
51 fowners tor:tor /var/lib/tor /var/log/tor /var/run/tor
52
53 if use logrotate; then
54 sed -e "s:/lib::" \
55 -e "s:/rc.d::" \
56 -e "s:\\*:\\*.:" \
57 -e "s:sharedscripts:create 0640 tor tor\n\tsharedscripts:" -i contrib/tor.logrotate || die
58 insinto /etc/logrotate.d
59 newins contrib/tor.logrotate tor
60 fi
61 }
62
63 pkg_postinst() {
64 elog "You must create /etc/tor/torrc, you can use the sample that is in that directory"
65 elog "To have privoxy and tor working together you must add:"
66 elog "forward-socks4a / localhost:9050 ."
67 elog "(notice the . at the end of the line)"
68 elog "to /etc/privoxy/config"
69 }

  ViewVC Help
Powered by ViewVC 1.1.20