Annotation of /trunk/core/utempter/utempter-0.5.5.6-r7.smage2
Parent Directory | Revision Log
Revision 3336 -
(hide annotations)
(download)
Mon Oct 19 23:14:29 2009 UTC (14 years, 11 months ago) by niro
File size: 1461 byte(s)
Mon Oct 19 23:14:29 2009 UTC (14 years, 11 months ago) by niro
File size: 1461 byte(s)
auto added: ver bump to 0.5.5.6-r7
1 | niro | 3336 | # $Id$ |
2 | |||
3 | PNAME="utempter" | ||
4 | PVER="0.5.5.6" | ||
5 | PBUILD="r7" | ||
6 | |||
7 | PCATEGORIE="sys-apps" | ||
8 | STATE="unstable" | ||
9 | |||
10 | DESCRIPTION="App that allows non-privileged apps to write utmp (login) info." | ||
11 | HOMEPAGE="http://www.redhat.com/" | ||
12 | |||
13 | DEPEND=">= virtual/glibc" | ||
14 | SDEPEND=">= app-arch/rpm2targz-9" | ||
15 | |||
16 | SRCFILE="${PNAME}-${PVER/.6/-6}.src.rpm" | ||
17 | SRCDIR="${BUILDDIR}/${PNAME}-${PVER:0:5}" | ||
18 | |||
19 | sminclude mtools | ||
20 | |||
21 | SRC_URI=( | ||
22 | mirror://${PNAME}/${SRCFILE} | ||
23 | mirror://${PNAME}/${PNAME}-${PVER}-soname-makefile-fix.patch | ||
24 | mirror://${PNAME}/${PNAME}-${PVER}-no_utmpx.patch | ||
25 | ) | ||
26 | |||
27 | src_prepare() | ||
28 | { | ||
29 | munpack ${SRCFILE} || die | ||
30 | tar xvzf ${BUILDDIR}/${PNAME}-${PVER:0:5}.tar.gz -C ${BUILDDIR} || die | ||
31 | cd ${SRCDIR} | ||
32 | |||
33 | mpatch ${PNAME}-${PVER}-soname-makefile-fix.patch || die | ||
34 | mpatch ${PNAME}-${PVER}-no_utmpx.patch || die | ||
35 | } | ||
36 | |||
37 | |||
38 | src_compile() | ||
39 | { | ||
40 | cd ${SRCDIR} | ||
41 | mmake RPM_OPT_FLAGS="${CFLAGS}" || die | ||
42 | } | ||
43 | |||
44 | src_install() | ||
45 | { | ||
46 | cd ${SRCDIR} | ||
47 | |||
48 | # needed directories | ||
49 | minstalldir /usr/bin || die | ||
50 | |||
51 | mmake RPM_BUILD_ROOT=${BINDIR} LIBDIR=/usr/$(mlibdir) install || die | ||
52 | |||
53 | # missing | ||
54 | minstallexec utmp || die | ||
55 | |||
56 | # fix permissions | ||
57 | mchown root:utmp /usr/sbin/utempter || die | ||
58 | mchmod 2755 /usr/sbin/utempter || die | ||
59 | } | ||
60 | |||
61 | preinstall() | ||
62 | { | ||
63 | ${MLIBDIR}/mgroupadd -o "-g 406" utmp | ||
64 | } | ||
65 | |||
66 | postinstall() | ||
67 | { | ||
68 | if [[ -z ${MROOT} ]] || [[ ${MROOT} = / ]] | ||
69 | then | ||
70 | if [ -f /var/log/wtmp ] | ||
71 | then | ||
72 | chown root:utmp /var/log/wtmp | ||
73 | chmod 664 /var/log/wtmp | ||
74 | fi | ||
75 | |||
76 | if [ -f /var/run/utmp ] | ||
77 | then | ||
78 | chown root:utmp /var/run/utmp | ||
79 | chmod 664 /var/run/utmp | ||
80 | fi | ||
81 | fi | ||
82 | } |
Properties
Name | Value |
---|---|
svn:keywords | Id |