wok-current view module-init-tools/receipt @ rev 24407
updated clamav and clamav-dev again (0.102.3 -> 0.104.2)
author | Hans-G?nter Theisgen |
---|---|
date | Wed Feb 09 14:12:35 2022 +0100 (2022-02-09) |
parents | 9e01bc6321ea |
children | 5926178cd6fa |
line source
1 # SliTaz package receipt.
3 PACKAGE="module-init-tools"
4 VERSION="3.12"
5 CATEGORY="base-system"
6 SHORT_DESC="Kernel modules manipulation tools."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 LICENSE="GPL2"
9 TARBALL="$PACKAGE-$VERSION.tar.gz"
10 WEB_SITE="https://www.kernel.org/pub/linux/utils/kernel/module-init-tools/"
11 WGET_URL="${WEB_SITE}$TARBALL"
13 DEPENDS="glibc-base gcc-lib-base zlib lzlib depmod"
14 BUILD_DEPENDS="wget zlib-dev lzlib-dev lzlib"
16 # What is the latest version available today?
17 current_version()
18 {
19 wget -O - ${WGET_URL%/*} 2>/dev/null | \
20 sed "/latest/d;/$PACKAGE-[0-9]/!d;/tar/!d;s|.*$PACKAGE-\\(.*\\).tar.*\".*|\\1|" | sort -Vr | sed q
21 }
23 # Rules to configure and make the package.
24 compile_rules()
25 {
26 for patch_file in lzlib depmod; do
27 if [ -f done.$patch_file ]; then
28 echo "Skipping $patch_file"
29 continue
30 fi
31 echo "Apply $patch_file.u"
32 patch -p1 < $stuff/$patch_file.u || return 1
33 touch done.$patch_file
34 done
36 # Don't generate manpages to avoid failure.
37 echo '.so man5/modprobe.conf.5' > modprobe.d.5
39 ./configure --enable-zlib \
40 --sbindir=/sbin --bindir=/bin --sysconfdir=/etc \
41 $CONFIGURE_ARGS &&
42 make && make install
43 }
45 # Rules to gen a SliTaz package suitable for Tazpkg.
46 genpkg_rules()
47 {
48 mkdir -p $fs/sbin $fs/etc
49 cp $install/sbin/insmod $fs/sbin
50 cp $install/sbin/modinfo $fs/sbin
51 cp $install/sbin/modprobe $fs/sbin
52 cp $install/sbin/rmmod $fs/sbin
53 # lsmod goes in /bin.
54 cp -a $install/bin $fs
55 # Create the modprobe config directory
56 mkdir -p $fs/etc/modprobe.d
57 }
59 # Remove Busybox symlink before installing
60 pre_install()
61 {
62 rm -f "$1/sbin/insmod"
63 rm -f "$1/sbin/modinfo"
64 rm -f "$1/sbin/modprobe"
65 rm -f "$1/sbin/rmmod"
66 # BusyBox puts lsmod in /sbin, not /bin
67 rm -f "$1/sbin/lsmod"
68 }
70 post_remove()
71 {
72 ln -s /bin/busybox "$1/sbin/insmod"
73 ln -s /bin/busybox "$1/sbin/modinfo"
74 ln -s /bin/busybox "$1/sbin/modprobe"
75 ln -s /bin/busybox "$1/sbin/rmmod"
76 # BusyBox puts lsmod in /sbin, not /bin
77 ln -s /bin/busybox "$1/sbin/lsmod"
78 }