summaryrefslogtreecommitdiff
path: root/libre/bbswitch
diff options
context:
space:
mode:
authorAndré Fabian Silva Delgado <emulatorman@parabola.nu>2017-02-21 13:12:00 -0300
committerAndré Fabian Silva Delgado <emulatorman@parabola.nu>2017-02-21 13:12:57 -0300
commitf56ba8f1996951923ec99508efd6688d518fe90f (patch)
treedd5a42d6595ca9f9b95965645cb8a244d649940d /libre/bbswitch
parentc7759b72cc7b72037e9142d71ffaa5ca84dd74b3 (diff)
downloadabslibre-f56ba8f1996951923ec99508efd6688d518fe90f.tar.gz
abslibre-f56ba8f1996951923ec99508efd6688d518fe90f.tar.bz2
abslibre-f56ba8f1996951923ec99508efd6688d518fe90f.zip
bbswitch: minor fix
Diffstat (limited to 'libre/bbswitch')
-rw-r--r--libre/bbswitch/PKGBUILD19
1 files changed, 12 insertions, 7 deletions
diff --git a/libre/bbswitch/PKGBUILD b/libre/bbswitch/PKGBUILD
index ff931a0ff..2c2ff169d 100644
--- a/libre/bbswitch/PKGBUILD
+++ b/libre/bbswitch/PKGBUILD
@@ -64,17 +64,22 @@ _package() {
gzip "${pkgdir}/usr/lib/modules/${_extramodules}/${pkgbase}.ko"
}
-_package-dkms() {
- depends=('dkms')
+if [[ ${_kernelname} == "" ]]; then
+ _package-dkms() {
+ depends=('dkms')
- cd "${srcdir}/${pkgbase}-${pkgver}"
+ cd "${srcdir}/${pkgbase}-${pkgver}"
- install -dm755 "${pkgdir}/usr/src/${pkgbase}-${pkgver}/"
+ install -dm755 "${pkgdir}/usr/src/${pkgbase}-${pkgver}/"
- install -Dm644 Makefile bbswitch.c dkms/dkms.conf "${pkgdir}/usr/src/${pkgbase}-${pkgver}/"
-}
+ install -Dm644 Makefile bbswitch.c dkms/dkms.conf "${pkgdir}/usr/src/${pkgbase}-${pkgver}/"
+ }
+
+ pkgname=("${pkgbase}${_kernelname}" "${pkgbase}${_kernelname}-dkms")
+else
+ pkgname=("${pkgbase}${_kernelname}")
+fi
-pkgname=("${pkgbase}${_kernelname}" "${pkgbase}${_kernelname}-dkms")
for _p in ${pkgname[@]}; do
eval "package_${_p}() {
$(declare -f "_package${_p#${pkgbase}${_kernelname}}")