# $Id: PKGBUILD 146297 2012-01-08 22:05:13Z dreisner $ # Maintainer: Dave Reisner pkgname=kmod pkgver=3 pkgrel=5 pkgdesc="Linux kernel module handling" arch=('i686' 'x86_64') url="http://git.profusion.mobi/cgit.cgi/kmod.git" license=('GPL2') depends=('glibc' 'zlib') options=('!libtool') provides=('module-init-tools=3.16') conflicts=('module-init-tools') replaces=('module-init-tools') source=("http://packages.profusion.mobi/$pkgname/$pkgname-$pkgver.tar.xz" "depmod-search.conf" "return-non-zero-on-fail.patch" "use-path-max-for-alias-names.patch" "fix-error-path-when-loading-deps.patch") md5sums=('bc0e69f75c2ac22c091f05e166e86c5d' '4b8cbcbc54b9029c99fd730e257d4436' '4be6f783a7fc2d1747ccaa2536d2e88f' '4d801693a6788236b4ed578c24514d62' 'd0f01e506e825156760e6129f04eea28') build() { cd "$pkgname-$pkgver" patch -Np1 <"$srcdir/return-non-zero-on-fail.patch" patch -Np1 <"$srcdir/use-path-max-for-alias-names.patch" patch -Np1 <"$srcdir/fix-error-path-when-loading-deps.patch" ./configure \ --sysconfdir=/etc \ --with-rootprefix= \ --with-rootlibdir=/lib \ --with-zlib make } check() { make -C "$pkgname-$pkgver" check } package() { make -C "$pkgname-$pkgver" DESTDIR="$pkgdir" install # binary directories install -dm755 "$pkgdir"/{,s}bin # configuration directories install -dm755 "$pkgdir"/{etc,lib}/{depmod,modprobe}.d # add symlinks to kmod ln -s /usr/bin/kmod "$pkgdir/bin/lsmod" for tool in {ins,rm,dep}mod mod{info,probe}; do ln -s ../usr/bin/kmod "$pkgdir/sbin/$tool" done # install depmod.d file for search/ dir install -Dm644 "$srcdir/depmod-search.conf" "$pkgdir/lib/depmod.d/search.conf" } # vim: ft=sh syn=sh et