wok view slitaz-tools/receipt @ rev 12847
Up: ffmpeg-dev (0.10.3)
author | Dominique Corbex <domcox@slitaz.org> |
---|---|
date | Wed May 23 13:00:38 2012 +0200 (2012-05-23) |
parents | bb299a081d94 |
children | f6382af837a6 |
line source
1 # SliTaz package receipt.
3 PACKAGE="slitaz-tools"
4 VERSION="5.0"
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/locale.conf
18 /etc/firewall.conf
19 /etc/slitaz/applications.conf"
21 # Rules to configure and make the package.
22 compile_rules()
23 {
24 cd $src
25 make && make DESTDIR=$DESTDIR install
26 }
28 # Rules to gen a SliTaz package suitable for Tazpkg.
29 genpkg_rules()
30 {
31 mkdir -p $fs
32 cp -a $install/* $fs
34 # Makefile bug in 5.0
35 cp -a $src/tinyutils/decode $fs/usr/bin
37 chmod 0644 $fs/usr/share/locale/*/*/*.mo
38 chown -R root.root $fs
39 }
41 # Pre install commands.
42 pre_install()
43 {
44 local root
45 root=$1
46 # Backup file to restore with post install
47 echo "Creating backups of configs..."
48 cp $root/etc/TZ $root/etc/TZ.bak 2>/dev/null
49 cp $root/etc/keymap.conf $root/etc/keymap.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/locale.conf.bak $root/etc/locale.conf 2>/dev/null
61 mv -f $root/etc/firewall.conf.bak $root/etc/firewall.conf 2>/dev/null
62 }