wpa_supplicant: added systemd build option.
This commit is contained in:
parent
bfed390d6e
commit
18396bd3c6
1 changed files with 16 additions and 16 deletions
|
@ -1,7 +1,7 @@
|
|||
# Template file for 'wpa_supplicant'
|
||||
pkgname=wpa_supplicant
|
||||
version=2.2
|
||||
revision=2
|
||||
revision=3
|
||||
build_wrksrc=$pkgname
|
||||
short_desc="WPA/WPA2/IEEE 802.1X Supplicant"
|
||||
maintainer="Juan RP <xtraeme@gmail.com>"
|
||||
|
@ -14,6 +14,8 @@ hostmakedepends="pkg-config"
|
|||
makedepends="libnl3-devel libressl-devel dbus-devel readline-devel>=6.3"
|
||||
conf_files="/etc/${pkgname}/${pkgname}.conf"
|
||||
|
||||
build_options="systemd"
|
||||
|
||||
pre_build() {
|
||||
sed -i 's|/usr/local|$(PREFIX)|g' Makefile
|
||||
cp -f ${FILESDIR}/config .config
|
||||
|
@ -27,30 +29,28 @@ do_build() {
|
|||
do_install() {
|
||||
make PREFIX=/usr BINDIR=/usr/bin DESTDIR=${DESTDIR} install
|
||||
|
||||
vinstall ${FILESDIR}/${pkgname}.tmpfiles.d \
|
||||
644 usr/lib/tmpfiles.d ${pkgname}.conf
|
||||
vinstall ${FILESDIR}/${pkgname}.conf 644 etc/$pkgname
|
||||
vsconf wpa_supplicant.conf
|
||||
|
||||
vinstall wpa_supplicant.conf 644 usr/share/examples/${pkgname}
|
||||
for d in 5 8; do
|
||||
install -d ${DESTDIR}/usr/share/man/man${d}
|
||||
done
|
||||
install -m644 doc/docbook/*.5 ${DESTDIR}/usr/share/man/man5
|
||||
install -m644 doc/docbook/*.8 ${DESTDIR}/usr/share/man/man8
|
||||
install -d ${DESTDIR}/usr/share/dbus-1/system-services
|
||||
install -m644 dbus/*.service \
|
||||
${DESTDIR}/usr/share/dbus-1/system-services/
|
||||
vinstall dbus/dbus-${pkgname}.conf 644 \
|
||||
etc/dbus-1/system.d ${pkgname}.conf
|
||||
install -m644 dbus/*.service ${DESTDIR}/usr/share/dbus-1/system-services/
|
||||
vinstall dbus/dbus-${pkgname}.conf 644 etc/dbus-1/system.d ${pkgname}.conf
|
||||
|
||||
vmkdir usr/lib/systemd/system
|
||||
install -m644 systemd/*.service ${DESTDIR}/usr/lib/systemd/system
|
||||
|
||||
# Fix wpa_supplicant@.service to respect instance name.
|
||||
sed -e 's,wpa_supplicant@wlan0.service,wpa_supplicant@%i.service,' -i \
|
||||
${DESTDIR}/usr/lib/systemd/system/wpa_supplicant@.service
|
||||
# Make wpa_supplicant@.service also work for wext (nl80211 is the default).
|
||||
sed -e 's|-i%I|& -Dnl80211,wext|' -i ${DESTDIR}/usr/lib/systemd/system/wpa_supplicant@.service
|
||||
if [ "$build_option_systemd" ]; then
|
||||
vinstall ${FILESDIR}/${pkgname}.tmpfiles.d 644 usr/lib/tmpfiles.d ${pkgname}.conf
|
||||
vmkdir usr/lib/systemd/system
|
||||
install -m644 systemd/*.service ${DESTDIR}/usr/lib/systemd/system
|
||||
# Fix wpa_supplicant@.service to respect instance name.
|
||||
sed -e 's,wpa_supplicant@wlan0.service,wpa_supplicant@%i.service,' -i \
|
||||
${DESTDIR}/usr/lib/systemd/system/wpa_supplicant@.service
|
||||
# Make wpa_supplicant@.service also work for wext (nl80211 is the default).
|
||||
sed -e 's|-i%I|& -Dnl80211,wext|' -i ${DESTDIR}/usr/lib/systemd/system/wpa_supplicant@.service
|
||||
fi
|
||||
|
||||
vinstall README 644 usr/share/licenses/$pkgname LICENSE
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue