summaryrefslogtreecommitdiffstats
path: root/abs/core-testing/klibc-module-init-tools/PKGBUILD
blob: a7d6884c2cb0bd3272a8db3e1afd2163d2c38993 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# $Id: PKGBUILD 23617 2009-01-11 14:11:13Z thomas $
# Maintainer: Thomas Baechler <thomas@archlinux.org>

pkgname=klibc-module-init-tools
pkgver=3.5
pkgrel=30
pkgdesc="Utilities for inserting and removing modules from the Linux kernel"
arch=(i686 x86_64)
url="http://www.kernel.org"
license=('GPL')
groups=('base')
depends=('klibc' $(basename /lib/klibc-*.so .so))
source=(http://www.kernel.org/pub/linux/utils/kernel/module-init-tools/module-init-tools-$pkgver.tar.bz2)
md5sums=('2b47686247fc9a99bfdb9dd1d1d80e6f')

build() {
  cd $startdir/src/module-init-tools-$pkgver
  CFLAGS="${CFLAGS} -DCONFIG_NO_BACKWARDS_COMPAT" CC=klcc LD=klcc ./configure --prefix=/usr/lib/klibc
  # klibc lacks getc_unlocked, so use getc instead
  sed 's|getc_unlocked|getc|g' -i *.c
  make || return 1
  INSTALL=/bin/install make DESTDIR=$startdir/pkg install || return 1
  rm -f $startdir/pkg/usr/lib/klibc/sbin/{generate-modprobe.conf,insmod.static}
  rm -rf $startdir/pkg/usr/lib/klibc/{share,man}
}