wok view busybox/receipt @ rev 1115
Fix DEPENDS clamav
author | Paul Issott <paul@slitaz.org> |
---|---|
date | Sun Jul 20 00:36:25 2008 +0000 (2008-07-20) |
parents | 90ac5dedc9bb |
children | d2ed22109d90 |
line source
1 # SliTaz package receipt.
3 PACKAGE="busybox"
4 VERSION="1.10.3"
5 CATEGORY="base-system"
6 SHORT_DESC="Busybox combines tiny versions of many common UNIX utilities."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 DEPENDS="slitaz-base-files"
9 BUILD_DEPENDS="bzip2"
10 TARBALL="$PACKAGE-$VERSION.tar.bz2"
11 WEB_SITE="http://www.busybox.net/"
12 WGET_URL="http://www.busybox.net/downloads/$TARBALL"
14 # Rules to configure and make the package.
15 compile_rules()
16 {
17 cd $src
18 while read file; do
19 patch -p1 < ../stuff/$file || return 1
20 done <<EOT
21 $PACKAGE-$VERSION-patch.u
22 $PACKAGE-$VERSION-vcsa2txt.u
23 $PACKAGE-$VERSION-cpio.u
24 $PACKAGE-$VERSION-dhcpc.u
25 $PACKAGE-$VERSION-cpio-mkdir.u
26 $PACKAGE-$VERSION-cpio-mtime.u
27 $PACKAGE-$VERSION-unlzma.u
28 $PACKAGE-$VERSION-tftp.u
29 $PACKAGE-$VERSION-tar.u
30 $PACKAGE-$VERSION-script.u
31 $PACKAGE-$VERSION-header_tar.u
32 $PACKAGE-$VERSION-stat.u
33 EOT
34 cp ../stuff/$PACKAGE-$VERSION.config .config
35 make oldconfig
36 make && make install
37 echo "Chmod 4755 on busybox binary..."
38 chmod 4755 _install/bin/busybox
39 }
41 # Rules to gen a SliTaz package suitable for Tazpkg.
42 genpkg_rules()
43 {
44 cp -a $src/_install/* $fs
45 mkdir -p $fs/etc/init.d
46 # Busybox config files.
47 cp stuff/busybox.conf $fs/etc
48 chmod 600 $fs/etc/busybox.conf
49 cp stuff/dnsd.conf $fs/etc
50 cp stuff/udhcpd.conf $fs/etc
51 touch $fs/etc/resolv.conf
52 cp stuff/inetd.conf $fs/etc
53 cp stuff/dnsd $fs/etc/init.d
54 cp stuff/udhcpd $fs/etc/init.d
55 cp stuff/inetd $fs/etc/init.d
56 cp stuff/zcip $fs/etc/init.d
57 cd $fs
58 rm linuxrc
59 ln -s bin/busybox init
60 cd $WOK/$PACKAGE
61 # Udhcpc stuff.
62 mkdir -p $fs/usr/share/udhcpc
63 cp $src/examples/udhcp/simple.script \
64 $fs/usr/share/udhcpc/default.script
65 chmod +x $fs/usr/share/udhcpc/default.script
66 # ZeroConf stuff.
67 cp stuff/zcip.script $fs/etc
68 }
70 # Force glibc-2.7 reinstall if 2.3.6 still in use.
71 pre_install()
72 {
73 cp -a /etc/resolv.conf /etc/resolv.conf-busybox-install
74 if grep -q 'VERSION="2.3.6"' /var/lib/tazpkg/installed/glibc-base/receipt; then
75 tazpkg get-install glibc-base --forced
76 fi
77 }
79 post_install()
80 {
81 ( cd $1/ ; cpio -o -H newc | gzip -9 ) > \
82 $1/$INSTALLED/$PACKAGE/volatile.cpio.gz <<EOT
83 etc/dnsd.conf
84 etc/inetd.conf
85 etc/udhcpd.conf
86 EOT
87 mv -f /etc/resolv.conf-busybox-install /etc/resolv.conf
88 }
90 repack_cleanup()
91 {
92 zcat $INSTALLED/$PACKAGE/volatile.cpio.gz | ( cd $1 ; cpio -id )
93 }