Contents of /smage/branches/alx07x-stable/core/wpa-supplicant/wpa-supplicant-2.6-r6.smage2
Parent Directory | Revision Log
Revision 11206 -
(show annotations)
(download)
Tue Dec 19 11:58:00 2017 UTC (6 years, 9 months ago) by niro
File size: 5934 byte(s)
Tue Dec 19 11:58:00 2017 UTC (6 years, 9 months ago) by niro
File size: 5934 byte(s)
-release branches/alx07x-stable
1 | # $Id$ |
2 | |
3 | PNAME="wpa-supplicant" |
4 | PVER="2.6" |
5 | PBUILD="r6" |
6 | |
7 | PCAT="net-wlan" |
8 | |
9 | DESCRIPTION="Linux WPA/WPA2/IEEE 802.1X Supplicant." |
10 | HOMEPAGE="http://hostap.epitest.fi/wpa_supplicant/" |
11 | |
12 | DEPEND=">= sys-apps/dbus-1.10 |
13 | == dev-libs/libnl3-3.2.25 |
14 | >= dev-libs/libtommath-0.42" |
15 | |
16 | SDEPEND=">= dev-util/pkgconfig-0.25 |
17 | >= virtual/sed |
18 | >= sys-apps/dbus-dev-1.10 |
19 | == dev-libs/libnl3-dev-3.2.25 |
20 | >= dev-libs/libtommath-dev-0.42" |
21 | |
22 | SRCFILE="${PNAME/-/_}-${PVER}.tar.gz" |
23 | SRCDIR="${BUILDDIR}/${PNAME/-/_}-${PVER}" |
24 | |
25 | # confd cvs revision |
26 | CONF_CVS_REV=1.3 |
27 | SKEL_CVS_REV=1.4 |
28 | |
29 | ALX_PKG_KEEP="etc/wpa_supplicant |
30 | usr/bin/wpa_supplicant |
31 | usr/bin/wpa_cli |
32 | usr/bin/wpa_passphrase |
33 | etc/dbus-1/system.d |
34 | usr/share/dbus-1/system-services |
35 | usr/lib/systemd" |
36 | sminclude mtools dbus systemd alx-split |
37 | |
38 | SRC_URI=( |
39 | http://hostap.epitest.fi/releases/${SRCFILE} |
40 | mirror://${PNAME}/${SRCFILE} |
41 | mirror://${PNAME}/confd-wpa_supplicant.skel-${SKEL_CVS_REV} |
42 | mirror://${PNAME}/confd-wpa_supplicant-${CONF_CVS_REV} |
43 | ) |
44 | |
45 | # latest stable branch |
46 | UP2TAG="release" |
47 | # latest devel branch |
48 | #UP2TAG="development" |
49 | UP2DATE="updatecmd ${HOMEPAGE} | grep -A1 'Latest ${UP2TAG}' | sed -n 's/.*-\(.*\).tar.*/\1/;$ p'" |
50 | |
51 | src_prepare() |
52 | { |
53 | local MCONFIG=${SRCDIR}/wpa_supplicant/.config |
54 | munpack ${SRCFILE} || die |
55 | cd ${SRCDIR}/wpa_supplicant |
56 | |
57 | # broken Makefile |
58 | sed -i 's@/usr/local@$(PREFIX)@g' Makefile |
59 | |
60 | # basic setup |
61 | maddconfig -b "CONFIG_CTRL_IFACE=y" || die |
62 | maddconfig -b "CONFIG_BACKEND=file" || die |
63 | maddconfig -b "CONFIG_NO_RANDOM_POOL=y" || die |
64 | |
65 | # dbus support |
66 | maddconfig -b "CONFIG_CTRL_IFACE_DBUS=y" || die |
67 | # Add support for new DBus control interface |
68 | # (fi.w1.hostap.wpa_supplicant1) |
69 | maddconfig -b "CONFIG_CTRL_IFACE_DBUS_NEW=y" || die |
70 | # Add introspection support for new DBus control interface |
71 | maddconfig -b "CONFIG_CTRL_IFACE_DBUS_INTRO=y" || die |
72 | |
73 | # not for alx |
74 | # # readline |
75 | # maddconfig -b "CONFIG_READLINE=y" || die |
76 | |
77 | # libnl-3.2 |
78 | maddconfig -b "CONFIG_LIBNL32=y" || die |
79 | |
80 | # wi-fi protected setup (WPS) support |
81 | maddconfig -b "CONFIG_WPS=y" || die |
82 | # enable WPS support with NFC config method |
83 | maddconfig -b "CONFIG_WPS_NFC=y" || die |
84 | |
85 | # # enable mitigation against certain attacks against TKIP |
86 | # maddconfig -b "CONFIG_DELAYED_MIC_ERROR_REPORT=y" || die |
87 | |
88 | # # no debug |
89 | # maddconfig -b "CONFIG_NO_STDOUT_DEBUG=y" || die |
90 | |
91 | # add support for writing debug log to a file (/tmp/wpa_supplicant-log-#.txt) |
92 | maddconfig -b "CONFIG_DEBUG_FILE=y" || die |
93 | |
94 | # support HT overrides (disable HT/HT40, mask MCS rates, etc.) |
95 | maddconfig -b "CONFIG_HT_OVERRIDES=y" || die |
96 | |
97 | # AP mode operations |
98 | maddconfig -b "CONFIG_AP=y" || die |
99 | |
100 | # P2P (Wi-Fi Direct) |
101 | maddconfig -b "CONFIG_P2P=y" || die |
102 | |
103 | # autoscan |
104 | maddconfig -b "CONFIG_AUTOSCAN_EXPONENTIAL=y" || die |
105 | # for periodic module: |
106 | maddconfig -b "CONFIG_AUTOSCAN_PERIODIC=y" || die |
107 | |
108 | # RSN IBSS/AdHoc support |
109 | maddconfig -b "CONFIG_IBSS_RSN=y" || die |
110 | |
111 | # simple background scan |
112 | maddconfig -b "CONFIG_BGSCAN_SIMPLE=y" || die |
113 | |
114 | # basic authentication methods |
115 | maddconfig -b "CONFIG_EAP_GTC=y" || die |
116 | maddconfig -b "CONFIG_EAP_MD5=y" || die |
117 | maddconfig -b "CONFIG_EAP_OTP=y" || die |
118 | # maddconfig -b "CONFIG_EAP_PSK=y" || die |
119 | maddconfig -b "CONFIG_IEEE8021X_EAPOL=y" || die |
120 | maddconfig -b "CONFIG_PKCS12=y" || die |
121 | # maddconfig -b "CONFIG_PAX=y" || die |
122 | # maddconfig -b "CONFIG_TLV=y" || die |
123 | maddconfig -b "CONFIG_PEERKEY=y" || die |
124 | # maddconfig -b "CONFIG_EAP_PAX=y" || die |
125 | # maddconfig -b "CONFIG_EAP_TLV=y" || die |
126 | |
127 | # ssl authentication methods |
128 | # alx has no openssl but libtommath |
129 | # maddconfig -b "CONFIG_TLS=openssl" || die |
130 | # needs libtommath but is a very small replacement for openssl |
131 | maddconfig -b "CONFIG_TLS=internal" || die |
132 | maddconfig -b "CONFIG_EAP_LEAP=y" || die |
133 | maddconfig -b "CONFIG_EAP_MSCHAPV2=y" || die |
134 | maddconfig -b "CONFIG_EAP_PEAP=y" || die |
135 | maddconfig -b "CONFIG_EAP_TLS=y" || die |
136 | maddconfig -b "CONFIG_EAP_TTLS=y" || die |
137 | maddconfig -b "CONFIG_SMARTCARD=y" || die |
138 | |
139 | # linux specific drivers |
140 | # maddconfig -b "CONFIG_WIRELESS_EXTENSION=y" || die |
141 | # maddconfig -b "CONFIG_DRIVER_ATMEL=y" || die |
142 | # maddconfig -b "CONFIG_DRIVER_HOSTAP=y" || die |
143 | # maddconfig -b "CONFIG_DRIVER_IPW=y" || die |
144 | # maddconfig -b "CONFIG_DRIVER_NDISWRAPPER=y" || die |
145 | maddconfig -b "CONFIG_DRIVER_NL80211=y" || die |
146 | # maddconfig -b "CONFIG_DRIVER_PRISM54=y" || die |
147 | # maddconfig -b "CONFIG_DRIVER_RALINK=y" || die |
148 | maddconfig -b "CONFIG_DRIVER_WEXT=y" || die |
149 | maddconfig -b "CONFIG_DRIVER_WIRED=y" || die |
150 | # maddconfig -b "CONFIG_DRIVER_BROADCOM=y" || die |
151 | # maddconfig -b "CONFIG_DRIVER_HERMES=y" || die |
152 | # needs madwifi headers |
153 | # maddconfig -b "CONFIG_DRIVER_MADWIFI=y" || die |
154 | } |
155 | |
156 | src_compile() |
157 | { |
158 | cd ${SRCDIR}/wpa_supplicant |
159 | mmake PREFIX=/usr BINDIR=/usr/bin LIBDIR=/usr/$(mlibdir) || die |
160 | } |
161 | |
162 | alx_generic_src_install() |
163 | { |
164 | cd ${SRCDIR}/wpa_supplicant |
165 | make PREFIX=/usr BINDIR=/usr/bin LIBDIR=/usr/$(mlibdir) DESTDIR=${BINDIR} install || die |
166 | |
167 | # config sample |
168 | minstalldir /usr/share/wpa_supplicant || die |
169 | minstallfile wpa_supplicant.conf /usr/share/wpa_supplicant || die |
170 | |
171 | # skeletons |
172 | minstallconf confd-wpa_supplicant.skel-${SKEL_CVS_REV} wpa_supplicant.skel || die |
173 | |
174 | # rc-config |
175 | minstallconf confd-wpa_supplicant-${CONF_CVS_REV} wpa_supplicant || die |
176 | |
177 | # dbus |
178 | minstalldbusconfig dbus/dbus-wpa_supplicant.conf wpa_supplicant.conf || die |
179 | minstalldbussystemservice dbus/fi.epitest.hostap.WPASupplicant.service || die |
180 | minstalldbussystemservice dbus/fi.w1.wpa_supplicant1.service || die |
181 | |
182 | # systemd services |
183 | local i |
184 | for i in systemd/*.service |
185 | do |
186 | minstallunit "${i}" || die "${i}" |
187 | done |
188 | |
189 | # man pages |
190 | minstallman doc/docbook/*.8 || die |
191 | minstallman doc/docbook/*.5 || die |
192 | # but not priv pages |
193 | rm -f ${BINDIR}/usr/share/man/man8/wpa_{priv,gui}.8 || die |
194 | |
195 | minstalldocs COPYING wpa_supplicant/ChangeLog wpa_supplicant/README* || die |
196 | } |
197 | |
198 | preinstall() |
199 | { |
200 | add_conf_prot_mask /etc/wpa_supplicant |
201 | } |
202 | |
203 | postinstall() |
204 | { |
205 | mreloadunit dbus.service |
206 | mstartunit wpa_supplicant.service |
207 | } |
208 | |
209 | postremove() |
210 | { |
211 | mreloadunit dbus.service |
212 | mstopunit wpa_supplicant.service |
213 | } |