Gentoo Archives: gentoo-commits

From: "Jeroen Roovers (jer)" <jer@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in net-dialup/freeradius: ChangeLog freeradius-3.0.2-r1.ebuild
Date: Sun, 04 May 2014 17:24:35
Message-Id: 20140504172429.C351D2004C@flycatcher.gentoo.org
1 jer 14/05/04 17:24:29
2
3 Modified: ChangeLog
4 Added: freeradius-3.0.2-r1.ebuild
5 Log:
6 Do not build or install static libraries.
7
8 (Portage version: 2.2.10/cvs/Linux x86_64, signed Manifest commit with key A792A613)
9
10 Revision Changes Path
11 1.122 net-dialup/freeradius/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-dialup/freeradius/ChangeLog?rev=1.122&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-dialup/freeradius/ChangeLog?rev=1.122&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-dialup/freeradius/ChangeLog?r1=1.121&r2=1.122
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/net-dialup/freeradius/ChangeLog,v
20 retrieving revision 1.121
21 retrieving revision 1.122
22 diff -u -r1.121 -r1.122
23 --- ChangeLog 4 May 2014 08:20:23 -0000 1.121
24 +++ ChangeLog 4 May 2014 17:24:29 -0000 1.122
25 @@ -1,6 +1,11 @@
26 # ChangeLog for net-dialup/freeradius
27 # Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/net-dialup/freeradius/ChangeLog,v 1.121 2014/05/04 08:20:23 ago Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/net-dialup/freeradius/ChangeLog,v 1.122 2014/05/04 17:24:29 jer Exp $
30 +
31 +*freeradius-3.0.2-r1 (04 May 2014)
32 +
33 + 04 May 2014; Jeroen Roovers <jer@g.o> +freeradius-3.0.2-r1.ebuild:
34 + Do not build or install static libraries.
35
36 04 May 2014; Agostino Sarubbo <ago@g.o> freeradius-2.2.5.ebuild:
37 Stable for amd64, wrt bug #501754
38
39
40
41 1.1 net-dialup/freeradius/freeradius-3.0.2-r1.ebuild
42
43 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-dialup/freeradius/freeradius-3.0.2-r1.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-dialup/freeradius/freeradius-3.0.2-r1.ebuild?rev=1.1&content-type=text/plain
45
46 Index: freeradius-3.0.2-r1.ebuild
47 ===================================================================
48 # Copyright 1999-2014 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/net-dialup/freeradius/freeradius-3.0.2-r1.ebuild,v 1.1 2014/05/04 17:24:29 jer Exp $
51
52 EAPI=5
53
54 PYTHON_COMPAT=( python2_7 )
55 inherit autotools eutils pam python-any-r1 user
56
57 PATCHSET=4
58
59 MY_P="${PN}-server-${PV}"
60
61 DESCRIPTION="Highly configurable free RADIUS server"
62 SRC_URI="
63 ftp://ftp.freeradius.org/pub/radius/${MY_P}.tar.gz
64 ftp://ftp.freeradius.org/pub/radius/old/${MY_P}.tar.gz
65 "
66 HOMEPAGE="http://www.freeradius.org/"
67
68 KEYWORDS=""
69 LICENSE="GPL-2"
70 SLOT="0"
71
72 IUSE="
73 bindist debug firebird iodbc kerberos ldap mysql odbc oracle pam pcap
74 postgres python readline sqlite ssl
75 "
76
77 REQUIRED_USE="bindist? ( !firebird )"
78
79 RDEPEND="!net-dialup/cistronradius
80 !net-dialup/gnuradius
81 sys-devel/libtool
82 dev-lang/perl
83 sys-libs/gdbm
84 python? ( ${PYTHON_DEPS} )
85 readline? ( sys-libs/readline )
86 pcap? ( net-libs/libpcap )
87 mysql? ( virtual/mysql )
88 postgres? ( dev-db/postgresql-base )
89 firebird? ( dev-db/firebird )
90 pam? ( virtual/pam )
91 ssl? ( dev-libs/openssl )
92 ldap? ( net-nds/openldap )
93 kerberos? ( virtual/krb5 )
94 sqlite? ( dev-db/sqlite:3 )
95 odbc? ( dev-db/unixODBC )
96 iodbc? ( dev-db/libiodbc )
97 oracle? ( dev-db/oracle-instantclient-basic )"
98 DEPEND="${RDEPEND}"
99
100 S="${WORKDIR}/${MY_P}"
101
102 RESTRICT="test"
103
104 pkg_setup() {
105 enewgroup radius
106 enewuser radius -1 -1 /var/log/radius radius
107
108 python-any-r1_pkg_setup
109 export PYTHONBIN="${EPYTHON}"
110 }
111
112 src_prepare() {
113 # most of the configuration options do not appear as ./configure
114 # switches. Instead it identifies the directories that are available
115 # and run through them. These might check for the presence of
116 # various libraries, in which case they are not built. To avoid
117 # automagic dependencies, we just remove all the modules that we're
118 # not interested in using.
119
120 use ssl || rm -r src/modules/rlm_eap/types/rlm_eap_{tls,ttls,peap}
121 use ldap || rm -r src/modules/rlm_ldap
122 use kerberos || rm -r src/modules/rlm_krb5
123 use pam || rm -r src/modules/rlm_pam
124 use python || rm -r src/modules/rlm_python
125 # Do not install ruby rlm module, bug #483108
126 rm -r src/modules/rlm_ruby
127
128 # these are all things we don't have in portage/I don't want to deal
129 # with myself
130 rm -r src/modules/rlm_eap/types/rlm_eap_tnc # requires TNCS library
131 rm -r src/modules/rlm_eap/types/rlm_eap_ikev2 # requires libeap-ikev2
132 rm -r src/modules/rlm_opendirectory # requires some membership.h
133 rm -r src/modules/rlm_redis{,who} # requires redis
134 rm -r src/modules/rlm_sql/drivers/rlm_sql_{db2,freetds}
135
136 # sql drivers that are not part of experimental are loaded from a
137 # file, so we have to remove them from the file itself when we
138 # remove them.
139 usesqldriver() {
140 local flag=$1
141 local driver=rlm_sql_${2:-${flag}}
142
143 if ! use ${flag}; then
144 rm -r src/modules/rlm_sql/drivers/${driver} || die
145 sed -i -e /${driver}/d src/modules/rlm_sql/stable || die
146 fi
147 }
148
149 sed -i -e 's:/var/run/radiusd:/run/radiusd:' raddb/radiusd.conf.in || die
150
151 # verbosity
152 # build shared libraries using jlibtool --shared
153 sed -i \
154 -e '/$(LIBTOOL)/s|--quiet ||g' \
155 -e 's:--mode=\(compile\|link\):& --shared:g' \
156 Make.inc.in || die
157
158 sed -i \
159 -e 's|--silent ||g' \
160 -e 's:--mode=\(compile\|link\):& --shared:g' \
161 scripts/libtool.mk || die
162
163 # crude measure to stop jlibtool from running ranlib and ar
164 sed -i \
165 -e '/LIBRARIAN/s|".*"|"true"|g' \
166 -e '/RANLIB/s|".*"|"true"|g' \
167 scripts/jlibtool.c || die
168
169 usesqldriver mysql
170 usesqldriver postgres postgresql
171 usesqldriver firebird
172 usesqldriver iodbc
173 usesqldriver odbc unixodbc
174 usesqldriver oracle
175 usesqldriver sqlite
176
177 epatch_user
178
179 eautoreconf
180 }
181
182 src_configure() {
183 # fix bug #77613
184 if has_version app-crypt/heimdal; then
185 myconf="${myconf} --enable-heimdal-krb5"
186 fi
187
188 use readline || export ac_cv_lib_readline=no
189 use pcap || export ac_cv_lib_pcap_pcap_open_live=no
190
191 # do not try to enable static with static-libs; upstream is a
192 # massacre of libtool best practices so you also have to make sure
193 # to --enable-shared explicitly.
194 econf \
195 --enable-shared \
196 --disable-static \
197 --disable-ltdl-install \
198 --with-system-libtool \
199 --with-system-libltdl \
200 --with-ascend-binary \
201 --with-udpfromto \
202 --with-dhcp \
203 --with-iodbc-include-dir=/usr/include/iodbc \
204 --with-experimental-modules \
205 --with-docdir=/usr/share/doc/${PF} \
206 --with-logdir=/var/log/radius \
207 $(use_enable debug developer) \
208 $(use_with ldap edir) \
209 $(use_with ssl openssl) \
210 ${myconf}
211 }
212
213 src_compile() {
214 # verbose, do not generate certificates
215 emake \
216 Q='' ECHO=true \
217 LOCAL_CERT_PRODUCTS=''
218 }
219
220 src_install() {
221 dodir /etc
222 diropts -m0750 -o root -g radius
223 dodir /etc/raddb
224 diropts -m0750 -o radius -g radius
225 dodir /var/log/radius
226 keepdir /var/log/radius/radacct
227 diropts
228
229 # verbose, do not install certificates
230 emake -j1 \
231 Q='' ECHO=true \
232 LOCAL_CERT_PRODUCTS='' \
233 R="${D}" \
234 install
235
236 fowners -R root:radius /etc/raddb
237
238 pamd_mimic_system radiusd auth account password session
239
240 dodoc CREDITS
241
242 rm "${D}/usr/sbin/rc.radiusd"
243
244 newinitd "${FILESDIR}/radius.init-r3" radiusd
245 newconfd "${FILESDIR}/radius.conf-r3" radiusd
246
247 prune_libtool_files
248 }
249
250 pkg_config() {
251 if use ssl; then
252 cd "${ROOT}"/etc/raddb/certs
253 ./bootstrap
254 fi
255 }
256
257 pkg_preinst() {
258 if ! has_version ${CATEGORY}/${PN} && use ssl; then
259 elog "You have to run \`emerge --config =${CATEGORY}/${PF}\` to be able"
260 elog "to start the radiusd service."
261 fi
262 }