Contents of /smage/trunk/core/slim/slim-1.3.2-r4.smage2
Parent Directory | Revision Log
Revision 1998 -
(show annotations)
(download)
Thu Nov 10 13:14:33 2011 UTC (12 years, 5 months ago) by niro
File size: 2967 byte(s)
Thu Nov 10 13:14:33 2011 UTC (12 years, 5 months ago) by niro
File size: 2967 byte(s)
auto added: ver bump to 1.3.2-r4
1 | # $Id$ |
2 | |
3 | PNAME="slim" |
4 | PVER="1.3.2" |
5 | PBUILD="r4" |
6 | |
7 | PCATEGORIE="x11-misc" |
8 | |
9 | DESCRIPTION="SLiM is a Desktop-independent graphical login manager for X11." |
10 | HOMEPAGE="http://slim.berlios.de/" |
11 | |
12 | DEPEND=">= x11-libs/libXmu-1.1 |
13 | >= x11-libs/libX11-1.4 |
14 | >= x11-libs/libXpm-3.9 |
15 | >= x11-libs/libXft-2.2 |
16 | >= media-libs/libpng-1.5 |
17 | >= media-libs/libjpeg-8 |
18 | >= x11-apps/xauth-1.0.5" |
19 | |
20 | SDEPEND=">= dev-util/pkgconfig-0.25 |
21 | >= x11-proto/xproto-7.0.20 |
22 | >= virtual/sed" |
23 | |
24 | SRCFILE="${PNAME}-${PVER}.tar.gz" |
25 | SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" |
26 | |
27 | MCORE_ONLY_KEEP="etc/slim.conf etc/rc.d/init.d/slim usr/bin/slim usr/share/slim/themes/default" |
28 | sminclude mtools mcore-split |
29 | |
30 | SRC_URI=( |
31 | http://download.berlios.de/${PNAME}/${SRCFILE} |
32 | mirror://${PNAME}/${SRCFILE} |
33 | mirror://${PNAME}/${PNAME}-${PVER}-restart-xserver-if-killed.patch |
34 | mirror://${PNAME}/${PNAME}-${PVER}-fix-keyboard-in-tty-from-which-slim-is-lauched.patch |
35 | mirror://${PNAME}/${PNAME}-${PVER}-fix-SIGTERM-freeze.patch |
36 | mirror://${PNAME}/${PNAME}-${PVER}-libpng15.patch |
37 | ) |
38 | |
39 | UP2DATE="updatecmd_berlios ${PNAME}" |
40 | |
41 | src_prepare() |
42 | { |
43 | munpack ${SRCFILE} || die |
44 | cd ${SRCDIR} |
45 | |
46 | # restart the xserver |
47 | mpatch ${PNAME}-${PVER}-restart-xserver-if-killed.patch || die |
48 | |
49 | # fix keyboard issues |
50 | mpatch ${PNAME}-${PVER}-fix-keyboard-in-tty-from-which-slim-is-lauched.patch || die |
51 | |
52 | # fix a sigterm segfault |
53 | mpatch ${PNAME}-${PVER}-fix-SIGTERM-freeze.patch || die |
54 | |
55 | # fix build against libpng-1.5.x |
56 | mpatch ${PNAME}-${PVER}-libpng15.patch || die |
57 | |
58 | # fix cflags and ldflags |
59 | sed -i \ |
60 | -e "s:^\(CFLAGS=\).*:\1-I. $(pkg-config --cflags freetype2 libpng x11):" \ |
61 | -e "s:^\(LDFLAGS=\).*:\1$(pkg-config --libs xft freetype2 libpng xmu) -ljpeg -lz -lm -lcrypt -lrt:" \ |
62 | -e "s:^\(MANDIR=\).*:\1/usr/share/man:" \ |
63 | Makefile || die |
64 | |
65 | # rename sim.lock to sim.pid and enable daemon mode by default |
66 | # fix the shutdown and reboot commands to match busybox |
67 | # secure x11 with -nolisten tcp |
68 | sed -i -e "s:/var/run/slim.lock:/var/run/slim.pid:" \ |
69 | -e "s:# daemon.*:daemon\tyes:" \ |
70 | -e "s:^\(halt_cmd.*\):\1\t/sbin/halt:" \ |
71 | -e "s:^\(reboot_cmd.*\):\1\t/sbin/reboot:" \ |
72 | -e "s:# xserver_arguments.*:xserver_arguments\t-nolisten tcp:" \ |
73 | slim.conf || die |
74 | } |
75 | |
76 | src_compile() |
77 | { |
78 | cd ${SRCDIR} |
79 | mmake || die |
80 | } |
81 | |
82 | mcore_generic_src_install() |
83 | { |
84 | cd ${SRCDIR} |
85 | mmake DESTDIR=${BINDIR} install || die |
86 | |
87 | # install a custom slim.conf |
88 | echo -e ${COLGREEN}" injecting custom slim-configs"${COLDEFAULT} |
89 | mcinjectfile slim.conf /etc || die |
90 | minstalldir /etc/rc.d/init.d || die |
91 | mcinjectexec slim.rc /etc/rc.d/init.d/slim || die |
92 | mcinjectfile slim.theme /usr/share/slim/themes/default/slim.theme || die |
93 | mcinjectfile panel.png /usr/share/slim/themes/default/panel.png || die |
94 | mcinjectfile mcore2.png /usr/share/slim/themes/default/background.png || die |
95 | if [ -f ${BINDIR}/usr/share/slim/themes/default/background.jpg ] |
96 | then |
97 | rm ${BINDIR}/usr/share/slim/themes/default/background.jpg || die |
98 | fi |
99 | } |
100 | |
101 | postinstall() |
102 | { |
103 | mstartservice slim |
104 | } |
105 | |
106 | postremove() |
107 | { |
108 | mstopservice slim |
109 | } |