2 # Contributor: Bartłomiej Piotrowski <bpiotrowski@archlinux.org>
3 # Contributor: Thomas Bächler <thomas@archlinux.org>
10 pkgdesc='A utility providing key negotiation for WPA wireless networks'
11 url='https://w1.fi/wpa_supplicant/'
14 depends=(openssl libdbus readline libnl pcsclite)
15 install=wpa_supplicant.install
17 https://w1.fi/releases/${pkgname}-${pkgver}.tar.gz{,.asc}
19 wpa_supplicant_tls.patch
20 wpa_supplicant_dbus_service_syslog.patch
21 wpa_supplicant_service_ignore-on-isolate.patch
22 wpa_supplicant-legacy-server-connect.patch
23 lower_security_level_for_tls_1.patch
24 disable-eapol-werror.patch
25 0001-nl80211-add-extra-ies-only-if-allowed-by-driver.patch
26 0002-AP-guard-FT-SAE-code-with-CONFIG_IEEE80211R_AP.patch
28 validpgpkeys=('EC4AA0A991A5F2464582D52D2B6EF432EFC895FA') # Jouni Malinen
29 sha256sums=('20df7ae5154b3830355f8ab4269123a87affdea59fe74fe9292a91d0d7e17b2f'
31 '1e32af4a1a147ee75358fd0b5636fb41332a7b91ec7a904292178256f735e9d2'
32 '08915b040d03a3e07cdc8ea6c76b497e00059e01ce85b67413dfe41d4fc68992'
33 '60f6a1cf2e124813dfce1da78ee1818e2ff5236aafa4113c7ae3b3f2a0b84006'
34 'd42bdbf3d4980b9f0a819612df0c39843c7e96c8afcb103aa656c824f93790b0'
35 '8fba11e4a5056d9e710707ded93341f61fdfef6c64ced992e3936cbd2d41a011'
36 'c3c0fb363f734c1512d24fd749b3ff7515f961b27bfadd04c128434b5c9f4a93'
37 '9aca193cc26682765467cf9131240e5de71f9b49a765a934284da5e308ea904e'
38 '7901d42eda48f82106901cbeb5e7be39025c878d5085a0a0d54ccbe36c3ecef4'
39 '24e844b0a08fe3fede1676cedfe29643375ae56ab1a5fe4f5783765a7b759c15')
44 # More permissive TLS fallback
45 patch -Np1 -i ../wpa_supplicant_tls.patch
47 # Unit improvements from Ubuntu
48 patch -Np1 -i ../wpa_supplicant_dbus_service_syslog.patch
50 # More unit improvements from Ubuntu
51 patch -Np1 -i ../wpa_supplicant_service_ignore-on-isolate.patch
53 # https://bugzilla.redhat.com/show_bug.cgi?id=2072070#c24
54 patch -Np1 -i ../wpa_supplicant-legacy-server-connect.patch
56 # http://lists.infradead.org/pipermail/hostap/2022-May/040571.html
57 # https://bugs.archlinux.org/task/76474
58 patch -Np1 -i ../lower_security_level_for_tls_1.patch
60 # https://salsa.debian.org/debian/wpa/-/commit/13e1d28e4f987a220c546df94df86bb9b2371874
61 patch -Np1 -i ../disable-eapol-werror.patch
63 # http://lists.infradead.org/pipermail/hostap/2022-January/040178.html
64 patch -Np1 -i ../0001-nl80211-add-extra-ies-only-if-allowed-by-driver.patch
66 # https://lists.infradead.org/pipermail/hostap/2022-April/040352.html
67 patch -Np1 -i ../0002-AP-guard-FT-SAE-code-with-CONFIG_IEEE80211R_AP.patch
69 cp ../wpa_supplicant_config $pkgname/.config
73 cd $pkgname-$pkgver/$pkgname
75 make LIBDIR=/usr/lib BINDIR=/usr/bin
76 make LIBDIR=/usr/lib BINDIR=/usr/bin eapol_test
80 cd $pkgname-$pkgver/$pkgname
82 make LIBDIR=/usr/lib BINDIR=/usr/bin DESTDIR="$pkgdir" install
84 install -Dm755 eapol_test "$pkgdir/usr/bin/eapol_test"
86 install -dm755 "$pkgdir/etc/wpa_supplicant"
87 install -Dm644 wpa_supplicant.conf -t "$pkgdir/usr/share/doc/wpa_supplicant"
89 install -Dm644 dbus/fi.w1.wpa_supplicant1.service \
90 -t "$pkgdir/usr/share/dbus-1/system-services"
92 install -Dm644 dbus/dbus-wpa_supplicant.conf \
93 "$pkgdir/usr/share/dbus-1/system.d/wpa_supplicant.conf"
95 install -Dm644 doc/docbook/*.5 -t "$pkgdir/usr/share/man/man5"
96 install -Dm644 doc/docbook/*.8 -t "$pkgdir/usr/share/man/man8"
97 rm "$pkgdir"/usr/share/man/man8/wpa_{priv,gui}.8
99 install -Dm644 systemd/*.service -t "$pkgdir/usr/lib/systemd/system"