annotate network/wpa-supplicant/wpa-supplicant.sh @ 1287:8c73c712e598

core/procps: upgrad to 3.3.17
author David Demelier <markand@malikania.fr>
date Tue, 16 Nov 2021 14:49:07 +0100
parents 325631424c65
children 9867e578b1a9
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1115
297b5eef115e vanilla: change shebangs to /bin/sh
David Demelier <markand@malikania.fr>
parents: 1037
diff changeset
1 #!/bin/sh
552
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
2 #
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
3 # Copyright (c) 2019 David Demelier <markand@malikania.fr>
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
4 #
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
5 # Permission to use, copy, modify, and/or distribute this software for any
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
6 # purpose with or without fee is hereby granted, provided that the above
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
7 # copyright notice and this permission notice appear in all copies.
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
8 #
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
9 # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
10 # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
11 # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
12 # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
13 # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
14 # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
15 # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
16 #
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
17
1221
a47aaf9743a0 misc: backed out changeset 4ccc42bf0284
David Demelier <markand@malikania.fr>
parents: 1220
diff changeset
18 PKGNAME=wpa-supplicant
a47aaf9743a0 misc: backed out changeset 4ccc42bf0284
David Demelier <markand@malikania.fr>
parents: 1220
diff changeset
19 PKGVERSION=2.8
a47aaf9743a0 misc: backed out changeset 4ccc42bf0284
David Demelier <markand@malikania.fr>
parents: 1220
diff changeset
20 PKGREVISION=1
a47aaf9743a0 misc: backed out changeset 4ccc42bf0284
David Demelier <markand@malikania.fr>
parents: 1220
diff changeset
21 PKGLICENSE="BSD3CLAUSE"
a47aaf9743a0 misc: backed out changeset 4ccc42bf0284
David Demelier <markand@malikania.fr>
parents: 1220
diff changeset
22 PKGSUMMARY="a utility providing key negotiation for WPA wireless networks"
a47aaf9743a0 misc: backed out changeset 4ccc42bf0284
David Demelier <markand@malikania.fr>
parents: 1220
diff changeset
23 PKGDOWNLOAD="https://w1.fi/releases/wpa_supplicant-$PKGVERSION.tar.gz"
a47aaf9743a0 misc: backed out changeset 4ccc42bf0284
David Demelier <markand@malikania.fr>
parents: 1220
diff changeset
24 PKGDEPENDS="bison:build libnl"
a47aaf9743a0 misc: backed out changeset 4ccc42bf0284
David Demelier <markand@malikania.fr>
parents: 1220
diff changeset
25 PKGOPTIONS="DBUS SSL"
552
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
26
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
27 : ${CC:=clang}
1037
c407c89fa383 network/wpa-supplicant: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
28 : ${CFLAGS:=-O2}
552
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
29 : ${DBUS:=yes}
1037
c407c89fa383 network/wpa-supplicant: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
30 : ${SSL:=libressl} # Note: can be libressl (or yes) or gnutls.
552
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
31
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
32 if [ "$DBUS" = "yes" ]; then
902
a133976e0783 vanilla: remove all origins, closes #2203
David Demelier <markand@malikania.fr>
parents: 899
diff changeset
33 PKGDEPENDS="$PKGDEPENDS dbus"
552
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
34 fi
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
35
1037
c407c89fa383 network/wpa-supplicant: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
36 case $SSL in
c407c89fa383 network/wpa-supplicant: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
37 "yes"|"libressl")
c407c89fa383 network/wpa-supplicant: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
38 PKGDEPENDS="libressl $PKGDEPENDS"
c407c89fa383 network/wpa-supplicant: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
39 with_ssl="openssl"
c407c89fa383 network/wpa-supplicant: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
40 ;;
c407c89fa383 network/wpa-supplicant: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
41 "gnutls")
c407c89fa383 network/wpa-supplicant: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
42 PKGDEPENDS="gnutls $PKGDEPENDS"
c407c89fa383 network/wpa-supplicant: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
43 with_ssl="gnutls"
c407c89fa383 network/wpa-supplicant: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
44 ;;
c407c89fa383 network/wpa-supplicant: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
45 esac
552
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
46
1222
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
47 build()
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
48 {
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
49 rm -rf wpa_supplicant-$PKGVERSION
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
50 tar xvf wpa_supplicant-$PKGVERSION.tar.gz
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
51 cd wpa_supplicant-$PKGVERSION/wpa_supplicant
552
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
52
1222
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
53 cp defconfig .config
552
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
54
1222
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
55 if [ "$DBUS" = "yes" ]; then
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
56 sed -i -e '/CONFIG_CTRL_IFACE_DBUS_NEW.*/d' .config
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
57 sed -i -e '/CONFIG_CTRL_IFACE_DBUS_INTRO.*/d' .config
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
58 fi
1037
c407c89fa383 network/wpa-supplicant: allow SSL=yes for default implementation
David Demelier <markand@malikania.fr>
parents: 1019
diff changeset
59
1222
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
60 if [ -n "$with_ssl" ]; then
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
61 sed -i -e "s/^#CONFIG_TLS.*/CONFIG_TLS=$with_ssl/" .config
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
62 fi
552
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
63
1222
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
64 make \
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
65 V=1 \
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
66 CC="$CC" \
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
67 EXTRA_CFLAGS="$CFLAGS" \
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
68 BINDIR=/bin \
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
69 LIBDIR=/lib \
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
70 DESTDIR=$DESTDIR \
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
71 all install
552
317831fa1a64 network/wpa-supplicant: initial import, closes #1620
David Demelier <markand@malikania.fr>
parents:
diff changeset
72
1222
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
73 cd ../..
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
74 rm -rf wpa_supplicant-$PKGVERSION
325631424c65 misc: bring back build function
David Demelier <markand@malikania.fr>
parents: 1221
diff changeset
75 }