wok view coreutils-operations/receipt @ rev 18644

coreutils-operations: clean pre_install()
author Aleksej Bobylev <al.bobylev@gmail.com>
date Mon Nov 30 02:55:10 2015 +0200 (2015-11-30)
parents 2c07945763bf
children 124c3a7da04f
line source
1 # SliTaz package receipt.
3 PACKAGE="coreutils-operations"
4 VERSION="8.12"
5 CATEGORY="system-tools"
6 SHORT_DESC="GNU utilities that perform basic operations."
7 MAINTAINER="rcx@zoominternet.net"
8 LICENSE="GPL3"
9 WEB_SITE="http://www.gnu.org/software/coreutils/"
10 WANTED="coreutils"
12 DEPENDS="glibc-base acl"
14 # Rules to gen a SliTaz package suitable for Tazpkg.
15 #
16 # This is a special package for installed system or developer. We only take
17 # a few things, as Busybox provides all the basic utilities, but not for compiling.
18 # But DO NOT erase a Busybox applet, remove it before with pre_install rules.
19 #
20 genpkg_rules()
21 {
22 mkdir -p $fs/bin
23 #cp -a $install/usr/bin/cp $fs/bin
24 cp -a $install/usr/bin/dd $fs/bin
25 cp -a $install/usr/bin/mv $fs/bin
26 cp -a $install/usr/bin/ln $fs/bin
27 #cp -a $install/usr/bin/rm $fs/bin
29 mkdir -p $fs/usr/bin
30 cp -a $install/usr/bin/install $fs/usr/bin
31 cp -a $install/usr/bin/shred $fs/usr/bin
32 }
34 # Pre and post install commands for Tazpkg.
35 # We must remove all Busybox symlink before installing.
36 #
37 pre_install()
38 {
39 local root
40 root=$1
41 qaction "Removing all Busybox replaced utils... "
42 rm -f $root/bin/dd $root/bin/mv $root/bin/ln
43 rm -f $root/usr/bin/install $root/usr/bin/shred
44 # Dont remove cp/rm or the installation will fail because tazpkg use
45 # cp and rm during the process.
46 #
47 #rm -f $root/bin/cp $root/bin/rm
48 qstatus
49 }
51 post_remove()
52 {
53 # use busybox ln applet directly since /bin/ln
54 # in this package is remove already
55 /bin/busybox ln -fs /bin/busybox $1/bin/cp
56 /bin/busybox ln -fs /bin/busybox $1/bin/dd
57 /bin/busybox ln -fs /bin/busybox $1/bin/mv
58 /bin/busybox ln -fs /bin/busybox $1/bin/ln
59 /bin/busybox ln -fs /bin/busybox $1/bin/rm
60 /bin/busybox ln -fs /bin/busybox $1/usr/bin/install
61 /bin/busybox ln -fs /bin/busybox $1/usr/bin/shred
62 }