wok-next annotate bash/receipt @ rev 1469
lxpanel: apply patch once
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Sat Oct 04 11:57:29 2008 +0000 (2008-10-04) |
parents | 24effb018b81 |
children | 65d3dfc87776 |
rev | line source |
---|---|
pankso@14 | 1 # SliTaz package receipt. |
pankso@14 | 2 |
pankso@14 | 3 PACKAGE="bash" |
pankso@14 | 4 VERSION="3.2" |
pankso@202 | 5 CATEGORY="system-tools" |
pankso@14 | 6 SHORT_DESC="The GNU bourne SHell." |
pankso@14 | 7 MAINTAINER="pankso@slitaz.org" |
pankso@14 | 8 DEPENDS="ncurses" |
pankso@14 | 9 TARBALL="$PACKAGE-$VERSION.tar.gz" |
pankso@14 | 10 WEB_SITE="http://www.gnu.org/software/bash/" |
pankso@14 | 11 WGET_URL="$GNU_MIRROR/$PACKAGE/$TARBALL" |
pankso@14 | 12 |
pankso@14 | 13 # Rules to configure and make the package. |
pankso@14 | 14 compile_rules() |
pankso@14 | 15 { |
pankso@14 | 16 # Patch and then build. |
pankso@14 | 17 cd $src |
pankso@111 | 18 busybox patch -p1 -i ../stuff/bash32-025.patch |
pankso@14 | 19 ./configure --prefix=/usr --bindir=/bin \ |
pankso@14 | 20 --enable-history --enable-alias \ |
pankso@14 | 21 --disable-nls --without-bash-malloc \ |
pankso@14 | 22 --disable-select --disable-help-builtin \ |
pankso@14 | 23 --infodir=/usr/share/info --mandir=/usr/share/man \ |
pankso@14 | 24 $CONFIGURE_ARGS |
pankso@14 | 25 make |
pankso@14 | 26 make DESTDIR=$PWD/_pkg install |
pankso@14 | 27 } |
pankso@14 | 28 |
pankso@14 | 29 # Rules to gen a SliTaz package suitable for Tazpkg. |
pankso@14 | 30 genpkg_rules() |
pankso@14 | 31 { |
pankso@14 | 32 cp -a $_pkg/bin $fs |
pankso@14 | 33 strip -s $fs/bin/bash |
pankso@14 | 34 # Config files. |
pankso@14 | 35 # |
pankso@14 | 36 mkdir $fs/etc |
pankso@14 | 37 cp stuff/example.bashrc $fs/etc/bashrc |
pankso@14 | 38 } |
pankso@14 | 39 |
pankso@14 | 40 # Post install commands for Tazpkg. |
pankso@14 | 41 # Check /bin/sh stat. |
pankso@14 | 42 # |
pankso@14 | 43 post_install() |
pankso@14 | 44 { |
pankso@14 | 45 local root |
pankso@14 | 46 root=$1 |
pankso@14 | 47 echo "Processing post-install commands..." |
pankso@14 | 48 sh=`readlink $root/bin/sh` |
pankso@14 | 49 if [ ! "$sh" = "/bin/bash" ]; then |
pankso@14 | 50 echo "" |
pankso@14 | 51 echo "**** Actual SH link : $sh" |
pankso@14 | 52 echo "" |
pankso@14 | 53 echo -n "Do you want Bash for /bin/sh (y/N) ? : "; read anser |
pankso@14 | 54 if [ "$anser" == "y" ]; then |
pankso@14 | 55 echo "" |
pankso@14 | 56 echo -n "Removin sh link to make a new one pointing on /bin/bash..." |
pankso@14 | 57 rm $root/bin/sh && ln -s /bin/bash $root/bin/sh |
pankso@14 | 58 status |
pankso@14 | 59 else |
pankso@14 | 60 echo "" |
pankso@14 | 61 echo "Leaving /bin/sh to : $sh" |
pankso@14 | 62 fi |
pankso@14 | 63 fi |
pankso@14 | 64 } |