Gentoo Archives: gentoo-commits

From: "Michal Gorny (mgorny)" <mgorny@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in sys-apps/systemd: ChangeLog systemd-39.ebuild
Date: Thu, 02 Feb 2012 20:48:07
Message-Id: 20120202204756.C93C52004B@flycatcher.gentoo.org
1 mgorny 12/02/02 20:47:56
2
3 Modified: ChangeLog
4 Added: systemd-39.ebuild
5 Log:
6 Version bump.
7
8 (Portage version: 2.2.0_alpha84_p53/cvs/Linux x86_64)
9
10 Revision Changes Path
11 1.22 sys-apps/systemd/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-apps/systemd/ChangeLog?rev=1.22&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-apps/systemd/ChangeLog?rev=1.22&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-apps/systemd/ChangeLog?r1=1.21&r2=1.22
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/sys-apps/systemd/ChangeLog,v
20 retrieving revision 1.21
21 retrieving revision 1.22
22 diff -u -r1.21 -r1.22
23 --- ChangeLog 21 Jan 2012 15:55:11 -0000 1.21
24 +++ ChangeLog 2 Feb 2012 20:47:56 -0000 1.22
25 @@ -1,6 +1,11 @@
26 # ChangeLog for sys-apps/systemd
27 # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/sys-apps/systemd/ChangeLog,v 1.21 2012/01/21 15:55:11 mgorny Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/sys-apps/systemd/ChangeLog,v 1.22 2012/02/02 20:47:56 mgorny Exp $
30 +
31 +*systemd-39 (02 Feb 2012)
32 +
33 + 02 Feb 2012; Michał Górny <mgorny@g.o> +systemd-39.ebuild:
34 + Version bump.
35
36 *systemd-38-r1 (21 Jan 2012)
37 *systemd-37-r4 (21 Jan 2012)
38
39
40
41 1.1 sys-apps/systemd/systemd-39.ebuild
42
43 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-apps/systemd/systemd-39.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-apps/systemd/systemd-39.ebuild?rev=1.1&content-type=text/plain
45
46 Index: systemd-39.ebuild
47 ===================================================================
48 # Copyright 1999-2012 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/sys-apps/systemd/systemd-39.ebuild,v 1.1 2012/02/02 20:47:56 mgorny Exp $
51
52 EAPI=4
53
54 inherit autotools-utils bash-completion-r1 linux-info pam systemd
55
56 DESCRIPTION="System and service manager for Linux"
57 HOMEPAGE="http://www.freedesktop.org/wiki/Software/systemd"
58 SRC_URI="http://www.freedesktop.org/software/systemd/${P}.tar.xz"
59
60 LICENSE="GPL-2"
61 SLOT="0"
62 KEYWORDS="~amd64 ~x86"
63 IUSE="acl audit cryptsetup gtk lzma pam plymouth selinux tcpd"
64
65 # We need to depend on sysvinit for sulogin which is used in the rescue
66 # mode. Bug #399615.
67
68 COMMON_DEPEND=">=sys-apps/dbus-1.4.10
69 sys-apps/sysvinit
70 >=sys-apps/util-linux-2.19
71 >=sys-fs/udev-172
72 sys-libs/libcap
73 acl? ( sys-apps/acl )
74 audit? ( >=sys-process/audit-2 )
75 cryptsetup? ( sys-fs/cryptsetup )
76 gtk? (
77 dev-libs/dbus-glib
78 >=dev-libs/glib-2.26
79 dev-libs/libgee:0
80 x11-libs/gtk+:2
81 >=x11-libs/libnotify-0.7 )
82 lzma? ( app-arch/xz-utils )
83 pam? ( virtual/pam )
84 plymouth? ( sys-boot/plymouth )
85 selinux? ( sys-libs/libselinux )
86 tcpd? ( sys-apps/tcp-wrappers )"
87
88 # Vala-0.10 doesn't work with libnotify 0.7.1
89 VALASLOT="0.14"
90 # A little higher than upstream requires
91 # but I had real trouble with 2.6.37 and systemd.
92 MINKV="2.6.38"
93
94 # dbus, udev versions because of systemd units
95 # blocker on old packages to avoid collisions with above
96 # openrc blocker to avoid udev rules starting openrc scripts
97 RDEPEND="${COMMON_DEPEND}
98 !<sys-apps/openrc-0.8.3"
99 DEPEND="${COMMON_DEPEND}
100 app-arch/xz-utils
101 dev-util/gperf
102 dev-util/intltool
103 gtk? ( dev-lang/vala:${VALASLOT} )
104 >=sys-kernel/linux-headers-${MINKV}"
105
106 # Due to vala being broken.
107 AUTOTOOLS_IN_SOURCE_BUILD=1
108
109 pkg_setup() {
110 enewgroup lock # used by var-lock.mount
111 enewgroup tty 5 # used by mount-setup for /dev/pts
112 }
113
114 src_prepare() {
115 # Force the rebuild of .vala sources
116 touch src/*.vala || die
117
118 # Fix hardcoded path in .vala.
119 sed -i -e 's:/lib/systemd:/usr/lib/systemd:g' src/*.vala || die
120
121 autotools-utils_src_prepare
122 }
123
124 src_configure() {
125 local myeconfargs=(
126 --with-distro=gentoo
127 # install everything to /usr
128 --with-rootprefix=/usr
129 --with-rootlibdir=/usr/$(get_libdir)
130 # but pam modules have to lie in /lib*
131 --with-pamlibdir=/$(get_libdir)/security
132 --localstatedir=/var
133 --docdir=/tmp/docs
134 $(use_enable acl)
135 $(use_enable audit)
136 $(use_enable cryptsetup libcryptsetup)
137 $(use_enable gtk)
138 $(use_enable lzma xz)
139 $(use_enable pam)
140 $(use_enable plymouth)
141 $(use_enable selinux)
142 $(use_enable tcpd tcpwrap)
143 )
144
145 if use gtk; then
146 export VALAC="$(type -p valac-${VALASLOT})"
147 fi
148
149 autotools-utils_src_configure
150 }
151
152 src_install() {
153 autotools-utils_src_install \
154 bashcompletiondir=/tmp
155
156 # compat for init= use
157 dosym ../usr/bin/systemd /bin/systemd
158 # rsyslog.service depends on it...
159 dosym ../usr/bin/systemctl /bin/systemctl
160
161 # move files as necessary
162 newbashcomp "${D}"/tmp/systemd-bash-completion.sh ${PN}
163 dodoc "${D}"/tmp/docs/*
164 rm -r "${D}"/tmp || die
165
166 # we just keep sysvinit tools, so no need for the mans
167 rm "${D}"/usr/share/man/man8/{halt,poweroff,reboot,runlevel,shutdown,telinit}.8 \
168 || die
169 rm "${D}"/usr/share/man/man1/init.1 || die
170
171 # Create /run/lock as required by new baselay/OpenRC compat.
172 insinto /usr/lib/tmpfiles.d
173 doins "${FILESDIR}"/gentoo-run.conf
174
175 # Migration helpers.
176 exeinto /usr/libexec/systemd
177 doexe "${FILESDIR}"/update-etc-systemd-symlinks.sh
178 systemd_dounit "${FILESDIR}"/update-etc-systemd-symlinks.{service,path}
179 systemd_enable_service sysinit.target update-etc-systemd-symlinks.path
180 }
181
182 pkg_preinst() {
183 local CONFIG_CHECK="~AUTOFS4_FS ~CGROUPS ~DEVTMPFS ~FANOTIFY ~IPV6"
184 kernel_is -ge ${MINKV//./ } || ewarn "Kernel version at least ${MINKV} required"
185 check_extra_config
186 }
187
188 optfeature() {
189 elog " [\e[1m$(has_version ${1} && echo I || echo ' ')\e[0m] ${1} (${2})"
190 }
191
192 pkg_postinst() {
193 mkdir -p "${ROOT}"/run || ewarn "Unable to mkdir /run, this could mean trouble."
194 if [[ ! -L "${ROOT}"/etc/mtab ]]; then
195 ewarn "Upstream suggests that the /etc/mtab file should be a symlink to /proc/mounts."
196 ewarn "It is known to cause users being unable to unmount user mounts. If you don't"
197 ewarn "require that specific feature, please call:"
198 ewarn " $ ln -sf '${ROOT}proc/self/mounts' '${ROOT}etc/mtab'"
199 ewarn
200 fi
201
202 elog "You may need to perform some additional configuration for some programs"
203 elog "to work, see the systemd manpages for loading modules and handling tmpfiles:"
204 elog " $ man modules-load.d"
205 elog " $ man tmpfiles.d"
206 elog
207
208 elog "To get additional features, a number of optional runtime dependencies may"
209 elog "be installed:"
210 optfeature 'dev-python/dbus-python' 'for systemd-analyze'
211 optfeature 'dev-python/pycairo[svg]' 'for systemd-analyze plotting ability'
212 elog
213
214 ewarn "Please note this is a work-in-progress and many packages in Gentoo"
215 ewarn "do not supply systemd unit files yet. You are testing it on your own"
216 ewarn "responsibility. Please remember than you can pass:"
217 ewarn " init=/sbin/init"
218 ewarn "to your kernel to boot using sysvinit / OpenRC."
219
220 # Don't run it if we're outta /
221 if [[ ! ${ROOT%/} ]]; then
222 # Update symlinks to moved units.
223 sh "${FILESDIR}"/update-etc-systemd-symlinks.sh
224
225 # Try to start migration unit.
226 ebegin "Trying to start migration helper path monitoring."
227 systemctl --system start update-etc-systemd-symlinks.path 2>/dev/null
228 eend ${?}
229 fi
230 }