Gentoo Archives: gentoo-commits

From: "Bjarke Istrup Pedersen (gurligebis)" <gurligebis@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in net-wireless/wpa_supplicant: ChangeLog wpa_supplicant-0.7.2-r2.ebuild wpa_supplicant-0.7.2-r1.ebuild
Date: Sat, 29 May 2010 09:55:03
Message-Id: 20100529095459.9BB852CF37@corvid.gentoo.org
1 gurligebis 10/05/29 09:54:59
2
3 Modified: ChangeLog
4 Added: wpa_supplicant-0.7.2-r2.ebuild
5 Removed: wpa_supplicant-0.7.2-r1.ebuild
6 Log:
7 Fixing bug #321627
8 (Portage version: 2.2_rc67/cvs/Linux i686)
9
10 Revision Changes Path
11 1.137 net-wireless/wpa_supplicant/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-wireless/wpa_supplicant/ChangeLog?rev=1.137&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-wireless/wpa_supplicant/ChangeLog?rev=1.137&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-wireless/wpa_supplicant/ChangeLog?r1=1.136&r2=1.137
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/net-wireless/wpa_supplicant/ChangeLog,v
20 retrieving revision 1.136
21 retrieving revision 1.137
22 diff -u -r1.136 -r1.137
23 --- ChangeLog 19 May 2010 18:29:10 -0000 1.136
24 +++ ChangeLog 29 May 2010 09:54:59 -0000 1.137
25 @@ -1,6 +1,13 @@
26 # ChangeLog for net-wireless/wpa_supplicant
27 # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/net-wireless/wpa_supplicant/ChangeLog,v 1.136 2010/05/19 18:29:10 chutzpah Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/net-wireless/wpa_supplicant/ChangeLog,v 1.137 2010/05/29 09:54:59 gurligebis Exp $
30 +
31 +*wpa_supplicant-0.7.2-r2 (29 May 2010)
32 +
33 + 29 May 2010; Bjarke Istrup Pedersen <gurligebis@g.o>
34 + -wpa_supplicant-0.7.2-r1.ebuild, +wpa_supplicant-0.7.2-r2.ebuild,
35 + +files/fix-ssid-combo.patch:
36 + Fixing bug #321627
37
38 *wpa_supplicant-0.7.2-r1 (19 May 2010)
39
40
41
42
43 1.1 net-wireless/wpa_supplicant/wpa_supplicant-0.7.2-r2.ebuild
44
45 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-wireless/wpa_supplicant/wpa_supplicant-0.7.2-r2.ebuild?rev=1.1&view=markup
46 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-wireless/wpa_supplicant/wpa_supplicant-0.7.2-r2.ebuild?rev=1.1&content-type=text/plain
47
48 Index: wpa_supplicant-0.7.2-r2.ebuild
49 ===================================================================
50 # Copyright 1999-2010 Gentoo Foundation
51 # Distributed under the terms of the GNU General Public License v2
52 # $Header: /var/cvsroot/gentoo-x86/net-wireless/wpa_supplicant/wpa_supplicant-0.7.2-r2.ebuild,v 1.1 2010/05/29 09:54:59 gurligebis Exp $
53
54 EAPI="2"
55
56 inherit eutils toolchain-funcs qt4-r2
57
58 DESCRIPTION="IEEE 802.1X/WPA supplicant for secure wireless transfers"
59 HOMEPAGE="http://hostap.epitest.fi/wpa_supplicant/"
60 SRC_URI="http://hostap.epitest.fi/releases/${P}.tar.gz"
61 LICENSE="|| ( GPL-2 BSD )"
62
63 SLOT="0"
64 KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~x86 ~x86-fbsd"
65 IUSE="dbus debug gnutls eap-sim fasteap madwifi ps3 qt4 readline ssl wps kernel_linux kernel_FreeBSD"
66
67 DEPEND="dbus? ( sys-apps/dbus )
68 kernel_linux? (
69 eap-sim? ( sys-apps/pcsc-lite )
70 madwifi? ( ||
71 ( >net-wireless/madwifi-ng-tools-0.9.3
72 net-wireless/madwifi-old )
73 )
74 dev-libs/libnl
75 )
76 !kernel_linux? ( net-libs/libpcap )
77 qt4? ( x11-libs/qt-gui:4
78 x11-libs/qt-svg:4 )
79 readline? ( sys-libs/ncurses sys-libs/readline )
80 ssl? ( dev-libs/openssl )
81 !ssl? ( gnutls? ( net-libs/gnutls ) )
82 !ssl? ( !gnutls? ( dev-libs/libtommath ) )
83 dev-util/pkgconfig"
84 RDEPEND="${DEPEND}"
85
86 S="${WORKDIR}/${P}/${PN}"
87
88 pkg_setup() {
89 if use fasteap && (use gnutls || use ssl) ; then
90 die "If you use fasteap, you must build with wpa_supplicant's internal TLS implementation. That is, both 'gnutls' and 'ssl' USE flags must be disabled"
91 fi
92
93 if use gnutls && use ssl ; then
94 einfo "You have both 'gnutls' and 'ssl' USE flags enabled: defaulting to USE=\"ssl\""
95 fi
96 }
97
98 src_prepare() {
99 # net/bpf.h needed for net-libs/libpcap on Gentoo/FreeBSD
100 sed -i \
101 -e "s:\(#include <pcap\.h>\):#include <net/bpf.h>\n\1:" \
102 ../src/l2_packet/l2_packet_freebsd.c || die
103
104 # People seem to take the example configuration file too literally (bug #102361)
105 sed -i \
106 -e "s:^\(opensc_engine_path\):#\1:" \
107 -e "s:^\(pkcs11_engine_path\):#\1:" \
108 -e "s:^\(pkcs11_module_path\):#\1:" \
109 wpa_supplicant.conf || die
110
111 # Change configuration to match Gentoo locations (bug #143750)
112 sed -i \
113 -e "s:/usr/lib/opensc:/usr/$(get_libdir):" \
114 -e "s:/usr/lib/pkcs11:/usr/$(get_libdir):" \
115 wpa_supplicant.conf || die
116
117 epatch "${FILESDIR}/${P}-dbus_path_fix.patch"
118
119 # bug (320097)
120 epatch "${FILESDIR}/do-not-call-dbus-functions-with-NULL-path.patch"
121
122 # bug (321627)
123 epatch "${FILESDIR}/fix-ssid-combo.patch"
124 }
125
126 src_configure() {
127 # Toolchain setup
128 echo "CC = $(tc-getCC)" > .config
129
130 # Basic setup
131 echo "CONFIG_CTRL_IFACE=y" >> .config
132 echo "CONFIG_BACKEND=file" >> .config
133
134 # Basic authentication methods
135 # NOTE: we don't set GPSK or SAKE as they conflict
136 # with the below options
137 echo "CONFIG_EAP_GTC=y" >> .config
138 echo "CONFIG_EAP_MD5=y" >> .config
139 echo "CONFIG_EAP_OTP=y" >> .config
140 echo "CONFIG_EAP_PAX=y" >> .config
141 echo "CONFIG_EAP_PSK=y" >> .config
142 echo "CONFIG_EAP_TLV=y" >> .config
143 echo "CONFIG_IEEE8021X_EAPOL=y" >> .config
144 echo "CONFIG_PKCS12=y" >> .config
145 echo "CONFIG_PEERKEY=y" >> .config
146 echo "CONFIG_EAP_LEAP=y" >> .config
147 echo "CONFIG_EAP_MSCHAPV2=y" >> .config
148 echo "CONFIG_EAP_PEAP=y" >> .config
149 echo "CONFIG_EAP_TLS=y" >> .config
150 echo "CONFIG_EAP_TTLS=y" >> .config
151
152 if use dbus ; then
153 echo "CONFIG_CTRL_IFACE_DBUS=y" >> .config
154 fi
155
156 if use debug ; then
157 echo "CONFIG_DEBUG_FILE=y" >> .config
158 fi
159
160 if use eap-sim ; then
161 # Smart card authentication
162 echo "CONFIG_EAP_SIM=y" >> .config
163 echo "CONFIG_EAP_AKA=y" >> .config
164 echo "CONFIG_EAP_AKA_PRIME=y" >> .config
165 echo "CONFIG_PCSC=y" >> .config
166 fi
167
168 if use fasteap ; then
169 echo "CONFIG_EAP_FAST=y" >> .config
170 fi
171
172 if use readline ; then
173 # readline/history support for wpa_cli
174 echo "CONFIG_READLINE=y" >> .config
175 fi
176
177 # SSL authentication methods
178 if use ssl ; then
179 echo "CONFIG_TLS=openssl" >> .config
180 echo "CONFIG_SMARTCARD=y" >> .config
181 elif use gnutls ; then
182 echo "CONFIG_TLS=gnutls" >> .config
183 echo "CONFIG_GNUTLS_EXTRA=y" >> .config
184 else
185 echo "CONFIG_TLS=internal" >> .config
186 fi
187
188 if use kernel_linux ; then
189 # Linux specific drivers
190 echo "CONFIG_DRIVER_ATMEL=y" >> .config
191 #echo "CONFIG_DRIVER_BROADCOM=y" >> .config
192 #echo "CONFIG_DRIVER_HERMES=y" >> .config
193 echo "CONFIG_DRIVER_HOSTAP=y" >> .config
194 echo "CONFIG_DRIVER_IPW=y" >> .config
195 echo "CONFIG_DRIVER_NDISWRAPPER=y" >> .config
196 echo "CONFIG_DRIVER_NL80211=y" >> .config
197 #echo "CONFIG_DRIVER_PRISM54=y" >> .config
198 echo "CONFIG_DRIVER_RALINK=y" >> .config
199 echo "CONFIG_DRIVER_WEXT=y" >> .config
200 echo "CONFIG_DRIVER_WIRED=y" >> .config
201
202 if use madwifi ; then
203 # Add include path for madwifi-driver headers
204 echo "CFLAGS += -I/usr/include/madwifi" >> .config
205 echo "CONFIG_DRIVER_MADWIFI=y" >> .config
206 fi
207
208 if use ps3 ; then
209 echo "CONFIG_DRIVER_PS3=y" >> .config
210 fi
211
212 elif use kernel_FreeBSD ; then
213 # FreeBSD specific driver
214 echo "CONFIG_DRIVER_BSD=y" >> .config
215 fi
216
217 # Wi-Fi Protected Setup (WPS)
218 if use wps ; then
219 echo "CONFIG_WPS=y" >> .config
220 fi
221
222 # Enable mitigation against certain attacks against TKIP
223 echo "CONFIG_DELAYED_MIC_ERROR_REPORT=y" >> .config
224
225 if use qt4 ; then
226 cd "${S}"/wpa_gui-qt4
227 eqmake4 wpa_gui.pro
228 fi
229 }
230
231 src_compile() {
232 einfo "Building wpa_supplicant"
233 emake || die "emake failed"
234
235 if use qt4 ; then
236 cd "${S}"/wpa_gui-qt4
237 einfo "Building wpa_gui"
238 emake || die "wpa_gui compilation failed"
239 fi
240 }
241
242 src_install() {
243 dosbin wpa_supplicant || die
244 dobin wpa_cli wpa_passphrase || die
245
246 # baselayout-1 compat
247 if has_version "<sys-apps/baselayout-2.0.0"; then
248 dodir /sbin
249 dosym /usr/sbin/wpa_supplicant /sbin/wpa_supplicant || die
250 dodir /bin
251 dosym /usr/bin/wpa_cli /bin/wpa_cli || die
252 fi
253
254 if has_version ">=sys-apps/openrc-0.5.0"; then
255 newinitd "$FILESDIR"/${PN}-init.d wpa_supplicant
256 newconfd "$FILESDIR"/${PN}-conf.d wpa_supplicant
257 fi
258
259 exeinto /etc/wpa_supplicant/
260 newexe "${FILESDIR}"/wpa_cli.sh wpa_cli.sh
261
262 dodoc ChangeLog {eap_testing,todo}.txt README{,-WPS} \
263 wpa_supplicant.conf || die "dodoc failed"
264
265 doman doc/docbook/*.{5,8} || die "doman failed"
266
267 if use qt4 ; then
268 into /usr
269 dobin wpa_gui-qt4/wpa_gui || die
270 doicon wpa_gui-qt4/icons/wpa_gui.svg || die "Icon not found"
271 make_desktop_entry wpa_gui "WPA Supplicant Administration GUI" "wpa_gui" "Qt;Network;"
272 fi
273
274 if use dbus ; then
275 cd "${S}"/dbus
276 insinto /etc/dbus-1/system.d
277 newins dbus-wpa_supplicant.conf wpa_supplicant.conf || die
278 insinto /usr/share/dbus-1/system-services
279 doins fi.epitest.hostap.WPASupplicant.service || die
280 keepdir /var/run/wpa_supplicant
281 fi
282 }
283
284 pkg_postinst() {
285 einfo "If this is a clean installation of wpa_supplicant, you"
286 einfo "have to create a configuration file named"
287 einfo "/etc/wpa_supplicant/wpa_supplicant.conf"
288 einfo
289 einfo "An example configuration file is available for reference in"
290 einfo "/usr/share/doc/${PF}/"
291
292 if [[ -e ${ROOT}etc/wpa_supplicant.conf ]] ; then
293 echo
294 ewarn "WARNING: your old configuration file ${ROOT}etc/wpa_supplicant.conf"
295 ewarn "needs to be moved to ${ROOT}etc/wpa_supplicant/wpa_supplicant.conf"
296 fi
297
298 if use madwifi ; then
299 echo
300 einfo "This package compiles against the headers installed by"
301 einfo "madwifi-old, madwifi-ng or madwifi-ng-tools."
302 einfo "You should re-emerge ${PN} after upgrading these packages."
303 fi
304 }