wok-6.x view slitaz-tools/receipt @ rev 12685
linux: fix modules.list to use new .xz compressed modules
author | Christophe Lincoln <pankso@slitaz.org> |
---|---|
date | Tue May 01 23:48:55 2012 +0200 (2012-05-01) |
parents | 89f94b3e502a |
children | bb299a081d94 |
line source
1 # SliTaz package receipt.
3 PACKAGE="slitaz-tools"
4 VERSION="4.9.1"
5 CATEGORY="system-tools"
6 SHORT_DESC="SliTaz tools provide installer and utils usable on termnial."
7 MAINTAINER="pankso@slitaz.org"
8 DEPENDS="slitaz-boot-scripts dialog gettext-base slitaz-configs-base"
9 BUILD_DEPENDS="gettext"
10 SUGGESTED="slitaz-tools-boxes"
11 TARBALL="$PACKAGE-$VERSION.tar.gz"
12 WEB_SITE="http://www.slitaz.org/"
13 WGET_URL="http://mirror.slitaz.org/sources/tools/$TARBALL"
14 CONFIG_FILES="
15 /etc/TZ
16 /etc/keymap.conf
17 /etc/X11/screen.conf
18 /etc/locale.conf
19 /etc/firewall.conf
20 /etc/slitaz/applications.conf"
22 # Rules to configure and make the package.
23 compile_rules()
24 {
25 cd $src
26 # temp tazinst patch (until next release)
27 patch -p1 < $stuff/tazinst.patch || return 1
28 make && make DESTDIR=$DESTDIR install
29 }
31 # Rules to gen a SliTaz package suitable for Tazpkg.
32 genpkg_rules()
33 {
34 mkdir -p $fs
35 cp -a $install/* $fs
36 chmod 0644 $fs/usr/share/locale/*/*/*.mo
37 chown -R root.root $fs
38 }
40 # Pre install commands.
41 pre_install()
42 {
43 local root
44 root=$1
45 # Backup file to restore with post install
46 echo "Creating backups of configs..."
47 cp $root/etc/TZ $root/etc/TZ.bak 2>/dev/null
48 cp $root/etc/keymap.conf $root/etc/keymap.conf.bak 2>/dev/null
49 cp $root/etc/X11/screen.conf $root/etc/X11/screen.conf.bak 2>/dev/null
50 cp $root/etc/locale.conf $root/etc/locale.conf.bak 2>/dev/null
51 cp $root/etc/firewall.conf $root/etc/firewall.conf.bak 2>/dev/null
52 }
54 # Post install
55 post_install()
56 {
57 echo "Restoring configs backups..."
58 mv -f $root/etc/TZ.bak $root/etc/TZ 2>/dev/null
59 mv -f $root/etc/keymap.conf.bak $root/etc/keymap.conf 2>/dev/null
60 mv -f $root/etc/X11/screen.conf.bak $root/etc/X11/screen.conf 2>/dev/null
61 mv -f $root/etc/locale.conf.bak $root/etc/locale.conf 2>/dev/null
62 mv -f $root/etc/firewall.conf.bak $root/etc/firewall.conf 2>/dev/null
63 # Install boxes package if old slitaz-tools
64 if [ -f $root/usr/bin/mountbox ] && [ ! -d /var/lib/tazpkg/installed/slitaz-tools-boxes ]; then
65 tazpkg get-install slitaz-tools-boxes
66 fi
67 }