wok view wicd/receipt @ rev 15034

sarg: no more /var ?
author Pascal Bellard <pascal.bellard@slitaz.org>
date Mon Aug 12 12:23:39 2013 +0000 (2013-08-12)
parents e3a30fd8f61d
children 2a21689b0af7
line source
1 # SliTaz package receipt.
3 PACKAGE="wicd"
4 VERSION="1.7.2.4"
5 CATEGORY="network"
6 SHORT_DESC="Network connection manager"
7 MAINTAINER="jozee@slitaz.org"
8 DEPENDS="python dbus-python ethtool wpa_supplicant pygtk"
9 BUILD_DEPENDS="python-distribute python-babel python-dev dbus-python-dev"
10 TARBALL="$PACKAGE-$VERSION.tar.gz"
11 WEB_SITE="http://wicd.sourceforge.net/"
12 WGET_URL="https://launchpad.net/wicd/${VERSION:0:3}/$VERSION/+download/$TARBALL"
13 TAGS="wireless ethernet"
15 # Rules to configure and make the package.
16 compile_rules()
17 {
18 cd $src
19 # Fix problem with new urwid FS#33378 LP#1075399
20 patch -Np0 -i $stuff/831_830.patch
21 patch -Np0 -i $stuff/835_834.patch
22 patch -Np0 -i $stuff/dbus_string_fix.patch
23 python setup.py configure
24 #HACK for https://bugs.launchpad.net/wicd/+bug/928589
25 mkdir -p translations/ast/LC_MESSAGES
26 msgfmt po/ast.po -o translations/ast/LC_MESSAGES/wicd.mo
27 python setup.py install --root=$DESTDIR
28 }
30 # Rules to gen a SliTaz package suitable for Tazpkg.
31 genpkg_rules()
32 {
33 mkdir -p $fs/usr
34 mkdir -p $fs/etc
35 mkdir -p $fs/var
36 cp -a $install/usr/* $fs/usr
37 cp -a $install/etc/* $fs/etc
38 cp -a $install/var/* $fs/var
39 rm -f -r $fs/usr/share/doc
40 rm -f -r $fs/usr/share/man
41 rm -f -r $fs/usr/share/icons/hicolor/*
42 rm -f -r $fs/usr/share/locale
43 cp -a $install/usr/share/icons/hicolor/scalable $fs/usr/share/icons/hicolor
44 cp -a $install/usr/share/icons/hicolor/32x32 $fs/usr/share/icons/hicolor
45 mkdir -p $fs/etc/init.d
46 cp -a $stuff/wicd $fs/etc/init.d
47 # dhclient as fake udhcpc wrapper
48 cp -a $stuff/dhclient $fs/usr/bin
49 # set permissions
50 chmod +x $fs/usr/bin/dhclient
52 # change bash to sh
53 sed -i 's/bash/sh/' $fs/usr/sbin/wicd \
54 $fs/usr/bin/wicd-client
56 }
58 # edit daemons.conf.
59 post_install()
60 {
61 local root
62 root=$1
63 if ! grep -q ^WICD_OPTIONS $root/etc/daemons.conf; then
64 echo '# wicd options.' >> $root/etc/daemons.conf
65 echo 'WICD_OPTIONS=""' >> $root/etc/daemons.conf
66 echo '' >> $root/etc/daemons.conf
67 fi
68 }