wok-next view dwm/receipt @ rev 21722

efivar: typo in post_install
author Pascal Bellard <pascal.bellard@slitaz.org>
date Tue Sep 01 10:31:46 2020 +0000 (2020-09-01)
parents 5669e8b3be70
children
line source
1 # SliTaz package receipt v2.
3 PACKAGE="dwm"
4 VERSION="6.2"
5 CATEGORY="x-window"
6 TAGS="window-manager"
7 SHORT_DESC="Very light dynamic window manager for X"
8 MAINTAINER="maintainer@slitaz.org"
9 LICENSE="MIT"
10 WEB_SITE="https://dwm.suckless.org/"
12 TARBALL="$PACKAGE-$VERSION.tar.gz"
13 WGET_URL="https://dl.suckless.org/dwm/$TARBALL"
15 BUILD_DEPENDS="libx11-dev libxinerama-dev xorg-libXft-dev xorgproto"
17 compile_rules()
18 {
19 # From blue to grey and have lighter grey
20 sed -i s/'#0066ff'/'#222222'/g config.def.h
21 sed -i s/'#cccccc'/'#f1efeb'/g config.def.h
23 # 6 tag-mask
24 sed -i s/', "7", "8", "9"'// config.def.h
26 # Firefox on current tag-mask
27 sed -i s/'1 << 8,'/'0, '/ config.def.h
29 # [Shift]+[Alt]+[Enter]
30 sed -i s/uxterm/xterm/ config.def.h
32 make CC=$HOST_SYSTEM-gcc || return 1
34 install -Dm755 $src/dwm $install/usr/bin/dwm
35 install -Dm755 $stuff/dwm-session $install/usr/bin/dwm-session
36 }
38 genpkg_rules()
39 {
40 copy @std
41 DEPENDS="libx11 xsetroot"
42 }
44 # Adding WM to SLIM available sessions.
45 post_install()
46 {
47 res=$(cat "$1/etc/slim.conf" | grep ^session | sed s/"sessions. *"//)
48 if ! echo "$res" | grep -q $PACKAGE
49 then
50 action "Adding $PACKAGE to /etc/slim.conf..."
51 sed -i "s/^sessions.*/sessions $res,dwm/" \
52 /etc/slim.conf
53 status
54 fi
55 }
57 # Remove dwm from SLIM available sessions.
58 post_remove()
59 {
60 if grep -q dwm "$1/etc/slim.conf"
61 then
62 sed -i s/,dwm// "$1/etc/slim.conf"
63 fi
64 }