Contents of /smage/trunk/core/sudo/sudo-1.8.0-r1.smage2
Parent Directory | Revision Log
Revision 1445 -
(show annotations)
(download)
Thu Mar 3 12:18:50 2011 UTC (13 years, 6 months ago) by niro
File size: 1665 byte(s)
Thu Mar 3 12:18:50 2011 UTC (13 years, 6 months ago) by niro
File size: 1665 byte(s)
-keep sudo plugins
1 | # $Id$ |
2 | |
3 | PNAME="sudo" |
4 | PVER="1.8.0" |
5 | PBUILD="r1" |
6 | |
7 | PCATEGORIE="app-admin" |
8 | STATE="unstable" |
9 | |
10 | DESCRIPTION="sudo allows to give certain users the ability to run some commands as another user while logging the commands." |
11 | HOMEPAGE="http://www.sudo.ws/" |
12 | |
13 | DEPEND=">= virtual/glibc" |
14 | |
15 | SRCFILE="${PNAME}-${PVER}.tar.gz" |
16 | SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" |
17 | |
18 | MCORE_ONLY_KEEP="etc/sudoers etc/sudoers.d usr/bin/sudo usr/$(mlibdir)/sudo/*.so" |
19 | sminclude mtools mcore-split |
20 | |
21 | SRC_URI=( |
22 | http://www.sudo.ws/${PNAME}/dist/${SRCFILE} |
23 | mirror://${PNAME}/${SRCFILE} |
24 | mirror://${PNAME}/sudo.pamd |
25 | mirror://${PNAME}/${PNAME}-1.8.0-allow-wheel.patch |
26 | ) |
27 | |
28 | UP2DATE="updatecmd http://www.sudo.ws/${PNAME}/dist | grep ${PNAME}- | lasttarball gz" |
29 | |
30 | src_prepare() |
31 | { |
32 | munpack ${SRCFILE} || die |
33 | cd ${SRCDIR} |
34 | |
35 | # allow the group wheel to run all commands |
36 | mpatch ${PNAME}-1.8.0-allow-wheel.patch || die |
37 | } |
38 | |
39 | src_compile() |
40 | { |
41 | cd ${SRCDIR} |
42 | |
43 | mconfigure \ |
44 | --libexecdir=/usr/$(mlibdir)/sudo \ |
45 | --with-all-insults \ |
46 | --disable-path-info \ |
47 | --with-env-editor \ |
48 | --without-pam \ |
49 | || die |
50 | |
51 | mmake || die |
52 | } |
53 | |
54 | mcore_generic_src_install() |
55 | { |
56 | cd ${SRCDIR} |
57 | |
58 | mmake DESTDIR=${BINDIR} install || die |
59 | # fix permissions - /var and /var/db get 0700 and this breaks the system! |
60 | mchmod 0755 /var || die |
61 | mchmod 0755 /var/db || die |
62 | |
63 | # docs |
64 | minstalldocs BUGS CHANGES HISTORY LICENSE PORTING \ |
65 | README RUNSON TODO TROUBLESHOOTING UPGRADE \ |
66 | || die |
67 | |
68 | # mcore-specific |
69 | # include configs from /etc/sudoers.d |
70 | minstalldir /etc/sudoers.d || die |
71 | # must be 0755!! |
72 | mchmod 0755 /etc/sudoers.d || die |
73 | mcinjectfile users_reboot.sudo /etc/sudoers.d/10_users_reboot || die |
74 | mchmod 0440 /etc/sudoers.d/10_users_reboot || die |
75 | } |