1 |
commit: feafa4face99ac3bee796885b6c4278776b3bd28 |
2 |
Author: William Hubbs <williamh <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Nov 20 18:52:29 2017 +0000 |
4 |
Commit: William Hubbs <williamh <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Nov 20 18:57:50 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=feafa4fa |
7 |
|
8 |
sys-apps/openrc: 0.34.9 bugfix release for bug #631958 |
9 |
|
10 |
This affects stable, and since this is the only change from 0.34.8 to |
11 |
0.34.9 we are going direct to stable. |
12 |
|
13 |
Package-Manager: Portage-2.3.13, Repoman-2.3.3 |
14 |
RepoMan-Options: --force |
15 |
|
16 |
sys-apps/openrc/Manifest | 1 + |
17 |
sys-apps/openrc/openrc-0.34.9.ebuild | 329 +++++++++++++++++++++++++++++++++++ |
18 |
2 files changed, 330 insertions(+) |
19 |
|
20 |
diff --git a/sys-apps/openrc/Manifest b/sys-apps/openrc/Manifest |
21 |
index 5f100aeda82..6fd23c1f576 100644 |
22 |
--- a/sys-apps/openrc/Manifest |
23 |
+++ b/sys-apps/openrc/Manifest |
24 |
@@ -17,4 +17,5 @@ DIST openrc-0.34.5.tar.gz 227278 SHA256 dad1ccddd3adef9ac3039e1402ad530cc5a54b35 |
25 |
DIST openrc-0.34.6.tar.gz 227096 SHA256 e4e6a1cb1e764c0a81831be72e08009ce6c1381adb3b96f115a2f8d72a666e2c SHA512 2e17fbc628c0753f4459678764911d787b8d40f309f978ddbdfdc4dfc5d3033a2ac35be00fb9ad558030249d215b9494a0e5eb43e41d3123aeca032032c82541 WHIRLPOOL c41365081fdc1eecde817e23ec665f80c28065fac72a1d58edeee676b83c53db7a422524a00ded35de818a1d775f9719afb7ce608d3d974a5e3e89fc86844f3b |
26 |
DIST openrc-0.34.7.tar.gz 227270 SHA256 e45e5da57088e31c31d936c8c1f8573584787c04a72829b12924a2843439a454 SHA512 2cc8feb18a57418227aebf08224f23561b161766bdacc956c1a8e9b054272538de3ab3ec5245b7b8adba80f242019d56bcb94c390ed1a483015d7720fe3f4f73 WHIRLPOOL 349e2092b32ec41d9bdb975369aaee0be71a1833b36a83cc1a0c1d1000ffc83733e35441089c890673fcca78100afb93e14af6c56d10a5534d76a2ba96d78955 |
27 |
DIST openrc-0.34.8.tar.gz 227636 SHA256 d8af528f165bdda39599f06ffa75a6f0e8178e754cccd26bc29478158fbd1b02 SHA512 2309e0d330c35467dd6008f1458ac9680207a4c783d4f4e6008a84a313088cfe796dd134dfec79699b8f9c90002b0ae621bb78a9925b987ae98fbd8ad75b947a WHIRLPOOL 003ee07cde6fdd9578393a44f070f8dac90a9dec863e014dc46bca16ccb2addd5647779cb2f4eb26801d393fc6412a083408fffa25e1cd02bc7754736a9d491b |
28 |
+DIST openrc-0.34.9.tar.gz 227686 SHA256 53f044d51a92c8d2959ce1a229a8192d5e56d6c56e0402967f33903c7eea97c2 SHA512 861113e357a7a662b8995fedd8aa5ba50fdae8890a4dee5413062b7c81305e8a8345a99b12cf8c2faa24966cddd9943ab2e499274ad1ddb5c79538c5d55a4fb1 WHIRLPOOL c10882a7dd5e97ff8b137229335fac61e5fa7d2085ea3306a59a171147385ea5e3f8779f799560fac74aa42499ed4a8d5874dd68bd3fdc10bb7c1536c57c2cf4 |
29 |
DIST openrc-0.34.tar.gz 225678 SHA256 fa95e111d884f60f967bfa78353f683615f599bbf449b89c0663eb173769fc73 SHA512 8ff0e3234db06ddeb7c930251f13ec9e4488e4c9776dfe46bb0c1af09835cb34655084bebb6638eb07e47a7f5ef95c1aaed9d06dfa3eaef9e36e9b7a7910f820 WHIRLPOOL aacc1b4636bbbf29d091d7322154898c98cd13947450a0d81cacc080803c1241fe3cbe3e731553c94e5e5ddb2e9c626de53efa9885a4e7be23399637099f1e4d |
30 |
|
31 |
diff --git a/sys-apps/openrc/openrc-0.34.9.ebuild b/sys-apps/openrc/openrc-0.34.9.ebuild |
32 |
new file mode 100644 |
33 |
index 00000000000..7c2ce709177 |
34 |
--- /dev/null |
35 |
+++ b/sys-apps/openrc/openrc-0.34.9.ebuild |
36 |
@@ -0,0 +1,329 @@ |
37 |
+# Copyright 1999-2017 Gentoo Foundation |
38 |
+# Distributed under the terms of the GNU General Public License v2 |
39 |
+ |
40 |
+EAPI=6 |
41 |
+ |
42 |
+inherit flag-o-matic pam toolchain-funcs |
43 |
+ |
44 |
+DESCRIPTION="OpenRC manages the services, startup and shutdown of a host" |
45 |
+HOMEPAGE="https://github.com/openrc/openrc/" |
46 |
+ |
47 |
+if [[ ${PV} == "9999" ]]; then |
48 |
+ EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git" |
49 |
+ inherit git-r3 |
50 |
+else |
51 |
+ SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz" |
52 |
+ KEYWORDS="alpha amd64 ~arm ~arm64 ~hppa ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd" |
53 |
+fi |
54 |
+ |
55 |
+LICENSE="BSD-2" |
56 |
+SLOT="0" |
57 |
+IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs |
58 |
+ unicode kernel_linux kernel_FreeBSD" |
59 |
+ |
60 |
+COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) ) |
61 |
+ ncurses? ( sys-libs/ncurses:0= ) |
62 |
+ pam? ( |
63 |
+ sys-auth/pambase |
64 |
+ virtual/pam |
65 |
+ ) |
66 |
+ audit? ( sys-process/audit ) |
67 |
+ kernel_linux? ( |
68 |
+ sys-process/psmisc |
69 |
+ !<sys-process/procps-3.3.9-r2 |
70 |
+ ) |
71 |
+ selinux? ( |
72 |
+ sys-apps/policycoreutils |
73 |
+ >=sys-libs/libselinux-2.6 |
74 |
+ ) |
75 |
+ !<sys-apps/baselayout-2.1-r1 |
76 |
+ !<sys-fs/udev-init-scripts-27" |
77 |
+DEPEND="${COMMON_DEPEND} |
78 |
+ virtual/os-headers |
79 |
+ ncurses? ( virtual/pkgconfig )" |
80 |
+RDEPEND="${COMMON_DEPEND} |
81 |
+ !prefix? ( |
82 |
+ kernel_linux? ( |
83 |
+ >=sys-apps/sysvinit-2.86-r6[selinux?] |
84 |
+ virtual/tmpfiles |
85 |
+ ) |
86 |
+ kernel_FreeBSD? ( sys-freebsd/freebsd-sbin ) |
87 |
+ ) |
88 |
+ selinux? ( |
89 |
+ >=sec-policy/selinux-base-policy-2.20170204-r4 |
90 |
+ >=sec-policy/selinux-openrc-2.20170204-r4 |
91 |
+ ) |
92 |
+" |
93 |
+ |
94 |
+PDEPEND="netifrc? ( net-misc/netifrc )" |
95 |
+ |
96 |
+src_prepare() { |
97 |
+ default |
98 |
+ |
99 |
+ sed -i 's:0444:0644:' mk/sys.mk || die |
100 |
+ |
101 |
+ if [[ ${PV} == "9999" ]] ; then |
102 |
+ local ver="git-${EGIT_VERSION:0:6}" |
103 |
+ sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die |
104 |
+ fi |
105 |
+} |
106 |
+ |
107 |
+src_compile() { |
108 |
+ unset LIBDIR #266688 |
109 |
+ |
110 |
+ MAKE_ARGS="${MAKE_ARGS} |
111 |
+ LIBNAME=$(get_libdir) |
112 |
+ LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc |
113 |
+ MKNET=$(usex newnet) |
114 |
+ MKSELINUX=$(usex selinux) |
115 |
+ MKAUDIT=$(usex audit) |
116 |
+ MKPAM=$(usev pam) |
117 |
+ MKSTATICLIBS=$(usex static-libs)" |
118 |
+ |
119 |
+ local brand="Unknown" |
120 |
+ if use kernel_linux ; then |
121 |
+ MAKE_ARGS="${MAKE_ARGS} OS=Linux" |
122 |
+ brand="Linux" |
123 |
+ elif use kernel_FreeBSD ; then |
124 |
+ MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD" |
125 |
+ brand="FreeBSD" |
126 |
+ fi |
127 |
+ export BRANDING="Gentoo ${brand}" |
128 |
+ use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}" |
129 |
+ export DEBUG=$(usev debug) |
130 |
+ export MKTERMCAP=$(usev ncurses) |
131 |
+ |
132 |
+ tc-export CC AR RANLIB |
133 |
+ emake ${MAKE_ARGS} |
134 |
+} |
135 |
+ |
136 |
+# set_config <file> <option name> <yes value> <no value> test |
137 |
+# a value of "#" will just comment out the option |
138 |
+set_config() { |
139 |
+ local file="${ED}/$1" var=$2 val com |
140 |
+ eval "${@:5}" && val=$3 || val=$4 |
141 |
+ [[ ${val} == "#" ]] && com="#" && val='\2' |
142 |
+ sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}" |
143 |
+} |
144 |
+ |
145 |
+set_config_yes_no() { |
146 |
+ set_config "$1" "$2" YES NO "${@:3}" |
147 |
+} |
148 |
+ |
149 |
+src_install() { |
150 |
+ emake ${MAKE_ARGS} DESTDIR="${D}" install |
151 |
+ |
152 |
+ # move the shared libs back to /usr so ldscript can install |
153 |
+ # more of a minimal set of files |
154 |
+ # disabled for now due to #270646 |
155 |
+ #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die |
156 |
+ #gen_usr_ldscript -a einfo rc |
157 |
+ gen_usr_ldscript libeinfo.so |
158 |
+ gen_usr_ldscript librc.so |
159 |
+ |
160 |
+ if ! use kernel_linux; then |
161 |
+ keepdir /$(get_libdir)/rc/init.d |
162 |
+ fi |
163 |
+ keepdir /$(get_libdir)/rc/tmp |
164 |
+ |
165 |
+ # Backup our default runlevels |
166 |
+ dodir /usr/share/"${PN}" |
167 |
+ cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die |
168 |
+ rm -rf "${ED}"/etc/runlevels |
169 |
+ |
170 |
+ # Setup unicode defaults for silly unicode users |
171 |
+ set_config_yes_no /etc/rc.conf unicode use unicode |
172 |
+ |
173 |
+ # Cater to the norm |
174 |
+ set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')' |
175 |
+ |
176 |
+ # On HPPA, do not run consolefont by default (bug #222889) |
177 |
+ if use hppa; then |
178 |
+ rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont |
179 |
+ fi |
180 |
+ |
181 |
+ # Support for logfile rotation |
182 |
+ insinto /etc/logrotate.d |
183 |
+ newins "${FILESDIR}"/openrc.logrotate openrc |
184 |
+ |
185 |
+ # install gentoo pam.d files |
186 |
+ newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon |
187 |
+ newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon |
188 |
+ |
189 |
+ # install documentation |
190 |
+ dodoc ChangeLog *.md |
191 |
+ if use newnet; then |
192 |
+ dodoc README.newnet |
193 |
+ fi |
194 |
+} |
195 |
+ |
196 |
+add_boot_init() { |
197 |
+ local initd=$1 |
198 |
+ local runlevel=${2:-boot} |
199 |
+ # if the initscript is not going to be installed and is not |
200 |
+ # currently installed, return |
201 |
+ [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \ |
202 |
+ || return |
203 |
+ [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return |
204 |
+ |
205 |
+ # if runlevels dont exist just yet, then create it but still flag |
206 |
+ # to pkg_postinst that it needs real setup #277323 |
207 |
+ if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then |
208 |
+ mkdir -p "${EROOT}"etc/runlevels/${runlevel} |
209 |
+ touch "${EROOT}"etc/runlevels/.add_boot_init.created |
210 |
+ fi |
211 |
+ |
212 |
+ elog "Auto-adding '${initd}' service to your ${runlevel} runlevel" |
213 |
+ ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd} |
214 |
+} |
215 |
+add_boot_init_mit_config() { |
216 |
+ local config=$1 initd=$2 |
217 |
+ if [[ -e ${EROOT}${config} ]] ; then |
218 |
+ if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then |
219 |
+ add_boot_init ${initd} |
220 |
+ fi |
221 |
+ fi |
222 |
+} |
223 |
+ |
224 |
+pkg_preinst() { |
225 |
+ local f LIBDIR=$(get_libdir) |
226 |
+ |
227 |
+ # avoid default thrashing in conf.d files when possible #295406 |
228 |
+ if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then |
229 |
+ ( |
230 |
+ unset hostname HOSTNAME |
231 |
+ source "${EROOT}"etc/conf.d/hostname |
232 |
+ : ${hostname:=${HOSTNAME}} |
233 |
+ [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}" |
234 |
+ ) |
235 |
+ fi |
236 |
+ |
237 |
+ # set default interactive shell to sulogin if it exists |
238 |
+ set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin |
239 |
+ |
240 |
+ # termencoding was added in 0.2.1 and needed in boot |
241 |
+ has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding |
242 |
+ |
243 |
+ # swapfiles was added in 0.9.9 and needed in boot (february 2012) |
244 |
+ has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles |
245 |
+ |
246 |
+ if ! has_version ">=sys-apps/openrc-0.11"; then |
247 |
+ add_boot_init sysfs sysinit |
248 |
+ fi |
249 |
+ |
250 |
+ if ! has_version ">=sys-apps/openrc-0.11.3" ; then |
251 |
+ migrate_udev_mount_script |
252 |
+ add_boot_init tmpfiles.setup boot |
253 |
+ fi |
254 |
+ |
255 |
+ # these were added in 0.12. |
256 |
+ if ! has_version ">=sys-apps/openrc-0.12"; then |
257 |
+ add_boot_init loopback |
258 |
+ add_boot_init tmpfiles.dev sysinit |
259 |
+ |
260 |
+ # ensure existing /etc/conf.d/net is not removed |
261 |
+ # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier |
262 |
+ # this needs to stay in openrc ebuilds for a long time. :( |
263 |
+ # Added in 0.12. |
264 |
+ if [[ -f "${EROOT}"etc/conf.d/net ]]; then |
265 |
+ einfo "Modifying conf.d/net to keep it from being removed" |
266 |
+ cat <<-EOF >>"${EROOT}"etc/conf.d/net |
267 |
+ |
268 |
+# The network scripts are now part of net-misc/netifrc |
269 |
+# In order to avoid sys-apps/${P} from removing this file, this comment was |
270 |
+# added; you can safely remove this comment. Please see |
271 |
+# /usr/share/doc/netifrc*/README* for more information. |
272 |
+EOF |
273 |
+ fi |
274 |
+ fi |
275 |
+ has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt |
276 |
+ |
277 |
+ if ! has_version ">=sys-apps/openrc-0.18.3"; then |
278 |
+ add_boot_init mtab |
279 |
+ if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then |
280 |
+ ewarn "${EROOT}etc/mtab will be replaced with a" |
281 |
+ ewarn "symbolic link to /proc/self/mounts on the next" |
282 |
+ ewarn "reboot." |
283 |
+ ewarn "Change the setting in ${EROOT}etc/conf.d/mtab" |
284 |
+ ewarn "if you do not want this to happen." |
285 |
+ fi |
286 |
+ fi |
287 |
+} |
288 |
+ |
289 |
+# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev. |
290 |
+migrate_udev_mount_script() { |
291 |
+ if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \ |
292 |
+ ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then |
293 |
+ add_boot_init udev-mount sysinit |
294 |
+ fi |
295 |
+ return 0 |
296 |
+} |
297 |
+ |
298 |
+pkg_postinst() { |
299 |
+ local LIBDIR=$(get_libdir) |
300 |
+ |
301 |
+ # Make our runlevels if they don't exist |
302 |
+ if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then |
303 |
+ einfo "Copying across default runlevels" |
304 |
+ cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc |
305 |
+ rm -f "${EROOT}"etc/runlevels/.add_boot_init.created |
306 |
+ else |
307 |
+ if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then |
308 |
+ mkdir -p "${EROOT}"etc/runlevels/sysinit |
309 |
+ cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \ |
310 |
+ "${EROOT}"etc/runlevels/sysinit |
311 |
+ fi |
312 |
+ if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then |
313 |
+ mkdir -p "${EROOT}"etc/runlevels/shutdown |
314 |
+ cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \ |
315 |
+ "${EROOT}"etc/runlevels/shutdown |
316 |
+ fi |
317 |
+ if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then |
318 |
+ cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \ |
319 |
+ "${EROOT}"etc/runlevels |
320 |
+ fi |
321 |
+ fi |
322 |
+ |
323 |
+ if use hppa; then |
324 |
+ elog "Setting the console font does not work on all HPPA consoles." |
325 |
+ elog "You can still enable it by running:" |
326 |
+ elog "# rc-update add consolefont boot" |
327 |
+ fi |
328 |
+ |
329 |
+ # Handle the conf.d/local.{start,stop} -> local.d transition |
330 |
+ if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then |
331 |
+ elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}" |
332 |
+ elog "files to ${EROOT}etc/local.d" |
333 |
+ mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start |
334 |
+ mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop |
335 |
+ chmod +x "${EROOT}"etc/local.d/*{start,stop} |
336 |
+ fi |
337 |
+ |
338 |
+ if use kernel_linux && [[ "${EROOT}" = "/" ]]; then |
339 |
+ if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then |
340 |
+ ewarn "The dependency data could not be migrated to /run/openrc." |
341 |
+ ewarn "This means you need to reboot your system." |
342 |
+ fi |
343 |
+ fi |
344 |
+ |
345 |
+ # update the dependency tree after touching all files #224171 |
346 |
+ [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u |
347 |
+ |
348 |
+ if ! use newnet && ! use netifrc; then |
349 |
+ ewarn "You have emerged OpenRc without network support. This" |
350 |
+ ewarn "means you need to SET UP a network manager such as" |
351 |
+ ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd," |
352 |
+ ewarn "net-misc/NetworkManager, or net-vpn/badvpn." |
353 |
+ ewarn "Or, you have the option of emerging openrc with the newnet" |
354 |
+ ewarn "use flag and configuring /etc/conf.d/network and" |
355 |
+ ewarn "/etc/conf.d/staticroute if you only use static interfaces." |
356 |
+ ewarn |
357 |
+ fi |
358 |
+ |
359 |
+ if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then |
360 |
+ ewarn "Please add the network service to your boot runlevel" |
361 |
+ ewarn "as soon as possible. Not doing so could leave you with a system" |
362 |
+ ewarn "without networking." |
363 |
+ ewarn |
364 |
+ fi |
365 |
+} |