wok view busybox/receipt @ rev 1591

gnupg: update 1.4.9
author Paul Issott <paul@slitaz.org>
date Fri Oct 17 13:06:12 2008 +0000 (2008-10-17)
parents e64f8e87ea6d
children 4316a95d4b4e
line source
1 # SliTaz package receipt.
3 PACKAGE="busybox"
4 VERSION="1.12.0"
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"
13 CONFIG_FILES="/etc/dnsd.conf /etc/inetd.conf /etc/udhcpd.conf /etc/resolv.conf"
15 # Rules to configure and make the package.
16 compile_rules()
17 {
18 cd $src
19 while read file; do
20 [ -f done.$file ] && continue
21 echo "Apply $file..."
22 patch -p1 < ../stuff/$file || return 1
23 touch done.$file
24 done <<EOT
25 $PACKAGE-$VERSION-vcsa2txt.u
26 $PACKAGE-$VERSION-dhcpc.u
27 $PACKAGE-$VERSION-cpio-mkdir.u
28 $PACKAGE-$VERSION-tar.u
29 $PACKAGE-$VERSION-stat.u
30 $PACKAGE-$VERSION-zmodules.u
31 $PACKAGE-$VERSION-modinfo.u
32 $PACKAGE-$VERSION-modprobe.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 mkdir -p $fs/etc/modprobe.d
62 # Udhcpc stuff.
63 mkdir -p $fs/usr/share/udhcpc
64 cp $src/examples/udhcp/simple.script \
65 $fs/usr/share/udhcpc/default.script
66 chmod +x $fs/usr/share/udhcpc/default.script
67 # ZeroConf stuff.
68 cp stuff/zcip.script $fs/etc
69 }
71 # Force glibc-2.7 reinstall if 2.3.6 still in use.
72 pre_install()
73 {
74 cp -a /etc/resolv.conf /etc/resolv.conf-busybox-install
75 if grep -q 'VERSION="2.3.6"' /var/lib/tazpkg/installed/glibc-base/receipt; then
76 tazpkg get-install glibc-base --forced
77 fi
78 }
80 post_install()
81 {
82 ( cd $1/ ; cpio -o -H newc | gzip -9 ) > \
83 $1/$INSTALLED/$PACKAGE/volatile.cpio.gz <<EOT
84 etc/dnsd.conf
85 etc/inetd.conf
86 etc/udhcpd.conf
87 etc/resolv.conf
88 EOT
89 mv -f /etc/resolv.conf-busybox-install /etc/resolv.conf
90 }
92 repack_cleanup()
93 {
94 zcat $INSTALLED/$PACKAGE/volatile.cpio.gz | ( cd $1 ; cpio -id )
95 }