core/kmod/PKGBUILD

51 lines
1.2 KiB
Bash
Raw Normal View History

# Maintainer: abveritas[at]chakra-project[dot]org>
pkgname=kmod
2013-08-21 05:35:18 +08:00
pkgver=14
2012-10-07 03:53:03 +08:00
pkgrel=1
pkgdesc="Linux kernel module handling"
arch=('x86_64')
url='http://git.kernel.org/?p=utils/kernel/kmod/kmod.git;a=summary'
license=('GPL2')
depends=('glibc' 'zlib')
options=('!libtool')
provides=('module-init-tools=3.16')
conflicts=('module-init-tools')
replaces=('module-init-tools')
source=("ftp://ftp.kernel.org/pub/linux/utils/kernel/$pkgname/$pkgname-$pkgver.tar.xz"
2012-10-07 03:53:03 +08:00
"depmod-search.conf")
2013-08-21 05:35:18 +08:00
sha1sums=('a9fa2993369a285f45aef11a8a2b56e7c57a56b1'
'489b0ce0efd193aab70421a852526ed04dd026c4')
build() {
cd "$pkgname-$pkgver"
./configure \
--sysconfdir=/etc \
2012-10-07 04:34:52 +08:00
--with-zlib
make
}
check() {
make -C "$pkgname-$pkgver" check
}
2012-06-03 06:07:19 +08:00
package() {
make -C "$pkgname-$pkgver" DESTDIR="$pkgdir" install
# extra directories
2012-06-03 06:07:19 +08:00
install -dm755 "$pkgdir"/{etc,usr/lib}/{depmod,modprobe}.d "$pkgdir/sbin"
# add symlinks to kmod
ln -s ../usr/bin/kmod "$pkgdir/sbin/modprobe"
ln -s ../usr/bin/kmod "$pkgdir/sbin/depmod"
for tool in {ins,ls,rm}mod modinfo; do
ln -s kmod "$pkgdir/usr/bin/$tool"
done
# install depmod.d file for search/ dir
2012-06-03 06:07:19 +08:00
install -Dm644 "$srcdir/depmod-search.conf" "$pkgdir/usr/lib/depmod.d/search.conf"
}