wok view lzma/receipt @ rev 9959

mcrypt: fix bdeps
author Eric Joseph-Alexandre <erjo@slitaz.org>
date Wed May 18 15:26:01 2011 +0200 (2011-05-18)
parents f554e00e7954
children b2c3e949d4ff
line source
1 # SliTaz package receipt.
3 PACKAGE="lzma"
4 VERSION="4.57"
5 CATEGORY="base-system"
6 SHORT_DESC="Compressor with a high compression ratio."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 TARBALL="lzma$(echo $VERSION | sed 's/\.//').tar.bz2"
9 WEB_SITE="http://sourceforge.net/projects/sevenzip/"
10 WGET_URL="$SF_MIRROR/sevenzip/$TARBALL"
11 DEPENDS="lzlib zlib gcc-lib-base"
12 TAGS="compression archive"
14 # Rules to compile & install the temporary toolchain.
15 cook_tmp_toolchain()
16 {
17 # Put & configure the home-script as needed for tmp toolchain.
18 rm /tools/usr/bin/lzma /tools/usr/bin/unlzma /tools/usr/bin/lzcat
19 cp stuff/lzma /tools/usr/bin
20 chmod 755 /tools/usr/bin/lzma
21 ln -s /tools/usr/bin/lzma /tools/usr/bin/unlzma
22 ln -s /tools/usr/bin/lzma /tools/usr/bin/lzcat
23 sed 's~/usr~/tools/usr~' -i /tools/usr/bin/lzma
25 cd $src
26 if [ ! -f done.lzlib.u ]; then
27 patch -p0 < $stuff/lzlib.u || return 1
28 touch done.lzlib.u
29 fi
30 cd CPP/7zip/Compress/LZMA_Alone
32 # Remove copyright message.
33 sed '/MY_VERSION_COPYRIGHT_DATE/d' -i LzmaAlone.cpp
35 make -f makefile.gcc lzma
36 { make -f makefile.gcc liblz.so.1.0.0 &&
37 make -f makefile.gcc lzma
38 } || return 1
40 cp -a lzma-shared /tools/usr/bin/lzma-alone
41 cp -a liblz.so.1.0.0 /tools/lib
42 ln -s /tools/lib/liblz.so.1.0.0 /tools/lib/liblz.so
43 ln -s /tools/lib/liblz.so.1.0.0 /tools/lib/liblz.so.1
44 }
47 # Rules to configure and make the package.
48 compile_rules()
49 {
50 cd $src
51 if [ ! -f done.lzlib.u ]; then
52 patch -p0 < $stuff/lzlib.u || return 1
53 touch done.lzlib.u
54 fi
55 cd CPP/7zip/Compress/LZMA_Alone
57 # Remove copyright message.
58 sed '/MY_VERSION_COPYRIGHT_DATE/d' -i LzmaAlone.cpp
60 make -f makefile.gcc lzma
61 make -f makefile.gcc liblz.so.1.0.0 &&
62 make -f makefile.gcc lzma
63 }
66 # Rules to gen a SliTaz package suitable for Tazpkg.
67 genpkg_rules()
68 {
69 mkdir -p $fs/usr/bin
70 cp -a $src/CPP/7zip/Compress/LZMA_Alone/lzma-shared $fs/usr/bin/lzma-alone
71 cp $stuff/lzma $fs/usr/bin
72 chmod 755 $fs/usr/bin/lzma
73 ln -s lzma $fs/usr/bin/unlzma
74 ln -s lzma $fs/usr/bin/lzcat
75 }
77 # Pre and post install commands for Tazpkg.
78 # We must remove all Busybox symlink before installing.
79 #
80 pre_install()
81 {
82 local root
83 root=$1
84 echo "Processing pre-install commands..."
85 echo -n "Removing all Busybox replaced utils... "
86 rm -f $root/usr/bin/unlzma
87 rm -f $root/usr/bin/lzcat
88 status
89 }
91 post_remove()
92 {
93 ln -s /bin/busybox $1/usr/bin/unlzma
94 ln -s /bin/busybox $1/usr/bin/lzcat
95 }