mirror of
https://gitdl.cn/https://github.com/chakralinux/core.git
synced 2025-02-12 05:14:48 +08:00
50 lines
1.5 KiB
Bash
50 lines
1.5 KiB
Bash
|
|
pkgname=ndiswrapper
|
|
pkgver=1.61
|
|
pkgrel=15
|
|
pkgdesc="Module for NDIS (Windows Network Drivers) drivers supplied by vendors. For linux-testing."
|
|
license=('GPL')
|
|
arch=('x86_64')
|
|
url="http://ndiswrapper.sourceforge.net"
|
|
depends=("linux=4.18.3")
|
|
makedepends=("linux-headers=4.18.3")
|
|
provides=("ndiswrapper-utils=$pkgver")
|
|
replaces=('ndiswrapper-utils')
|
|
conflicts=('ndiswrapper-utils')
|
|
makedepends=('linux-headers')
|
|
_extramodules=extramodules-CHAKRA
|
|
source=("http://downloads.sourceforge.net/sourceforge/ndiswrapper/ndiswrapper-$pkgver.tar.gz"
|
|
'linux-4.11.patch'
|
|
'linux-4.13.patch'
|
|
'linux-4.15.patch')
|
|
sha1sums=('213854ca8a83f9b5972db8fa873d346124e4bcb5'
|
|
'4d1866b495a7929a3d21b6aebf0fa150702668b6'
|
|
'09b308bbc948acc59d33882524b53ce210bb1848'
|
|
'4a47e255e27767dd87757f159eb1fdf1ddaf4993')
|
|
|
|
KERNEL_VERSION=$(</usr/lib/modules/$_extramodules/version)
|
|
|
|
prepare() {
|
|
cd ndiswrapper-$pkgver
|
|
|
|
patch -p1 -i ../linux-4.11.patch
|
|
patch -p2 -i ../linux-4.13.patch
|
|
patch -p1 -i ../linux-4.15.patch
|
|
|
|
sed -i -e 's|strnicmp|strncasecmp|' driver/ndis.c
|
|
sed -i "/modinfo/s/s/usr\//" driver/Makefile
|
|
}
|
|
|
|
build() {
|
|
cd ndiswrapper-$pkgver
|
|
make -C driver KVERS_UNAME=${KERNEL_VERSION}
|
|
make -C utils
|
|
}
|
|
|
|
package() {
|
|
cd ndiswrapper-$pkgver
|
|
|
|
make sbindir=usr/sbin usrsbindir=usr/bin KBUILD="/usr/lib/modules/$KERNEL_VERSION/build/" INST_DIR="usr/lib/modules/$_extramodules" \
|
|
KVERS=$KERNEL_VERSION DESTDIR="$pkgdir/" install
|
|
}
|