wok view razorqt/receipt @ rev 15021

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