wok annotate jwm/receipt @ rev 15724

Move to undigest: php-cups fotoxx printoxx gtkaml v4l-dvb
author Pascal Bellard <pascal.bellard@slitaz.org>
date Thu Dec 26 14:11:39 2013 +0000 (2013-12-26)
parents 612c43caa4ec
children 410490fd06f0
rev   line source
pankso@25 1 # SliTaz package receipt.
pankso@25 2
pankso@25 3 PACKAGE="jwm"
pankso@12019 4 VERSION="2.1.0"
pankso@25 5 CATEGORY="x-window"
pankso@25 6 SHORT_DESC="JWM is a light Window Manager for the X window system."
pankso@25 7 MAINTAINER="pankso@slitaz.org"
pascal@15215 8 LICENSE="GPL2"
pankso@25 9 TARBALL="$PACKAGE-$VERSION.tar.bz2"
pankso@25 10 WEB_SITE="http://www.joewing.net/programs/jwm/"
pankso@25 11 WGET_URL="http://www.joewing.net/programs/jwm/releases/$TARBALL"
jozee@4941 12 TAGS="wm window-manager"
pankso@25 13
pankso@12407 14 DEPENDS="xorg-libX11 xorg-libXft xorg-libXrender xorg-libXpm xorg-libXext \
pankso@12407 15 xorg-libXmu xorg-libXinerama xorg-libXau xorg-libXdmcp xorg-libXt libjpeg \
pankso@12407 16 libpng slitaz-configs-base xorg-xload xorg-xclock nano"
pankso@12407 17 BUILD_DEPENDS="xorg-dev xorg-libXft-dev jpeg-dev libpng-dev"
pankso@12019 18
pankso@25 19 # Rules to configure and make the package.
pankso@25 20 compile_rules()
pankso@25 21 {
pankso@90 22 cd $src
slaxemulator@9700 23 [ -f done.resize-backgound.u ] || patch -p1 < $stuff/resize-backgound.u
pascal@1553 24 touch done.resize-backgound.u
pankso@90 25 ./configure \
pankso@90 26 --prefix=/usr \
pankso@90 27 --mandir=/usr/share/man \
pankso@12407 28 --sysconfdir=/etc/xdg/jwm \
pankso@90 29 --disable-fribidi \
pascal@1553 30 $CONFIGURE_ARGS &&
pankso@90 31 make
pankso@25 32 }
pankso@25 33
pankso@25 34 # Rules to gen a SliTaz package suitable for Tazpkg.
pankso@25 35 genpkg_rules()
pankso@25 36 {
pankso@12407 37 mkdir -p $fs/usr/bin $fs/etc/xdg/jwm $fs/usr/share
pankso@272 38 cp -a $src/src/jwm $fs/usr/bin
pankso@12019 39 # Simple and default config file.
pankso@12407 40 cp $stuff/simple.jwmrc $fs/etc/xdg/jwm/simple.jwmrc
pankso@12407 41 cp $stuff/slitaz.jwmrc $fs/etc/xdg/jwm/system.jwmrc
pankso@12407 42 cp -r $stuff/xsessions $fs/usr/share
pankso@25 43 }
pankso@12308 44
pankso@12308 45 post_install()
pankso@12308 46 {
pankso@12407 47 if [ -d "$1/etc/jwm" ]; then
pankso@12407 48 echo "Removing old system wide configs: $1/etc/jwm"
pankso@12407 49 rm -rf $1/etc/jwm
pankso@12407 50 fi
pankso@12308 51 res=$(cat $1/etc/slim.conf | grep ^session | sed s/"sessions. *"//)
pankso@12308 52 # Adding WM to SLIM available sessions.
pankso@12308 53 if ! echo "$res" | grep -q $PACKAGE; then
pankso@12308 54 echo -n "Adding $PACKAGE to /etc/slim.conf..."
pankso@12308 55 sed -i "s/^sessions.*/sessions ${res},$PACKAGE/" $1/etc/slim.conf
pankso@12308 56 status
pankso@12308 57 fi
pankso@12308 58 }
pankso@12308 59
pankso@12308 60 post_remove()
pankso@12308 61 {
pankso@12308 62 # Remove WM from SLIM available sessions.
pankso@12308 63 if grep -q $PACKAGE $1/etc/slim.conf; then
pankso@12308 64 sed -i s/,$PACKAGE// $1/etc/slim.conf
pankso@12308 65 fi
pankso@12308 66 }