wok view module-init-tools/receipt @ rev 5018
update DEPENDS: nvidia is hardware-specific and should be removed or optional
author | Rohit Joshi <jozee@slitaz.org> |
---|---|
date | Mon Mar 01 08:54:30 2010 +0000 (2010-03-01) |
parents | 71c7aacfbbb2 |
children | c755ed365a9b |
line source
1 # SliTaz package receipt.
3 PACKAGE="module-init-tools"
4 VERSION="3.10"
5 CATEGORY="base-system"
6 SHORT_DESC="Kernel modules manipulation tools."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 DEPENDS="glibc-base gcc-lib-base zlib lzlib depmod"
9 TARBALL="$PACKAGE-$VERSION.tar.gz"
10 WEB_SITE="http://ftp.kernel.org/pub/linux/utils/kernel/module-init-tools/"
11 WGET_URL="${WEB_SITE}$TARBALL"
12 BUILD_DEPENDS="zlib-dev lzlib-dev lzlib"
14 # Rules to configure and make the package.
15 compile_rules()
16 {
17 cd $src
18 for patch_file in lzlib depmod; do
19 if [ -f done.$patch_file ]; then
20 echo "Skipping $patch_file"
21 continue
22 fi
23 echo "Apply $patch_file.u"
24 patch -p1 < ../stuff/$patch_file.u || return 1
25 touch done.$patch_file
26 done
27 ./configure --enable-zlib --prefix=/usr \
28 --sbindir=/sbin --bindir=/bin --sysconfdir=/etc \
29 --infodir=/usr/share/info --mandir=/usr/share/man \
30 $CONFIGURE_ARGS &&
31 make &&
32 make DESTDIR=$PWD/_pkg install
33 }
35 # Rules to gen a SliTaz package suitable for Tazpkg.
36 genpkg_rules()
37 {
38 mkdir -p $fs/sbin $fs/etc
39 cp $_pkg/sbin/insmod $fs/sbin
40 cp $_pkg/sbin/modinfo $fs/sbin
41 cp $_pkg/sbin/modprobe $fs/sbin
42 cp $_pkg/sbin/rmmod $fs/sbin
43 # lsmod goes in /bin.
44 cp -a $_pkg/bin $fs
45 strip -s $fs/sbin/*
46 strip -s $fs/bin/*
47 # Create the modprobe config directory
48 mkdir -p $fs/etc/modprobe.d
49 }
51 # Remove Busybox symlink before installing
52 pre_install()
53 {
54 rm -f $1/sbin/insmod
55 rm -f $1/sbin/modinfo
56 rm -f $1/sbin/modprobe
57 rm -f $1/sbin/rmmod
58 # BusyBox puts lsmod in /sbin, not /bin
59 rm -f $1/sbin/lsmod
60 }
62 post_remove()
63 {
64 ln -s /bin/busybox /sbin/insmod
65 ln -s /bin/busybox /sbin/modinfo
66 ln -s /bin/busybox /sbin/modprobe
67 ln -s /bin/busybox /sbin/rmmod
68 # BusyBox puts lsmod in /sbin, not /bin
69 ln -s /bin/busybox /sbin/lsmod
70 }