wok-next view slitaz-configs/receipt @ rev 19879
qemacs: does not need gcc3
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Wed Oct 04 18:36:44 2017 +0200 (2017-10-04) |
parents | 7ae7ca392d9e |
children | 250165915708 |
line source
1 # SliTaz package receipt v2.
3 PACKAGE="slitaz-configs"
4 VERSION="312"
5 CATEGORY="base-system"
6 SHORT_DESC="SliTaz config files"
7 MAINTAINER="pankso@slitaz.org"
8 LICENSE="GPL3"
9 WEB_SITE="http://www.slitaz.org/"
10 HOST_ARCH="i486 arm"
12 TARBALL="$PACKAGE-$VERSION.tar.bz2"
13 WGET_URL="http://hg.slitaz.org/slitaz-configs/archive/$VERSION.tar.bz2"
15 BUILD_DEPENDS_arm="gettext"
16 BUILD_DEPENDS="locale-de locale-en locale-fr locale-hu locale-ja locale-pt_BR \
17 locale-ru locale-zh_CN gettext"
18 SPLIT="slitaz-themes slitaz-configs-base"
20 # Rules to configure and make the package.
21 compile_rules()
22 {
23 case "$ARCH" in
24 i?86)
25 make DESTDIR=$DESTDIR menu
26 ln -s menu.en.xml $install/etc/xdg/openbox/menu.xml
27 ;;
28 esac
29 find /usr/share/locale -type f -name 'slitaz*'
31 cp -a $src/rootfs/* $install
33 # Put applications.conf to /etc/skel
34 mkdir -p $install/etc/skel/.config/slitaz/
35 cp -a $install/etc/slitaz/applications.conf $install/etc/skel/.config/slitaz/
37 cd $install/etc/skel
38 mkdir -p Desktop Documents Downloads Images Music Public Templates Videos
40 # actually isolinux splash is png
41 mv $install/boot/isolinux/splash.jpg $install/boot/isolinux/splash.png
43 # LXPanel settings are in lxpanel package
44 rm -r $install/etc/lxpanel
46 # Polkit *.pkla files are not working anymore,
47 # Polkit switches to javascript-based rules
48 rm -r $install/etc/polkit-1
50 # LXsession settings are in lxsession package
51 rm -r $install/etc/skel/.config/lxsession
53 # Beaver is gone...
54 sed -i 's|beaver|leafpad|' $install/usr/share/applications/defaults.list
56 # SliTaz backgrounds in the slitaz-next package
57 rm $install/usr/share/images/slitaz-background*
59 # SLiM theme in the slim package
60 rm -r $install/usr/share/slim
62 # PCManFM settings in the pcmanfm package
63 rm -r $install/usr/share/slitaz/lxde
65 # Remove templates, use that in /usr/share/templates/ only
66 rm $install/etc/skel/Templates/*
68 chown -R root:root $install
69 }
71 # Rules to gen a SliTaz package suitable for Tazpkg.
72 genpkg_rules()
73 {
74 case $PACKAGE in
75 slitaz-configs)
76 # Special case for ARM since some (most) config files are in slitaz-arm repo.
77 # i486/arm common configs are provided by slitaz-configs-base.
78 case "$ARCH" in
79 i?86)
80 copy \
81 /etc/skel/.gtkrc-2.0* \
82 /etc/skel/.icons/ \
83 /etc/skel/.Xdefaults \
84 /etc/skel/.xinitrc \
85 /etc/skel/.Xresources \
86 /etc/skel/.xsession \
87 /etc/xdg/openbox/autostart \
88 /etc/xdg/openbox/environment \
89 /etc/xdg/openbox/menu.en.xml \
90 /etc/xdg/openbox/menu.xml \
91 /etc/xdg/openbox/rc.xml \
92 /usr/bin/ \
93 /usr/share/applications/ \
94 /usr/share/images/ \
95 /usr/share/pixmaps/ \
96 /usr/share/slitaz/ \
97 /usr/share/templates/ \
98 /usr/share/webhome/ \
99 /root/
100 DEPENDS="slitaz-configs-base xorg-libXcomposite \
101 xorg-libXdamage xorg-xcompmgr transset-df ttf-dejavu \
102 slim"
103 ;;
104 arm)
105 copy \
106 /usr/share/applications/ \
107 /usr/share/slitaz/
108 DEPENDS="slitaz-arm-configs ttf-dejavu slim"
109 ;;
110 esac
112 CAT="base-system|for GUI systems"
113 ;;
114 slitaz-themes)
115 copy /usr/share/themes/SliTaz*/ /usr/share/slim/ /usr/share/lxdm/
116 CAT="customization|GTK+2, Openbox3, LXDM and SLiM themes"
117 DEPENDS="slim"
118 ;;
119 slitaz-configs-base)
120 CAT="base-system|for text based systems"
122 # Copy rootfs files and set permissions.
123 case "$ARCH" in
124 arm*)
125 # Most ARM configs are in slitaz-arm repo but Openbox, webhome
126 # are common to all arch.
127 copy \
128 /usr/bin/ \
129 /etc/lxpanel/ \
130 /etc/skel/
131 # No dbus on ARM
132 sed "s/exec dbus.*$/exec\"/" -i $fs/etc/skel/.xinitrc
133 ;;
134 *)
135 copy \
136 /boot/ \
137 /etc/skel/ \
138 /etc/polkit-1/ \
139 /etc/slitaz/
140 CONFIG_FILES="/etc/slitaz/applications.conf"
141 ;;
142 esac
143 copy \
144 /usr/share/ \
145 /root/
146 remove_already_packed
148 DEPENDS="tazlito tazpkg"
149 # Handle SliTaz arch
150 case "$SLITAZ_ARCH" in
151 arm*) DEPENDS="" ;;
152 esac
153 ;;
154 esac
155 }
157 # By default SLiM provide a base theme and config file have both
158 # base and slitaz who will be choose randomly, so make sure we use
159 # only slitaz theme.
160 post_install_slitaz_themes() {
161 chroot "$1/" slim-theme -s slitaz
162 }
163 pre_remove_slitaz_themes() {
164 chroot "$1/" slim-theme -f slitaz
165 }
167 post_install_slitaz_configs() {
168 for i in $(ls -d "$1/root" "$1"/home/* 2>/dev/null); do
169 [ -d "$i" ] && cp -f "$1/etc/skel/.xinitrc" "$i"
170 done
171 sed -i 's|$HOME/.config|/etc|' "$1/root/.xinitrc"
172 chmod 0750 $1/root
173 }