wok view bash/receipt @ rev 10256
Add rails.
author | Christopher Rogers <slaxemulator@gmail.com> |
---|---|
date | Sat May 21 04:03:00 2011 +0000 (2011-05-21) |
parents | a1644dbcf632 |
children | 704c6dd3e3ab |
line source
1 # SliTaz package receipt.
3 PACKAGE="bash"
4 VERSION="4.2"
5 CATEGORY="system-tools"
6 SHORT_DESC="The GNU bourne SHell."
7 MAINTAINER="pankso@slitaz.org"
8 DEPENDS="readline"
9 BUILD_DEPENDS="readline bison"
10 TARBALL="$PACKAGE-$VERSION.tar.gz"
11 WEB_SITE="http://www.gnu.org/software/bash/"
12 WGET_URL="$GNU_MIRROR/$PACKAGE/$TARBALL"
14 # Rules to compile & install the temporary toolchain.
15 cook_tmp_toolchain()
16 {
17 cd $src
18 ./configure --without-bash-malloc &&
19 make && make install
20 }
22 # Rules to configure and make the package.
23 compile_rules()
24 {
25 # Patch and then build.
26 cd $src
27 ./configure --bindir=/bin \
28 --enable-history --enable-alias \
29 --disable-nls --without-bash-malloc \
30 --disable-help-builtin --with-installed-readline \
31 $CONFIGURE_ARGS &&
32 make &&
33 # Bash doesn't care about DESTDIR in environnment variable.
34 make DESTDIR=$DESTDIR install
35 }
37 # Rules to gen a SliTaz package suitable for Tazpkg.
38 genpkg_rules()
39 {
40 cp -a $_pkg/bin $fs
41 # Config files.
42 #
43 mkdir $fs/etc
44 cp $stuff/example.bashrc $fs/etc/bashrc
45 }
47 # Post install commands for Tazpkg.
48 # Check /bin/sh stat.
49 #
50 post_install()
51 {
52 local root
53 root=$1
54 echo "Processing post-install commands..."
55 sh=`readlink $root/bin/sh`
56 if [ ! "$sh" = "/bin/bash" ]; then
57 echo ""
58 echo "**** Actual SH link : $sh"
59 echo ""
60 echo -n "Do you want Bash for /bin/sh (yes/No) ? : "
61 read -t 30 anser
62 if [ "$anser" == "yes" ]; then
63 echo ""
64 echo -n "Removing sh link to make a new one pointing on /bin/bash..."
65 rm $root/bin/sh && ln -s /bin/bash $root/bin/sh
66 status
67 else
68 echo ""
69 echo "Leaving /bin/sh to : $sh"
70 fi
71 fi
72 }
74 # Restore a valid sh link if needed.
75 pre_remove()
76 {
77 local root
78 root=$1
79 sh=`readlink $root/bin/sh`
80 if [ ! "$sh" = "busybox" ]; then
81 rm $root/bin/sh &&
82 ln -s /bin/busybox $root/bin/sh
83 fi
84 }