wok view lzma/receipt @ rev 15861

audacious: update TARBALL
author Pascal Bellard <pascal.bellard@slitaz.org>
date Thu Jan 30 09:06:41 2014 +0000 (2014-01-30)
parents b2c3e949d4ff
children f6332424127f
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 LICENSE="LGPL2.1"
9 TARBALL="lzma$(echo $VERSION | sed 's/\.//').tar.bz2"
10 WEB_SITE="http://sourceforge.net/projects/sevenzip/"
11 WGET_URL="$SF_MIRROR/sevenzip/$TARBALL"
12 TAGS="compression archive"
14 DEPENDS="lzlib zlib gcc-lib-base"
16 # Rules to compile & install the temporary toolchain.
17 cook_tmp_toolchain()
18 {
19 # Put & configure the home-script as needed for tmp toolchain.
20 rm /tools/usr/bin/lzma /tools/usr/bin/unlzma /tools/usr/bin/lzcat
21 cp stuff/lzma /tools/usr/bin
22 chmod 755 /tools/usr/bin/lzma
23 ln -s /tools/usr/bin/lzma /tools/usr/bin/unlzma
24 ln -s /tools/usr/bin/lzma /tools/usr/bin/lzcat
25 sed 's~/usr~/tools/usr~' -i /tools/usr/bin/lzma
27 cd $src
28 if [ ! -f done.lzlib.u ]; then
29 patch -p0 < $stuff/lzlib.u || return 1
30 touch done.lzlib.u
31 fi
32 cd CPP/7zip/Compress/LZMA_Alone
34 # Remove copyright message.
35 sed '/MY_VERSION_COPYRIGHT_DATE/d' -i LzmaAlone.cpp
37 make -f makefile.gcc lzma 2> /dev/null
38 { make -f makefile.gcc liblz.so.1.0.0 &&
39 make -f makefile.gcc lzma
40 } || return 1
42 cp -a lzma-shared /tools/usr/bin/lzma-alone
43 cp -a liblz.so.1.0.0 /tools/lib
44 ln -s /tools/lib/liblz.so.1.0.0 /tools/lib/liblz.so
45 ln -s /tools/lib/liblz.so.1.0.0 /tools/lib/liblz.so.1
46 }
49 # Rules to configure and make the package.
50 compile_rules()
51 {
52 cd $src
53 if [ ! -f done.lzlib.u ]; then
54 patch -p0 < $stuff/lzlib.u || return 1
55 touch done.lzlib.u
56 fi
57 cd CPP/7zip/Compress/LZMA_Alone
59 # Remove copyright message.
60 sed '/MY_VERSION_COPYRIGHT_DATE/d' -i LzmaAlone.cpp
62 make -f makefile.gcc lzma 2> /dev/null
63 make -f makefile.gcc liblz.so.1.0.0 &&
64 make -f makefile.gcc lzma
65 }
68 # Rules to gen a SliTaz package suitable for Tazpkg.
69 genpkg_rules()
70 {
71 mkdir -p $fs/usr/bin
72 cp -a $src/CPP/7zip/Compress/LZMA_Alone/lzma-shared $fs/usr/bin/lzma-alone
73 cp $stuff/lzma $fs/usr/bin
74 chmod 755 $fs/usr/bin/lzma
75 ln -s lzma $fs/usr/bin/unlzma
76 ln -s lzma $fs/usr/bin/lzcat
77 }
79 # Pre and post install commands for Tazpkg.
80 # We must remove all Busybox symlink before installing.
81 #
82 pre_install()
83 {
84 local root
85 root=$1
86 echo "Processing pre-install commands..."
87 echo -n "Removing all Busybox replaced utils... "
88 rm -f $root/usr/bin/unlzma
89 rm -f $root/usr/bin/lzcat
90 status
91 }
93 post_remove()
94 {
95 ln -s /bin/busybox $1/usr/bin/unlzma
96 ln -s /bin/busybox $1/usr/bin/lzcat
97 }