2019-06-21 08:39:04 +00:00
|
|
|
#!/bin/sh -e
|
|
|
|
|
2020-02-24 15:04:00 +00:00
|
|
|
# The wpa_supplicant package is built statically using
|
|
|
|
# libnl-tiny which is a minimal version of libnl maintained
|
|
|
|
# by OpenWRT.
|
2022-03-26 08:45:52 +00:00
|
|
|
mv libnl-tiny* libnl.tar.gz
|
|
|
|
tar xf libnl.tar.gz
|
|
|
|
mv libnl-tiny* libnl
|
2020-02-24 15:04:00 +00:00
|
|
|
|
2022-03-26 08:45:52 +00:00
|
|
|
export CFLAGS="$CFLAGS -D_GNU_SOURCE -I$PWD/libnl/include"
|
|
|
|
export LDFLAGS="-L$PWD/libnl"
|
|
|
|
|
|
|
|
(
|
|
|
|
cd libnl
|
|
|
|
|
|
|
|
$CC $CFLAGS $CPPFLAGS -c ./*.c
|
|
|
|
ar rc libnl-tiny.a ./*.o
|
|
|
|
)
|
2020-02-24 15:04:00 +00:00
|
|
|
|
2019-06-21 08:39:04 +00:00
|
|
|
cd wpa_supplicant
|
|
|
|
|
2022-03-26 08:45:52 +00:00
|
|
|
make LIBDIR=/usr/lib BINDIR=/usr/bin
|
2021-07-18 03:30:32 +00:00
|
|
|
make LIBDIR=/usr/lib BINDIR=/usr/bin install
|
2020-08-14 06:48:18 +00:00
|
|
|
|
2021-07-01 16:35:51 +00:00
|
|
|
mkdir -p \
|
|
|
|
"$1/usr/share/man/man5" \
|
|
|
|
"$1/usr/share/man/man8"
|
2020-08-14 06:48:18 +00:00
|
|
|
|
2021-07-01 16:35:51 +00:00
|
|
|
cp -f doc/docbook/*.5 "$1/usr/share/man/man5"
|
|
|
|
cp -f doc/docbook/*.8 "$1/usr/share/man/man8"
|
2021-07-29 07:22:51 +00:00
|
|
|
|
|
|
|
# Install runit service.
|
|
|
|
mkdir -p "$1/etc/sv/wpa_supplicant"
|
|
|
|
cp -f wpa_supplicant.run "$1/etc/sv/wpa_supplicant/run"
|
|
|
|
ln -sf /run/runit/supervise.wpa_supplicant "$1/etc/sv/wpa_supplicant/supervise"
|