wok-next annotate module-init-tools/receipt @ rev 9480

Up: lirc to 0.9.0.
author Christopher Rogers <slaxemulator@gmail.com>
date Mon Apr 04 13:32:25 2011 +0000 (2011-04-04)
parents d2d594c8804d
children 9624c47bd4ee
rev   line source
pankso@5 1 # SliTaz package receipt.
pankso@5 2
pankso@5 3 PACKAGE="module-init-tools"
gokhlayeh@7897 4 VERSION="3.12"
pankso@178 5 CATEGORY="base-system"
pankso@5 6 SHORT_DESC="Kernel modules manipulation tools."
pankso@289 7 MAINTAINER="pascal.bellard@slitaz.org"
rcx@3742 8 DEPENDS="glibc-base gcc-lib-base zlib lzlib depmod"
pankso@5 9 TARBALL="$PACKAGE-$VERSION.tar.gz"
pankso@5 10 WEB_SITE="http://ftp.kernel.org/pub/linux/utils/kernel/module-init-tools/"
pankso@5 11 WGET_URL="${WEB_SITE}$TARBALL"
pascal@897 12 BUILD_DEPENDS="zlib-dev lzlib-dev lzlib"
pankso@5 13
pankso@5 14 # Rules to configure and make the package.
pankso@5 15 compile_rules()
pankso@5 16 {
pankso@5 17 cd $src
pascal@3436 18 for patch_file in lzlib depmod; do
pascal@3436 19 if [ -f done.$patch_file ]; then
pascal@3436 20 echo "Skipping $patch_file"
pascal@3436 21 continue
pascal@3436 22 fi
pascal@3436 23 echo "Apply $patch_file.u"
pascal@3436 24 patch -p1 < ../stuff/$patch_file.u || return 1
pascal@3436 25 touch done.$patch_file
pascal@3436 26 done
gokhlayeh@7897 27
gokhlayeh@7897 28 # Don't generate manpages to avoid failure.
gokhlayeh@7897 29 echo '.so man5/modprobe.conf.5' > modprobe.d.5
gokhlayeh@7897 30
pankso@5 31 ./configure --enable-zlib --prefix=/usr \
pankso@5 32 --sbindir=/sbin --bindir=/bin --sysconfdir=/etc \
pankso@5 33 --infodir=/usr/share/info --mandir=/usr/share/man \
pascal@1553 34 $CONFIGURE_ARGS &&
pascal@1553 35 make &&
pankso@5 36 make DESTDIR=$PWD/_pkg install
pankso@5 37 }
pankso@5 38
pankso@5 39 # Rules to gen a SliTaz package suitable for Tazpkg.
pankso@5 40 genpkg_rules()
pankso@5 41 {
pankso@5 42 mkdir -p $fs/sbin $fs/etc
pankso@5 43 cp $_pkg/sbin/insmod $fs/sbin
pankso@5 44 cp $_pkg/sbin/modinfo $fs/sbin
pankso@5 45 cp $_pkg/sbin/modprobe $fs/sbin
pankso@5 46 cp $_pkg/sbin/rmmod $fs/sbin
pankso@5 47 # lsmod goes in /bin.
pankso@5 48 cp -a $_pkg/bin $fs
rcx@4030 49 # Create the modprobe config directory
rcx@4030 50 mkdir -p $fs/etc/modprobe.d
pankso@5 51 }
rcx@3742 52
rcx@3742 53 # Remove Busybox symlink before installing
rcx@3742 54 pre_install()
rcx@3742 55 {
rcx@3742 56 rm -f $1/sbin/insmod
rcx@3742 57 rm -f $1/sbin/modinfo
rcx@3742 58 rm -f $1/sbin/modprobe
rcx@3742 59 rm -f $1/sbin/rmmod
rcx@3742 60 # BusyBox puts lsmod in /sbin, not /bin
rcx@3742 61 rm -f $1/sbin/lsmod
rcx@3742 62 }
rcx@3742 63
rcx@3742 64 post_remove()
rcx@3742 65 {
rcx@3742 66 ln -s /bin/busybox /sbin/insmod
rcx@3742 67 ln -s /bin/busybox /sbin/modinfo
rcx@3742 68 ln -s /bin/busybox /sbin/modprobe
rcx@3742 69 ln -s /bin/busybox /sbin/rmmod
rcx@3742 70 # BusyBox puts lsmod in /sbin, not /bin
rcx@3742 71 ln -s /bin/busybox /sbin/lsmod
rcx@3742 72 }