Gentoo Archives: gentoo-commits

From: "Alon Bar-Lev (alonbl)" <alonbl@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1_rc6.ebuild openvpn-2.1_rc5.ebuild
Date: Thu, 24 Jan 2008 17:27:29
Message-Id: E1JI5rJ-00065S-Mu@stork.gentoo.org
1 alonbl 08/01/24 17:27:25
2
3 Modified: ChangeLog
4 Added: openvpn-2.1_rc6.ebuild
5 Removed: openvpn-2.1_rc5.ebuild
6 Log:
7 Version bump
8 (Portage version: 2.1.4)
9
10 Revision Changes Path
11 1.120 net-misc/openvpn/ChangeLog
12
13 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-misc/openvpn/ChangeLog?rev=1.120&view=markup
14 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-misc/openvpn/ChangeLog?rev=1.120&content-type=text/plain
15 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-misc/openvpn/ChangeLog?r1=1.119&r2=1.120
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/net-misc/openvpn/ChangeLog,v
20 retrieving revision 1.119
21 retrieving revision 1.120
22 diff -u -r1.119 -r1.120
23 --- ChangeLog 23 Jan 2008 22:15:31 -0000 1.119
24 +++ ChangeLog 24 Jan 2008 17:27:25 -0000 1.120
25 @@ -1,6 +1,12 @@
26 # ChangeLog for net-misc/openvpn
27 # Copyright 2002-2008 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/net-misc/openvpn/ChangeLog,v 1.119 2008/01/23 22:15:31 alonbl Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/net-misc/openvpn/ChangeLog,v 1.120 2008/01/24 17:27:25 alonbl Exp $
30 +
31 +*openvpn-2.1_rc6 (24 Jan 2008)
32 +
33 + 24 Jan 2008; Alon Bar-Lev <alonbl@g.o> -openvpn-2.1_rc5.ebuild,
34 + +openvpn-2.1_rc6.ebuild:
35 + Version bump
36
37 *openvpn-2.1_rc5 (23 Jan 2008)
38
39
40
41
42 1.1 net-misc/openvpn/openvpn-2.1_rc6.ebuild
43
44 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-misc/openvpn/openvpn-2.1_rc6.ebuild?rev=1.1&view=markup
45 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-misc/openvpn/openvpn-2.1_rc6.ebuild?rev=1.1&content-type=text/plain
46
47 Index: openvpn-2.1_rc6.ebuild
48 ===================================================================
49 # Copyright 1999-2008 Gentoo Foundation
50 # Distributed under the terms of the GNU General Public License v2
51 # $Header: /var/cvsroot/gentoo-x86/net-misc/openvpn/openvpn-2.1_rc6.ebuild,v 1.1 2008/01/24 17:27:25 alonbl Exp $
52
53 inherit eutils multilib
54
55 DESCRIPTION="OpenVPN is a robust and highly flexible tunneling application compatible with many OSes."
56 SRC_URI="http://openvpn.net/beta/${P}.tar.gz"
57 HOMEPAGE="http://openvpn.net/"
58
59 LICENSE="GPL-2"
60 SLOT="0"
61 KEYWORDS="~alpha ~amd64 ~hppa ~ppc ~ppc64 ~sh ~sparc ~sparc-fbsd ~x86 ~x86-fbsd"
62 IUSE="examples iproute2 minimal pam passwordsave selinux ssl static pkcs11 threads userland_BSD"
63
64 DEPEND=">=dev-libs/lzo-1.07
65 kernel_linux? (
66 iproute2? ( sys-apps/iproute2 ) !iproute2? ( sys-apps/net-tools )
67 )
68 !minimal? ( pam? ( virtual/pam ) )
69 selinux? ( sec-policy/selinux-openvpn )
70 ssl? ( >=dev-libs/openssl-0.9.6 )
71 pkcs11? ( >=dev-libs/pkcs11-helper-1.05 )"
72
73 pkg_setup() {
74 if use iproute2 ; then
75 if built_with_use sys-apps/iproute2 minimal ; then
76 eerror "iproute2 support requires that sys-apps/iproute2 was not"
77 eerror "built with the minimal USE flag"
78 die "iproute2 support not available"
79 fi
80 fi
81 }
82
83 src_compile() {
84 local myconf=""
85
86 if use minimal ; then
87 myconf="${myconf} --disable-plugins"
88 myconf="${myconf} --disable-pkcs11"
89 else
90 myconf="$(use_enable pkcs11)"
91 fi
92
93 econf ${myconf} \
94 $(use_enable passwordsave password-save) \
95 $(use_enable ssl) \
96 $(use_enable ssl crypto) \
97 $(use_enable threads pthread) \
98 $(use_enable iproute2) \
99 || die "configure failed"
100
101 use static && sed -i -e '/^LIBS/s/LIBS = /LIBS = -static /' Makefile
102
103 emake || die "make failed"
104
105 if ! use minimal ; then
106 cd plugin
107 for i in $( ls 2>/dev/null ); do
108 [[ ${i} == "README" || ${i} == "examples" ]] && continue
109 [[ ${i} == "auth-pam" ]] && ! use pam && continue
110 einfo "Building ${i} plugin"
111 cd "${i}"
112 emake || die "make failed"
113 cd ..
114 done
115 cd ..
116 fi
117 }
118
119 src_install() {
120 make DESTDIR="${D}" install || die "make install failed"
121
122 # install documentation
123 dodoc AUTHORS ChangeLog PORTS README
124
125 # Empty dir
126 dodir /etc/openvpn
127 keepdir /etc/openvpn
128
129 # Install some helper scripts
130 exeinto /etc/openvpn
131 doexe "${FILESDIR}/up.sh"
132 doexe "${FILESDIR}/down.sh"
133
134 # Install the init script and config file
135 newinitd "${FILESDIR}/${PN}-2.1.init" openvpn
136 newconfd "${FILESDIR}/${PN}-2.1.conf" openvpn
137
138 # install examples, controlled by the respective useflag
139 if use examples ; then
140 # dodoc does not supportly support directory traversal, #15193
141 insinto /usr/share/doc/${PF}/examples
142 doins -r sample-{config-files,keys,scripts} contrib
143 prepalldocs
144 fi
145
146 # Install plugins and easy-rsa
147 if ! use minimal ; then
148 cd easy-rsa/2.0
149 make install "DESTDIR=${D}/usr/share/${PN}/easy-rsa"
150 cd ../..
151
152 exeinto "/usr/$(get_libdir)/${PN}"
153 doexe plugin/*/*.so
154 fi
155 }
156
157 pkg_postinst() {
158 # Add openvpn user so openvpn servers can drop privs
159 # Clients should run as root so they can change ip addresses,
160 # dns information and other such things.
161 enewgroup openvpn
162 enewuser openvpn "" "" "" openvpn
163
164 if [[ -n $(ls /etc/openvpn/*/local.conf 2>/dev/null) ]] ; then
165 ewarn "WARNING: The openvpn init script has changed"
166 ewarn ""
167 fi
168
169 einfo "The openvpn init script expects to find the configuration file"
170 einfo "openvpn.conf in /etc/openvpn along with any extra files it may need."
171 einfo ""
172 einfo "To create more VPNs, simply create a new .conf file for it and"
173 einfo "then create a symlink to the openvpn init script from a link called"
174 einfo "openvpn.newconfname - like so"
175 einfo " cd /etc/openvpn"
176 einfo " ${EDITOR##*/} foo.conf"
177 einfo " cd /etc/init.d"
178 einfo " ln -s openvpn openvpn.foo"
179 einfo ""
180 einfo "You can then treat openvpn.foo as any other service, so you can"
181 einfo "stop one vpn and start another if you need to."
182
183 if grep -Eq "^[ \t]*(up|down)[ \t].*" "${ROOT}/etc/openvpn"/*.conf 2>/dev/null ; then
184 ewarn ""
185 ewarn "WARNING: If you use the remote keyword then you are deemed to be"
186 ewarn "a client by our init script and as such we force up,down scripts."
187 ewarn "These scripts call /etc/openvpn/\$SVCNAME-{up,down}.sh where you"
188 ewarn "can move your scripts to."
189 fi
190
191 if ! use minimal ; then
192 einfo ""
193 einfo "plugins have been installed into /usr/$(get_libdir)/${PN}"
194 fi
195 }
196
197
198
199 --
200 gentoo-commits@l.g.o mailing list