linux-lts move KERNEL_VERSION inside the function call

This commit is contained in:
AlmAck 2018-09-07 22:59:07 +02:00
parent cd7afdbb90
commit dbdd9837b2
2 changed files with 4 additions and 3 deletions

View File

@ -13,7 +13,7 @@
# adding '+' in front of the pkgname cause # adding '+' in front of the pkgname cause
# a pkgrel++ only (deps version updated too) # a pkgrel++ only (deps version updated too)
# #
# GitLab-CI:0 # GitLab-CI:1
#core_packages #core_packages
linux-lts linux-lts

View File

@ -13,20 +13,21 @@ _extramodules=extramodules-CHAKRA-LTS
source=("http://downloads.sourceforge.net/sourceforge/ndiswrapper/ndiswrapper-$pkgver.tar.gz") source=("http://downloads.sourceforge.net/sourceforge/ndiswrapper/ndiswrapper-$pkgver.tar.gz")
sha1sums=('213854ca8a83f9b5972db8fa873d346124e4bcb5') sha1sums=('213854ca8a83f9b5972db8fa873d346124e4bcb5')
KERNEL_VERSION=$(</usr/lib/modules/$_extramodules/version)
prepare() { prepare() {
cd "$srcdir/$_pkgname-$pkgver" cd "$srcdir/$_pkgname-$pkgver"
sed -i "/modinfo/s/s/usr\//" driver/Makefile sed -i "/modinfo/s/s/usr\//" driver/Makefile
} }
build() { build() {
KERNEL_VERSION=$(cat /usr/lib/modules/$_extramodules/version)
cd ndiswrapper-$pkgver cd ndiswrapper-$pkgver
make -C driver KVERS_UNAME=${KERNEL_VERSION} make -C driver KVERS_UNAME=${KERNEL_VERSION}
make -C utils make -C utils
} }
package() { package() {
KERNEL_VERSION=$(cat /usr/lib/modules/$_extramodules/version)
cd ndiswrapper-$pkgver cd ndiswrapper-$pkgver
make sbindir=usr/sbin usrsbindir=usr/bin KBUILD="/usr/lib/modules/$KERNEL_VERSION/build/" INST_DIR="usr/lib/modules/$_extramodules" \ make sbindir=usr/sbin usrsbindir=usr/bin KBUILD="/usr/lib/modules/$KERNEL_VERSION/build/" INST_DIR="usr/lib/modules/$_extramodules" \