wok-current annotate razorqt/receipt @ rev 15060

dahdi-tools: update bdeps
author Pascal Bellard <pascal.bellard@slitaz.org>
date Tue Aug 13 10:47:54 2013 +0000 (2013-08-13)
parents 9000cde8e23a
children 6a7afc995cac
rev   line source
pankso@12312 1 # SliTaz package receipt.
pankso@12312 2
pankso@12312 3 PACKAGE="razorqt"
pankso@13506 4 VERSION="0.5.0"
pankso@12312 5 CATEGORY="x-window"
pankso@12312 6 SHORT_DESC="Light and fast QT based Desktop Environment."
pankso@12312 7 MAINTAINER="pankso@slitaz.org"
pascal@15021 8 LICENSE="GPL2 LGPL2.1"
pankso@12312 9 TARBALL="$PACKAGE-$VERSION.tar.bz2"
pankso@12312 10 WEB_SITE="http://razor-qt.org/"
pankso@12312 11 WGET_URL="https://github.com/downloads/Razor-qt/razor-qt/$TARBALL"
pankso@13506 12 SUGGESTED="razorqt-themes razorqt-appswitcher razorqt-power \
pankso@13506 13 razorqt-runner razorqt-autosuspend"
pankso@12312 14
pankso@13506 15 DEPENDS="xorg-libX11 libQtCore libQtDBus libQtGui libQtScript libmagic \
pankso@13506 16 libstatgrab alsa-lib"
pankso@13506 17 BUILD_DEPENDS="wget cmake Qt4-dev qmake xorg-dev libmagic-dev upower-dev \
pankso@13506 18 grep libstatgrab-dev alsa-lib-dev polkit-dev polkit-qt-dev glib-dev \
pascal@13507 19 libgio-dev grep"
pankso@13506 20
pankso@13506 21 GENERIC_MENUS="no"
pankso@12312 22
pankso@12312 23 # Rules to configure and make the package.
pankso@12312 24 compile_rules()
pankso@12312 25 {
pankso@12312 26 cd $src
pankso@12312 27 cmake -DCMAKE_INSTALL_PREFIX=/usr .
pankso@12312 28 make && make install
pankso@12312 29 }
pankso@12312 30
pankso@12312 31 # Rules to gen a SliTaz package suitable for Tazpkg.
pankso@12312 32 genpkg_rules()
pankso@12312 33 {
pankso@13506 34 mkdir -p $fs/usr/lib $fs/usr/share $fs/etc
pankso@13506 35
pankso@12312 36 # Use SliTaz XDG Menu
pankso@13506 37 cp -a $install/etc $fs
pankso@13506 38 rm -rf $fs/etc/xdg/menus
pankso@13506 39
pankso@13506 40 # Copy almost everything then split
pankso@12312 41 cp -a $install/usr/bin $fs/usr
pankso@13506 42 cp -f $install/usr/share/xsessions $fs/usr/share
pankso@13506 43 cp -a $install/usr/share/applications $fs/usr/share
pankso@13506 44
pankso@12418 45 # Split more plugins ?
pankso@12312 46 cp -a $install/usr/lib/*.so* $fs/usr/lib
pankso@12312 47 cp -a $install/usr/lib/razor-* $fs/usr/lib
pankso@12312 48 cp -a $install/usr/share/librazorqt $fs/usr/share
pankso@12312 49 cp -a $install/usr/share/razor $fs/usr/share
pankso@13506 50
pankso@12312 51 # Appswitcher --> razorqt-appswitcher
pankso@12312 52 rm -f $fs/usr/bin/razor-appswitcher
pankso@13506 53 rm -f $fs/etc/xdg/autostart/razor-appswitcher.desktop
pankso@13506 54
pankso@13506 55 # Autosuspend --> razorqt-autosuspend
pankso@13506 56 rm -f $fs/usr/bin/razor-autosuspend
pankso@13506 57 rm -f $fs/usr/bin/razor-config-autosuspend
pankso@13506 58 rm -f $fs/etc/xdg/autostart/razor-autosuspend.desktop
pankso@13506 59 rm -f $fs/usr/share/applications/razor-config-autosuspend.desktop
pankso@13506 60 rm -rf $fs/usr/share/razor/razor-autosuspend
pankso@13506 61 rm -rf $fs/usr/share/razor/razor-config-autosuspend
pankso@13506 62
pankso@12418 63 # Power --> razorqt-power
pankso@12418 64 rm -f $fs/usr/bin/razor-power
pankso@12418 65 rm -rf $fs/usr/share/razor/razor-power
pankso@13506 66 rm -f $fs/usr/share/applications/razor-power.desktop
pankso@13506 67
pankso@13506 68 # Policykit-agent --> razorqt-policykit-agent
pankso@13506 69 rm -f $fs/usr/bin/razor-policykit-agent
pankso@13506 70 rm -f $fs/etc/xdg/autostart/razor-policykit-agent.desktop
pankso@13506 71
pankso@13506 72 # Runner --> razorqt-runner
pankso@13506 73 rm -f $fs/usr/bin/razor-runner
pankso@13506 74 rm -rf $fs/usr/share/razor/razor-runner
pankso@13506 75 rm -f $fs/etc/xdg/autostart/razor-runner.desktop
pankso@13506 76
pankso@12312 77 # Themes --> razorqt-themes
pankso@12312 78 rm -rf $fs/usr/share/razor/themes
pankso@12312 79 mkdir -p $fs/usr/share/razor/themes
pankso@12312 80 cp -a $install/usr/share/razor/themes/light \
pankso@12312 81 $fs/usr/share/razor/themes
pankso@13506 82
pankso@12312 83 # Custom SliTaz integration
pankso@13506 84 cp -a $stuff/*.conf $fs/etc/razor
pankso@12312 85 }
pankso@12312 86
pankso@12312 87 post_install()
pankso@12312 88 {
pankso@12312 89 res=$(cat $1/etc/slim.conf | grep ^session | sed s/"sessions. *"//)
pankso@12312 90 # Adding WM to SLIM available sessions.
pankso@12312 91 if ! echo "$res" | grep -q $PACKAGE; then
pankso@12312 92 echo -n "Adding $PACKAGE to /etc/slim.conf..."
pankso@12312 93 sed -i "s/^sessions.*/sessions ${res},$PACKAGE/" $1/etc/slim.conf
pankso@12312 94 status
pankso@12312 95 fi
pankso@12312 96 }
pankso@12312 97
pankso@12312 98 post_remove()
pankso@12312 99 {
pankso@12312 100 # Remove WM from SLIM available sessions.
pankso@12312 101 if grep -q $PACKAGE $1/etc/slim.conf; then
pankso@12312 102 sed -i s/,$PACKAGE// $1/etc/slim.conf
pankso@12312 103 fi
pankso@12312 104 }