wok view jwm/receipt @ rev 16074

Add f3
author Paul Issott <paul@slitaz.org>
date Fri Mar 14 20:38:37 2014 +0000 (2014-03-14)
parents 509a8cf333fe
children f20bb2aafa21
line source
1 # SliTaz package receipt.
3 PACKAGE="jwm"
4 VERSION="2.2.0"
5 CATEGORY="x-window"
6 SHORT_DESC="JWM is a light Window Manager for the X window system."
7 MAINTAINER="pankso@slitaz.org"
8 LICENSE="GPL2"
9 TARBALL="$PACKAGE-$VERSION.tar.xz"
10 WEB_SITE="http://www.joewing.net/programs/jwm/"
11 WGET_URL="http://www.joewing.net/programs/jwm/releases/$TARBALL"
12 TAGS="wm window-manager"
13 HOST_ARCH="i486 arm"
15 DEPENDS="xorg-libX11 xorg-libXft xorg-libXrender xorg-libXpm xorg-libXext \
16 xorg-libXmu xorg-libXinerama xorg-libXau xorg-libXdmcp xorg-libXt libjpeg \
17 libpng slitaz-configs-base xorg-xload xorg-xclock nano imlib2 hsetroot compton"
18 BUILD_DEPENDS="xorg-libX11-dev xorg-libXft-dev jpeg-dev libpng-dev"
20 # Handle cross compilation
21 case "$ARCH" in
22 arm) ARCH_ARGS="--disable-nls" ;;
23 esac
25 # Rules to configure and make the package.
26 compile_rules()
27 {
28 #[ -f done.resize-backgound.u ] || patch -p1 < $stuff/resize-backgound.u
29 #touch done.resize-backgound.u
30 ./configure \
31 --prefix=/usr \
32 --mandir=/usr/share/man \
33 --sysconfdir=/etc/xdg/jwm \
34 --disable-fribidi \
35 --disable-rpath \
36 --disable-rsvg \
37 --disable-confirm \
38 $CONFIGURE_ARGS $ARCH_ARGS 2>/dev/null &&
39 make && make install
40 }
42 testsuite()
43 {
44 readelf -h $install/usr/bin/jwm
45 }
47 # Rules to gen a SliTaz package suitable for Tazpkg.
48 genpkg_rules()
49 {
50 mkdir -p $fs/etc/xdg/jwm $fs/usr/share
51 cp -a $install/usr/bin $fs/usr/bin
52 # Simple and default config file.
53 cp $stuff/simple.jwmrc $fs/etc/xdg/jwm/simple.jwmrc
54 cp $stuff/slitaz.jwmrc $fs/etc/xdg/jwm/system.jwmrc
55 cp -r $stuff/xsessions $fs/usr/share
56 }
58 post_install()
59 {
60 if [ -d "$1/etc/jwm" ]; then
61 echo "Removing old system wide configs: $1/etc/jwm"
62 rm -rf $1/etc/jwm
63 fi
64 res=$(cat $1/etc/slim.conf | grep ^session | sed s/"sessions. *"//)
65 # Adding WM to SLIM available sessions.
66 if ! echo "$res" | grep -q $PACKAGE; then
67 echo -n "Adding $PACKAGE to /etc/slim.conf..."
68 sed -i "s/^sessions.*/sessions ${res},$PACKAGE/" $1/etc/slim.conf
69 status
70 fi
71 }
73 post_remove()
74 {
75 # Remove WM from SLIM available sessions.
76 if grep -q $PACKAGE $1/etc/slim.conf; then
77 sed -i s/,$PACKAGE// $1/etc/slim.conf
78 fi
79 }