Contents of /trunk/extras/slim/slim-1.3.4-r2.smage2
Parent Directory | Revision Log
Revision 13172 -
(show annotations)
(download)
Thu Aug 30 13:26:44 2012 UTC (11 years, 9 months ago) by niro
File size: 2601 byte(s)
Thu Aug 30 13:26:44 2012 UTC (11 years, 9 months ago) by niro
File size: 2601 byte(s)
-fixed service files
1 | # $Id$ |
2 | |
3 | PNAME="slim" |
4 | PVER="1.3.4" |
5 | PBUILD="r2" |
6 | |
7 | PCAT="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.5 |
15 | >= x11-libs/libXft-2.2 |
16 | >= media-libs/libpng-1.5 |
17 | >= media-libs/libjpeg-8 |
18 | >= sys-libs/pam-1.1 |
19 | >= sys-libs/libstdc++-4.6" |
20 | |
21 | SDEPEND=">= dev-util/pkgconfig-0.25 |
22 | >= x11-proto/xproto-7 |
23 | >= sys-apps/sed-4" |
24 | |
25 | SRCFILE="${PNAME}-${PVER}.tar.gz" |
26 | SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" |
27 | |
28 | SVC_REV=1.2 |
29 | TMPFILES_REV=1.2 |
30 | PAMD_REV=1.2 |
31 | |
32 | sminclude mtools cmake |
33 | |
34 | SRC_URI=( |
35 | http://download.berlios.de/${PNAME}/${SRCFILE} |
36 | mirror://${PNAME}/${SRCFILE} |
37 | mirror://${PNAME}/${PNAME}-${PVER}-libpng15.patch |
38 | mirror://${PNAME}/slim.service-${SVC_REV} |
39 | mirror://${PNAME}/slim.tmpfiles-${TMPFILES_REV} |
40 | mirror://${PNAME}/slim.logrotate |
41 | mirror://${PNAME}/slim.pamd-${PAMD_REV} |
42 | mirror://${PNAME}/magellan-slim.theme |
43 | mirror://${PNAME}/magellan-panel.png |
44 | mirror://${PNAME}/magellan-wallpaper.png |
45 | ) |
46 | |
47 | UP2DATE="updatecmd_berlios ${PNAME}" |
48 | |
49 | src_prepare() |
50 | { |
51 | munpack ${SRCFILE} || die |
52 | cd ${SRCDIR} |
53 | |
54 | # fix build against libpng-1.5.x |
55 | mpatch ${PNAME}-${PVER}-libpng15.patch || die |
56 | |
57 | # rename sim.lock to sim.pid and enable daemon mode by default |
58 | # fix the shutdown and reboot commands to match busybox |
59 | # secure x11 with -nolisten tcp |
60 | # and usr /run instead of /var/run |
61 | sed -i -e "s:/var/run/slim.lock:/run/slim.pid:" \ |
62 | -e "s:/var/run/slim.auth:/run/slim.auth:" \ |
63 | -e "s:# daemon.*:daemon\tyes:" \ |
64 | -e "s:^\(halt_cmd.*\):\1\t/sbin/halt:" \ |
65 | -e "s:^\(reboot_cmd.*\):\1\t/sbin/reboot:" \ |
66 | -e "s:#xserver_arguments.*:xserver_arguments\t-nolisten tcp vt07:" \ |
67 | slim.conf || die |
68 | } |
69 | |
70 | src_compile() |
71 | { |
72 | cd ${SRCDIR} |
73 | cmake_configure $(cmake_opt USE_PAM yes) || die |
74 | mmake || die |
75 | } |
76 | |
77 | src_install() |
78 | { |
79 | cd ${SRCDIR} |
80 | mmake DESTDIR=${BINDIR} install || die |
81 | |
82 | minstallunit slim.service-${SVC_REV} slim@.service || die |
83 | minstalltmp slim.tmpfiles-${TMPFILES_REV} slim.conf || die |
84 | minstallpam slim.pamd-${PAMD_REV} slim || die |
85 | minstalllog slim.logrotate slim || die |
86 | |
87 | # theme |
88 | minstallfile -s magellan-slim.theme /usr/share/slim/themes/default/slim.theme || die |
89 | minstallfile -s magellan-panel.png /usr/share/slim/themes/default/panel.png || die |
90 | minstallfile -s magellan-wallpaper.png /usr/share/slim/themes/default/background.png || die |
91 | if [ -f ${BINDIR}/usr/share/slim/themes/default/background.jpg ] |
92 | then |
93 | rm ${BINDIR}/usr/share/slim/themes/default/background.jpg || die |
94 | fi |
95 | } |
96 | |
97 | postinstall() |
98 | { |
99 | mstartunit slim@.service slim |
100 | } |
101 | |
102 | postremove() |
103 | { |
104 | mstopunit slim@.service slim |
105 | } |