Gentoo Archives: gentoo-commits

From: "Richard Farina (zerochaos)" <zerochaos@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in net-wireless/wpa_supplicant: metadata.xml wpa_supplicant-2.3-r1.ebuild ChangeLog
Date: Mon, 27 Oct 2014 19:34:03
Message-Id: 20141027193346.5EE5C8E06@oystercatcher.gentoo.org
1 zerochaos 14/10/27 19:33:46
2
3 Modified: metadata.xml ChangeLog
4 Added: wpa_supplicant-2.3-r1.ebuild
5 Log:
6 new handling for config file, enable new features, enable optional new features
7
8 (Portage version: 2.2.14/cvs/Linux x86_64, signed Manifest commit with key DD11F94A)
9
10 Revision Changes Path
11 1.16 net-wireless/wpa_supplicant/metadata.xml
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-wireless/wpa_supplicant/metadata.xml?rev=1.16&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-wireless/wpa_supplicant/metadata.xml?rev=1.16&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-wireless/wpa_supplicant/metadata.xml?r1=1.15&r2=1.16
16
17 Index: metadata.xml
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/net-wireless/wpa_supplicant/metadata.xml,v
20 retrieving revision 1.15
21 retrieving revision 1.16
22 diff -u -r1.15 -r1.16
23 --- metadata.xml 14 Apr 2014 07:05:47 -0000 1.15
24 +++ metadata.xml 27 Oct 2014 19:33:46 -0000 1.16
25 @@ -13,8 +13,11 @@
26 <flag name='ap'>Add support for access point mode</flag>
27 <flag name='eap-sim'>Add support for EAP-SIM authentication algorithm</flag>
28 <flag name='fasteap'>Add support for FAST-EAP authentication algorithm</flag>
29 + <flag name='hs2.0'>Add support for 802.11u and Passpoint for HotSpot 2.0</flag>
30 <flag name='p2p'>Add support for Wi-Fi Direct mode</flag>
31 <flag name='ps3'>Add support for ps3 hypervisor driven gelic wifi</flag>
32 + <flag name='tdls'>Add support for Tunneled Direct Link Setup (802.11z)</flag>
33 + <flag name='uncommon-eap-types'>Add support for Wi-Fi Protected Setup</flag>
34 <flag name='wps'>Add support for Wi-Fi Protected Setup</flag>
35 <flag name='wimax'>Add support for Wimax EAP-PEER authentication algorithm</flag>
36 <flag name='smartcard'>Add support for smartcards</flag>
37
38
39
40 1.220 net-wireless/wpa_supplicant/ChangeLog
41
42 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-wireless/wpa_supplicant/ChangeLog?rev=1.220&view=markup
43 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-wireless/wpa_supplicant/ChangeLog?rev=1.220&content-type=text/plain
44 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-wireless/wpa_supplicant/ChangeLog?r1=1.219&r2=1.220
45
46 Index: ChangeLog
47 ===================================================================
48 RCS file: /var/cvsroot/gentoo-x86/net-wireless/wpa_supplicant/ChangeLog,v
49 retrieving revision 1.219
50 retrieving revision 1.220
51 diff -u -r1.219 -r1.220
52 --- ChangeLog 16 Oct 2014 17:24:30 -0000 1.219
53 +++ ChangeLog 27 Oct 2014 19:33:46 -0000 1.220
54 @@ -1,6 +1,13 @@
55 # ChangeLog for net-wireless/wpa_supplicant
56 # Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2
57 -# $Header: /var/cvsroot/gentoo-x86/net-wireless/wpa_supplicant/ChangeLog,v 1.219 2014/10/16 17:24:30 gurligebis Exp $
58 +# $Header: /var/cvsroot/gentoo-x86/net-wireless/wpa_supplicant/ChangeLog,v 1.220 2014/10/27 19:33:46 zerochaos Exp $
59 +
60 +*wpa_supplicant-2.3-r1 (27 Oct 2014)
61 +
62 + 27 Oct 2014; Rick Farina <zerochaos@g.o> +wpa_supplicant-2.3-r1.ebuild,
63 + metadata.xml:
64 + new handling for config file, enable new features, enable optional new
65 + features
66
67 16 Oct 2014; <gurligebis@g.o> wpa_supplicant-2.3.ebuild:
68 Changing to using upstream supplied systemd files, fixing bug #525436
69
70
71
72 1.1 net-wireless/wpa_supplicant/wpa_supplicant-2.3-r1.ebuild
73
74 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-wireless/wpa_supplicant/wpa_supplicant-2.3-r1.ebuild?rev=1.1&view=markup
75 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-wireless/wpa_supplicant/wpa_supplicant-2.3-r1.ebuild?rev=1.1&content-type=text/plain
76
77 Index: wpa_supplicant-2.3-r1.ebuild
78 ===================================================================
79 # Copyright 1999-2014 Gentoo Foundation
80 # Distributed under the terms of the GNU General Public License v2
81 # $Header: /var/cvsroot/gentoo-x86/net-wireless/wpa_supplicant/wpa_supplicant-2.3-r1.ebuild,v 1.1 2014/10/27 19:33:46 zerochaos Exp $
82
83 EAPI=5
84
85 inherit eutils toolchain-funcs qt4-r2 systemd multilib
86
87 DESCRIPTION="IEEE 802.1X/WPA supplicant for secure wireless transfers"
88 HOMEPAGE="http://hostap.epitest.fi/wpa_supplicant/"
89 SRC_URI="http://hostap.epitest.fi/releases/${P}.tar.gz"
90 LICENSE="|| ( GPL-2 BSD )"
91
92 SLOT="0"
93 #KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd"
94 IUSE="ap dbus gnutls eap-sim fasteap +hs2.0 p2p ps3 qt4 readline selinux smartcard ssl tdls uncommon-eap-types wimax wps kernel_linux kernel_FreeBSD"
95 REQUIRED_USE="fasteap? ( !gnutls !ssl ) smartcard? ( ssl )"
96
97 RDEPEND="dbus? ( sys-apps/dbus )
98 kernel_linux? (
99 eap-sim? ( sys-apps/pcsc-lite )
100 dev-libs/libnl:3
101 net-wireless/crda
102 )
103 !kernel_linux? ( net-libs/libpcap )
104 qt4? (
105 dev-qt/qtcore:4
106 dev-qt/qtgui:4
107 dev-qt/qtsvg:4
108 )
109 readline? (
110 sys-libs/ncurses
111 sys-libs/readline
112 )
113 ssl? ( dev-libs/openssl )
114 !ssl? ( gnutls? ( net-libs/gnutls ) )
115 !ssl? ( !gnutls? ( dev-libs/libtommath ) )
116 selinux? ( sec-policy/selinux-networkmanager )"
117 DEPEND="${RDEPEND}
118 virtual/pkgconfig"
119
120 S="${WORKDIR}/${P}/${PN}"
121
122 Kconfig_style_config() {
123 #param 1 is CONFIG_* item
124 #param 2 is what to set it = to, defaulting in y
125 CONFIG_PARAM="${CONFIG_HEADER:-CONFIG_}$1"
126 setting="${2:-y}"
127
128 if [ ! $setting = n ]; then
129 #first remove any leading "# " if $2 is not n
130 sed -i "/^# *$CONFIG_PARAM/s/^# *//" .config || echo "Kconfig_style_config error uncommenting $CONFIG_PARAM"
131 #set item = $setting (defaulting to y)
132 sed -i "/^$CONFIG_PARAM/s/=.*/=$setting/" .config || echo "Kconfig_style_config error setting $CONFIG_PARAM=$setting"
133 else
134 #ensure item commented out
135 sed -i "/^$CONFIG_PARAM/s/$CONFIG_PARAM/# $CONFIG_PARAM/" .config || echo "Kconfig_style_config error commenting $CONFIG_PARAM"
136 fi
137 }
138
139 pkg_setup() {
140 if use gnutls && use ssl ; then
141 elog "You have both 'gnutls' and 'ssl' USE flags enabled: defaulting to USE=\"ssl\""
142 fi
143 }
144
145 src_prepare() {
146 # net/bpf.h needed for net-libs/libpcap on Gentoo/FreeBSD
147 sed -i \
148 -e "s:\(#include <pcap\.h>\):#include <net/bpf.h>\n\1:" \
149 ../src/l2_packet/l2_packet_freebsd.c || die
150
151 # People seem to take the example configuration file too literally (bug #102361)
152 sed -i \
153 -e "s:^\(opensc_engine_path\):#\1:" \
154 -e "s:^\(pkcs11_engine_path\):#\1:" \
155 -e "s:^\(pkcs11_module_path\):#\1:" \
156 wpa_supplicant.conf || die
157
158 # Change configuration to match Gentoo locations (bug #143750)
159 sed -i \
160 -e "s:/usr/lib/opensc:/usr/$(get_libdir):" \
161 -e "s:/usr/lib/pkcs11:/usr/$(get_libdir):" \
162 wpa_supplicant.conf || die
163
164 if use dbus; then
165 epatch "${FILESDIR}/${P}-dbus-path-fix.patch"
166 fi
167
168 # systemd entries to D-Bus service files (bug #372877)
169 echo 'SystemdService=wpa_supplicant.service' \
170 | tee -a dbus/*.service >/dev/null || die
171
172 cd "${WORKDIR}/${P}"
173
174 if use wimax; then
175 # generate-libeap-peer.patch comes before
176 # fix-undefined-reference-to-random_get_bytes.patch
177 epatch "${FILESDIR}/${P}-generate-libeap-peer.patch"
178 epatch "${FILESDIR}/${P}-fix-undefined-reference-to-random_get_bytes.patch"
179
180 # multilib-strict fix (bug #373685)
181 sed -e "s/\/usr\/lib/\/usr\/$(get_libdir)/" -i src/eap_peer/Makefile
182 fi
183
184 # bug (320097)
185 epatch "${FILESDIR}/${P}-do-not-call-dbus-functions-with-NULL-path.patch"
186
187 # TODO - NEED TESTING TO SEE IF STILL NEEDED, NOT COMPATIBLE WITH 1.0 OUT OF THE BOX,
188 # SO WOULD BE NICE TO JUST DROP IT, IF IT IS NOT NEEDED.
189 # bug (374089)
190 #epatch "${FILESDIR}/${P}-dbus-WPAIE-fix.patch"
191 }
192
193 src_configure() {
194 # Toolchain setup
195 tc-export CC
196
197 cp defconfig .config
198
199 # Basic setup
200 Kconfig_style_config CTRL_IFACE
201 Kconfig_style_config BACKEND file
202 Kconfig_style_config IBSS_RSN
203 Kconfig_style_config IEEE80211W
204 Kconfig_style_config IEEE80211R
205
206 # Basic authentication methods
207 # NOTE: we don't set GPSK or SAKE as they conflict
208 # with the below options
209 Kconfig_style_config EAP_GTC
210 Kconfig_style_config EAP_MD5
211 Kconfig_style_config EAP_OTP
212 Kconfig_style_config EAP_PAX
213 Kconfig_style_config EAP_PSK
214 Kconfig_style_config EAP_TLV
215 Kconfig_style_config EAP_EXE
216 Kconfig_style_config IEEE8021X_EAPOL
217 Kconfig_style_config PKCS12
218 Kconfig_style_config PEERKEY
219 Kconfig_style_config EAP_LEAP
220 Kconfig_style_config EAP_MSCHAPV2
221 Kconfig_style_config EAP_PEAP
222 Kconfig_style_config EAP_TLS
223 Kconfig_style_config EAP_TTLS
224
225 # Enabling background scanning.
226 Kconfig_style_config BGSCAN_SIMPLE
227 Kconfig_style_config BGSCAN_LEARN
228
229 if use dbus ; then
230 Kconfig_style_config CTRL_IFACE_DBUS
231 Kconfig_style_config CTRL_IFACE_DBUS_NEW
232 Kconfig_style_config CTRL_IFACE_DBUS_INTRO
233 fi
234
235 # Enable support for writing debug info to a log file.
236 Kconfig_style_config DEBUG_FILE
237
238 if use hs2.0 ; then
239 Kconfig_style_config INTERWORKING
240 Kconfig_style_config HS20
241 fi
242
243 if use uncommon-eap-types; then
244 Kconfig_style_config EAP_GPSK
245 Kconfig_style_config EAP_SAKE
246 Kconfig_style_config EAP_GPSK_SHA256
247 Kconfig_style_config EAP_IKEV2
248 Kconfig_style_config EAP_EKE
249 fi
250
251 if use eap-sim ; then
252 # Smart card authentication
253 Kconfig_style_config EAP_SIM
254 Kconfig_style_config EAP_AKA
255 Kconfig_style_config EAP_AKA_PRIME
256 Kconfig_style_config PCSC
257 fi
258
259 if use fasteap ; then
260 Kconfig_style_config EAP_FAST
261 fi
262
263 if use readline ; then
264 # readline/history support for wpa_cli
265 Kconfig_style_config READLINE
266 else
267 #internal line edit mode for wpa_cli
268 Kconfig_style_config WPA_CLI_EDIT
269 fi
270
271 # SSL authentication methods
272 if use ssl ; then
273 Kconfig_style_config TLS openssl
274 elif use gnutls ; then
275 Kconfig_style_config TLS gnutls
276 Kconfig_style_config GNUTLS_EXTRA
277 else
278 Kconfig_style_config TLS internal
279 fi
280
281 if use smartcard ; then
282 Kconfig_style_config SMARTCARD
283 fi
284
285 if use tdls ; then
286 Kconfig_style_config TDLS
287 fi
288
289 if use kernel_linux ; then
290 # Linux specific drivers
291 Kconfig_style_config DRIVER_ATMEL
292 Kconfig_style_config DRIVER_HOSTAP
293 Kconfig_style_config DRIVER_IPW
294 Kconfig_style_config DRIVER_NL80211
295 Kconfig_style_config DRIVER_RALINK
296 Kconfig_style_config DRIVER_WEXT
297 Kconfig_style_config DRIVER_WIRED
298
299 if use ps3 ; then
300 Kconfig_style_config DRIVER_PS3
301 fi
302
303 elif use kernel_FreeBSD ; then
304 # FreeBSD specific driver
305 Kconfig_style_config DRIVER_BSD
306 fi
307
308 # Wi-Fi Protected Setup (WPS)
309 if use wps ; then
310 Kconfig_style_config WPS
311 Kconfig_style_config WPS2
312 # USB Flash Drive
313 Kconfig_style_config WPS_UFD
314 # External Registrar
315 Kconfig_style_config WPS_ER
316 # Universal Plug'n'Play
317 Kconfig_style_config WPS_UPNP
318 # Near Field Communication
319 Kconfig_style_config WPS_NFC
320 fi
321
322 # Wi-Fi Direct (WiDi)
323 if use p2p ; then
324 Kconfig_style_config P2P
325 Kconfig_style_config WIFI_DISPLAY
326 fi
327
328 # Access Point Mode
329 if use ap ; then
330 Kconfig_style_config AP
331 fi
332
333 # Enable mitigation against certain attacks against TKIP
334 Kconfig_style_config DELAYED_MIC_ERROR_REPORT
335
336 # If we are using libnl 2.0 and above, enable support for it
337 # Bug 382159
338 # Removed for now, since the 3.2 version is broken, and we don't
339 # support it.
340 if has_version ">=dev-libs/libnl-3.2"; then
341 Kconfig_style_config LIBNL32
342 fi
343
344 if use qt4 ; then
345 pushd "${S}"/wpa_gui-qt4 > /dev/null
346 eqmake4 wpa_gui.pro
347 popd > /dev/null
348 fi
349 }
350
351 src_compile() {
352 einfo "Building wpa_supplicant"
353 emake V=1 BINDIR=/usr/sbin
354
355 if use wimax; then
356 emake -C ../src/eap_peer clean
357 emake -C ../src/eap_peer
358 fi
359
360 if use qt4 ; then
361 pushd "${S}"/wpa_gui-qt4 > /dev/null
362 einfo "Building wpa_gui"
363 emake
364 popd > /dev/null
365 fi
366 }
367
368 src_install() {
369 dosbin wpa_supplicant
370 dobin wpa_cli wpa_passphrase
371
372 # baselayout-1 compat
373 if has_version "<sys-apps/baselayout-2.0.0"; then
374 dodir /sbin
375 dosym /usr/sbin/wpa_supplicant /sbin/wpa_supplicant
376 dodir /bin
377 dosym /usr/bin/wpa_cli /bin/wpa_cli
378 fi
379
380 if has_version ">=sys-apps/openrc-0.5.0"; then
381 newinitd "${FILESDIR}/${PN}-init.d" wpa_supplicant
382 newconfd "${FILESDIR}/${PN}-conf.d" wpa_supplicant
383 fi
384
385 exeinto /etc/wpa_supplicant/
386 newexe "${FILESDIR}/wpa_cli.sh" wpa_cli.sh
387
388 dodoc ChangeLog {eap_testing,todo}.txt README{,-WPS} \
389 wpa_supplicant.conf
390
391 newdoc .config build-config
392
393 doman doc/docbook/*.{5,8}
394
395 if use qt4 ; then
396 into /usr
397 dobin wpa_gui-qt4/wpa_gui
398 doicon wpa_gui-qt4/icons/wpa_gui.svg
399 make_desktop_entry wpa_gui "WPA Supplicant Administration GUI" "wpa_gui" "Qt;Network;"
400 fi
401
402 use wimax && emake DESTDIR="${D}" -C ../src/eap_peer install
403
404 if use dbus ; then
405 pushd "${S}"/dbus > /dev/null
406 insinto /etc/dbus-1/system.d
407 newins dbus-wpa_supplicant.conf wpa_supplicant.conf
408 insinto /usr/share/dbus-1/system-services
409 doins fi.epitest.hostap.WPASupplicant.service fi.w1.wpa_supplicant1.service
410 popd > /dev/null
411 fi
412
413 # systemd stuff
414 systemd_dounit systemd/*.service
415 }
416
417 pkg_postinst() {
418 elog "If this is a clean installation of wpa_supplicant, you"
419 elog "have to create a configuration file named"
420 elog "/etc/wpa_supplicant/wpa_supplicant.conf"
421 elog
422 elog "An example configuration file is available for reference in"
423 elog "/usr/share/doc/${PF}/"
424
425 if [[ -e ${ROOT}etc/wpa_supplicant.conf ]] ; then
426 echo
427 ewarn "WARNING: your old configuration file ${ROOT}etc/wpa_supplicant.conf"
428 ewarn "needs to be moved to ${ROOT}etc/wpa_supplicant/wpa_supplicant.conf"
429 fi
430
431 # Mea culpa, feel free to remove that after some time --mgorny.
432 local fn
433 for fn in wpa_supplicant{,@wlan0}.service; do
434 if [[ -e "${ROOT}"/etc/systemd/system/network.target.wants/${fn} ]]
435 then
436 ebegin "Moving ${fn} to multi-user.target"
437 mv "${ROOT}"/etc/systemd/system/network.target.wants/${fn} \
438 "${ROOT}"/etc/systemd/system/multi-user.target.wants/
439 eend ${?} \
440 "Please try to re-enable ${fn}"
441 fi
442 done
443 }