wok annotate partimage/receipt @ rev 14476
gst-plugins-base-dev: update deps+bdeps
author | Dominique Corbex <domcox@slitaz.org> |
---|---|
date | Thu May 02 22:38:49 2013 +0200 (2013-05-02) |
parents | ba5507fa22f8 |
children | 380ffe05937a |
rev | line source |
---|---|
erjo@582 | 1 # SliTaz package receipt. |
erjo@582 | 2 |
erjo@582 | 3 PACKAGE="partimage" |
slaxemulator@8643 | 4 VERSION="0.6.9" |
erjo@582 | 5 CATEGORY="system-tools" |
erjo@582 | 6 SHORT_DESC="Saves partitions in an image file." |
erjo@784 | 7 MAINTAINER="erjo@slitaz.org" |
pascal@5005 | 8 DEPENDS="newt bzip2 openssl slitaz-base-files zlib gcc-lib-base" |
erjo@8722 | 9 BUILD_DEPENDS="newt newt-dev slang-dev bzip2-dev openssl-dev zlib-dev" |
erjo@582 | 10 TARBALL="$PACKAGE-$VERSION.tar.bz2" |
erjo@582 | 11 WEB_SITE="http://www.partimage.org/Index.fr.html" |
slaxemulator@8643 | 12 WGET_URL="$SF_MIRROR/$PACKAGE/$TARBALL" |
erjo@582 | 13 |
erjo@582 | 14 # Rules to configure and make the package. |
erjo@582 | 15 compile_rules() |
slaxemulator@8643 | 16 { |
erjo@582 | 17 cd $src |
pascal@12783 | 18 sed -i 's/gzFile \*m_gzImageFile/gzFile m_gzImageFile/' src/client/imagefile.h |
pascal@12783 | 19 sed -i 's/(gzFile \*) gzdopen/gzdopen/' src/client/imagefile.cpp |
erjo@582 | 20 ./configure --prefix=/usr \ |
erjo@582 | 21 --sysconfdir=/etc \ |
erjo@582 | 22 --infodir=/usr/share/info \ |
pascal@1484 | 23 --mandir=/usr/share/man $CONFIGURE_ARGS && |
pascal@1484 | 24 make && |
erjo@582 | 25 make DESTDIR=$PWD/_pkg install |
erjo@582 | 26 } |
erjo@582 | 27 |
erjo@582 | 28 # Rules to gen a SliTaz package suitable for Tazpkg. |
erjo@582 | 29 genpkg_rules() |
erjo@582 | 30 { |
pascal@11689 | 31 mkdir -p $fs/usr $fs/etc/init.d $fs/var/lib/partimaged |
erjo@582 | 32 cp -a $_pkg/usr/sbin $fs/usr |
erjo@582 | 33 cp -a $_pkg/etc $fs/ |
erjo@582 | 34 install -g root -o root -m 0600 stuff/etc/partimaged/partimaged.* $fs/etc/partimaged |
erjo@582 | 35 install -g root -o root -m 0755 stuff/etc/init.d/partimaged $fs/etc/init.d |
erjo@582 | 36 } |
erjo@582 | 37 |
erjo@582 | 38 post_install() |
erjo@582 | 39 { |
erjo@582 | 40 echo "Processing post install commands..." |
erjo@582 | 41 echo "Adding user/group partimag..." |
pascal@1137 | 42 chroot $1/ adduser -S -H -D partimag |
erjo@582 | 43 |
erjo@582 | 44 echo "Setting permissions for config files" |
pascal@1137 | 45 chmod 0600 $1/etc/partimaged/* |
pascal@1137 | 46 chown partimag.partimag $1/etc/partimaged/* |
erjo@582 | 47 |
erjo@582 | 48 echo " Creating image files directory" |
pascal@1137 | 49 install -g partimag -o partimag -m 0755 -d $1/var/lib/partimaged |
erjo@582 | 50 |
erjo@582 | 51 echo "" |
erjo@582 | 52 echo -e "\nTo starts $PACKAGE server you can run :\n" |
erjo@582 | 53 echo "/etc/init.d/partimaged start" |
erjo@582 | 54 echo -e "Or add partimaged to RUN_DAEMONS in /etc/rcS.conf\n" |
erjo@582 | 55 } |
erjo@582 | 56 |
erjo@582 | 57 post_remove() |
erjo@582 | 58 { |
slaxemulator@8643 | 59 chroot $1/ deluser partimag |
slaxemulator@8643 | 60 chroot $1/ delgroup partimag |
erjo@582 | 61 |
slaxemulator@8643 | 62 if [ -f $1/etc/paritimaged ]; then |
slaxemulator@8643 | 63 rm -rf $1/etc/partimaged |
erjo@582 | 64 fi |
erjo@582 | 65 } |
erjo@582 | 66 |
erjo@582 | 67 |