Gentoo Archives: gentoo-commits

From: William Hubbs <williamh@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-apps/openrc/
Date: Tue, 28 Nov 2017 18:58:38
Message-Id: 1511895506.5bccb25dcbc3c99871c8f1ccb7c5556693e59bb5.williamh@gentoo
1 commit: 5bccb25dcbc3c99871c8f1ccb7c5556693e59bb5
2 Author: William Hubbs <williamh <AT> gentoo <DOT> org>
3 AuthorDate: Tue Nov 28 18:58:00 2017 +0000
4 Commit: William Hubbs <williamh <AT> gentoo <DOT> org>
5 CommitDate: Tue Nov 28 18:58:26 2017 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5bccb25d
7
8 sys-apps/openrc: remove multiple unstable versions
9
10 Package-Manager: Portage-2.3.13, Repoman-2.3.3
11
12 sys-apps/openrc/Manifest | 19 --
13 sys-apps/openrc/openrc-0.27.2.ebuild | 329 -----------------------------------
14 sys-apps/openrc/openrc-0.29.ebuild | 329 -----------------------------------
15 sys-apps/openrc/openrc-0.30.ebuild | 329 -----------------------------------
16 sys-apps/openrc/openrc-0.31.1.ebuild | 329 -----------------------------------
17 sys-apps/openrc/openrc-0.31.2.ebuild | 329 -----------------------------------
18 sys-apps/openrc/openrc-0.31.ebuild | 329 -----------------------------------
19 sys-apps/openrc/openrc-0.32.ebuild | 329 -----------------------------------
20 sys-apps/openrc/openrc-0.33.1.ebuild | 329 -----------------------------------
21 sys-apps/openrc/openrc-0.33.ebuild | 329 -----------------------------------
22 sys-apps/openrc/openrc-0.34.1.ebuild | 329 -----------------------------------
23 sys-apps/openrc/openrc-0.34.2.ebuild | 329 -----------------------------------
24 sys-apps/openrc/openrc-0.34.3.ebuild | 329 -----------------------------------
25 sys-apps/openrc/openrc-0.34.4.ebuild | 329 -----------------------------------
26 sys-apps/openrc/openrc-0.34.5.ebuild | 329 -----------------------------------
27 sys-apps/openrc/openrc-0.34.6.ebuild | 329 -----------------------------------
28 sys-apps/openrc/openrc-0.34.7.ebuild | 329 -----------------------------------
29 sys-apps/openrc/openrc-0.34.8.ebuild | 329 -----------------------------------
30 sys-apps/openrc/openrc-0.34.9.ebuild | 329 -----------------------------------
31 sys-apps/openrc/openrc-0.34.ebuild | 329 -----------------------------------
32 20 files changed, 6270 deletions(-)
33
34 diff --git a/sys-apps/openrc/Manifest b/sys-apps/openrc/Manifest
35 index b5ce61a81a0..ab733857b49 100644
36 --- a/sys-apps/openrc/Manifest
37 +++ b/sys-apps/openrc/Manifest
38 @@ -1,22 +1,3 @@
39 -DIST openrc-0.27.2.tar.gz 223572 BLAKE2B 41351ec87f45413b9e7785e62f5caa3ff09eee76c574d1e5ca6f2c3cf3375628c5921be10efbbcb89a49bc99219341f89a0268be657d60abc00d16cda2059bb5 SHA512 a3f3ed8f6dbd188065fc4ed0af1e4ca0d203dbad092bc67405bea182be359bf37c9c94cb97d898c0d34befef92e9d8a2f6a8b4bafe7e95fcaa291b5d0aabed22
40 DIST openrc-0.28.tar.gz 224228 BLAKE2B 6f4693003aba77148bb5ed3516c1372e3ca67364a25d866fce418ba6a287a8cc0c33534cbe1edcdab32a869f8f8dc72819fb2dffc46375bca1e053fb3acf415b SHA512 a10c293bf4287bcc4ffb9c996cbc1294f979483ea9fb2efb0dd1becee193f49ff114530c078850e8c11cf2c0a812be2e74801352fdbfe313b90cd9af5b8ccf93
41 -DIST openrc-0.29.tar.gz 223275 BLAKE2B 80a114204ffdf646ea0f0974a95ba7e88cac008b0b849d7471265b9a879653123738972a573bcecd474a3705f7ed1beba42210d010d253cb256ca7beed7106fd SHA512 1accc52c3e729432fee433395eb7551fa7913004999c595f6485a0505b7916338df6d9e7d95304e865adf67df54378525a758b34bb67beefe240a90700e4f7d8
42 -DIST openrc-0.30.tar.gz 222383 BLAKE2B 69c9e388441994428efa1e8614db2129c5d1410d657fa895d9e43bbf0d5195d646a1f2cda016ac7e7930d5a110cacfff9f5377849bc7778ee09e6edea1486db1 SHA512 d1893adc776184cdb9a7ab884250d29357d1e4855f5f1f93577e6ca2ff30f3233d263d237672395caaff6e479bcba5e52c31c9089e8904ed70b40a29f10864cb
43 -DIST openrc-0.31.1.tar.gz 224059 BLAKE2B b5ef4a91e1ff4c50ac13dafca5547ef49b0aaad124e3c583c70966464e4abdb7165af66a7ada299bf9e062fd44ffc72a5733ce41847228351c2ae20409a2e998 SHA512 98001e05896d113e20fad27ba100e2db5588262cb9c0b52c2800b38fd320b9baf4a99302044ef4045ba3a746d685d0cc27f8fdb42dccbc0574e32c6db9e6d3d2
44 -DIST openrc-0.31.2.tar.gz 224891 BLAKE2B 0788122892fda26a4fce20b3a748282062411b26ac6b23e99d5e2cb8115d04ab9e82ed624815dd04cf8115e7e65f7dc3791d30878f23db6ed22726cff5e72fd5 SHA512 c7a43eddd0652b8b9a62914d7aebcb6eab5fbd8f041a25f95c68f15c97eab3d27802a335da3703ce1e9828bd9a4fdc7e7c311075b875164af024c82a181b10df
45 -DIST openrc-0.31.tar.gz 223966 BLAKE2B 4b104483438bc9a6e8a84c6701bfafa46b4119ddb68fdd39f8c8a0160ce136bf9096dbafc99551932a7d918d91d864f0dfe09f16e6e3f0c5148fccdc8cab3421 SHA512 2c28daa5b2bfd3c31a2b87b08a7b39dc078ab0224c713a2b738e991f968f07d4761770a813fb449df551d6e3db58ed997ac8bbe210d1fb17b4c88ead859eba7b
46 DIST openrc-0.32.1.tar.gz 223808 BLAKE2B 4aadd36e371de56d5c2b59597ab04c1b004be73e370fa00560b77ab0587ba49fb4a49608aba4ad85ed7279eadf54e023961e25784e3078edeed4891956995f38 SHA512 9cd48978fcd69a6d80b474a06b56550cc8c538d6d7a1cb6f88b90087593eebb8185ee5192ec05be2f87f61de53dbe6ded9058aee7ae8f806bb0d7d7da70f62d8
47 -DIST openrc-0.32.tar.gz 223935 BLAKE2B a5b3426feb6ba6599662ecfb4975208658ac2a6a0a222478199c5aee71f20a3fef35508ac552f67caeaace3a18b0d4f9775ca4ff655d9901482cae04289943dd SHA512 a355ba31d50b1c58f724d446449a8e31bb6f4c13b2da886880579e2666bcefe612a4eae64732f3ef7549fbfc84f3e088c4ca98e6be30108adfbf0a6d648d2635
48 -DIST openrc-0.33.1.tar.gz 224256 BLAKE2B cd8c4fa21e6a1341ad16a0cdf7289af63fbcccc7c35e0858b66e3b7f4030de6c420465c04a7886931679b7c094e345076e9a0e34fd58a54f7e0d75897b0a2015 SHA512 87388e96e2e4a1100699ed816a4bd71307d237b9e8013d48ecaaf453170cdb27bf642a6a227a3f934580e1f1f5985337fab50164b69b28489ee7f2813802f883
49 -DIST openrc-0.33.tar.gz 224148 BLAKE2B 8982423f45f170d5a447806aba5d0da33796eb9bb0325bf3b684e5460770020324d48690fb7094c267d1e14fbcf87871e7c377a23ac23fb0bef37f38eb73666a SHA512 6c4b27f3c433f418ae205074214697697b8e124110db2985200a698b4123bac468aa962026ca638c2c1b71e5b3121bfe5280a34d7a954a0aa1ede0b79dfab18e
50 -DIST openrc-0.34.1.tar.gz 225744 BLAKE2B 66669b6fe1532410bdd25114d77add711fcbc03dbfca1de83eaaad49efc26d41c75776b93898bc658a27955eca1f1d70a2c0ae7593069cde6ad174748c4d915d SHA512 dbb6fd3af5c3020a16b010c7b242c7506390ad53dc961c32339149b89cca597c34c632d0ad71b450034e2466221653bed29b3e1e6c6da15987d04c6981c0392d
51 DIST openrc-0.34.10.tar.gz 227909 BLAKE2B 7f9ca169d03c785d7629d227023f947dd3a70a420ff8043ece075924ea5a7d803c78572cef1e5310dbda44c1b905a681301493785137acb9bdbd8a21ccf44093 SHA512 7df66a9e7aeeecb9109e4231e4be4e42cca8e9ad77486cace3a4969af1e4d0bac2522cf832a40990e81e0022598732cd12f07e55f21e576af07144fae538df6f
52 -DIST openrc-0.34.2.tar.gz 226006 BLAKE2B d4916b5f005f331be2bf359f2707540d8a3b9ccecfb9ae0e03cbc8aef17043d4800d0c1d28a7adccad0fdf28a5f73548c7ef8b5b2889cfe584f16fef71c863d4 SHA512 67a26babf5e0026aaebed45eab1ac667531c347f2ba76ad6d3fb60731d95880b831a330f4ac8996188264bdf563b583b6cdcb0002d7ace8327928b78226a29a1
53 -DIST openrc-0.34.3.tar.gz 226693 BLAKE2B 76a2785a015102f75ea86c28f1b7e574f2717097b7a3451b8c0d6f8526096a941ce79032118a1ec54f1ef74ecffcda2f1a0a140bd4ab3c3504b34fa1a9506e70 SHA512 516849d20fba93cf560aaeb51b29fa495265b317b37fc48e193876b131f770665235560fcb2e64e7c7a8046699daafee170887cdb19144938cbf669724505f3b
54 -DIST openrc-0.34.4.tar.gz 227129 BLAKE2B 1cf3c1522d17fdcda27b26ea94d1b12366d0f4715fd30f79ab068653798aba85eb2076d3062b8278dba5014f91d8ac13629b000f4415435a6112accfd4915032 SHA512 f502a8411929d153d4d2e5e4f4052691c6ff85432eb0b8a5534c7880d9b58b3ac919f04af1f1be38c76cd8dec3740bc718b486c06f06f08ba41d311d963250ec
55 -DIST openrc-0.34.5.tar.gz 227278 BLAKE2B f4e1a1bd8231c12e4b9b3444366eb21e888c3cd96b3c53e5241c1cbcc55bbdcb657fad05c7a5b7b805eaf21907270cc1325ca65fd86968333236beb365e5821a SHA512 2e743b7d8f287bab8c74e9cac46935a7895483fd181d969a8e3a6709ccd6d222255b509730b9165f191626774fc372e426049678796d72e4d43541b8232674c7
56 -DIST openrc-0.34.6.tar.gz 227096 BLAKE2B 622f81216c4b0493362afaf8d9a61808c49efefd32deef6aaec598aae583e5a97286b76cdfb169c7f58f1c668e3a93fb505bd306b3c364ed4d0367f48b155819 SHA512 2e17fbc628c0753f4459678764911d787b8d40f309f978ddbdfdc4dfc5d3033a2ac35be00fb9ad558030249d215b9494a0e5eb43e41d3123aeca032032c82541
57 -DIST openrc-0.34.7.tar.gz 227270 BLAKE2B a2fc2e3bacd2e82122f134f67d9206f94b987316dcada6ea41e80d34f93e7ac3dda2c5a68554fafe545ba764f8af11926e41f19dbceb42662a55fbcfc7540d6c SHA512 2cc8feb18a57418227aebf08224f23561b161766bdacc956c1a8e9b054272538de3ab3ec5245b7b8adba80f242019d56bcb94c390ed1a483015d7720fe3f4f73
58 -DIST openrc-0.34.8.tar.gz 227636 BLAKE2B 1a917b7e8a04e1bed0190c195c6829020450a99cbe19e8d32503210da34fd77eb5ef6043128859f70b03392a67b6f6e997b0a73a541bc58a68e141d09b4c6fb6 SHA512 2309e0d330c35467dd6008f1458ac9680207a4c783d4f4e6008a84a313088cfe796dd134dfec79699b8f9c90002b0ae621bb78a9925b987ae98fbd8ad75b947a
59 -DIST openrc-0.34.9.tar.gz 227686 BLAKE2B c73d2eaf92e54930e22ceb79a6307b2c30f14ff105a38015e34f482fb7c56fe89d67967a4413566a40cbf84b2bbfa2ba3420c8f89f233a173bcf4f60230242e5 SHA512 861113e357a7a662b8995fedd8aa5ba50fdae8890a4dee5413062b7c81305e8a8345a99b12cf8c2faa24966cddd9943ab2e499274ad1ddb5c79538c5d55a4fb1
60 -DIST openrc-0.34.tar.gz 225678 BLAKE2B 81aff0ba0af6eaf63742bf2f9b26be6911bf3795bb514b371286155f70898d8639f230bcf1b11c2d8070a52a4c0874380c0776023456bcf60eadc35046c76b4a SHA512 8ff0e3234db06ddeb7c930251f13ec9e4488e4c9776dfe46bb0c1af09835cb34655084bebb6638eb07e47a7f5ef95c1aaed9d06dfa3eaef9e36e9b7a7910f820
61
62 diff --git a/sys-apps/openrc/openrc-0.27.2.ebuild b/sys-apps/openrc/openrc-0.27.2.ebuild
63 deleted file mode 100644
64 index 278de480e1f..00000000000
65 --- a/sys-apps/openrc/openrc-0.27.2.ebuild
66 +++ /dev/null
67 @@ -1,329 +0,0 @@
68 -# Copyright 1999-2017 Gentoo Foundation
69 -# Distributed under the terms of the GNU General Public License v2
70 -
71 -EAPI=6
72 -
73 -inherit flag-o-matic pam toolchain-funcs
74 -
75 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
76 -HOMEPAGE="https://github.com/openrc/openrc/"
77 -
78 -if [[ ${PV} == "9999" ]]; then
79 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
80 - inherit git-r3
81 -else
82 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
83 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
84 -fi
85 -
86 -LICENSE="BSD-2"
87 -SLOT="0"
88 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
89 - unicode kernel_linux kernel_FreeBSD"
90 -
91 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
92 - ncurses? ( sys-libs/ncurses:0= )
93 - pam? (
94 - sys-auth/pambase
95 - virtual/pam
96 - )
97 - audit? ( sys-process/audit )
98 - kernel_linux? (
99 - sys-process/psmisc
100 - !<sys-process/procps-3.3.9-r2
101 - )
102 - selinux? (
103 - sys-apps/policycoreutils
104 - sys-libs/libselinux
105 - )
106 - !<sys-apps/baselayout-2.1-r1
107 - !<sys-fs/udev-init-scripts-27"
108 -DEPEND="${COMMON_DEPEND}
109 - virtual/os-headers
110 - ncurses? ( virtual/pkgconfig )"
111 -RDEPEND="${COMMON_DEPEND}
112 - !prefix? (
113 - kernel_linux? (
114 - >=sys-apps/sysvinit-2.86-r6[selinux?]
115 - virtual/tmpfiles
116 - )
117 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
118 - )
119 - selinux? (
120 - sec-policy/selinux-base-policy
121 - sec-policy/selinux-openrc
122 - )
123 -"
124 -
125 -PDEPEND="netifrc? ( net-misc/netifrc )"
126 -
127 -src_prepare() {
128 - default
129 -
130 - sed -i 's:0444:0644:' mk/sys.mk || die
131 -
132 - if [[ ${PV} == "9999" ]] ; then
133 - local ver="git-${EGIT_VERSION:0:6}"
134 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
135 - fi
136 -}
137 -
138 -src_compile() {
139 - unset LIBDIR #266688
140 -
141 - MAKE_ARGS="${MAKE_ARGS}
142 - LIBNAME=$(get_libdir)
143 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
144 - MKNET=$(usex newnet)
145 - MKSELINUX=$(usex selinux)
146 - MKAUDIT=$(usex audit)
147 - MKPAM=$(usev pam)
148 - MKSTATICLIBS=$(usex static-libs)"
149 -
150 - local brand="Unknown"
151 - if use kernel_linux ; then
152 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
153 - brand="Linux"
154 - elif use kernel_FreeBSD ; then
155 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
156 - brand="FreeBSD"
157 - fi
158 - export BRANDING="Gentoo ${brand}"
159 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
160 - export DEBUG=$(usev debug)
161 - export MKTERMCAP=$(usev ncurses)
162 -
163 - tc-export CC AR RANLIB
164 - emake ${MAKE_ARGS}
165 -}
166 -
167 -# set_config <file> <option name> <yes value> <no value> test
168 -# a value of "#" will just comment out the option
169 -set_config() {
170 - local file="${ED}/$1" var=$2 val com
171 - eval "${@:5}" && val=$3 || val=$4
172 - [[ ${val} == "#" ]] && com="#" && val='\2'
173 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
174 -}
175 -
176 -set_config_yes_no() {
177 - set_config "$1" "$2" YES NO "${@:3}"
178 -}
179 -
180 -src_install() {
181 - emake ${MAKE_ARGS} DESTDIR="${D}" install
182 -
183 - # move the shared libs back to /usr so ldscript can install
184 - # more of a minimal set of files
185 - # disabled for now due to #270646
186 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
187 - #gen_usr_ldscript -a einfo rc
188 - gen_usr_ldscript libeinfo.so
189 - gen_usr_ldscript librc.so
190 -
191 - if ! use kernel_linux; then
192 - keepdir /$(get_libdir)/rc/init.d
193 - fi
194 - keepdir /$(get_libdir)/rc/tmp
195 -
196 - # Backup our default runlevels
197 - dodir /usr/share/"${PN}"
198 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
199 - rm -rf "${ED}"/etc/runlevels
200 -
201 - # Setup unicode defaults for silly unicode users
202 - set_config_yes_no /etc/rc.conf unicode use unicode
203 -
204 - # Cater to the norm
205 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
206 -
207 - # On HPPA, do not run consolefont by default (bug #222889)
208 - if use hppa; then
209 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
210 - fi
211 -
212 - # Support for logfile rotation
213 - insinto /etc/logrotate.d
214 - newins "${FILESDIR}"/openrc.logrotate openrc
215 -
216 - # install gentoo pam.d files
217 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
218 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
219 -
220 - # install documentation
221 - dodoc ChangeLog *.md
222 - if use newnet; then
223 - dodoc README.newnet
224 - fi
225 -}
226 -
227 -add_boot_init() {
228 - local initd=$1
229 - local runlevel=${2:-boot}
230 - # if the initscript is not going to be installed and is not
231 - # currently installed, return
232 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
233 - || return
234 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
235 -
236 - # if runlevels dont exist just yet, then create it but still flag
237 - # to pkg_postinst that it needs real setup #277323
238 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
239 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
240 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
241 - fi
242 -
243 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
244 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
245 -}
246 -add_boot_init_mit_config() {
247 - local config=$1 initd=$2
248 - if [[ -e ${EROOT}${config} ]] ; then
249 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
250 - add_boot_init ${initd}
251 - fi
252 - fi
253 -}
254 -
255 -pkg_preinst() {
256 - local f LIBDIR=$(get_libdir)
257 -
258 - # avoid default thrashing in conf.d files when possible #295406
259 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
260 - (
261 - unset hostname HOSTNAME
262 - source "${EROOT}"etc/conf.d/hostname
263 - : ${hostname:=${HOSTNAME}}
264 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
265 - )
266 - fi
267 -
268 - # set default interactive shell to sulogin if it exists
269 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
270 -
271 - # termencoding was added in 0.2.1 and needed in boot
272 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
273 -
274 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
275 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
276 -
277 - if ! has_version ">=sys-apps/openrc-0.11"; then
278 - add_boot_init sysfs sysinit
279 - fi
280 -
281 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
282 - migrate_udev_mount_script
283 - add_boot_init tmpfiles.setup boot
284 - fi
285 -
286 - # these were added in 0.12.
287 - if ! has_version ">=sys-apps/openrc-0.12"; then
288 - add_boot_init loopback
289 - add_boot_init tmpfiles.dev sysinit
290 -
291 - # ensure existing /etc/conf.d/net is not removed
292 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
293 - # this needs to stay in openrc ebuilds for a long time. :(
294 - # Added in 0.12.
295 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
296 - einfo "Modifying conf.d/net to keep it from being removed"
297 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
298 -
299 -# The network scripts are now part of net-misc/netifrc
300 -# In order to avoid sys-apps/${P} from removing this file, this comment was
301 -# added; you can safely remove this comment. Please see
302 -# /usr/share/doc/netifrc*/README* for more information.
303 -EOF
304 - fi
305 - fi
306 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
307 -
308 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
309 - add_boot_init mtab
310 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
311 - ewarn "${EROOT}etc/mtab will be replaced with a"
312 - ewarn "symbolic link to /proc/self/mounts on the next"
313 - ewarn "reboot."
314 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
315 - ewarn "if you do not want this to happen."
316 - fi
317 - fi
318 -}
319 -
320 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
321 -migrate_udev_mount_script() {
322 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
323 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
324 - add_boot_init udev-mount sysinit
325 - fi
326 - return 0
327 -}
328 -
329 -pkg_postinst() {
330 - local LIBDIR=$(get_libdir)
331 -
332 - # Make our runlevels if they don't exist
333 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
334 - einfo "Copying across default runlevels"
335 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
336 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
337 - else
338 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
339 - mkdir -p "${EROOT}"etc/runlevels/sysinit
340 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
341 - "${EROOT}"etc/runlevels/sysinit
342 - fi
343 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
344 - mkdir -p "${EROOT}"etc/runlevels/shutdown
345 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
346 - "${EROOT}"etc/runlevels/shutdown
347 - fi
348 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
349 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
350 - "${EROOT}"etc/runlevels
351 - fi
352 - fi
353 -
354 - if use hppa; then
355 - elog "Setting the console font does not work on all HPPA consoles."
356 - elog "You can still enable it by running:"
357 - elog "# rc-update add consolefont boot"
358 - fi
359 -
360 - # Handle the conf.d/local.{start,stop} -> local.d transition
361 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
362 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
363 - elog "files to ${EROOT}etc/local.d"
364 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
365 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
366 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
367 - fi
368 -
369 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
370 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
371 - ewarn "The dependency data could not be migrated to /run/openrc."
372 - ewarn "This means you need to reboot your system."
373 - fi
374 - fi
375 -
376 - # update the dependency tree after touching all files #224171
377 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
378 -
379 - if ! use newnet && ! use netifrc; then
380 - ewarn "You have emerged OpenRc without network support. This"
381 - ewarn "means you need to SET UP a network manager such as"
382 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
383 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
384 - ewarn "Or, you have the option of emerging openrc with the newnet"
385 - ewarn "use flag and configuring /etc/conf.d/network and"
386 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
387 - ewarn
388 - fi
389 -
390 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
391 - ewarn "Please add the network service to your boot runlevel"
392 - ewarn "as soon as possible. Not doing so could leave you with a system"
393 - ewarn "without networking."
394 - ewarn
395 - fi
396 -}
397
398 diff --git a/sys-apps/openrc/openrc-0.29.ebuild b/sys-apps/openrc/openrc-0.29.ebuild
399 deleted file mode 100644
400 index 278de480e1f..00000000000
401 --- a/sys-apps/openrc/openrc-0.29.ebuild
402 +++ /dev/null
403 @@ -1,329 +0,0 @@
404 -# Copyright 1999-2017 Gentoo Foundation
405 -# Distributed under the terms of the GNU General Public License v2
406 -
407 -EAPI=6
408 -
409 -inherit flag-o-matic pam toolchain-funcs
410 -
411 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
412 -HOMEPAGE="https://github.com/openrc/openrc/"
413 -
414 -if [[ ${PV} == "9999" ]]; then
415 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
416 - inherit git-r3
417 -else
418 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
419 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
420 -fi
421 -
422 -LICENSE="BSD-2"
423 -SLOT="0"
424 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
425 - unicode kernel_linux kernel_FreeBSD"
426 -
427 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
428 - ncurses? ( sys-libs/ncurses:0= )
429 - pam? (
430 - sys-auth/pambase
431 - virtual/pam
432 - )
433 - audit? ( sys-process/audit )
434 - kernel_linux? (
435 - sys-process/psmisc
436 - !<sys-process/procps-3.3.9-r2
437 - )
438 - selinux? (
439 - sys-apps/policycoreutils
440 - sys-libs/libselinux
441 - )
442 - !<sys-apps/baselayout-2.1-r1
443 - !<sys-fs/udev-init-scripts-27"
444 -DEPEND="${COMMON_DEPEND}
445 - virtual/os-headers
446 - ncurses? ( virtual/pkgconfig )"
447 -RDEPEND="${COMMON_DEPEND}
448 - !prefix? (
449 - kernel_linux? (
450 - >=sys-apps/sysvinit-2.86-r6[selinux?]
451 - virtual/tmpfiles
452 - )
453 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
454 - )
455 - selinux? (
456 - sec-policy/selinux-base-policy
457 - sec-policy/selinux-openrc
458 - )
459 -"
460 -
461 -PDEPEND="netifrc? ( net-misc/netifrc )"
462 -
463 -src_prepare() {
464 - default
465 -
466 - sed -i 's:0444:0644:' mk/sys.mk || die
467 -
468 - if [[ ${PV} == "9999" ]] ; then
469 - local ver="git-${EGIT_VERSION:0:6}"
470 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
471 - fi
472 -}
473 -
474 -src_compile() {
475 - unset LIBDIR #266688
476 -
477 - MAKE_ARGS="${MAKE_ARGS}
478 - LIBNAME=$(get_libdir)
479 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
480 - MKNET=$(usex newnet)
481 - MKSELINUX=$(usex selinux)
482 - MKAUDIT=$(usex audit)
483 - MKPAM=$(usev pam)
484 - MKSTATICLIBS=$(usex static-libs)"
485 -
486 - local brand="Unknown"
487 - if use kernel_linux ; then
488 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
489 - brand="Linux"
490 - elif use kernel_FreeBSD ; then
491 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
492 - brand="FreeBSD"
493 - fi
494 - export BRANDING="Gentoo ${brand}"
495 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
496 - export DEBUG=$(usev debug)
497 - export MKTERMCAP=$(usev ncurses)
498 -
499 - tc-export CC AR RANLIB
500 - emake ${MAKE_ARGS}
501 -}
502 -
503 -# set_config <file> <option name> <yes value> <no value> test
504 -# a value of "#" will just comment out the option
505 -set_config() {
506 - local file="${ED}/$1" var=$2 val com
507 - eval "${@:5}" && val=$3 || val=$4
508 - [[ ${val} == "#" ]] && com="#" && val='\2'
509 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
510 -}
511 -
512 -set_config_yes_no() {
513 - set_config "$1" "$2" YES NO "${@:3}"
514 -}
515 -
516 -src_install() {
517 - emake ${MAKE_ARGS} DESTDIR="${D}" install
518 -
519 - # move the shared libs back to /usr so ldscript can install
520 - # more of a minimal set of files
521 - # disabled for now due to #270646
522 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
523 - #gen_usr_ldscript -a einfo rc
524 - gen_usr_ldscript libeinfo.so
525 - gen_usr_ldscript librc.so
526 -
527 - if ! use kernel_linux; then
528 - keepdir /$(get_libdir)/rc/init.d
529 - fi
530 - keepdir /$(get_libdir)/rc/tmp
531 -
532 - # Backup our default runlevels
533 - dodir /usr/share/"${PN}"
534 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
535 - rm -rf "${ED}"/etc/runlevels
536 -
537 - # Setup unicode defaults for silly unicode users
538 - set_config_yes_no /etc/rc.conf unicode use unicode
539 -
540 - # Cater to the norm
541 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
542 -
543 - # On HPPA, do not run consolefont by default (bug #222889)
544 - if use hppa; then
545 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
546 - fi
547 -
548 - # Support for logfile rotation
549 - insinto /etc/logrotate.d
550 - newins "${FILESDIR}"/openrc.logrotate openrc
551 -
552 - # install gentoo pam.d files
553 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
554 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
555 -
556 - # install documentation
557 - dodoc ChangeLog *.md
558 - if use newnet; then
559 - dodoc README.newnet
560 - fi
561 -}
562 -
563 -add_boot_init() {
564 - local initd=$1
565 - local runlevel=${2:-boot}
566 - # if the initscript is not going to be installed and is not
567 - # currently installed, return
568 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
569 - || return
570 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
571 -
572 - # if runlevels dont exist just yet, then create it but still flag
573 - # to pkg_postinst that it needs real setup #277323
574 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
575 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
576 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
577 - fi
578 -
579 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
580 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
581 -}
582 -add_boot_init_mit_config() {
583 - local config=$1 initd=$2
584 - if [[ -e ${EROOT}${config} ]] ; then
585 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
586 - add_boot_init ${initd}
587 - fi
588 - fi
589 -}
590 -
591 -pkg_preinst() {
592 - local f LIBDIR=$(get_libdir)
593 -
594 - # avoid default thrashing in conf.d files when possible #295406
595 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
596 - (
597 - unset hostname HOSTNAME
598 - source "${EROOT}"etc/conf.d/hostname
599 - : ${hostname:=${HOSTNAME}}
600 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
601 - )
602 - fi
603 -
604 - # set default interactive shell to sulogin if it exists
605 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
606 -
607 - # termencoding was added in 0.2.1 and needed in boot
608 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
609 -
610 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
611 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
612 -
613 - if ! has_version ">=sys-apps/openrc-0.11"; then
614 - add_boot_init sysfs sysinit
615 - fi
616 -
617 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
618 - migrate_udev_mount_script
619 - add_boot_init tmpfiles.setup boot
620 - fi
621 -
622 - # these were added in 0.12.
623 - if ! has_version ">=sys-apps/openrc-0.12"; then
624 - add_boot_init loopback
625 - add_boot_init tmpfiles.dev sysinit
626 -
627 - # ensure existing /etc/conf.d/net is not removed
628 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
629 - # this needs to stay in openrc ebuilds for a long time. :(
630 - # Added in 0.12.
631 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
632 - einfo "Modifying conf.d/net to keep it from being removed"
633 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
634 -
635 -# The network scripts are now part of net-misc/netifrc
636 -# In order to avoid sys-apps/${P} from removing this file, this comment was
637 -# added; you can safely remove this comment. Please see
638 -# /usr/share/doc/netifrc*/README* for more information.
639 -EOF
640 - fi
641 - fi
642 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
643 -
644 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
645 - add_boot_init mtab
646 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
647 - ewarn "${EROOT}etc/mtab will be replaced with a"
648 - ewarn "symbolic link to /proc/self/mounts on the next"
649 - ewarn "reboot."
650 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
651 - ewarn "if you do not want this to happen."
652 - fi
653 - fi
654 -}
655 -
656 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
657 -migrate_udev_mount_script() {
658 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
659 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
660 - add_boot_init udev-mount sysinit
661 - fi
662 - return 0
663 -}
664 -
665 -pkg_postinst() {
666 - local LIBDIR=$(get_libdir)
667 -
668 - # Make our runlevels if they don't exist
669 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
670 - einfo "Copying across default runlevels"
671 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
672 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
673 - else
674 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
675 - mkdir -p "${EROOT}"etc/runlevels/sysinit
676 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
677 - "${EROOT}"etc/runlevels/sysinit
678 - fi
679 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
680 - mkdir -p "${EROOT}"etc/runlevels/shutdown
681 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
682 - "${EROOT}"etc/runlevels/shutdown
683 - fi
684 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
685 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
686 - "${EROOT}"etc/runlevels
687 - fi
688 - fi
689 -
690 - if use hppa; then
691 - elog "Setting the console font does not work on all HPPA consoles."
692 - elog "You can still enable it by running:"
693 - elog "# rc-update add consolefont boot"
694 - fi
695 -
696 - # Handle the conf.d/local.{start,stop} -> local.d transition
697 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
698 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
699 - elog "files to ${EROOT}etc/local.d"
700 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
701 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
702 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
703 - fi
704 -
705 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
706 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
707 - ewarn "The dependency data could not be migrated to /run/openrc."
708 - ewarn "This means you need to reboot your system."
709 - fi
710 - fi
711 -
712 - # update the dependency tree after touching all files #224171
713 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
714 -
715 - if ! use newnet && ! use netifrc; then
716 - ewarn "You have emerged OpenRc without network support. This"
717 - ewarn "means you need to SET UP a network manager such as"
718 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
719 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
720 - ewarn "Or, you have the option of emerging openrc with the newnet"
721 - ewarn "use flag and configuring /etc/conf.d/network and"
722 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
723 - ewarn
724 - fi
725 -
726 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
727 - ewarn "Please add the network service to your boot runlevel"
728 - ewarn "as soon as possible. Not doing so could leave you with a system"
729 - ewarn "without networking."
730 - ewarn
731 - fi
732 -}
733
734 diff --git a/sys-apps/openrc/openrc-0.30.ebuild b/sys-apps/openrc/openrc-0.30.ebuild
735 deleted file mode 100644
736 index 278de480e1f..00000000000
737 --- a/sys-apps/openrc/openrc-0.30.ebuild
738 +++ /dev/null
739 @@ -1,329 +0,0 @@
740 -# Copyright 1999-2017 Gentoo Foundation
741 -# Distributed under the terms of the GNU General Public License v2
742 -
743 -EAPI=6
744 -
745 -inherit flag-o-matic pam toolchain-funcs
746 -
747 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
748 -HOMEPAGE="https://github.com/openrc/openrc/"
749 -
750 -if [[ ${PV} == "9999" ]]; then
751 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
752 - inherit git-r3
753 -else
754 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
755 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
756 -fi
757 -
758 -LICENSE="BSD-2"
759 -SLOT="0"
760 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
761 - unicode kernel_linux kernel_FreeBSD"
762 -
763 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
764 - ncurses? ( sys-libs/ncurses:0= )
765 - pam? (
766 - sys-auth/pambase
767 - virtual/pam
768 - )
769 - audit? ( sys-process/audit )
770 - kernel_linux? (
771 - sys-process/psmisc
772 - !<sys-process/procps-3.3.9-r2
773 - )
774 - selinux? (
775 - sys-apps/policycoreutils
776 - sys-libs/libselinux
777 - )
778 - !<sys-apps/baselayout-2.1-r1
779 - !<sys-fs/udev-init-scripts-27"
780 -DEPEND="${COMMON_DEPEND}
781 - virtual/os-headers
782 - ncurses? ( virtual/pkgconfig )"
783 -RDEPEND="${COMMON_DEPEND}
784 - !prefix? (
785 - kernel_linux? (
786 - >=sys-apps/sysvinit-2.86-r6[selinux?]
787 - virtual/tmpfiles
788 - )
789 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
790 - )
791 - selinux? (
792 - sec-policy/selinux-base-policy
793 - sec-policy/selinux-openrc
794 - )
795 -"
796 -
797 -PDEPEND="netifrc? ( net-misc/netifrc )"
798 -
799 -src_prepare() {
800 - default
801 -
802 - sed -i 's:0444:0644:' mk/sys.mk || die
803 -
804 - if [[ ${PV} == "9999" ]] ; then
805 - local ver="git-${EGIT_VERSION:0:6}"
806 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
807 - fi
808 -}
809 -
810 -src_compile() {
811 - unset LIBDIR #266688
812 -
813 - MAKE_ARGS="${MAKE_ARGS}
814 - LIBNAME=$(get_libdir)
815 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
816 - MKNET=$(usex newnet)
817 - MKSELINUX=$(usex selinux)
818 - MKAUDIT=$(usex audit)
819 - MKPAM=$(usev pam)
820 - MKSTATICLIBS=$(usex static-libs)"
821 -
822 - local brand="Unknown"
823 - if use kernel_linux ; then
824 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
825 - brand="Linux"
826 - elif use kernel_FreeBSD ; then
827 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
828 - brand="FreeBSD"
829 - fi
830 - export BRANDING="Gentoo ${brand}"
831 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
832 - export DEBUG=$(usev debug)
833 - export MKTERMCAP=$(usev ncurses)
834 -
835 - tc-export CC AR RANLIB
836 - emake ${MAKE_ARGS}
837 -}
838 -
839 -# set_config <file> <option name> <yes value> <no value> test
840 -# a value of "#" will just comment out the option
841 -set_config() {
842 - local file="${ED}/$1" var=$2 val com
843 - eval "${@:5}" && val=$3 || val=$4
844 - [[ ${val} == "#" ]] && com="#" && val='\2'
845 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
846 -}
847 -
848 -set_config_yes_no() {
849 - set_config "$1" "$2" YES NO "${@:3}"
850 -}
851 -
852 -src_install() {
853 - emake ${MAKE_ARGS} DESTDIR="${D}" install
854 -
855 - # move the shared libs back to /usr so ldscript can install
856 - # more of a minimal set of files
857 - # disabled for now due to #270646
858 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
859 - #gen_usr_ldscript -a einfo rc
860 - gen_usr_ldscript libeinfo.so
861 - gen_usr_ldscript librc.so
862 -
863 - if ! use kernel_linux; then
864 - keepdir /$(get_libdir)/rc/init.d
865 - fi
866 - keepdir /$(get_libdir)/rc/tmp
867 -
868 - # Backup our default runlevels
869 - dodir /usr/share/"${PN}"
870 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
871 - rm -rf "${ED}"/etc/runlevels
872 -
873 - # Setup unicode defaults for silly unicode users
874 - set_config_yes_no /etc/rc.conf unicode use unicode
875 -
876 - # Cater to the norm
877 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
878 -
879 - # On HPPA, do not run consolefont by default (bug #222889)
880 - if use hppa; then
881 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
882 - fi
883 -
884 - # Support for logfile rotation
885 - insinto /etc/logrotate.d
886 - newins "${FILESDIR}"/openrc.logrotate openrc
887 -
888 - # install gentoo pam.d files
889 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
890 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
891 -
892 - # install documentation
893 - dodoc ChangeLog *.md
894 - if use newnet; then
895 - dodoc README.newnet
896 - fi
897 -}
898 -
899 -add_boot_init() {
900 - local initd=$1
901 - local runlevel=${2:-boot}
902 - # if the initscript is not going to be installed and is not
903 - # currently installed, return
904 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
905 - || return
906 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
907 -
908 - # if runlevels dont exist just yet, then create it but still flag
909 - # to pkg_postinst that it needs real setup #277323
910 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
911 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
912 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
913 - fi
914 -
915 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
916 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
917 -}
918 -add_boot_init_mit_config() {
919 - local config=$1 initd=$2
920 - if [[ -e ${EROOT}${config} ]] ; then
921 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
922 - add_boot_init ${initd}
923 - fi
924 - fi
925 -}
926 -
927 -pkg_preinst() {
928 - local f LIBDIR=$(get_libdir)
929 -
930 - # avoid default thrashing in conf.d files when possible #295406
931 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
932 - (
933 - unset hostname HOSTNAME
934 - source "${EROOT}"etc/conf.d/hostname
935 - : ${hostname:=${HOSTNAME}}
936 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
937 - )
938 - fi
939 -
940 - # set default interactive shell to sulogin if it exists
941 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
942 -
943 - # termencoding was added in 0.2.1 and needed in boot
944 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
945 -
946 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
947 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
948 -
949 - if ! has_version ">=sys-apps/openrc-0.11"; then
950 - add_boot_init sysfs sysinit
951 - fi
952 -
953 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
954 - migrate_udev_mount_script
955 - add_boot_init tmpfiles.setup boot
956 - fi
957 -
958 - # these were added in 0.12.
959 - if ! has_version ">=sys-apps/openrc-0.12"; then
960 - add_boot_init loopback
961 - add_boot_init tmpfiles.dev sysinit
962 -
963 - # ensure existing /etc/conf.d/net is not removed
964 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
965 - # this needs to stay in openrc ebuilds for a long time. :(
966 - # Added in 0.12.
967 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
968 - einfo "Modifying conf.d/net to keep it from being removed"
969 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
970 -
971 -# The network scripts are now part of net-misc/netifrc
972 -# In order to avoid sys-apps/${P} from removing this file, this comment was
973 -# added; you can safely remove this comment. Please see
974 -# /usr/share/doc/netifrc*/README* for more information.
975 -EOF
976 - fi
977 - fi
978 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
979 -
980 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
981 - add_boot_init mtab
982 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
983 - ewarn "${EROOT}etc/mtab will be replaced with a"
984 - ewarn "symbolic link to /proc/self/mounts on the next"
985 - ewarn "reboot."
986 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
987 - ewarn "if you do not want this to happen."
988 - fi
989 - fi
990 -}
991 -
992 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
993 -migrate_udev_mount_script() {
994 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
995 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
996 - add_boot_init udev-mount sysinit
997 - fi
998 - return 0
999 -}
1000 -
1001 -pkg_postinst() {
1002 - local LIBDIR=$(get_libdir)
1003 -
1004 - # Make our runlevels if they don't exist
1005 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
1006 - einfo "Copying across default runlevels"
1007 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
1008 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
1009 - else
1010 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
1011 - mkdir -p "${EROOT}"etc/runlevels/sysinit
1012 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
1013 - "${EROOT}"etc/runlevels/sysinit
1014 - fi
1015 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
1016 - mkdir -p "${EROOT}"etc/runlevels/shutdown
1017 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
1018 - "${EROOT}"etc/runlevels/shutdown
1019 - fi
1020 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
1021 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
1022 - "${EROOT}"etc/runlevels
1023 - fi
1024 - fi
1025 -
1026 - if use hppa; then
1027 - elog "Setting the console font does not work on all HPPA consoles."
1028 - elog "You can still enable it by running:"
1029 - elog "# rc-update add consolefont boot"
1030 - fi
1031 -
1032 - # Handle the conf.d/local.{start,stop} -> local.d transition
1033 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
1034 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
1035 - elog "files to ${EROOT}etc/local.d"
1036 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
1037 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
1038 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
1039 - fi
1040 -
1041 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
1042 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
1043 - ewarn "The dependency data could not be migrated to /run/openrc."
1044 - ewarn "This means you need to reboot your system."
1045 - fi
1046 - fi
1047 -
1048 - # update the dependency tree after touching all files #224171
1049 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
1050 -
1051 - if ! use newnet && ! use netifrc; then
1052 - ewarn "You have emerged OpenRc without network support. This"
1053 - ewarn "means you need to SET UP a network manager such as"
1054 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
1055 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
1056 - ewarn "Or, you have the option of emerging openrc with the newnet"
1057 - ewarn "use flag and configuring /etc/conf.d/network and"
1058 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
1059 - ewarn
1060 - fi
1061 -
1062 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
1063 - ewarn "Please add the network service to your boot runlevel"
1064 - ewarn "as soon as possible. Not doing so could leave you with a system"
1065 - ewarn "without networking."
1066 - ewarn
1067 - fi
1068 -}
1069
1070 diff --git a/sys-apps/openrc/openrc-0.31.1.ebuild b/sys-apps/openrc/openrc-0.31.1.ebuild
1071 deleted file mode 100644
1072 index 278de480e1f..00000000000
1073 --- a/sys-apps/openrc/openrc-0.31.1.ebuild
1074 +++ /dev/null
1075 @@ -1,329 +0,0 @@
1076 -# Copyright 1999-2017 Gentoo Foundation
1077 -# Distributed under the terms of the GNU General Public License v2
1078 -
1079 -EAPI=6
1080 -
1081 -inherit flag-o-matic pam toolchain-funcs
1082 -
1083 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
1084 -HOMEPAGE="https://github.com/openrc/openrc/"
1085 -
1086 -if [[ ${PV} == "9999" ]]; then
1087 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
1088 - inherit git-r3
1089 -else
1090 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
1091 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
1092 -fi
1093 -
1094 -LICENSE="BSD-2"
1095 -SLOT="0"
1096 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
1097 - unicode kernel_linux kernel_FreeBSD"
1098 -
1099 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
1100 - ncurses? ( sys-libs/ncurses:0= )
1101 - pam? (
1102 - sys-auth/pambase
1103 - virtual/pam
1104 - )
1105 - audit? ( sys-process/audit )
1106 - kernel_linux? (
1107 - sys-process/psmisc
1108 - !<sys-process/procps-3.3.9-r2
1109 - )
1110 - selinux? (
1111 - sys-apps/policycoreutils
1112 - sys-libs/libselinux
1113 - )
1114 - !<sys-apps/baselayout-2.1-r1
1115 - !<sys-fs/udev-init-scripts-27"
1116 -DEPEND="${COMMON_DEPEND}
1117 - virtual/os-headers
1118 - ncurses? ( virtual/pkgconfig )"
1119 -RDEPEND="${COMMON_DEPEND}
1120 - !prefix? (
1121 - kernel_linux? (
1122 - >=sys-apps/sysvinit-2.86-r6[selinux?]
1123 - virtual/tmpfiles
1124 - )
1125 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
1126 - )
1127 - selinux? (
1128 - sec-policy/selinux-base-policy
1129 - sec-policy/selinux-openrc
1130 - )
1131 -"
1132 -
1133 -PDEPEND="netifrc? ( net-misc/netifrc )"
1134 -
1135 -src_prepare() {
1136 - default
1137 -
1138 - sed -i 's:0444:0644:' mk/sys.mk || die
1139 -
1140 - if [[ ${PV} == "9999" ]] ; then
1141 - local ver="git-${EGIT_VERSION:0:6}"
1142 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
1143 - fi
1144 -}
1145 -
1146 -src_compile() {
1147 - unset LIBDIR #266688
1148 -
1149 - MAKE_ARGS="${MAKE_ARGS}
1150 - LIBNAME=$(get_libdir)
1151 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
1152 - MKNET=$(usex newnet)
1153 - MKSELINUX=$(usex selinux)
1154 - MKAUDIT=$(usex audit)
1155 - MKPAM=$(usev pam)
1156 - MKSTATICLIBS=$(usex static-libs)"
1157 -
1158 - local brand="Unknown"
1159 - if use kernel_linux ; then
1160 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
1161 - brand="Linux"
1162 - elif use kernel_FreeBSD ; then
1163 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
1164 - brand="FreeBSD"
1165 - fi
1166 - export BRANDING="Gentoo ${brand}"
1167 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
1168 - export DEBUG=$(usev debug)
1169 - export MKTERMCAP=$(usev ncurses)
1170 -
1171 - tc-export CC AR RANLIB
1172 - emake ${MAKE_ARGS}
1173 -}
1174 -
1175 -# set_config <file> <option name> <yes value> <no value> test
1176 -# a value of "#" will just comment out the option
1177 -set_config() {
1178 - local file="${ED}/$1" var=$2 val com
1179 - eval "${@:5}" && val=$3 || val=$4
1180 - [[ ${val} == "#" ]] && com="#" && val='\2'
1181 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
1182 -}
1183 -
1184 -set_config_yes_no() {
1185 - set_config "$1" "$2" YES NO "${@:3}"
1186 -}
1187 -
1188 -src_install() {
1189 - emake ${MAKE_ARGS} DESTDIR="${D}" install
1190 -
1191 - # move the shared libs back to /usr so ldscript can install
1192 - # more of a minimal set of files
1193 - # disabled for now due to #270646
1194 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
1195 - #gen_usr_ldscript -a einfo rc
1196 - gen_usr_ldscript libeinfo.so
1197 - gen_usr_ldscript librc.so
1198 -
1199 - if ! use kernel_linux; then
1200 - keepdir /$(get_libdir)/rc/init.d
1201 - fi
1202 - keepdir /$(get_libdir)/rc/tmp
1203 -
1204 - # Backup our default runlevels
1205 - dodir /usr/share/"${PN}"
1206 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
1207 - rm -rf "${ED}"/etc/runlevels
1208 -
1209 - # Setup unicode defaults for silly unicode users
1210 - set_config_yes_no /etc/rc.conf unicode use unicode
1211 -
1212 - # Cater to the norm
1213 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
1214 -
1215 - # On HPPA, do not run consolefont by default (bug #222889)
1216 - if use hppa; then
1217 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
1218 - fi
1219 -
1220 - # Support for logfile rotation
1221 - insinto /etc/logrotate.d
1222 - newins "${FILESDIR}"/openrc.logrotate openrc
1223 -
1224 - # install gentoo pam.d files
1225 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
1226 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
1227 -
1228 - # install documentation
1229 - dodoc ChangeLog *.md
1230 - if use newnet; then
1231 - dodoc README.newnet
1232 - fi
1233 -}
1234 -
1235 -add_boot_init() {
1236 - local initd=$1
1237 - local runlevel=${2:-boot}
1238 - # if the initscript is not going to be installed and is not
1239 - # currently installed, return
1240 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
1241 - || return
1242 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
1243 -
1244 - # if runlevels dont exist just yet, then create it but still flag
1245 - # to pkg_postinst that it needs real setup #277323
1246 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
1247 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
1248 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
1249 - fi
1250 -
1251 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
1252 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
1253 -}
1254 -add_boot_init_mit_config() {
1255 - local config=$1 initd=$2
1256 - if [[ -e ${EROOT}${config} ]] ; then
1257 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
1258 - add_boot_init ${initd}
1259 - fi
1260 - fi
1261 -}
1262 -
1263 -pkg_preinst() {
1264 - local f LIBDIR=$(get_libdir)
1265 -
1266 - # avoid default thrashing in conf.d files when possible #295406
1267 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
1268 - (
1269 - unset hostname HOSTNAME
1270 - source "${EROOT}"etc/conf.d/hostname
1271 - : ${hostname:=${HOSTNAME}}
1272 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
1273 - )
1274 - fi
1275 -
1276 - # set default interactive shell to sulogin if it exists
1277 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
1278 -
1279 - # termencoding was added in 0.2.1 and needed in boot
1280 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
1281 -
1282 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
1283 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
1284 -
1285 - if ! has_version ">=sys-apps/openrc-0.11"; then
1286 - add_boot_init sysfs sysinit
1287 - fi
1288 -
1289 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
1290 - migrate_udev_mount_script
1291 - add_boot_init tmpfiles.setup boot
1292 - fi
1293 -
1294 - # these were added in 0.12.
1295 - if ! has_version ">=sys-apps/openrc-0.12"; then
1296 - add_boot_init loopback
1297 - add_boot_init tmpfiles.dev sysinit
1298 -
1299 - # ensure existing /etc/conf.d/net is not removed
1300 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
1301 - # this needs to stay in openrc ebuilds for a long time. :(
1302 - # Added in 0.12.
1303 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
1304 - einfo "Modifying conf.d/net to keep it from being removed"
1305 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
1306 -
1307 -# The network scripts are now part of net-misc/netifrc
1308 -# In order to avoid sys-apps/${P} from removing this file, this comment was
1309 -# added; you can safely remove this comment. Please see
1310 -# /usr/share/doc/netifrc*/README* for more information.
1311 -EOF
1312 - fi
1313 - fi
1314 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
1315 -
1316 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
1317 - add_boot_init mtab
1318 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
1319 - ewarn "${EROOT}etc/mtab will be replaced with a"
1320 - ewarn "symbolic link to /proc/self/mounts on the next"
1321 - ewarn "reboot."
1322 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
1323 - ewarn "if you do not want this to happen."
1324 - fi
1325 - fi
1326 -}
1327 -
1328 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
1329 -migrate_udev_mount_script() {
1330 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
1331 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
1332 - add_boot_init udev-mount sysinit
1333 - fi
1334 - return 0
1335 -}
1336 -
1337 -pkg_postinst() {
1338 - local LIBDIR=$(get_libdir)
1339 -
1340 - # Make our runlevels if they don't exist
1341 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
1342 - einfo "Copying across default runlevels"
1343 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
1344 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
1345 - else
1346 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
1347 - mkdir -p "${EROOT}"etc/runlevels/sysinit
1348 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
1349 - "${EROOT}"etc/runlevels/sysinit
1350 - fi
1351 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
1352 - mkdir -p "${EROOT}"etc/runlevels/shutdown
1353 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
1354 - "${EROOT}"etc/runlevels/shutdown
1355 - fi
1356 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
1357 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
1358 - "${EROOT}"etc/runlevels
1359 - fi
1360 - fi
1361 -
1362 - if use hppa; then
1363 - elog "Setting the console font does not work on all HPPA consoles."
1364 - elog "You can still enable it by running:"
1365 - elog "# rc-update add consolefont boot"
1366 - fi
1367 -
1368 - # Handle the conf.d/local.{start,stop} -> local.d transition
1369 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
1370 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
1371 - elog "files to ${EROOT}etc/local.d"
1372 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
1373 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
1374 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
1375 - fi
1376 -
1377 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
1378 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
1379 - ewarn "The dependency data could not be migrated to /run/openrc."
1380 - ewarn "This means you need to reboot your system."
1381 - fi
1382 - fi
1383 -
1384 - # update the dependency tree after touching all files #224171
1385 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
1386 -
1387 - if ! use newnet && ! use netifrc; then
1388 - ewarn "You have emerged OpenRc without network support. This"
1389 - ewarn "means you need to SET UP a network manager such as"
1390 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
1391 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
1392 - ewarn "Or, you have the option of emerging openrc with the newnet"
1393 - ewarn "use flag and configuring /etc/conf.d/network and"
1394 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
1395 - ewarn
1396 - fi
1397 -
1398 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
1399 - ewarn "Please add the network service to your boot runlevel"
1400 - ewarn "as soon as possible. Not doing so could leave you with a system"
1401 - ewarn "without networking."
1402 - ewarn
1403 - fi
1404 -}
1405
1406 diff --git a/sys-apps/openrc/openrc-0.31.2.ebuild b/sys-apps/openrc/openrc-0.31.2.ebuild
1407 deleted file mode 100644
1408 index 15376774cd7..00000000000
1409 --- a/sys-apps/openrc/openrc-0.31.2.ebuild
1410 +++ /dev/null
1411 @@ -1,329 +0,0 @@
1412 -# Copyright 1999-2017 Gentoo Foundation
1413 -# Distributed under the terms of the GNU General Public License v2
1414 -
1415 -EAPI=6
1416 -
1417 -inherit flag-o-matic pam toolchain-funcs
1418 -
1419 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
1420 -HOMEPAGE="https://github.com/openrc/openrc/"
1421 -
1422 -if [[ ${PV} == "9999" ]]; then
1423 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
1424 - inherit git-r3
1425 -else
1426 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
1427 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
1428 -fi
1429 -
1430 -LICENSE="BSD-2"
1431 -SLOT="0"
1432 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
1433 - unicode kernel_linux kernel_FreeBSD"
1434 -
1435 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
1436 - ncurses? ( sys-libs/ncurses:0= )
1437 - pam? (
1438 - sys-auth/pambase
1439 - virtual/pam
1440 - )
1441 - audit? ( sys-process/audit )
1442 - kernel_linux? (
1443 - sys-process/psmisc
1444 - !<sys-process/procps-3.3.9-r2
1445 - )
1446 - selinux? (
1447 - sys-apps/policycoreutils
1448 - >=sys-libs/libselinux-2.6
1449 - )
1450 - !<sys-apps/baselayout-2.1-r1
1451 - !<sys-fs/udev-init-scripts-27"
1452 -DEPEND="${COMMON_DEPEND}
1453 - virtual/os-headers
1454 - ncurses? ( virtual/pkgconfig )"
1455 -RDEPEND="${COMMON_DEPEND}
1456 - !prefix? (
1457 - kernel_linux? (
1458 - >=sys-apps/sysvinit-2.86-r6[selinux?]
1459 - virtual/tmpfiles
1460 - )
1461 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
1462 - )
1463 - selinux? (
1464 - >=sec-policy/selinux-base-policy-2.20170204-r4
1465 - >=sec-policy/selinux-openrc-2.20170204-r4
1466 - )
1467 -"
1468 -
1469 -PDEPEND="netifrc? ( net-misc/netifrc )"
1470 -
1471 -src_prepare() {
1472 - default
1473 -
1474 - sed -i 's:0444:0644:' mk/sys.mk || die
1475 -
1476 - if [[ ${PV} == "9999" ]] ; then
1477 - local ver="git-${EGIT_VERSION:0:6}"
1478 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
1479 - fi
1480 -}
1481 -
1482 -src_compile() {
1483 - unset LIBDIR #266688
1484 -
1485 - MAKE_ARGS="${MAKE_ARGS}
1486 - LIBNAME=$(get_libdir)
1487 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
1488 - MKNET=$(usex newnet)
1489 - MKSELINUX=$(usex selinux)
1490 - MKAUDIT=$(usex audit)
1491 - MKPAM=$(usev pam)
1492 - MKSTATICLIBS=$(usex static-libs)"
1493 -
1494 - local brand="Unknown"
1495 - if use kernel_linux ; then
1496 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
1497 - brand="Linux"
1498 - elif use kernel_FreeBSD ; then
1499 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
1500 - brand="FreeBSD"
1501 - fi
1502 - export BRANDING="Gentoo ${brand}"
1503 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
1504 - export DEBUG=$(usev debug)
1505 - export MKTERMCAP=$(usev ncurses)
1506 -
1507 - tc-export CC AR RANLIB
1508 - emake ${MAKE_ARGS}
1509 -}
1510 -
1511 -# set_config <file> <option name> <yes value> <no value> test
1512 -# a value of "#" will just comment out the option
1513 -set_config() {
1514 - local file="${ED}/$1" var=$2 val com
1515 - eval "${@:5}" && val=$3 || val=$4
1516 - [[ ${val} == "#" ]] && com="#" && val='\2'
1517 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
1518 -}
1519 -
1520 -set_config_yes_no() {
1521 - set_config "$1" "$2" YES NO "${@:3}"
1522 -}
1523 -
1524 -src_install() {
1525 - emake ${MAKE_ARGS} DESTDIR="${D}" install
1526 -
1527 - # move the shared libs back to /usr so ldscript can install
1528 - # more of a minimal set of files
1529 - # disabled for now due to #270646
1530 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
1531 - #gen_usr_ldscript -a einfo rc
1532 - gen_usr_ldscript libeinfo.so
1533 - gen_usr_ldscript librc.so
1534 -
1535 - if ! use kernel_linux; then
1536 - keepdir /$(get_libdir)/rc/init.d
1537 - fi
1538 - keepdir /$(get_libdir)/rc/tmp
1539 -
1540 - # Backup our default runlevels
1541 - dodir /usr/share/"${PN}"
1542 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
1543 - rm -rf "${ED}"/etc/runlevels
1544 -
1545 - # Setup unicode defaults for silly unicode users
1546 - set_config_yes_no /etc/rc.conf unicode use unicode
1547 -
1548 - # Cater to the norm
1549 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
1550 -
1551 - # On HPPA, do not run consolefont by default (bug #222889)
1552 - if use hppa; then
1553 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
1554 - fi
1555 -
1556 - # Support for logfile rotation
1557 - insinto /etc/logrotate.d
1558 - newins "${FILESDIR}"/openrc.logrotate openrc
1559 -
1560 - # install gentoo pam.d files
1561 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
1562 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
1563 -
1564 - # install documentation
1565 - dodoc ChangeLog *.md
1566 - if use newnet; then
1567 - dodoc README.newnet
1568 - fi
1569 -}
1570 -
1571 -add_boot_init() {
1572 - local initd=$1
1573 - local runlevel=${2:-boot}
1574 - # if the initscript is not going to be installed and is not
1575 - # currently installed, return
1576 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
1577 - || return
1578 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
1579 -
1580 - # if runlevels dont exist just yet, then create it but still flag
1581 - # to pkg_postinst that it needs real setup #277323
1582 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
1583 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
1584 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
1585 - fi
1586 -
1587 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
1588 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
1589 -}
1590 -add_boot_init_mit_config() {
1591 - local config=$1 initd=$2
1592 - if [[ -e ${EROOT}${config} ]] ; then
1593 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
1594 - add_boot_init ${initd}
1595 - fi
1596 - fi
1597 -}
1598 -
1599 -pkg_preinst() {
1600 - local f LIBDIR=$(get_libdir)
1601 -
1602 - # avoid default thrashing in conf.d files when possible #295406
1603 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
1604 - (
1605 - unset hostname HOSTNAME
1606 - source "${EROOT}"etc/conf.d/hostname
1607 - : ${hostname:=${HOSTNAME}}
1608 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
1609 - )
1610 - fi
1611 -
1612 - # set default interactive shell to sulogin if it exists
1613 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
1614 -
1615 - # termencoding was added in 0.2.1 and needed in boot
1616 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
1617 -
1618 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
1619 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
1620 -
1621 - if ! has_version ">=sys-apps/openrc-0.11"; then
1622 - add_boot_init sysfs sysinit
1623 - fi
1624 -
1625 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
1626 - migrate_udev_mount_script
1627 - add_boot_init tmpfiles.setup boot
1628 - fi
1629 -
1630 - # these were added in 0.12.
1631 - if ! has_version ">=sys-apps/openrc-0.12"; then
1632 - add_boot_init loopback
1633 - add_boot_init tmpfiles.dev sysinit
1634 -
1635 - # ensure existing /etc/conf.d/net is not removed
1636 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
1637 - # this needs to stay in openrc ebuilds for a long time. :(
1638 - # Added in 0.12.
1639 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
1640 - einfo "Modifying conf.d/net to keep it from being removed"
1641 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
1642 -
1643 -# The network scripts are now part of net-misc/netifrc
1644 -# In order to avoid sys-apps/${P} from removing this file, this comment was
1645 -# added; you can safely remove this comment. Please see
1646 -# /usr/share/doc/netifrc*/README* for more information.
1647 -EOF
1648 - fi
1649 - fi
1650 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
1651 -
1652 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
1653 - add_boot_init mtab
1654 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
1655 - ewarn "${EROOT}etc/mtab will be replaced with a"
1656 - ewarn "symbolic link to /proc/self/mounts on the next"
1657 - ewarn "reboot."
1658 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
1659 - ewarn "if you do not want this to happen."
1660 - fi
1661 - fi
1662 -}
1663 -
1664 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
1665 -migrate_udev_mount_script() {
1666 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
1667 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
1668 - add_boot_init udev-mount sysinit
1669 - fi
1670 - return 0
1671 -}
1672 -
1673 -pkg_postinst() {
1674 - local LIBDIR=$(get_libdir)
1675 -
1676 - # Make our runlevels if they don't exist
1677 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
1678 - einfo "Copying across default runlevels"
1679 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
1680 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
1681 - else
1682 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
1683 - mkdir -p "${EROOT}"etc/runlevels/sysinit
1684 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
1685 - "${EROOT}"etc/runlevels/sysinit
1686 - fi
1687 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
1688 - mkdir -p "${EROOT}"etc/runlevels/shutdown
1689 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
1690 - "${EROOT}"etc/runlevels/shutdown
1691 - fi
1692 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
1693 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
1694 - "${EROOT}"etc/runlevels
1695 - fi
1696 - fi
1697 -
1698 - if use hppa; then
1699 - elog "Setting the console font does not work on all HPPA consoles."
1700 - elog "You can still enable it by running:"
1701 - elog "# rc-update add consolefont boot"
1702 - fi
1703 -
1704 - # Handle the conf.d/local.{start,stop} -> local.d transition
1705 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
1706 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
1707 - elog "files to ${EROOT}etc/local.d"
1708 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
1709 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
1710 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
1711 - fi
1712 -
1713 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
1714 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
1715 - ewarn "The dependency data could not be migrated to /run/openrc."
1716 - ewarn "This means you need to reboot your system."
1717 - fi
1718 - fi
1719 -
1720 - # update the dependency tree after touching all files #224171
1721 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
1722 -
1723 - if ! use newnet && ! use netifrc; then
1724 - ewarn "You have emerged OpenRc without network support. This"
1725 - ewarn "means you need to SET UP a network manager such as"
1726 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
1727 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
1728 - ewarn "Or, you have the option of emerging openrc with the newnet"
1729 - ewarn "use flag and configuring /etc/conf.d/network and"
1730 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
1731 - ewarn
1732 - fi
1733 -
1734 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
1735 - ewarn "Please add the network service to your boot runlevel"
1736 - ewarn "as soon as possible. Not doing so could leave you with a system"
1737 - ewarn "without networking."
1738 - ewarn
1739 - fi
1740 -}
1741
1742 diff --git a/sys-apps/openrc/openrc-0.31.ebuild b/sys-apps/openrc/openrc-0.31.ebuild
1743 deleted file mode 100644
1744 index 278de480e1f..00000000000
1745 --- a/sys-apps/openrc/openrc-0.31.ebuild
1746 +++ /dev/null
1747 @@ -1,329 +0,0 @@
1748 -# Copyright 1999-2017 Gentoo Foundation
1749 -# Distributed under the terms of the GNU General Public License v2
1750 -
1751 -EAPI=6
1752 -
1753 -inherit flag-o-matic pam toolchain-funcs
1754 -
1755 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
1756 -HOMEPAGE="https://github.com/openrc/openrc/"
1757 -
1758 -if [[ ${PV} == "9999" ]]; then
1759 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
1760 - inherit git-r3
1761 -else
1762 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
1763 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
1764 -fi
1765 -
1766 -LICENSE="BSD-2"
1767 -SLOT="0"
1768 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
1769 - unicode kernel_linux kernel_FreeBSD"
1770 -
1771 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
1772 - ncurses? ( sys-libs/ncurses:0= )
1773 - pam? (
1774 - sys-auth/pambase
1775 - virtual/pam
1776 - )
1777 - audit? ( sys-process/audit )
1778 - kernel_linux? (
1779 - sys-process/psmisc
1780 - !<sys-process/procps-3.3.9-r2
1781 - )
1782 - selinux? (
1783 - sys-apps/policycoreutils
1784 - sys-libs/libselinux
1785 - )
1786 - !<sys-apps/baselayout-2.1-r1
1787 - !<sys-fs/udev-init-scripts-27"
1788 -DEPEND="${COMMON_DEPEND}
1789 - virtual/os-headers
1790 - ncurses? ( virtual/pkgconfig )"
1791 -RDEPEND="${COMMON_DEPEND}
1792 - !prefix? (
1793 - kernel_linux? (
1794 - >=sys-apps/sysvinit-2.86-r6[selinux?]
1795 - virtual/tmpfiles
1796 - )
1797 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
1798 - )
1799 - selinux? (
1800 - sec-policy/selinux-base-policy
1801 - sec-policy/selinux-openrc
1802 - )
1803 -"
1804 -
1805 -PDEPEND="netifrc? ( net-misc/netifrc )"
1806 -
1807 -src_prepare() {
1808 - default
1809 -
1810 - sed -i 's:0444:0644:' mk/sys.mk || die
1811 -
1812 - if [[ ${PV} == "9999" ]] ; then
1813 - local ver="git-${EGIT_VERSION:0:6}"
1814 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
1815 - fi
1816 -}
1817 -
1818 -src_compile() {
1819 - unset LIBDIR #266688
1820 -
1821 - MAKE_ARGS="${MAKE_ARGS}
1822 - LIBNAME=$(get_libdir)
1823 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
1824 - MKNET=$(usex newnet)
1825 - MKSELINUX=$(usex selinux)
1826 - MKAUDIT=$(usex audit)
1827 - MKPAM=$(usev pam)
1828 - MKSTATICLIBS=$(usex static-libs)"
1829 -
1830 - local brand="Unknown"
1831 - if use kernel_linux ; then
1832 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
1833 - brand="Linux"
1834 - elif use kernel_FreeBSD ; then
1835 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
1836 - brand="FreeBSD"
1837 - fi
1838 - export BRANDING="Gentoo ${brand}"
1839 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
1840 - export DEBUG=$(usev debug)
1841 - export MKTERMCAP=$(usev ncurses)
1842 -
1843 - tc-export CC AR RANLIB
1844 - emake ${MAKE_ARGS}
1845 -}
1846 -
1847 -# set_config <file> <option name> <yes value> <no value> test
1848 -# a value of "#" will just comment out the option
1849 -set_config() {
1850 - local file="${ED}/$1" var=$2 val com
1851 - eval "${@:5}" && val=$3 || val=$4
1852 - [[ ${val} == "#" ]] && com="#" && val='\2'
1853 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
1854 -}
1855 -
1856 -set_config_yes_no() {
1857 - set_config "$1" "$2" YES NO "${@:3}"
1858 -}
1859 -
1860 -src_install() {
1861 - emake ${MAKE_ARGS} DESTDIR="${D}" install
1862 -
1863 - # move the shared libs back to /usr so ldscript can install
1864 - # more of a minimal set of files
1865 - # disabled for now due to #270646
1866 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
1867 - #gen_usr_ldscript -a einfo rc
1868 - gen_usr_ldscript libeinfo.so
1869 - gen_usr_ldscript librc.so
1870 -
1871 - if ! use kernel_linux; then
1872 - keepdir /$(get_libdir)/rc/init.d
1873 - fi
1874 - keepdir /$(get_libdir)/rc/tmp
1875 -
1876 - # Backup our default runlevels
1877 - dodir /usr/share/"${PN}"
1878 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
1879 - rm -rf "${ED}"/etc/runlevels
1880 -
1881 - # Setup unicode defaults for silly unicode users
1882 - set_config_yes_no /etc/rc.conf unicode use unicode
1883 -
1884 - # Cater to the norm
1885 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
1886 -
1887 - # On HPPA, do not run consolefont by default (bug #222889)
1888 - if use hppa; then
1889 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
1890 - fi
1891 -
1892 - # Support for logfile rotation
1893 - insinto /etc/logrotate.d
1894 - newins "${FILESDIR}"/openrc.logrotate openrc
1895 -
1896 - # install gentoo pam.d files
1897 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
1898 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
1899 -
1900 - # install documentation
1901 - dodoc ChangeLog *.md
1902 - if use newnet; then
1903 - dodoc README.newnet
1904 - fi
1905 -}
1906 -
1907 -add_boot_init() {
1908 - local initd=$1
1909 - local runlevel=${2:-boot}
1910 - # if the initscript is not going to be installed and is not
1911 - # currently installed, return
1912 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
1913 - || return
1914 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
1915 -
1916 - # if runlevels dont exist just yet, then create it but still flag
1917 - # to pkg_postinst that it needs real setup #277323
1918 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
1919 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
1920 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
1921 - fi
1922 -
1923 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
1924 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
1925 -}
1926 -add_boot_init_mit_config() {
1927 - local config=$1 initd=$2
1928 - if [[ -e ${EROOT}${config} ]] ; then
1929 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
1930 - add_boot_init ${initd}
1931 - fi
1932 - fi
1933 -}
1934 -
1935 -pkg_preinst() {
1936 - local f LIBDIR=$(get_libdir)
1937 -
1938 - # avoid default thrashing in conf.d files when possible #295406
1939 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
1940 - (
1941 - unset hostname HOSTNAME
1942 - source "${EROOT}"etc/conf.d/hostname
1943 - : ${hostname:=${HOSTNAME}}
1944 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
1945 - )
1946 - fi
1947 -
1948 - # set default interactive shell to sulogin if it exists
1949 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
1950 -
1951 - # termencoding was added in 0.2.1 and needed in boot
1952 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
1953 -
1954 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
1955 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
1956 -
1957 - if ! has_version ">=sys-apps/openrc-0.11"; then
1958 - add_boot_init sysfs sysinit
1959 - fi
1960 -
1961 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
1962 - migrate_udev_mount_script
1963 - add_boot_init tmpfiles.setup boot
1964 - fi
1965 -
1966 - # these were added in 0.12.
1967 - if ! has_version ">=sys-apps/openrc-0.12"; then
1968 - add_boot_init loopback
1969 - add_boot_init tmpfiles.dev sysinit
1970 -
1971 - # ensure existing /etc/conf.d/net is not removed
1972 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
1973 - # this needs to stay in openrc ebuilds for a long time. :(
1974 - # Added in 0.12.
1975 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
1976 - einfo "Modifying conf.d/net to keep it from being removed"
1977 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
1978 -
1979 -# The network scripts are now part of net-misc/netifrc
1980 -# In order to avoid sys-apps/${P} from removing this file, this comment was
1981 -# added; you can safely remove this comment. Please see
1982 -# /usr/share/doc/netifrc*/README* for more information.
1983 -EOF
1984 - fi
1985 - fi
1986 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
1987 -
1988 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
1989 - add_boot_init mtab
1990 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
1991 - ewarn "${EROOT}etc/mtab will be replaced with a"
1992 - ewarn "symbolic link to /proc/self/mounts on the next"
1993 - ewarn "reboot."
1994 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
1995 - ewarn "if you do not want this to happen."
1996 - fi
1997 - fi
1998 -}
1999 -
2000 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
2001 -migrate_udev_mount_script() {
2002 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
2003 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
2004 - add_boot_init udev-mount sysinit
2005 - fi
2006 - return 0
2007 -}
2008 -
2009 -pkg_postinst() {
2010 - local LIBDIR=$(get_libdir)
2011 -
2012 - # Make our runlevels if they don't exist
2013 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
2014 - einfo "Copying across default runlevels"
2015 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
2016 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
2017 - else
2018 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
2019 - mkdir -p "${EROOT}"etc/runlevels/sysinit
2020 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
2021 - "${EROOT}"etc/runlevels/sysinit
2022 - fi
2023 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
2024 - mkdir -p "${EROOT}"etc/runlevels/shutdown
2025 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
2026 - "${EROOT}"etc/runlevels/shutdown
2027 - fi
2028 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
2029 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
2030 - "${EROOT}"etc/runlevels
2031 - fi
2032 - fi
2033 -
2034 - if use hppa; then
2035 - elog "Setting the console font does not work on all HPPA consoles."
2036 - elog "You can still enable it by running:"
2037 - elog "# rc-update add consolefont boot"
2038 - fi
2039 -
2040 - # Handle the conf.d/local.{start,stop} -> local.d transition
2041 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
2042 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
2043 - elog "files to ${EROOT}etc/local.d"
2044 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
2045 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
2046 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
2047 - fi
2048 -
2049 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
2050 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
2051 - ewarn "The dependency data could not be migrated to /run/openrc."
2052 - ewarn "This means you need to reboot your system."
2053 - fi
2054 - fi
2055 -
2056 - # update the dependency tree after touching all files #224171
2057 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
2058 -
2059 - if ! use newnet && ! use netifrc; then
2060 - ewarn "You have emerged OpenRc without network support. This"
2061 - ewarn "means you need to SET UP a network manager such as"
2062 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
2063 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
2064 - ewarn "Or, you have the option of emerging openrc with the newnet"
2065 - ewarn "use flag and configuring /etc/conf.d/network and"
2066 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
2067 - ewarn
2068 - fi
2069 -
2070 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
2071 - ewarn "Please add the network service to your boot runlevel"
2072 - ewarn "as soon as possible. Not doing so could leave you with a system"
2073 - ewarn "without networking."
2074 - ewarn
2075 - fi
2076 -}
2077
2078 diff --git a/sys-apps/openrc/openrc-0.32.ebuild b/sys-apps/openrc/openrc-0.32.ebuild
2079 deleted file mode 100644
2080 index 15376774cd7..00000000000
2081 --- a/sys-apps/openrc/openrc-0.32.ebuild
2082 +++ /dev/null
2083 @@ -1,329 +0,0 @@
2084 -# Copyright 1999-2017 Gentoo Foundation
2085 -# Distributed under the terms of the GNU General Public License v2
2086 -
2087 -EAPI=6
2088 -
2089 -inherit flag-o-matic pam toolchain-funcs
2090 -
2091 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
2092 -HOMEPAGE="https://github.com/openrc/openrc/"
2093 -
2094 -if [[ ${PV} == "9999" ]]; then
2095 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
2096 - inherit git-r3
2097 -else
2098 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
2099 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
2100 -fi
2101 -
2102 -LICENSE="BSD-2"
2103 -SLOT="0"
2104 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
2105 - unicode kernel_linux kernel_FreeBSD"
2106 -
2107 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
2108 - ncurses? ( sys-libs/ncurses:0= )
2109 - pam? (
2110 - sys-auth/pambase
2111 - virtual/pam
2112 - )
2113 - audit? ( sys-process/audit )
2114 - kernel_linux? (
2115 - sys-process/psmisc
2116 - !<sys-process/procps-3.3.9-r2
2117 - )
2118 - selinux? (
2119 - sys-apps/policycoreutils
2120 - >=sys-libs/libselinux-2.6
2121 - )
2122 - !<sys-apps/baselayout-2.1-r1
2123 - !<sys-fs/udev-init-scripts-27"
2124 -DEPEND="${COMMON_DEPEND}
2125 - virtual/os-headers
2126 - ncurses? ( virtual/pkgconfig )"
2127 -RDEPEND="${COMMON_DEPEND}
2128 - !prefix? (
2129 - kernel_linux? (
2130 - >=sys-apps/sysvinit-2.86-r6[selinux?]
2131 - virtual/tmpfiles
2132 - )
2133 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
2134 - )
2135 - selinux? (
2136 - >=sec-policy/selinux-base-policy-2.20170204-r4
2137 - >=sec-policy/selinux-openrc-2.20170204-r4
2138 - )
2139 -"
2140 -
2141 -PDEPEND="netifrc? ( net-misc/netifrc )"
2142 -
2143 -src_prepare() {
2144 - default
2145 -
2146 - sed -i 's:0444:0644:' mk/sys.mk || die
2147 -
2148 - if [[ ${PV} == "9999" ]] ; then
2149 - local ver="git-${EGIT_VERSION:0:6}"
2150 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
2151 - fi
2152 -}
2153 -
2154 -src_compile() {
2155 - unset LIBDIR #266688
2156 -
2157 - MAKE_ARGS="${MAKE_ARGS}
2158 - LIBNAME=$(get_libdir)
2159 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
2160 - MKNET=$(usex newnet)
2161 - MKSELINUX=$(usex selinux)
2162 - MKAUDIT=$(usex audit)
2163 - MKPAM=$(usev pam)
2164 - MKSTATICLIBS=$(usex static-libs)"
2165 -
2166 - local brand="Unknown"
2167 - if use kernel_linux ; then
2168 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
2169 - brand="Linux"
2170 - elif use kernel_FreeBSD ; then
2171 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
2172 - brand="FreeBSD"
2173 - fi
2174 - export BRANDING="Gentoo ${brand}"
2175 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
2176 - export DEBUG=$(usev debug)
2177 - export MKTERMCAP=$(usev ncurses)
2178 -
2179 - tc-export CC AR RANLIB
2180 - emake ${MAKE_ARGS}
2181 -}
2182 -
2183 -# set_config <file> <option name> <yes value> <no value> test
2184 -# a value of "#" will just comment out the option
2185 -set_config() {
2186 - local file="${ED}/$1" var=$2 val com
2187 - eval "${@:5}" && val=$3 || val=$4
2188 - [[ ${val} == "#" ]] && com="#" && val='\2'
2189 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
2190 -}
2191 -
2192 -set_config_yes_no() {
2193 - set_config "$1" "$2" YES NO "${@:3}"
2194 -}
2195 -
2196 -src_install() {
2197 - emake ${MAKE_ARGS} DESTDIR="${D}" install
2198 -
2199 - # move the shared libs back to /usr so ldscript can install
2200 - # more of a minimal set of files
2201 - # disabled for now due to #270646
2202 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
2203 - #gen_usr_ldscript -a einfo rc
2204 - gen_usr_ldscript libeinfo.so
2205 - gen_usr_ldscript librc.so
2206 -
2207 - if ! use kernel_linux; then
2208 - keepdir /$(get_libdir)/rc/init.d
2209 - fi
2210 - keepdir /$(get_libdir)/rc/tmp
2211 -
2212 - # Backup our default runlevels
2213 - dodir /usr/share/"${PN}"
2214 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
2215 - rm -rf "${ED}"/etc/runlevels
2216 -
2217 - # Setup unicode defaults for silly unicode users
2218 - set_config_yes_no /etc/rc.conf unicode use unicode
2219 -
2220 - # Cater to the norm
2221 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
2222 -
2223 - # On HPPA, do not run consolefont by default (bug #222889)
2224 - if use hppa; then
2225 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
2226 - fi
2227 -
2228 - # Support for logfile rotation
2229 - insinto /etc/logrotate.d
2230 - newins "${FILESDIR}"/openrc.logrotate openrc
2231 -
2232 - # install gentoo pam.d files
2233 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
2234 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
2235 -
2236 - # install documentation
2237 - dodoc ChangeLog *.md
2238 - if use newnet; then
2239 - dodoc README.newnet
2240 - fi
2241 -}
2242 -
2243 -add_boot_init() {
2244 - local initd=$1
2245 - local runlevel=${2:-boot}
2246 - # if the initscript is not going to be installed and is not
2247 - # currently installed, return
2248 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
2249 - || return
2250 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
2251 -
2252 - # if runlevels dont exist just yet, then create it but still flag
2253 - # to pkg_postinst that it needs real setup #277323
2254 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
2255 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
2256 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
2257 - fi
2258 -
2259 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
2260 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
2261 -}
2262 -add_boot_init_mit_config() {
2263 - local config=$1 initd=$2
2264 - if [[ -e ${EROOT}${config} ]] ; then
2265 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
2266 - add_boot_init ${initd}
2267 - fi
2268 - fi
2269 -}
2270 -
2271 -pkg_preinst() {
2272 - local f LIBDIR=$(get_libdir)
2273 -
2274 - # avoid default thrashing in conf.d files when possible #295406
2275 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
2276 - (
2277 - unset hostname HOSTNAME
2278 - source "${EROOT}"etc/conf.d/hostname
2279 - : ${hostname:=${HOSTNAME}}
2280 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
2281 - )
2282 - fi
2283 -
2284 - # set default interactive shell to sulogin if it exists
2285 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
2286 -
2287 - # termencoding was added in 0.2.1 and needed in boot
2288 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
2289 -
2290 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
2291 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
2292 -
2293 - if ! has_version ">=sys-apps/openrc-0.11"; then
2294 - add_boot_init sysfs sysinit
2295 - fi
2296 -
2297 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
2298 - migrate_udev_mount_script
2299 - add_boot_init tmpfiles.setup boot
2300 - fi
2301 -
2302 - # these were added in 0.12.
2303 - if ! has_version ">=sys-apps/openrc-0.12"; then
2304 - add_boot_init loopback
2305 - add_boot_init tmpfiles.dev sysinit
2306 -
2307 - # ensure existing /etc/conf.d/net is not removed
2308 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
2309 - # this needs to stay in openrc ebuilds for a long time. :(
2310 - # Added in 0.12.
2311 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
2312 - einfo "Modifying conf.d/net to keep it from being removed"
2313 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
2314 -
2315 -# The network scripts are now part of net-misc/netifrc
2316 -# In order to avoid sys-apps/${P} from removing this file, this comment was
2317 -# added; you can safely remove this comment. Please see
2318 -# /usr/share/doc/netifrc*/README* for more information.
2319 -EOF
2320 - fi
2321 - fi
2322 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
2323 -
2324 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
2325 - add_boot_init mtab
2326 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
2327 - ewarn "${EROOT}etc/mtab will be replaced with a"
2328 - ewarn "symbolic link to /proc/self/mounts on the next"
2329 - ewarn "reboot."
2330 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
2331 - ewarn "if you do not want this to happen."
2332 - fi
2333 - fi
2334 -}
2335 -
2336 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
2337 -migrate_udev_mount_script() {
2338 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
2339 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
2340 - add_boot_init udev-mount sysinit
2341 - fi
2342 - return 0
2343 -}
2344 -
2345 -pkg_postinst() {
2346 - local LIBDIR=$(get_libdir)
2347 -
2348 - # Make our runlevels if they don't exist
2349 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
2350 - einfo "Copying across default runlevels"
2351 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
2352 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
2353 - else
2354 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
2355 - mkdir -p "${EROOT}"etc/runlevels/sysinit
2356 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
2357 - "${EROOT}"etc/runlevels/sysinit
2358 - fi
2359 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
2360 - mkdir -p "${EROOT}"etc/runlevels/shutdown
2361 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
2362 - "${EROOT}"etc/runlevels/shutdown
2363 - fi
2364 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
2365 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
2366 - "${EROOT}"etc/runlevels
2367 - fi
2368 - fi
2369 -
2370 - if use hppa; then
2371 - elog "Setting the console font does not work on all HPPA consoles."
2372 - elog "You can still enable it by running:"
2373 - elog "# rc-update add consolefont boot"
2374 - fi
2375 -
2376 - # Handle the conf.d/local.{start,stop} -> local.d transition
2377 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
2378 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
2379 - elog "files to ${EROOT}etc/local.d"
2380 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
2381 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
2382 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
2383 - fi
2384 -
2385 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
2386 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
2387 - ewarn "The dependency data could not be migrated to /run/openrc."
2388 - ewarn "This means you need to reboot your system."
2389 - fi
2390 - fi
2391 -
2392 - # update the dependency tree after touching all files #224171
2393 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
2394 -
2395 - if ! use newnet && ! use netifrc; then
2396 - ewarn "You have emerged OpenRc without network support. This"
2397 - ewarn "means you need to SET UP a network manager such as"
2398 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
2399 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
2400 - ewarn "Or, you have the option of emerging openrc with the newnet"
2401 - ewarn "use flag and configuring /etc/conf.d/network and"
2402 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
2403 - ewarn
2404 - fi
2405 -
2406 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
2407 - ewarn "Please add the network service to your boot runlevel"
2408 - ewarn "as soon as possible. Not doing so could leave you with a system"
2409 - ewarn "without networking."
2410 - ewarn
2411 - fi
2412 -}
2413
2414 diff --git a/sys-apps/openrc/openrc-0.33.1.ebuild b/sys-apps/openrc/openrc-0.33.1.ebuild
2415 deleted file mode 100644
2416 index 15376774cd7..00000000000
2417 --- a/sys-apps/openrc/openrc-0.33.1.ebuild
2418 +++ /dev/null
2419 @@ -1,329 +0,0 @@
2420 -# Copyright 1999-2017 Gentoo Foundation
2421 -# Distributed under the terms of the GNU General Public License v2
2422 -
2423 -EAPI=6
2424 -
2425 -inherit flag-o-matic pam toolchain-funcs
2426 -
2427 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
2428 -HOMEPAGE="https://github.com/openrc/openrc/"
2429 -
2430 -if [[ ${PV} == "9999" ]]; then
2431 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
2432 - inherit git-r3
2433 -else
2434 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
2435 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
2436 -fi
2437 -
2438 -LICENSE="BSD-2"
2439 -SLOT="0"
2440 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
2441 - unicode kernel_linux kernel_FreeBSD"
2442 -
2443 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
2444 - ncurses? ( sys-libs/ncurses:0= )
2445 - pam? (
2446 - sys-auth/pambase
2447 - virtual/pam
2448 - )
2449 - audit? ( sys-process/audit )
2450 - kernel_linux? (
2451 - sys-process/psmisc
2452 - !<sys-process/procps-3.3.9-r2
2453 - )
2454 - selinux? (
2455 - sys-apps/policycoreutils
2456 - >=sys-libs/libselinux-2.6
2457 - )
2458 - !<sys-apps/baselayout-2.1-r1
2459 - !<sys-fs/udev-init-scripts-27"
2460 -DEPEND="${COMMON_DEPEND}
2461 - virtual/os-headers
2462 - ncurses? ( virtual/pkgconfig )"
2463 -RDEPEND="${COMMON_DEPEND}
2464 - !prefix? (
2465 - kernel_linux? (
2466 - >=sys-apps/sysvinit-2.86-r6[selinux?]
2467 - virtual/tmpfiles
2468 - )
2469 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
2470 - )
2471 - selinux? (
2472 - >=sec-policy/selinux-base-policy-2.20170204-r4
2473 - >=sec-policy/selinux-openrc-2.20170204-r4
2474 - )
2475 -"
2476 -
2477 -PDEPEND="netifrc? ( net-misc/netifrc )"
2478 -
2479 -src_prepare() {
2480 - default
2481 -
2482 - sed -i 's:0444:0644:' mk/sys.mk || die
2483 -
2484 - if [[ ${PV} == "9999" ]] ; then
2485 - local ver="git-${EGIT_VERSION:0:6}"
2486 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
2487 - fi
2488 -}
2489 -
2490 -src_compile() {
2491 - unset LIBDIR #266688
2492 -
2493 - MAKE_ARGS="${MAKE_ARGS}
2494 - LIBNAME=$(get_libdir)
2495 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
2496 - MKNET=$(usex newnet)
2497 - MKSELINUX=$(usex selinux)
2498 - MKAUDIT=$(usex audit)
2499 - MKPAM=$(usev pam)
2500 - MKSTATICLIBS=$(usex static-libs)"
2501 -
2502 - local brand="Unknown"
2503 - if use kernel_linux ; then
2504 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
2505 - brand="Linux"
2506 - elif use kernel_FreeBSD ; then
2507 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
2508 - brand="FreeBSD"
2509 - fi
2510 - export BRANDING="Gentoo ${brand}"
2511 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
2512 - export DEBUG=$(usev debug)
2513 - export MKTERMCAP=$(usev ncurses)
2514 -
2515 - tc-export CC AR RANLIB
2516 - emake ${MAKE_ARGS}
2517 -}
2518 -
2519 -# set_config <file> <option name> <yes value> <no value> test
2520 -# a value of "#" will just comment out the option
2521 -set_config() {
2522 - local file="${ED}/$1" var=$2 val com
2523 - eval "${@:5}" && val=$3 || val=$4
2524 - [[ ${val} == "#" ]] && com="#" && val='\2'
2525 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
2526 -}
2527 -
2528 -set_config_yes_no() {
2529 - set_config "$1" "$2" YES NO "${@:3}"
2530 -}
2531 -
2532 -src_install() {
2533 - emake ${MAKE_ARGS} DESTDIR="${D}" install
2534 -
2535 - # move the shared libs back to /usr so ldscript can install
2536 - # more of a minimal set of files
2537 - # disabled for now due to #270646
2538 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
2539 - #gen_usr_ldscript -a einfo rc
2540 - gen_usr_ldscript libeinfo.so
2541 - gen_usr_ldscript librc.so
2542 -
2543 - if ! use kernel_linux; then
2544 - keepdir /$(get_libdir)/rc/init.d
2545 - fi
2546 - keepdir /$(get_libdir)/rc/tmp
2547 -
2548 - # Backup our default runlevels
2549 - dodir /usr/share/"${PN}"
2550 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
2551 - rm -rf "${ED}"/etc/runlevels
2552 -
2553 - # Setup unicode defaults for silly unicode users
2554 - set_config_yes_no /etc/rc.conf unicode use unicode
2555 -
2556 - # Cater to the norm
2557 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
2558 -
2559 - # On HPPA, do not run consolefont by default (bug #222889)
2560 - if use hppa; then
2561 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
2562 - fi
2563 -
2564 - # Support for logfile rotation
2565 - insinto /etc/logrotate.d
2566 - newins "${FILESDIR}"/openrc.logrotate openrc
2567 -
2568 - # install gentoo pam.d files
2569 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
2570 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
2571 -
2572 - # install documentation
2573 - dodoc ChangeLog *.md
2574 - if use newnet; then
2575 - dodoc README.newnet
2576 - fi
2577 -}
2578 -
2579 -add_boot_init() {
2580 - local initd=$1
2581 - local runlevel=${2:-boot}
2582 - # if the initscript is not going to be installed and is not
2583 - # currently installed, return
2584 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
2585 - || return
2586 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
2587 -
2588 - # if runlevels dont exist just yet, then create it but still flag
2589 - # to pkg_postinst that it needs real setup #277323
2590 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
2591 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
2592 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
2593 - fi
2594 -
2595 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
2596 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
2597 -}
2598 -add_boot_init_mit_config() {
2599 - local config=$1 initd=$2
2600 - if [[ -e ${EROOT}${config} ]] ; then
2601 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
2602 - add_boot_init ${initd}
2603 - fi
2604 - fi
2605 -}
2606 -
2607 -pkg_preinst() {
2608 - local f LIBDIR=$(get_libdir)
2609 -
2610 - # avoid default thrashing in conf.d files when possible #295406
2611 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
2612 - (
2613 - unset hostname HOSTNAME
2614 - source "${EROOT}"etc/conf.d/hostname
2615 - : ${hostname:=${HOSTNAME}}
2616 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
2617 - )
2618 - fi
2619 -
2620 - # set default interactive shell to sulogin if it exists
2621 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
2622 -
2623 - # termencoding was added in 0.2.1 and needed in boot
2624 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
2625 -
2626 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
2627 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
2628 -
2629 - if ! has_version ">=sys-apps/openrc-0.11"; then
2630 - add_boot_init sysfs sysinit
2631 - fi
2632 -
2633 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
2634 - migrate_udev_mount_script
2635 - add_boot_init tmpfiles.setup boot
2636 - fi
2637 -
2638 - # these were added in 0.12.
2639 - if ! has_version ">=sys-apps/openrc-0.12"; then
2640 - add_boot_init loopback
2641 - add_boot_init tmpfiles.dev sysinit
2642 -
2643 - # ensure existing /etc/conf.d/net is not removed
2644 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
2645 - # this needs to stay in openrc ebuilds for a long time. :(
2646 - # Added in 0.12.
2647 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
2648 - einfo "Modifying conf.d/net to keep it from being removed"
2649 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
2650 -
2651 -# The network scripts are now part of net-misc/netifrc
2652 -# In order to avoid sys-apps/${P} from removing this file, this comment was
2653 -# added; you can safely remove this comment. Please see
2654 -# /usr/share/doc/netifrc*/README* for more information.
2655 -EOF
2656 - fi
2657 - fi
2658 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
2659 -
2660 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
2661 - add_boot_init mtab
2662 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
2663 - ewarn "${EROOT}etc/mtab will be replaced with a"
2664 - ewarn "symbolic link to /proc/self/mounts on the next"
2665 - ewarn "reboot."
2666 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
2667 - ewarn "if you do not want this to happen."
2668 - fi
2669 - fi
2670 -}
2671 -
2672 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
2673 -migrate_udev_mount_script() {
2674 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
2675 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
2676 - add_boot_init udev-mount sysinit
2677 - fi
2678 - return 0
2679 -}
2680 -
2681 -pkg_postinst() {
2682 - local LIBDIR=$(get_libdir)
2683 -
2684 - # Make our runlevels if they don't exist
2685 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
2686 - einfo "Copying across default runlevels"
2687 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
2688 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
2689 - else
2690 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
2691 - mkdir -p "${EROOT}"etc/runlevels/sysinit
2692 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
2693 - "${EROOT}"etc/runlevels/sysinit
2694 - fi
2695 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
2696 - mkdir -p "${EROOT}"etc/runlevels/shutdown
2697 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
2698 - "${EROOT}"etc/runlevels/shutdown
2699 - fi
2700 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
2701 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
2702 - "${EROOT}"etc/runlevels
2703 - fi
2704 - fi
2705 -
2706 - if use hppa; then
2707 - elog "Setting the console font does not work on all HPPA consoles."
2708 - elog "You can still enable it by running:"
2709 - elog "# rc-update add consolefont boot"
2710 - fi
2711 -
2712 - # Handle the conf.d/local.{start,stop} -> local.d transition
2713 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
2714 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
2715 - elog "files to ${EROOT}etc/local.d"
2716 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
2717 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
2718 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
2719 - fi
2720 -
2721 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
2722 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
2723 - ewarn "The dependency data could not be migrated to /run/openrc."
2724 - ewarn "This means you need to reboot your system."
2725 - fi
2726 - fi
2727 -
2728 - # update the dependency tree after touching all files #224171
2729 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
2730 -
2731 - if ! use newnet && ! use netifrc; then
2732 - ewarn "You have emerged OpenRc without network support. This"
2733 - ewarn "means you need to SET UP a network manager such as"
2734 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
2735 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
2736 - ewarn "Or, you have the option of emerging openrc with the newnet"
2737 - ewarn "use flag and configuring /etc/conf.d/network and"
2738 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
2739 - ewarn
2740 - fi
2741 -
2742 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
2743 - ewarn "Please add the network service to your boot runlevel"
2744 - ewarn "as soon as possible. Not doing so could leave you with a system"
2745 - ewarn "without networking."
2746 - ewarn
2747 - fi
2748 -}
2749
2750 diff --git a/sys-apps/openrc/openrc-0.33.ebuild b/sys-apps/openrc/openrc-0.33.ebuild
2751 deleted file mode 100644
2752 index 15376774cd7..00000000000
2753 --- a/sys-apps/openrc/openrc-0.33.ebuild
2754 +++ /dev/null
2755 @@ -1,329 +0,0 @@
2756 -# Copyright 1999-2017 Gentoo Foundation
2757 -# Distributed under the terms of the GNU General Public License v2
2758 -
2759 -EAPI=6
2760 -
2761 -inherit flag-o-matic pam toolchain-funcs
2762 -
2763 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
2764 -HOMEPAGE="https://github.com/openrc/openrc/"
2765 -
2766 -if [[ ${PV} == "9999" ]]; then
2767 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
2768 - inherit git-r3
2769 -else
2770 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
2771 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
2772 -fi
2773 -
2774 -LICENSE="BSD-2"
2775 -SLOT="0"
2776 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
2777 - unicode kernel_linux kernel_FreeBSD"
2778 -
2779 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
2780 - ncurses? ( sys-libs/ncurses:0= )
2781 - pam? (
2782 - sys-auth/pambase
2783 - virtual/pam
2784 - )
2785 - audit? ( sys-process/audit )
2786 - kernel_linux? (
2787 - sys-process/psmisc
2788 - !<sys-process/procps-3.3.9-r2
2789 - )
2790 - selinux? (
2791 - sys-apps/policycoreutils
2792 - >=sys-libs/libselinux-2.6
2793 - )
2794 - !<sys-apps/baselayout-2.1-r1
2795 - !<sys-fs/udev-init-scripts-27"
2796 -DEPEND="${COMMON_DEPEND}
2797 - virtual/os-headers
2798 - ncurses? ( virtual/pkgconfig )"
2799 -RDEPEND="${COMMON_DEPEND}
2800 - !prefix? (
2801 - kernel_linux? (
2802 - >=sys-apps/sysvinit-2.86-r6[selinux?]
2803 - virtual/tmpfiles
2804 - )
2805 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
2806 - )
2807 - selinux? (
2808 - >=sec-policy/selinux-base-policy-2.20170204-r4
2809 - >=sec-policy/selinux-openrc-2.20170204-r4
2810 - )
2811 -"
2812 -
2813 -PDEPEND="netifrc? ( net-misc/netifrc )"
2814 -
2815 -src_prepare() {
2816 - default
2817 -
2818 - sed -i 's:0444:0644:' mk/sys.mk || die
2819 -
2820 - if [[ ${PV} == "9999" ]] ; then
2821 - local ver="git-${EGIT_VERSION:0:6}"
2822 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
2823 - fi
2824 -}
2825 -
2826 -src_compile() {
2827 - unset LIBDIR #266688
2828 -
2829 - MAKE_ARGS="${MAKE_ARGS}
2830 - LIBNAME=$(get_libdir)
2831 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
2832 - MKNET=$(usex newnet)
2833 - MKSELINUX=$(usex selinux)
2834 - MKAUDIT=$(usex audit)
2835 - MKPAM=$(usev pam)
2836 - MKSTATICLIBS=$(usex static-libs)"
2837 -
2838 - local brand="Unknown"
2839 - if use kernel_linux ; then
2840 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
2841 - brand="Linux"
2842 - elif use kernel_FreeBSD ; then
2843 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
2844 - brand="FreeBSD"
2845 - fi
2846 - export BRANDING="Gentoo ${brand}"
2847 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
2848 - export DEBUG=$(usev debug)
2849 - export MKTERMCAP=$(usev ncurses)
2850 -
2851 - tc-export CC AR RANLIB
2852 - emake ${MAKE_ARGS}
2853 -}
2854 -
2855 -# set_config <file> <option name> <yes value> <no value> test
2856 -# a value of "#" will just comment out the option
2857 -set_config() {
2858 - local file="${ED}/$1" var=$2 val com
2859 - eval "${@:5}" && val=$3 || val=$4
2860 - [[ ${val} == "#" ]] && com="#" && val='\2'
2861 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
2862 -}
2863 -
2864 -set_config_yes_no() {
2865 - set_config "$1" "$2" YES NO "${@:3}"
2866 -}
2867 -
2868 -src_install() {
2869 - emake ${MAKE_ARGS} DESTDIR="${D}" install
2870 -
2871 - # move the shared libs back to /usr so ldscript can install
2872 - # more of a minimal set of files
2873 - # disabled for now due to #270646
2874 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
2875 - #gen_usr_ldscript -a einfo rc
2876 - gen_usr_ldscript libeinfo.so
2877 - gen_usr_ldscript librc.so
2878 -
2879 - if ! use kernel_linux; then
2880 - keepdir /$(get_libdir)/rc/init.d
2881 - fi
2882 - keepdir /$(get_libdir)/rc/tmp
2883 -
2884 - # Backup our default runlevels
2885 - dodir /usr/share/"${PN}"
2886 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
2887 - rm -rf "${ED}"/etc/runlevels
2888 -
2889 - # Setup unicode defaults for silly unicode users
2890 - set_config_yes_no /etc/rc.conf unicode use unicode
2891 -
2892 - # Cater to the norm
2893 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
2894 -
2895 - # On HPPA, do not run consolefont by default (bug #222889)
2896 - if use hppa; then
2897 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
2898 - fi
2899 -
2900 - # Support for logfile rotation
2901 - insinto /etc/logrotate.d
2902 - newins "${FILESDIR}"/openrc.logrotate openrc
2903 -
2904 - # install gentoo pam.d files
2905 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
2906 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
2907 -
2908 - # install documentation
2909 - dodoc ChangeLog *.md
2910 - if use newnet; then
2911 - dodoc README.newnet
2912 - fi
2913 -}
2914 -
2915 -add_boot_init() {
2916 - local initd=$1
2917 - local runlevel=${2:-boot}
2918 - # if the initscript is not going to be installed and is not
2919 - # currently installed, return
2920 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
2921 - || return
2922 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
2923 -
2924 - # if runlevels dont exist just yet, then create it but still flag
2925 - # to pkg_postinst that it needs real setup #277323
2926 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
2927 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
2928 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
2929 - fi
2930 -
2931 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
2932 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
2933 -}
2934 -add_boot_init_mit_config() {
2935 - local config=$1 initd=$2
2936 - if [[ -e ${EROOT}${config} ]] ; then
2937 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
2938 - add_boot_init ${initd}
2939 - fi
2940 - fi
2941 -}
2942 -
2943 -pkg_preinst() {
2944 - local f LIBDIR=$(get_libdir)
2945 -
2946 - # avoid default thrashing in conf.d files when possible #295406
2947 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
2948 - (
2949 - unset hostname HOSTNAME
2950 - source "${EROOT}"etc/conf.d/hostname
2951 - : ${hostname:=${HOSTNAME}}
2952 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
2953 - )
2954 - fi
2955 -
2956 - # set default interactive shell to sulogin if it exists
2957 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
2958 -
2959 - # termencoding was added in 0.2.1 and needed in boot
2960 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
2961 -
2962 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
2963 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
2964 -
2965 - if ! has_version ">=sys-apps/openrc-0.11"; then
2966 - add_boot_init sysfs sysinit
2967 - fi
2968 -
2969 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
2970 - migrate_udev_mount_script
2971 - add_boot_init tmpfiles.setup boot
2972 - fi
2973 -
2974 - # these were added in 0.12.
2975 - if ! has_version ">=sys-apps/openrc-0.12"; then
2976 - add_boot_init loopback
2977 - add_boot_init tmpfiles.dev sysinit
2978 -
2979 - # ensure existing /etc/conf.d/net is not removed
2980 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
2981 - # this needs to stay in openrc ebuilds for a long time. :(
2982 - # Added in 0.12.
2983 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
2984 - einfo "Modifying conf.d/net to keep it from being removed"
2985 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
2986 -
2987 -# The network scripts are now part of net-misc/netifrc
2988 -# In order to avoid sys-apps/${P} from removing this file, this comment was
2989 -# added; you can safely remove this comment. Please see
2990 -# /usr/share/doc/netifrc*/README* for more information.
2991 -EOF
2992 - fi
2993 - fi
2994 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
2995 -
2996 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
2997 - add_boot_init mtab
2998 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
2999 - ewarn "${EROOT}etc/mtab will be replaced with a"
3000 - ewarn "symbolic link to /proc/self/mounts on the next"
3001 - ewarn "reboot."
3002 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
3003 - ewarn "if you do not want this to happen."
3004 - fi
3005 - fi
3006 -}
3007 -
3008 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
3009 -migrate_udev_mount_script() {
3010 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
3011 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
3012 - add_boot_init udev-mount sysinit
3013 - fi
3014 - return 0
3015 -}
3016 -
3017 -pkg_postinst() {
3018 - local LIBDIR=$(get_libdir)
3019 -
3020 - # Make our runlevels if they don't exist
3021 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
3022 - einfo "Copying across default runlevels"
3023 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
3024 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
3025 - else
3026 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
3027 - mkdir -p "${EROOT}"etc/runlevels/sysinit
3028 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
3029 - "${EROOT}"etc/runlevels/sysinit
3030 - fi
3031 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
3032 - mkdir -p "${EROOT}"etc/runlevels/shutdown
3033 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
3034 - "${EROOT}"etc/runlevels/shutdown
3035 - fi
3036 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
3037 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
3038 - "${EROOT}"etc/runlevels
3039 - fi
3040 - fi
3041 -
3042 - if use hppa; then
3043 - elog "Setting the console font does not work on all HPPA consoles."
3044 - elog "You can still enable it by running:"
3045 - elog "# rc-update add consolefont boot"
3046 - fi
3047 -
3048 - # Handle the conf.d/local.{start,stop} -> local.d transition
3049 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
3050 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
3051 - elog "files to ${EROOT}etc/local.d"
3052 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
3053 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
3054 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
3055 - fi
3056 -
3057 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
3058 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
3059 - ewarn "The dependency data could not be migrated to /run/openrc."
3060 - ewarn "This means you need to reboot your system."
3061 - fi
3062 - fi
3063 -
3064 - # update the dependency tree after touching all files #224171
3065 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
3066 -
3067 - if ! use newnet && ! use netifrc; then
3068 - ewarn "You have emerged OpenRc without network support. This"
3069 - ewarn "means you need to SET UP a network manager such as"
3070 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
3071 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
3072 - ewarn "Or, you have the option of emerging openrc with the newnet"
3073 - ewarn "use flag and configuring /etc/conf.d/network and"
3074 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
3075 - ewarn
3076 - fi
3077 -
3078 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
3079 - ewarn "Please add the network service to your boot runlevel"
3080 - ewarn "as soon as possible. Not doing so could leave you with a system"
3081 - ewarn "without networking."
3082 - ewarn
3083 - fi
3084 -}
3085
3086 diff --git a/sys-apps/openrc/openrc-0.34.1.ebuild b/sys-apps/openrc/openrc-0.34.1.ebuild
3087 deleted file mode 100644
3088 index 15376774cd7..00000000000
3089 --- a/sys-apps/openrc/openrc-0.34.1.ebuild
3090 +++ /dev/null
3091 @@ -1,329 +0,0 @@
3092 -# Copyright 1999-2017 Gentoo Foundation
3093 -# Distributed under the terms of the GNU General Public License v2
3094 -
3095 -EAPI=6
3096 -
3097 -inherit flag-o-matic pam toolchain-funcs
3098 -
3099 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
3100 -HOMEPAGE="https://github.com/openrc/openrc/"
3101 -
3102 -if [[ ${PV} == "9999" ]]; then
3103 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
3104 - inherit git-r3
3105 -else
3106 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
3107 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
3108 -fi
3109 -
3110 -LICENSE="BSD-2"
3111 -SLOT="0"
3112 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
3113 - unicode kernel_linux kernel_FreeBSD"
3114 -
3115 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
3116 - ncurses? ( sys-libs/ncurses:0= )
3117 - pam? (
3118 - sys-auth/pambase
3119 - virtual/pam
3120 - )
3121 - audit? ( sys-process/audit )
3122 - kernel_linux? (
3123 - sys-process/psmisc
3124 - !<sys-process/procps-3.3.9-r2
3125 - )
3126 - selinux? (
3127 - sys-apps/policycoreutils
3128 - >=sys-libs/libselinux-2.6
3129 - )
3130 - !<sys-apps/baselayout-2.1-r1
3131 - !<sys-fs/udev-init-scripts-27"
3132 -DEPEND="${COMMON_DEPEND}
3133 - virtual/os-headers
3134 - ncurses? ( virtual/pkgconfig )"
3135 -RDEPEND="${COMMON_DEPEND}
3136 - !prefix? (
3137 - kernel_linux? (
3138 - >=sys-apps/sysvinit-2.86-r6[selinux?]
3139 - virtual/tmpfiles
3140 - )
3141 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
3142 - )
3143 - selinux? (
3144 - >=sec-policy/selinux-base-policy-2.20170204-r4
3145 - >=sec-policy/selinux-openrc-2.20170204-r4
3146 - )
3147 -"
3148 -
3149 -PDEPEND="netifrc? ( net-misc/netifrc )"
3150 -
3151 -src_prepare() {
3152 - default
3153 -
3154 - sed -i 's:0444:0644:' mk/sys.mk || die
3155 -
3156 - if [[ ${PV} == "9999" ]] ; then
3157 - local ver="git-${EGIT_VERSION:0:6}"
3158 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
3159 - fi
3160 -}
3161 -
3162 -src_compile() {
3163 - unset LIBDIR #266688
3164 -
3165 - MAKE_ARGS="${MAKE_ARGS}
3166 - LIBNAME=$(get_libdir)
3167 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
3168 - MKNET=$(usex newnet)
3169 - MKSELINUX=$(usex selinux)
3170 - MKAUDIT=$(usex audit)
3171 - MKPAM=$(usev pam)
3172 - MKSTATICLIBS=$(usex static-libs)"
3173 -
3174 - local brand="Unknown"
3175 - if use kernel_linux ; then
3176 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
3177 - brand="Linux"
3178 - elif use kernel_FreeBSD ; then
3179 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
3180 - brand="FreeBSD"
3181 - fi
3182 - export BRANDING="Gentoo ${brand}"
3183 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
3184 - export DEBUG=$(usev debug)
3185 - export MKTERMCAP=$(usev ncurses)
3186 -
3187 - tc-export CC AR RANLIB
3188 - emake ${MAKE_ARGS}
3189 -}
3190 -
3191 -# set_config <file> <option name> <yes value> <no value> test
3192 -# a value of "#" will just comment out the option
3193 -set_config() {
3194 - local file="${ED}/$1" var=$2 val com
3195 - eval "${@:5}" && val=$3 || val=$4
3196 - [[ ${val} == "#" ]] && com="#" && val='\2'
3197 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
3198 -}
3199 -
3200 -set_config_yes_no() {
3201 - set_config "$1" "$2" YES NO "${@:3}"
3202 -}
3203 -
3204 -src_install() {
3205 - emake ${MAKE_ARGS} DESTDIR="${D}" install
3206 -
3207 - # move the shared libs back to /usr so ldscript can install
3208 - # more of a minimal set of files
3209 - # disabled for now due to #270646
3210 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
3211 - #gen_usr_ldscript -a einfo rc
3212 - gen_usr_ldscript libeinfo.so
3213 - gen_usr_ldscript librc.so
3214 -
3215 - if ! use kernel_linux; then
3216 - keepdir /$(get_libdir)/rc/init.d
3217 - fi
3218 - keepdir /$(get_libdir)/rc/tmp
3219 -
3220 - # Backup our default runlevels
3221 - dodir /usr/share/"${PN}"
3222 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
3223 - rm -rf "${ED}"/etc/runlevels
3224 -
3225 - # Setup unicode defaults for silly unicode users
3226 - set_config_yes_no /etc/rc.conf unicode use unicode
3227 -
3228 - # Cater to the norm
3229 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
3230 -
3231 - # On HPPA, do not run consolefont by default (bug #222889)
3232 - if use hppa; then
3233 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
3234 - fi
3235 -
3236 - # Support for logfile rotation
3237 - insinto /etc/logrotate.d
3238 - newins "${FILESDIR}"/openrc.logrotate openrc
3239 -
3240 - # install gentoo pam.d files
3241 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
3242 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
3243 -
3244 - # install documentation
3245 - dodoc ChangeLog *.md
3246 - if use newnet; then
3247 - dodoc README.newnet
3248 - fi
3249 -}
3250 -
3251 -add_boot_init() {
3252 - local initd=$1
3253 - local runlevel=${2:-boot}
3254 - # if the initscript is not going to be installed and is not
3255 - # currently installed, return
3256 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
3257 - || return
3258 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
3259 -
3260 - # if runlevels dont exist just yet, then create it but still flag
3261 - # to pkg_postinst that it needs real setup #277323
3262 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
3263 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
3264 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
3265 - fi
3266 -
3267 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
3268 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
3269 -}
3270 -add_boot_init_mit_config() {
3271 - local config=$1 initd=$2
3272 - if [[ -e ${EROOT}${config} ]] ; then
3273 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
3274 - add_boot_init ${initd}
3275 - fi
3276 - fi
3277 -}
3278 -
3279 -pkg_preinst() {
3280 - local f LIBDIR=$(get_libdir)
3281 -
3282 - # avoid default thrashing in conf.d files when possible #295406
3283 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
3284 - (
3285 - unset hostname HOSTNAME
3286 - source "${EROOT}"etc/conf.d/hostname
3287 - : ${hostname:=${HOSTNAME}}
3288 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
3289 - )
3290 - fi
3291 -
3292 - # set default interactive shell to sulogin if it exists
3293 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
3294 -
3295 - # termencoding was added in 0.2.1 and needed in boot
3296 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
3297 -
3298 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
3299 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
3300 -
3301 - if ! has_version ">=sys-apps/openrc-0.11"; then
3302 - add_boot_init sysfs sysinit
3303 - fi
3304 -
3305 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
3306 - migrate_udev_mount_script
3307 - add_boot_init tmpfiles.setup boot
3308 - fi
3309 -
3310 - # these were added in 0.12.
3311 - if ! has_version ">=sys-apps/openrc-0.12"; then
3312 - add_boot_init loopback
3313 - add_boot_init tmpfiles.dev sysinit
3314 -
3315 - # ensure existing /etc/conf.d/net is not removed
3316 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
3317 - # this needs to stay in openrc ebuilds for a long time. :(
3318 - # Added in 0.12.
3319 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
3320 - einfo "Modifying conf.d/net to keep it from being removed"
3321 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
3322 -
3323 -# The network scripts are now part of net-misc/netifrc
3324 -# In order to avoid sys-apps/${P} from removing this file, this comment was
3325 -# added; you can safely remove this comment. Please see
3326 -# /usr/share/doc/netifrc*/README* for more information.
3327 -EOF
3328 - fi
3329 - fi
3330 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
3331 -
3332 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
3333 - add_boot_init mtab
3334 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
3335 - ewarn "${EROOT}etc/mtab will be replaced with a"
3336 - ewarn "symbolic link to /proc/self/mounts on the next"
3337 - ewarn "reboot."
3338 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
3339 - ewarn "if you do not want this to happen."
3340 - fi
3341 - fi
3342 -}
3343 -
3344 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
3345 -migrate_udev_mount_script() {
3346 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
3347 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
3348 - add_boot_init udev-mount sysinit
3349 - fi
3350 - return 0
3351 -}
3352 -
3353 -pkg_postinst() {
3354 - local LIBDIR=$(get_libdir)
3355 -
3356 - # Make our runlevels if they don't exist
3357 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
3358 - einfo "Copying across default runlevels"
3359 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
3360 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
3361 - else
3362 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
3363 - mkdir -p "${EROOT}"etc/runlevels/sysinit
3364 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
3365 - "${EROOT}"etc/runlevels/sysinit
3366 - fi
3367 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
3368 - mkdir -p "${EROOT}"etc/runlevels/shutdown
3369 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
3370 - "${EROOT}"etc/runlevels/shutdown
3371 - fi
3372 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
3373 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
3374 - "${EROOT}"etc/runlevels
3375 - fi
3376 - fi
3377 -
3378 - if use hppa; then
3379 - elog "Setting the console font does not work on all HPPA consoles."
3380 - elog "You can still enable it by running:"
3381 - elog "# rc-update add consolefont boot"
3382 - fi
3383 -
3384 - # Handle the conf.d/local.{start,stop} -> local.d transition
3385 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
3386 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
3387 - elog "files to ${EROOT}etc/local.d"
3388 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
3389 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
3390 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
3391 - fi
3392 -
3393 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
3394 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
3395 - ewarn "The dependency data could not be migrated to /run/openrc."
3396 - ewarn "This means you need to reboot your system."
3397 - fi
3398 - fi
3399 -
3400 - # update the dependency tree after touching all files #224171
3401 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
3402 -
3403 - if ! use newnet && ! use netifrc; then
3404 - ewarn "You have emerged OpenRc without network support. This"
3405 - ewarn "means you need to SET UP a network manager such as"
3406 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
3407 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
3408 - ewarn "Or, you have the option of emerging openrc with the newnet"
3409 - ewarn "use flag and configuring /etc/conf.d/network and"
3410 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
3411 - ewarn
3412 - fi
3413 -
3414 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
3415 - ewarn "Please add the network service to your boot runlevel"
3416 - ewarn "as soon as possible. Not doing so could leave you with a system"
3417 - ewarn "without networking."
3418 - ewarn
3419 - fi
3420 -}
3421
3422 diff --git a/sys-apps/openrc/openrc-0.34.2.ebuild b/sys-apps/openrc/openrc-0.34.2.ebuild
3423 deleted file mode 100644
3424 index 15376774cd7..00000000000
3425 --- a/sys-apps/openrc/openrc-0.34.2.ebuild
3426 +++ /dev/null
3427 @@ -1,329 +0,0 @@
3428 -# Copyright 1999-2017 Gentoo Foundation
3429 -# Distributed under the terms of the GNU General Public License v2
3430 -
3431 -EAPI=6
3432 -
3433 -inherit flag-o-matic pam toolchain-funcs
3434 -
3435 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
3436 -HOMEPAGE="https://github.com/openrc/openrc/"
3437 -
3438 -if [[ ${PV} == "9999" ]]; then
3439 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
3440 - inherit git-r3
3441 -else
3442 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
3443 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
3444 -fi
3445 -
3446 -LICENSE="BSD-2"
3447 -SLOT="0"
3448 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
3449 - unicode kernel_linux kernel_FreeBSD"
3450 -
3451 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
3452 - ncurses? ( sys-libs/ncurses:0= )
3453 - pam? (
3454 - sys-auth/pambase
3455 - virtual/pam
3456 - )
3457 - audit? ( sys-process/audit )
3458 - kernel_linux? (
3459 - sys-process/psmisc
3460 - !<sys-process/procps-3.3.9-r2
3461 - )
3462 - selinux? (
3463 - sys-apps/policycoreutils
3464 - >=sys-libs/libselinux-2.6
3465 - )
3466 - !<sys-apps/baselayout-2.1-r1
3467 - !<sys-fs/udev-init-scripts-27"
3468 -DEPEND="${COMMON_DEPEND}
3469 - virtual/os-headers
3470 - ncurses? ( virtual/pkgconfig )"
3471 -RDEPEND="${COMMON_DEPEND}
3472 - !prefix? (
3473 - kernel_linux? (
3474 - >=sys-apps/sysvinit-2.86-r6[selinux?]
3475 - virtual/tmpfiles
3476 - )
3477 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
3478 - )
3479 - selinux? (
3480 - >=sec-policy/selinux-base-policy-2.20170204-r4
3481 - >=sec-policy/selinux-openrc-2.20170204-r4
3482 - )
3483 -"
3484 -
3485 -PDEPEND="netifrc? ( net-misc/netifrc )"
3486 -
3487 -src_prepare() {
3488 - default
3489 -
3490 - sed -i 's:0444:0644:' mk/sys.mk || die
3491 -
3492 - if [[ ${PV} == "9999" ]] ; then
3493 - local ver="git-${EGIT_VERSION:0:6}"
3494 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
3495 - fi
3496 -}
3497 -
3498 -src_compile() {
3499 - unset LIBDIR #266688
3500 -
3501 - MAKE_ARGS="${MAKE_ARGS}
3502 - LIBNAME=$(get_libdir)
3503 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
3504 - MKNET=$(usex newnet)
3505 - MKSELINUX=$(usex selinux)
3506 - MKAUDIT=$(usex audit)
3507 - MKPAM=$(usev pam)
3508 - MKSTATICLIBS=$(usex static-libs)"
3509 -
3510 - local brand="Unknown"
3511 - if use kernel_linux ; then
3512 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
3513 - brand="Linux"
3514 - elif use kernel_FreeBSD ; then
3515 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
3516 - brand="FreeBSD"
3517 - fi
3518 - export BRANDING="Gentoo ${brand}"
3519 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
3520 - export DEBUG=$(usev debug)
3521 - export MKTERMCAP=$(usev ncurses)
3522 -
3523 - tc-export CC AR RANLIB
3524 - emake ${MAKE_ARGS}
3525 -}
3526 -
3527 -# set_config <file> <option name> <yes value> <no value> test
3528 -# a value of "#" will just comment out the option
3529 -set_config() {
3530 - local file="${ED}/$1" var=$2 val com
3531 - eval "${@:5}" && val=$3 || val=$4
3532 - [[ ${val} == "#" ]] && com="#" && val='\2'
3533 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
3534 -}
3535 -
3536 -set_config_yes_no() {
3537 - set_config "$1" "$2" YES NO "${@:3}"
3538 -}
3539 -
3540 -src_install() {
3541 - emake ${MAKE_ARGS} DESTDIR="${D}" install
3542 -
3543 - # move the shared libs back to /usr so ldscript can install
3544 - # more of a minimal set of files
3545 - # disabled for now due to #270646
3546 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
3547 - #gen_usr_ldscript -a einfo rc
3548 - gen_usr_ldscript libeinfo.so
3549 - gen_usr_ldscript librc.so
3550 -
3551 - if ! use kernel_linux; then
3552 - keepdir /$(get_libdir)/rc/init.d
3553 - fi
3554 - keepdir /$(get_libdir)/rc/tmp
3555 -
3556 - # Backup our default runlevels
3557 - dodir /usr/share/"${PN}"
3558 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
3559 - rm -rf "${ED}"/etc/runlevels
3560 -
3561 - # Setup unicode defaults for silly unicode users
3562 - set_config_yes_no /etc/rc.conf unicode use unicode
3563 -
3564 - # Cater to the norm
3565 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
3566 -
3567 - # On HPPA, do not run consolefont by default (bug #222889)
3568 - if use hppa; then
3569 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
3570 - fi
3571 -
3572 - # Support for logfile rotation
3573 - insinto /etc/logrotate.d
3574 - newins "${FILESDIR}"/openrc.logrotate openrc
3575 -
3576 - # install gentoo pam.d files
3577 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
3578 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
3579 -
3580 - # install documentation
3581 - dodoc ChangeLog *.md
3582 - if use newnet; then
3583 - dodoc README.newnet
3584 - fi
3585 -}
3586 -
3587 -add_boot_init() {
3588 - local initd=$1
3589 - local runlevel=${2:-boot}
3590 - # if the initscript is not going to be installed and is not
3591 - # currently installed, return
3592 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
3593 - || return
3594 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
3595 -
3596 - # if runlevels dont exist just yet, then create it but still flag
3597 - # to pkg_postinst that it needs real setup #277323
3598 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
3599 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
3600 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
3601 - fi
3602 -
3603 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
3604 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
3605 -}
3606 -add_boot_init_mit_config() {
3607 - local config=$1 initd=$2
3608 - if [[ -e ${EROOT}${config} ]] ; then
3609 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
3610 - add_boot_init ${initd}
3611 - fi
3612 - fi
3613 -}
3614 -
3615 -pkg_preinst() {
3616 - local f LIBDIR=$(get_libdir)
3617 -
3618 - # avoid default thrashing in conf.d files when possible #295406
3619 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
3620 - (
3621 - unset hostname HOSTNAME
3622 - source "${EROOT}"etc/conf.d/hostname
3623 - : ${hostname:=${HOSTNAME}}
3624 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
3625 - )
3626 - fi
3627 -
3628 - # set default interactive shell to sulogin if it exists
3629 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
3630 -
3631 - # termencoding was added in 0.2.1 and needed in boot
3632 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
3633 -
3634 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
3635 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
3636 -
3637 - if ! has_version ">=sys-apps/openrc-0.11"; then
3638 - add_boot_init sysfs sysinit
3639 - fi
3640 -
3641 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
3642 - migrate_udev_mount_script
3643 - add_boot_init tmpfiles.setup boot
3644 - fi
3645 -
3646 - # these were added in 0.12.
3647 - if ! has_version ">=sys-apps/openrc-0.12"; then
3648 - add_boot_init loopback
3649 - add_boot_init tmpfiles.dev sysinit
3650 -
3651 - # ensure existing /etc/conf.d/net is not removed
3652 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
3653 - # this needs to stay in openrc ebuilds for a long time. :(
3654 - # Added in 0.12.
3655 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
3656 - einfo "Modifying conf.d/net to keep it from being removed"
3657 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
3658 -
3659 -# The network scripts are now part of net-misc/netifrc
3660 -# In order to avoid sys-apps/${P} from removing this file, this comment was
3661 -# added; you can safely remove this comment. Please see
3662 -# /usr/share/doc/netifrc*/README* for more information.
3663 -EOF
3664 - fi
3665 - fi
3666 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
3667 -
3668 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
3669 - add_boot_init mtab
3670 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
3671 - ewarn "${EROOT}etc/mtab will be replaced with a"
3672 - ewarn "symbolic link to /proc/self/mounts on the next"
3673 - ewarn "reboot."
3674 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
3675 - ewarn "if you do not want this to happen."
3676 - fi
3677 - fi
3678 -}
3679 -
3680 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
3681 -migrate_udev_mount_script() {
3682 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
3683 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
3684 - add_boot_init udev-mount sysinit
3685 - fi
3686 - return 0
3687 -}
3688 -
3689 -pkg_postinst() {
3690 - local LIBDIR=$(get_libdir)
3691 -
3692 - # Make our runlevels if they don't exist
3693 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
3694 - einfo "Copying across default runlevels"
3695 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
3696 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
3697 - else
3698 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
3699 - mkdir -p "${EROOT}"etc/runlevels/sysinit
3700 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
3701 - "${EROOT}"etc/runlevels/sysinit
3702 - fi
3703 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
3704 - mkdir -p "${EROOT}"etc/runlevels/shutdown
3705 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
3706 - "${EROOT}"etc/runlevels/shutdown
3707 - fi
3708 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
3709 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
3710 - "${EROOT}"etc/runlevels
3711 - fi
3712 - fi
3713 -
3714 - if use hppa; then
3715 - elog "Setting the console font does not work on all HPPA consoles."
3716 - elog "You can still enable it by running:"
3717 - elog "# rc-update add consolefont boot"
3718 - fi
3719 -
3720 - # Handle the conf.d/local.{start,stop} -> local.d transition
3721 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
3722 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
3723 - elog "files to ${EROOT}etc/local.d"
3724 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
3725 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
3726 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
3727 - fi
3728 -
3729 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
3730 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
3731 - ewarn "The dependency data could not be migrated to /run/openrc."
3732 - ewarn "This means you need to reboot your system."
3733 - fi
3734 - fi
3735 -
3736 - # update the dependency tree after touching all files #224171
3737 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
3738 -
3739 - if ! use newnet && ! use netifrc; then
3740 - ewarn "You have emerged OpenRc without network support. This"
3741 - ewarn "means you need to SET UP a network manager such as"
3742 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
3743 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
3744 - ewarn "Or, you have the option of emerging openrc with the newnet"
3745 - ewarn "use flag and configuring /etc/conf.d/network and"
3746 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
3747 - ewarn
3748 - fi
3749 -
3750 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
3751 - ewarn "Please add the network service to your boot runlevel"
3752 - ewarn "as soon as possible. Not doing so could leave you with a system"
3753 - ewarn "without networking."
3754 - ewarn
3755 - fi
3756 -}
3757
3758 diff --git a/sys-apps/openrc/openrc-0.34.3.ebuild b/sys-apps/openrc/openrc-0.34.3.ebuild
3759 deleted file mode 100644
3760 index 15376774cd7..00000000000
3761 --- a/sys-apps/openrc/openrc-0.34.3.ebuild
3762 +++ /dev/null
3763 @@ -1,329 +0,0 @@
3764 -# Copyright 1999-2017 Gentoo Foundation
3765 -# Distributed under the terms of the GNU General Public License v2
3766 -
3767 -EAPI=6
3768 -
3769 -inherit flag-o-matic pam toolchain-funcs
3770 -
3771 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
3772 -HOMEPAGE="https://github.com/openrc/openrc/"
3773 -
3774 -if [[ ${PV} == "9999" ]]; then
3775 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
3776 - inherit git-r3
3777 -else
3778 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
3779 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
3780 -fi
3781 -
3782 -LICENSE="BSD-2"
3783 -SLOT="0"
3784 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
3785 - unicode kernel_linux kernel_FreeBSD"
3786 -
3787 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
3788 - ncurses? ( sys-libs/ncurses:0= )
3789 - pam? (
3790 - sys-auth/pambase
3791 - virtual/pam
3792 - )
3793 - audit? ( sys-process/audit )
3794 - kernel_linux? (
3795 - sys-process/psmisc
3796 - !<sys-process/procps-3.3.9-r2
3797 - )
3798 - selinux? (
3799 - sys-apps/policycoreutils
3800 - >=sys-libs/libselinux-2.6
3801 - )
3802 - !<sys-apps/baselayout-2.1-r1
3803 - !<sys-fs/udev-init-scripts-27"
3804 -DEPEND="${COMMON_DEPEND}
3805 - virtual/os-headers
3806 - ncurses? ( virtual/pkgconfig )"
3807 -RDEPEND="${COMMON_DEPEND}
3808 - !prefix? (
3809 - kernel_linux? (
3810 - >=sys-apps/sysvinit-2.86-r6[selinux?]
3811 - virtual/tmpfiles
3812 - )
3813 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
3814 - )
3815 - selinux? (
3816 - >=sec-policy/selinux-base-policy-2.20170204-r4
3817 - >=sec-policy/selinux-openrc-2.20170204-r4
3818 - )
3819 -"
3820 -
3821 -PDEPEND="netifrc? ( net-misc/netifrc )"
3822 -
3823 -src_prepare() {
3824 - default
3825 -
3826 - sed -i 's:0444:0644:' mk/sys.mk || die
3827 -
3828 - if [[ ${PV} == "9999" ]] ; then
3829 - local ver="git-${EGIT_VERSION:0:6}"
3830 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
3831 - fi
3832 -}
3833 -
3834 -src_compile() {
3835 - unset LIBDIR #266688
3836 -
3837 - MAKE_ARGS="${MAKE_ARGS}
3838 - LIBNAME=$(get_libdir)
3839 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
3840 - MKNET=$(usex newnet)
3841 - MKSELINUX=$(usex selinux)
3842 - MKAUDIT=$(usex audit)
3843 - MKPAM=$(usev pam)
3844 - MKSTATICLIBS=$(usex static-libs)"
3845 -
3846 - local brand="Unknown"
3847 - if use kernel_linux ; then
3848 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
3849 - brand="Linux"
3850 - elif use kernel_FreeBSD ; then
3851 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
3852 - brand="FreeBSD"
3853 - fi
3854 - export BRANDING="Gentoo ${brand}"
3855 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
3856 - export DEBUG=$(usev debug)
3857 - export MKTERMCAP=$(usev ncurses)
3858 -
3859 - tc-export CC AR RANLIB
3860 - emake ${MAKE_ARGS}
3861 -}
3862 -
3863 -# set_config <file> <option name> <yes value> <no value> test
3864 -# a value of "#" will just comment out the option
3865 -set_config() {
3866 - local file="${ED}/$1" var=$2 val com
3867 - eval "${@:5}" && val=$3 || val=$4
3868 - [[ ${val} == "#" ]] && com="#" && val='\2'
3869 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
3870 -}
3871 -
3872 -set_config_yes_no() {
3873 - set_config "$1" "$2" YES NO "${@:3}"
3874 -}
3875 -
3876 -src_install() {
3877 - emake ${MAKE_ARGS} DESTDIR="${D}" install
3878 -
3879 - # move the shared libs back to /usr so ldscript can install
3880 - # more of a minimal set of files
3881 - # disabled for now due to #270646
3882 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
3883 - #gen_usr_ldscript -a einfo rc
3884 - gen_usr_ldscript libeinfo.so
3885 - gen_usr_ldscript librc.so
3886 -
3887 - if ! use kernel_linux; then
3888 - keepdir /$(get_libdir)/rc/init.d
3889 - fi
3890 - keepdir /$(get_libdir)/rc/tmp
3891 -
3892 - # Backup our default runlevels
3893 - dodir /usr/share/"${PN}"
3894 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
3895 - rm -rf "${ED}"/etc/runlevels
3896 -
3897 - # Setup unicode defaults for silly unicode users
3898 - set_config_yes_no /etc/rc.conf unicode use unicode
3899 -
3900 - # Cater to the norm
3901 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
3902 -
3903 - # On HPPA, do not run consolefont by default (bug #222889)
3904 - if use hppa; then
3905 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
3906 - fi
3907 -
3908 - # Support for logfile rotation
3909 - insinto /etc/logrotate.d
3910 - newins "${FILESDIR}"/openrc.logrotate openrc
3911 -
3912 - # install gentoo pam.d files
3913 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
3914 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
3915 -
3916 - # install documentation
3917 - dodoc ChangeLog *.md
3918 - if use newnet; then
3919 - dodoc README.newnet
3920 - fi
3921 -}
3922 -
3923 -add_boot_init() {
3924 - local initd=$1
3925 - local runlevel=${2:-boot}
3926 - # if the initscript is not going to be installed and is not
3927 - # currently installed, return
3928 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
3929 - || return
3930 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
3931 -
3932 - # if runlevels dont exist just yet, then create it but still flag
3933 - # to pkg_postinst that it needs real setup #277323
3934 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
3935 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
3936 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
3937 - fi
3938 -
3939 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
3940 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
3941 -}
3942 -add_boot_init_mit_config() {
3943 - local config=$1 initd=$2
3944 - if [[ -e ${EROOT}${config} ]] ; then
3945 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
3946 - add_boot_init ${initd}
3947 - fi
3948 - fi
3949 -}
3950 -
3951 -pkg_preinst() {
3952 - local f LIBDIR=$(get_libdir)
3953 -
3954 - # avoid default thrashing in conf.d files when possible #295406
3955 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
3956 - (
3957 - unset hostname HOSTNAME
3958 - source "${EROOT}"etc/conf.d/hostname
3959 - : ${hostname:=${HOSTNAME}}
3960 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
3961 - )
3962 - fi
3963 -
3964 - # set default interactive shell to sulogin if it exists
3965 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
3966 -
3967 - # termencoding was added in 0.2.1 and needed in boot
3968 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
3969 -
3970 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
3971 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
3972 -
3973 - if ! has_version ">=sys-apps/openrc-0.11"; then
3974 - add_boot_init sysfs sysinit
3975 - fi
3976 -
3977 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
3978 - migrate_udev_mount_script
3979 - add_boot_init tmpfiles.setup boot
3980 - fi
3981 -
3982 - # these were added in 0.12.
3983 - if ! has_version ">=sys-apps/openrc-0.12"; then
3984 - add_boot_init loopback
3985 - add_boot_init tmpfiles.dev sysinit
3986 -
3987 - # ensure existing /etc/conf.d/net is not removed
3988 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
3989 - # this needs to stay in openrc ebuilds for a long time. :(
3990 - # Added in 0.12.
3991 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
3992 - einfo "Modifying conf.d/net to keep it from being removed"
3993 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
3994 -
3995 -# The network scripts are now part of net-misc/netifrc
3996 -# In order to avoid sys-apps/${P} from removing this file, this comment was
3997 -# added; you can safely remove this comment. Please see
3998 -# /usr/share/doc/netifrc*/README* for more information.
3999 -EOF
4000 - fi
4001 - fi
4002 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
4003 -
4004 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
4005 - add_boot_init mtab
4006 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
4007 - ewarn "${EROOT}etc/mtab will be replaced with a"
4008 - ewarn "symbolic link to /proc/self/mounts on the next"
4009 - ewarn "reboot."
4010 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
4011 - ewarn "if you do not want this to happen."
4012 - fi
4013 - fi
4014 -}
4015 -
4016 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
4017 -migrate_udev_mount_script() {
4018 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
4019 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
4020 - add_boot_init udev-mount sysinit
4021 - fi
4022 - return 0
4023 -}
4024 -
4025 -pkg_postinst() {
4026 - local LIBDIR=$(get_libdir)
4027 -
4028 - # Make our runlevels if they don't exist
4029 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
4030 - einfo "Copying across default runlevels"
4031 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
4032 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
4033 - else
4034 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
4035 - mkdir -p "${EROOT}"etc/runlevels/sysinit
4036 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
4037 - "${EROOT}"etc/runlevels/sysinit
4038 - fi
4039 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
4040 - mkdir -p "${EROOT}"etc/runlevels/shutdown
4041 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
4042 - "${EROOT}"etc/runlevels/shutdown
4043 - fi
4044 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
4045 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
4046 - "${EROOT}"etc/runlevels
4047 - fi
4048 - fi
4049 -
4050 - if use hppa; then
4051 - elog "Setting the console font does not work on all HPPA consoles."
4052 - elog "You can still enable it by running:"
4053 - elog "# rc-update add consolefont boot"
4054 - fi
4055 -
4056 - # Handle the conf.d/local.{start,stop} -> local.d transition
4057 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
4058 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
4059 - elog "files to ${EROOT}etc/local.d"
4060 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
4061 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
4062 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
4063 - fi
4064 -
4065 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
4066 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
4067 - ewarn "The dependency data could not be migrated to /run/openrc."
4068 - ewarn "This means you need to reboot your system."
4069 - fi
4070 - fi
4071 -
4072 - # update the dependency tree after touching all files #224171
4073 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
4074 -
4075 - if ! use newnet && ! use netifrc; then
4076 - ewarn "You have emerged OpenRc without network support. This"
4077 - ewarn "means you need to SET UP a network manager such as"
4078 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
4079 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
4080 - ewarn "Or, you have the option of emerging openrc with the newnet"
4081 - ewarn "use flag and configuring /etc/conf.d/network and"
4082 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
4083 - ewarn
4084 - fi
4085 -
4086 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
4087 - ewarn "Please add the network service to your boot runlevel"
4088 - ewarn "as soon as possible. Not doing so could leave you with a system"
4089 - ewarn "without networking."
4090 - ewarn
4091 - fi
4092 -}
4093
4094 diff --git a/sys-apps/openrc/openrc-0.34.4.ebuild b/sys-apps/openrc/openrc-0.34.4.ebuild
4095 deleted file mode 100644
4096 index 15376774cd7..00000000000
4097 --- a/sys-apps/openrc/openrc-0.34.4.ebuild
4098 +++ /dev/null
4099 @@ -1,329 +0,0 @@
4100 -# Copyright 1999-2017 Gentoo Foundation
4101 -# Distributed under the terms of the GNU General Public License v2
4102 -
4103 -EAPI=6
4104 -
4105 -inherit flag-o-matic pam toolchain-funcs
4106 -
4107 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
4108 -HOMEPAGE="https://github.com/openrc/openrc/"
4109 -
4110 -if [[ ${PV} == "9999" ]]; then
4111 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
4112 - inherit git-r3
4113 -else
4114 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
4115 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
4116 -fi
4117 -
4118 -LICENSE="BSD-2"
4119 -SLOT="0"
4120 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
4121 - unicode kernel_linux kernel_FreeBSD"
4122 -
4123 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
4124 - ncurses? ( sys-libs/ncurses:0= )
4125 - pam? (
4126 - sys-auth/pambase
4127 - virtual/pam
4128 - )
4129 - audit? ( sys-process/audit )
4130 - kernel_linux? (
4131 - sys-process/psmisc
4132 - !<sys-process/procps-3.3.9-r2
4133 - )
4134 - selinux? (
4135 - sys-apps/policycoreutils
4136 - >=sys-libs/libselinux-2.6
4137 - )
4138 - !<sys-apps/baselayout-2.1-r1
4139 - !<sys-fs/udev-init-scripts-27"
4140 -DEPEND="${COMMON_DEPEND}
4141 - virtual/os-headers
4142 - ncurses? ( virtual/pkgconfig )"
4143 -RDEPEND="${COMMON_DEPEND}
4144 - !prefix? (
4145 - kernel_linux? (
4146 - >=sys-apps/sysvinit-2.86-r6[selinux?]
4147 - virtual/tmpfiles
4148 - )
4149 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
4150 - )
4151 - selinux? (
4152 - >=sec-policy/selinux-base-policy-2.20170204-r4
4153 - >=sec-policy/selinux-openrc-2.20170204-r4
4154 - )
4155 -"
4156 -
4157 -PDEPEND="netifrc? ( net-misc/netifrc )"
4158 -
4159 -src_prepare() {
4160 - default
4161 -
4162 - sed -i 's:0444:0644:' mk/sys.mk || die
4163 -
4164 - if [[ ${PV} == "9999" ]] ; then
4165 - local ver="git-${EGIT_VERSION:0:6}"
4166 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
4167 - fi
4168 -}
4169 -
4170 -src_compile() {
4171 - unset LIBDIR #266688
4172 -
4173 - MAKE_ARGS="${MAKE_ARGS}
4174 - LIBNAME=$(get_libdir)
4175 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
4176 - MKNET=$(usex newnet)
4177 - MKSELINUX=$(usex selinux)
4178 - MKAUDIT=$(usex audit)
4179 - MKPAM=$(usev pam)
4180 - MKSTATICLIBS=$(usex static-libs)"
4181 -
4182 - local brand="Unknown"
4183 - if use kernel_linux ; then
4184 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
4185 - brand="Linux"
4186 - elif use kernel_FreeBSD ; then
4187 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
4188 - brand="FreeBSD"
4189 - fi
4190 - export BRANDING="Gentoo ${brand}"
4191 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
4192 - export DEBUG=$(usev debug)
4193 - export MKTERMCAP=$(usev ncurses)
4194 -
4195 - tc-export CC AR RANLIB
4196 - emake ${MAKE_ARGS}
4197 -}
4198 -
4199 -# set_config <file> <option name> <yes value> <no value> test
4200 -# a value of "#" will just comment out the option
4201 -set_config() {
4202 - local file="${ED}/$1" var=$2 val com
4203 - eval "${@:5}" && val=$3 || val=$4
4204 - [[ ${val} == "#" ]] && com="#" && val='\2'
4205 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
4206 -}
4207 -
4208 -set_config_yes_no() {
4209 - set_config "$1" "$2" YES NO "${@:3}"
4210 -}
4211 -
4212 -src_install() {
4213 - emake ${MAKE_ARGS} DESTDIR="${D}" install
4214 -
4215 - # move the shared libs back to /usr so ldscript can install
4216 - # more of a minimal set of files
4217 - # disabled for now due to #270646
4218 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
4219 - #gen_usr_ldscript -a einfo rc
4220 - gen_usr_ldscript libeinfo.so
4221 - gen_usr_ldscript librc.so
4222 -
4223 - if ! use kernel_linux; then
4224 - keepdir /$(get_libdir)/rc/init.d
4225 - fi
4226 - keepdir /$(get_libdir)/rc/tmp
4227 -
4228 - # Backup our default runlevels
4229 - dodir /usr/share/"${PN}"
4230 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
4231 - rm -rf "${ED}"/etc/runlevels
4232 -
4233 - # Setup unicode defaults for silly unicode users
4234 - set_config_yes_no /etc/rc.conf unicode use unicode
4235 -
4236 - # Cater to the norm
4237 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
4238 -
4239 - # On HPPA, do not run consolefont by default (bug #222889)
4240 - if use hppa; then
4241 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
4242 - fi
4243 -
4244 - # Support for logfile rotation
4245 - insinto /etc/logrotate.d
4246 - newins "${FILESDIR}"/openrc.logrotate openrc
4247 -
4248 - # install gentoo pam.d files
4249 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
4250 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
4251 -
4252 - # install documentation
4253 - dodoc ChangeLog *.md
4254 - if use newnet; then
4255 - dodoc README.newnet
4256 - fi
4257 -}
4258 -
4259 -add_boot_init() {
4260 - local initd=$1
4261 - local runlevel=${2:-boot}
4262 - # if the initscript is not going to be installed and is not
4263 - # currently installed, return
4264 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
4265 - || return
4266 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
4267 -
4268 - # if runlevels dont exist just yet, then create it but still flag
4269 - # to pkg_postinst that it needs real setup #277323
4270 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
4271 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
4272 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
4273 - fi
4274 -
4275 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
4276 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
4277 -}
4278 -add_boot_init_mit_config() {
4279 - local config=$1 initd=$2
4280 - if [[ -e ${EROOT}${config} ]] ; then
4281 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
4282 - add_boot_init ${initd}
4283 - fi
4284 - fi
4285 -}
4286 -
4287 -pkg_preinst() {
4288 - local f LIBDIR=$(get_libdir)
4289 -
4290 - # avoid default thrashing in conf.d files when possible #295406
4291 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
4292 - (
4293 - unset hostname HOSTNAME
4294 - source "${EROOT}"etc/conf.d/hostname
4295 - : ${hostname:=${HOSTNAME}}
4296 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
4297 - )
4298 - fi
4299 -
4300 - # set default interactive shell to sulogin if it exists
4301 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
4302 -
4303 - # termencoding was added in 0.2.1 and needed in boot
4304 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
4305 -
4306 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
4307 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
4308 -
4309 - if ! has_version ">=sys-apps/openrc-0.11"; then
4310 - add_boot_init sysfs sysinit
4311 - fi
4312 -
4313 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
4314 - migrate_udev_mount_script
4315 - add_boot_init tmpfiles.setup boot
4316 - fi
4317 -
4318 - # these were added in 0.12.
4319 - if ! has_version ">=sys-apps/openrc-0.12"; then
4320 - add_boot_init loopback
4321 - add_boot_init tmpfiles.dev sysinit
4322 -
4323 - # ensure existing /etc/conf.d/net is not removed
4324 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
4325 - # this needs to stay in openrc ebuilds for a long time. :(
4326 - # Added in 0.12.
4327 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
4328 - einfo "Modifying conf.d/net to keep it from being removed"
4329 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
4330 -
4331 -# The network scripts are now part of net-misc/netifrc
4332 -# In order to avoid sys-apps/${P} from removing this file, this comment was
4333 -# added; you can safely remove this comment. Please see
4334 -# /usr/share/doc/netifrc*/README* for more information.
4335 -EOF
4336 - fi
4337 - fi
4338 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
4339 -
4340 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
4341 - add_boot_init mtab
4342 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
4343 - ewarn "${EROOT}etc/mtab will be replaced with a"
4344 - ewarn "symbolic link to /proc/self/mounts on the next"
4345 - ewarn "reboot."
4346 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
4347 - ewarn "if you do not want this to happen."
4348 - fi
4349 - fi
4350 -}
4351 -
4352 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
4353 -migrate_udev_mount_script() {
4354 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
4355 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
4356 - add_boot_init udev-mount sysinit
4357 - fi
4358 - return 0
4359 -}
4360 -
4361 -pkg_postinst() {
4362 - local LIBDIR=$(get_libdir)
4363 -
4364 - # Make our runlevels if they don't exist
4365 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
4366 - einfo "Copying across default runlevels"
4367 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
4368 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
4369 - else
4370 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
4371 - mkdir -p "${EROOT}"etc/runlevels/sysinit
4372 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
4373 - "${EROOT}"etc/runlevels/sysinit
4374 - fi
4375 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
4376 - mkdir -p "${EROOT}"etc/runlevels/shutdown
4377 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
4378 - "${EROOT}"etc/runlevels/shutdown
4379 - fi
4380 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
4381 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
4382 - "${EROOT}"etc/runlevels
4383 - fi
4384 - fi
4385 -
4386 - if use hppa; then
4387 - elog "Setting the console font does not work on all HPPA consoles."
4388 - elog "You can still enable it by running:"
4389 - elog "# rc-update add consolefont boot"
4390 - fi
4391 -
4392 - # Handle the conf.d/local.{start,stop} -> local.d transition
4393 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
4394 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
4395 - elog "files to ${EROOT}etc/local.d"
4396 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
4397 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
4398 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
4399 - fi
4400 -
4401 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
4402 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
4403 - ewarn "The dependency data could not be migrated to /run/openrc."
4404 - ewarn "This means you need to reboot your system."
4405 - fi
4406 - fi
4407 -
4408 - # update the dependency tree after touching all files #224171
4409 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
4410 -
4411 - if ! use newnet && ! use netifrc; then
4412 - ewarn "You have emerged OpenRc without network support. This"
4413 - ewarn "means you need to SET UP a network manager such as"
4414 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
4415 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
4416 - ewarn "Or, you have the option of emerging openrc with the newnet"
4417 - ewarn "use flag and configuring /etc/conf.d/network and"
4418 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
4419 - ewarn
4420 - fi
4421 -
4422 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
4423 - ewarn "Please add the network service to your boot runlevel"
4424 - ewarn "as soon as possible. Not doing so could leave you with a system"
4425 - ewarn "without networking."
4426 - ewarn
4427 - fi
4428 -}
4429
4430 diff --git a/sys-apps/openrc/openrc-0.34.5.ebuild b/sys-apps/openrc/openrc-0.34.5.ebuild
4431 deleted file mode 100644
4432 index 15376774cd7..00000000000
4433 --- a/sys-apps/openrc/openrc-0.34.5.ebuild
4434 +++ /dev/null
4435 @@ -1,329 +0,0 @@
4436 -# Copyright 1999-2017 Gentoo Foundation
4437 -# Distributed under the terms of the GNU General Public License v2
4438 -
4439 -EAPI=6
4440 -
4441 -inherit flag-o-matic pam toolchain-funcs
4442 -
4443 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
4444 -HOMEPAGE="https://github.com/openrc/openrc/"
4445 -
4446 -if [[ ${PV} == "9999" ]]; then
4447 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
4448 - inherit git-r3
4449 -else
4450 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
4451 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
4452 -fi
4453 -
4454 -LICENSE="BSD-2"
4455 -SLOT="0"
4456 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
4457 - unicode kernel_linux kernel_FreeBSD"
4458 -
4459 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
4460 - ncurses? ( sys-libs/ncurses:0= )
4461 - pam? (
4462 - sys-auth/pambase
4463 - virtual/pam
4464 - )
4465 - audit? ( sys-process/audit )
4466 - kernel_linux? (
4467 - sys-process/psmisc
4468 - !<sys-process/procps-3.3.9-r2
4469 - )
4470 - selinux? (
4471 - sys-apps/policycoreutils
4472 - >=sys-libs/libselinux-2.6
4473 - )
4474 - !<sys-apps/baselayout-2.1-r1
4475 - !<sys-fs/udev-init-scripts-27"
4476 -DEPEND="${COMMON_DEPEND}
4477 - virtual/os-headers
4478 - ncurses? ( virtual/pkgconfig )"
4479 -RDEPEND="${COMMON_DEPEND}
4480 - !prefix? (
4481 - kernel_linux? (
4482 - >=sys-apps/sysvinit-2.86-r6[selinux?]
4483 - virtual/tmpfiles
4484 - )
4485 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
4486 - )
4487 - selinux? (
4488 - >=sec-policy/selinux-base-policy-2.20170204-r4
4489 - >=sec-policy/selinux-openrc-2.20170204-r4
4490 - )
4491 -"
4492 -
4493 -PDEPEND="netifrc? ( net-misc/netifrc )"
4494 -
4495 -src_prepare() {
4496 - default
4497 -
4498 - sed -i 's:0444:0644:' mk/sys.mk || die
4499 -
4500 - if [[ ${PV} == "9999" ]] ; then
4501 - local ver="git-${EGIT_VERSION:0:6}"
4502 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
4503 - fi
4504 -}
4505 -
4506 -src_compile() {
4507 - unset LIBDIR #266688
4508 -
4509 - MAKE_ARGS="${MAKE_ARGS}
4510 - LIBNAME=$(get_libdir)
4511 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
4512 - MKNET=$(usex newnet)
4513 - MKSELINUX=$(usex selinux)
4514 - MKAUDIT=$(usex audit)
4515 - MKPAM=$(usev pam)
4516 - MKSTATICLIBS=$(usex static-libs)"
4517 -
4518 - local brand="Unknown"
4519 - if use kernel_linux ; then
4520 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
4521 - brand="Linux"
4522 - elif use kernel_FreeBSD ; then
4523 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
4524 - brand="FreeBSD"
4525 - fi
4526 - export BRANDING="Gentoo ${brand}"
4527 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
4528 - export DEBUG=$(usev debug)
4529 - export MKTERMCAP=$(usev ncurses)
4530 -
4531 - tc-export CC AR RANLIB
4532 - emake ${MAKE_ARGS}
4533 -}
4534 -
4535 -# set_config <file> <option name> <yes value> <no value> test
4536 -# a value of "#" will just comment out the option
4537 -set_config() {
4538 - local file="${ED}/$1" var=$2 val com
4539 - eval "${@:5}" && val=$3 || val=$4
4540 - [[ ${val} == "#" ]] && com="#" && val='\2'
4541 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
4542 -}
4543 -
4544 -set_config_yes_no() {
4545 - set_config "$1" "$2" YES NO "${@:3}"
4546 -}
4547 -
4548 -src_install() {
4549 - emake ${MAKE_ARGS} DESTDIR="${D}" install
4550 -
4551 - # move the shared libs back to /usr so ldscript can install
4552 - # more of a minimal set of files
4553 - # disabled for now due to #270646
4554 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
4555 - #gen_usr_ldscript -a einfo rc
4556 - gen_usr_ldscript libeinfo.so
4557 - gen_usr_ldscript librc.so
4558 -
4559 - if ! use kernel_linux; then
4560 - keepdir /$(get_libdir)/rc/init.d
4561 - fi
4562 - keepdir /$(get_libdir)/rc/tmp
4563 -
4564 - # Backup our default runlevels
4565 - dodir /usr/share/"${PN}"
4566 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
4567 - rm -rf "${ED}"/etc/runlevels
4568 -
4569 - # Setup unicode defaults for silly unicode users
4570 - set_config_yes_no /etc/rc.conf unicode use unicode
4571 -
4572 - # Cater to the norm
4573 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
4574 -
4575 - # On HPPA, do not run consolefont by default (bug #222889)
4576 - if use hppa; then
4577 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
4578 - fi
4579 -
4580 - # Support for logfile rotation
4581 - insinto /etc/logrotate.d
4582 - newins "${FILESDIR}"/openrc.logrotate openrc
4583 -
4584 - # install gentoo pam.d files
4585 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
4586 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
4587 -
4588 - # install documentation
4589 - dodoc ChangeLog *.md
4590 - if use newnet; then
4591 - dodoc README.newnet
4592 - fi
4593 -}
4594 -
4595 -add_boot_init() {
4596 - local initd=$1
4597 - local runlevel=${2:-boot}
4598 - # if the initscript is not going to be installed and is not
4599 - # currently installed, return
4600 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
4601 - || return
4602 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
4603 -
4604 - # if runlevels dont exist just yet, then create it but still flag
4605 - # to pkg_postinst that it needs real setup #277323
4606 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
4607 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
4608 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
4609 - fi
4610 -
4611 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
4612 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
4613 -}
4614 -add_boot_init_mit_config() {
4615 - local config=$1 initd=$2
4616 - if [[ -e ${EROOT}${config} ]] ; then
4617 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
4618 - add_boot_init ${initd}
4619 - fi
4620 - fi
4621 -}
4622 -
4623 -pkg_preinst() {
4624 - local f LIBDIR=$(get_libdir)
4625 -
4626 - # avoid default thrashing in conf.d files when possible #295406
4627 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
4628 - (
4629 - unset hostname HOSTNAME
4630 - source "${EROOT}"etc/conf.d/hostname
4631 - : ${hostname:=${HOSTNAME}}
4632 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
4633 - )
4634 - fi
4635 -
4636 - # set default interactive shell to sulogin if it exists
4637 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
4638 -
4639 - # termencoding was added in 0.2.1 and needed in boot
4640 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
4641 -
4642 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
4643 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
4644 -
4645 - if ! has_version ">=sys-apps/openrc-0.11"; then
4646 - add_boot_init sysfs sysinit
4647 - fi
4648 -
4649 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
4650 - migrate_udev_mount_script
4651 - add_boot_init tmpfiles.setup boot
4652 - fi
4653 -
4654 - # these were added in 0.12.
4655 - if ! has_version ">=sys-apps/openrc-0.12"; then
4656 - add_boot_init loopback
4657 - add_boot_init tmpfiles.dev sysinit
4658 -
4659 - # ensure existing /etc/conf.d/net is not removed
4660 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
4661 - # this needs to stay in openrc ebuilds for a long time. :(
4662 - # Added in 0.12.
4663 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
4664 - einfo "Modifying conf.d/net to keep it from being removed"
4665 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
4666 -
4667 -# The network scripts are now part of net-misc/netifrc
4668 -# In order to avoid sys-apps/${P} from removing this file, this comment was
4669 -# added; you can safely remove this comment. Please see
4670 -# /usr/share/doc/netifrc*/README* for more information.
4671 -EOF
4672 - fi
4673 - fi
4674 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
4675 -
4676 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
4677 - add_boot_init mtab
4678 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
4679 - ewarn "${EROOT}etc/mtab will be replaced with a"
4680 - ewarn "symbolic link to /proc/self/mounts on the next"
4681 - ewarn "reboot."
4682 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
4683 - ewarn "if you do not want this to happen."
4684 - fi
4685 - fi
4686 -}
4687 -
4688 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
4689 -migrate_udev_mount_script() {
4690 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
4691 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
4692 - add_boot_init udev-mount sysinit
4693 - fi
4694 - return 0
4695 -}
4696 -
4697 -pkg_postinst() {
4698 - local LIBDIR=$(get_libdir)
4699 -
4700 - # Make our runlevels if they don't exist
4701 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
4702 - einfo "Copying across default runlevels"
4703 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
4704 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
4705 - else
4706 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
4707 - mkdir -p "${EROOT}"etc/runlevels/sysinit
4708 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
4709 - "${EROOT}"etc/runlevels/sysinit
4710 - fi
4711 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
4712 - mkdir -p "${EROOT}"etc/runlevels/shutdown
4713 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
4714 - "${EROOT}"etc/runlevels/shutdown
4715 - fi
4716 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
4717 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
4718 - "${EROOT}"etc/runlevels
4719 - fi
4720 - fi
4721 -
4722 - if use hppa; then
4723 - elog "Setting the console font does not work on all HPPA consoles."
4724 - elog "You can still enable it by running:"
4725 - elog "# rc-update add consolefont boot"
4726 - fi
4727 -
4728 - # Handle the conf.d/local.{start,stop} -> local.d transition
4729 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
4730 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
4731 - elog "files to ${EROOT}etc/local.d"
4732 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
4733 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
4734 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
4735 - fi
4736 -
4737 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
4738 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
4739 - ewarn "The dependency data could not be migrated to /run/openrc."
4740 - ewarn "This means you need to reboot your system."
4741 - fi
4742 - fi
4743 -
4744 - # update the dependency tree after touching all files #224171
4745 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
4746 -
4747 - if ! use newnet && ! use netifrc; then
4748 - ewarn "You have emerged OpenRc without network support. This"
4749 - ewarn "means you need to SET UP a network manager such as"
4750 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
4751 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
4752 - ewarn "Or, you have the option of emerging openrc with the newnet"
4753 - ewarn "use flag and configuring /etc/conf.d/network and"
4754 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
4755 - ewarn
4756 - fi
4757 -
4758 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
4759 - ewarn "Please add the network service to your boot runlevel"
4760 - ewarn "as soon as possible. Not doing so could leave you with a system"
4761 - ewarn "without networking."
4762 - ewarn
4763 - fi
4764 -}
4765
4766 diff --git a/sys-apps/openrc/openrc-0.34.6.ebuild b/sys-apps/openrc/openrc-0.34.6.ebuild
4767 deleted file mode 100644
4768 index 15376774cd7..00000000000
4769 --- a/sys-apps/openrc/openrc-0.34.6.ebuild
4770 +++ /dev/null
4771 @@ -1,329 +0,0 @@
4772 -# Copyright 1999-2017 Gentoo Foundation
4773 -# Distributed under the terms of the GNU General Public License v2
4774 -
4775 -EAPI=6
4776 -
4777 -inherit flag-o-matic pam toolchain-funcs
4778 -
4779 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
4780 -HOMEPAGE="https://github.com/openrc/openrc/"
4781 -
4782 -if [[ ${PV} == "9999" ]]; then
4783 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
4784 - inherit git-r3
4785 -else
4786 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
4787 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
4788 -fi
4789 -
4790 -LICENSE="BSD-2"
4791 -SLOT="0"
4792 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
4793 - unicode kernel_linux kernel_FreeBSD"
4794 -
4795 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
4796 - ncurses? ( sys-libs/ncurses:0= )
4797 - pam? (
4798 - sys-auth/pambase
4799 - virtual/pam
4800 - )
4801 - audit? ( sys-process/audit )
4802 - kernel_linux? (
4803 - sys-process/psmisc
4804 - !<sys-process/procps-3.3.9-r2
4805 - )
4806 - selinux? (
4807 - sys-apps/policycoreutils
4808 - >=sys-libs/libselinux-2.6
4809 - )
4810 - !<sys-apps/baselayout-2.1-r1
4811 - !<sys-fs/udev-init-scripts-27"
4812 -DEPEND="${COMMON_DEPEND}
4813 - virtual/os-headers
4814 - ncurses? ( virtual/pkgconfig )"
4815 -RDEPEND="${COMMON_DEPEND}
4816 - !prefix? (
4817 - kernel_linux? (
4818 - >=sys-apps/sysvinit-2.86-r6[selinux?]
4819 - virtual/tmpfiles
4820 - )
4821 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
4822 - )
4823 - selinux? (
4824 - >=sec-policy/selinux-base-policy-2.20170204-r4
4825 - >=sec-policy/selinux-openrc-2.20170204-r4
4826 - )
4827 -"
4828 -
4829 -PDEPEND="netifrc? ( net-misc/netifrc )"
4830 -
4831 -src_prepare() {
4832 - default
4833 -
4834 - sed -i 's:0444:0644:' mk/sys.mk || die
4835 -
4836 - if [[ ${PV} == "9999" ]] ; then
4837 - local ver="git-${EGIT_VERSION:0:6}"
4838 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
4839 - fi
4840 -}
4841 -
4842 -src_compile() {
4843 - unset LIBDIR #266688
4844 -
4845 - MAKE_ARGS="${MAKE_ARGS}
4846 - LIBNAME=$(get_libdir)
4847 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
4848 - MKNET=$(usex newnet)
4849 - MKSELINUX=$(usex selinux)
4850 - MKAUDIT=$(usex audit)
4851 - MKPAM=$(usev pam)
4852 - MKSTATICLIBS=$(usex static-libs)"
4853 -
4854 - local brand="Unknown"
4855 - if use kernel_linux ; then
4856 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
4857 - brand="Linux"
4858 - elif use kernel_FreeBSD ; then
4859 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
4860 - brand="FreeBSD"
4861 - fi
4862 - export BRANDING="Gentoo ${brand}"
4863 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
4864 - export DEBUG=$(usev debug)
4865 - export MKTERMCAP=$(usev ncurses)
4866 -
4867 - tc-export CC AR RANLIB
4868 - emake ${MAKE_ARGS}
4869 -}
4870 -
4871 -# set_config <file> <option name> <yes value> <no value> test
4872 -# a value of "#" will just comment out the option
4873 -set_config() {
4874 - local file="${ED}/$1" var=$2 val com
4875 - eval "${@:5}" && val=$3 || val=$4
4876 - [[ ${val} == "#" ]] && com="#" && val='\2'
4877 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
4878 -}
4879 -
4880 -set_config_yes_no() {
4881 - set_config "$1" "$2" YES NO "${@:3}"
4882 -}
4883 -
4884 -src_install() {
4885 - emake ${MAKE_ARGS} DESTDIR="${D}" install
4886 -
4887 - # move the shared libs back to /usr so ldscript can install
4888 - # more of a minimal set of files
4889 - # disabled for now due to #270646
4890 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
4891 - #gen_usr_ldscript -a einfo rc
4892 - gen_usr_ldscript libeinfo.so
4893 - gen_usr_ldscript librc.so
4894 -
4895 - if ! use kernel_linux; then
4896 - keepdir /$(get_libdir)/rc/init.d
4897 - fi
4898 - keepdir /$(get_libdir)/rc/tmp
4899 -
4900 - # Backup our default runlevels
4901 - dodir /usr/share/"${PN}"
4902 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
4903 - rm -rf "${ED}"/etc/runlevels
4904 -
4905 - # Setup unicode defaults for silly unicode users
4906 - set_config_yes_no /etc/rc.conf unicode use unicode
4907 -
4908 - # Cater to the norm
4909 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
4910 -
4911 - # On HPPA, do not run consolefont by default (bug #222889)
4912 - if use hppa; then
4913 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
4914 - fi
4915 -
4916 - # Support for logfile rotation
4917 - insinto /etc/logrotate.d
4918 - newins "${FILESDIR}"/openrc.logrotate openrc
4919 -
4920 - # install gentoo pam.d files
4921 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
4922 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
4923 -
4924 - # install documentation
4925 - dodoc ChangeLog *.md
4926 - if use newnet; then
4927 - dodoc README.newnet
4928 - fi
4929 -}
4930 -
4931 -add_boot_init() {
4932 - local initd=$1
4933 - local runlevel=${2:-boot}
4934 - # if the initscript is not going to be installed and is not
4935 - # currently installed, return
4936 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
4937 - || return
4938 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
4939 -
4940 - # if runlevels dont exist just yet, then create it but still flag
4941 - # to pkg_postinst that it needs real setup #277323
4942 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
4943 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
4944 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
4945 - fi
4946 -
4947 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
4948 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
4949 -}
4950 -add_boot_init_mit_config() {
4951 - local config=$1 initd=$2
4952 - if [[ -e ${EROOT}${config} ]] ; then
4953 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
4954 - add_boot_init ${initd}
4955 - fi
4956 - fi
4957 -}
4958 -
4959 -pkg_preinst() {
4960 - local f LIBDIR=$(get_libdir)
4961 -
4962 - # avoid default thrashing in conf.d files when possible #295406
4963 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
4964 - (
4965 - unset hostname HOSTNAME
4966 - source "${EROOT}"etc/conf.d/hostname
4967 - : ${hostname:=${HOSTNAME}}
4968 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
4969 - )
4970 - fi
4971 -
4972 - # set default interactive shell to sulogin if it exists
4973 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
4974 -
4975 - # termencoding was added in 0.2.1 and needed in boot
4976 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
4977 -
4978 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
4979 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
4980 -
4981 - if ! has_version ">=sys-apps/openrc-0.11"; then
4982 - add_boot_init sysfs sysinit
4983 - fi
4984 -
4985 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
4986 - migrate_udev_mount_script
4987 - add_boot_init tmpfiles.setup boot
4988 - fi
4989 -
4990 - # these were added in 0.12.
4991 - if ! has_version ">=sys-apps/openrc-0.12"; then
4992 - add_boot_init loopback
4993 - add_boot_init tmpfiles.dev sysinit
4994 -
4995 - # ensure existing /etc/conf.d/net is not removed
4996 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
4997 - # this needs to stay in openrc ebuilds for a long time. :(
4998 - # Added in 0.12.
4999 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
5000 - einfo "Modifying conf.d/net to keep it from being removed"
5001 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
5002 -
5003 -# The network scripts are now part of net-misc/netifrc
5004 -# In order to avoid sys-apps/${P} from removing this file, this comment was
5005 -# added; you can safely remove this comment. Please see
5006 -# /usr/share/doc/netifrc*/README* for more information.
5007 -EOF
5008 - fi
5009 - fi
5010 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
5011 -
5012 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
5013 - add_boot_init mtab
5014 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
5015 - ewarn "${EROOT}etc/mtab will be replaced with a"
5016 - ewarn "symbolic link to /proc/self/mounts on the next"
5017 - ewarn "reboot."
5018 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
5019 - ewarn "if you do not want this to happen."
5020 - fi
5021 - fi
5022 -}
5023 -
5024 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
5025 -migrate_udev_mount_script() {
5026 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
5027 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
5028 - add_boot_init udev-mount sysinit
5029 - fi
5030 - return 0
5031 -}
5032 -
5033 -pkg_postinst() {
5034 - local LIBDIR=$(get_libdir)
5035 -
5036 - # Make our runlevels if they don't exist
5037 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
5038 - einfo "Copying across default runlevels"
5039 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
5040 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
5041 - else
5042 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
5043 - mkdir -p "${EROOT}"etc/runlevels/sysinit
5044 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
5045 - "${EROOT}"etc/runlevels/sysinit
5046 - fi
5047 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
5048 - mkdir -p "${EROOT}"etc/runlevels/shutdown
5049 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
5050 - "${EROOT}"etc/runlevels/shutdown
5051 - fi
5052 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
5053 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
5054 - "${EROOT}"etc/runlevels
5055 - fi
5056 - fi
5057 -
5058 - if use hppa; then
5059 - elog "Setting the console font does not work on all HPPA consoles."
5060 - elog "You can still enable it by running:"
5061 - elog "# rc-update add consolefont boot"
5062 - fi
5063 -
5064 - # Handle the conf.d/local.{start,stop} -> local.d transition
5065 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
5066 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
5067 - elog "files to ${EROOT}etc/local.d"
5068 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
5069 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
5070 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
5071 - fi
5072 -
5073 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
5074 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
5075 - ewarn "The dependency data could not be migrated to /run/openrc."
5076 - ewarn "This means you need to reboot your system."
5077 - fi
5078 - fi
5079 -
5080 - # update the dependency tree after touching all files #224171
5081 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
5082 -
5083 - if ! use newnet && ! use netifrc; then
5084 - ewarn "You have emerged OpenRc without network support. This"
5085 - ewarn "means you need to SET UP a network manager such as"
5086 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
5087 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
5088 - ewarn "Or, you have the option of emerging openrc with the newnet"
5089 - ewarn "use flag and configuring /etc/conf.d/network and"
5090 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
5091 - ewarn
5092 - fi
5093 -
5094 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
5095 - ewarn "Please add the network service to your boot runlevel"
5096 - ewarn "as soon as possible. Not doing so could leave you with a system"
5097 - ewarn "without networking."
5098 - ewarn
5099 - fi
5100 -}
5101
5102 diff --git a/sys-apps/openrc/openrc-0.34.7.ebuild b/sys-apps/openrc/openrc-0.34.7.ebuild
5103 deleted file mode 100644
5104 index f54f45f0fd3..00000000000
5105 --- a/sys-apps/openrc/openrc-0.34.7.ebuild
5106 +++ /dev/null
5107 @@ -1,329 +0,0 @@
5108 -# Copyright 1999-2017 Gentoo Foundation
5109 -# Distributed under the terms of the GNU General Public License v2
5110 -
5111 -EAPI=6
5112 -
5113 -inherit flag-o-matic pam toolchain-funcs
5114 -
5115 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
5116 -HOMEPAGE="https://github.com/openrc/openrc/"
5117 -
5118 -if [[ ${PV} == "9999" ]]; then
5119 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
5120 - inherit git-r3
5121 -else
5122 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
5123 - KEYWORDS="alpha amd64 ~arm ~arm64 hppa ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
5124 -fi
5125 -
5126 -LICENSE="BSD-2"
5127 -SLOT="0"
5128 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
5129 - unicode kernel_linux kernel_FreeBSD"
5130 -
5131 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
5132 - ncurses? ( sys-libs/ncurses:0= )
5133 - pam? (
5134 - sys-auth/pambase
5135 - virtual/pam
5136 - )
5137 - audit? ( sys-process/audit )
5138 - kernel_linux? (
5139 - sys-process/psmisc
5140 - !<sys-process/procps-3.3.9-r2
5141 - )
5142 - selinux? (
5143 - sys-apps/policycoreutils
5144 - >=sys-libs/libselinux-2.6
5145 - )
5146 - !<sys-apps/baselayout-2.1-r1
5147 - !<sys-fs/udev-init-scripts-27"
5148 -DEPEND="${COMMON_DEPEND}
5149 - virtual/os-headers
5150 - ncurses? ( virtual/pkgconfig )"
5151 -RDEPEND="${COMMON_DEPEND}
5152 - !prefix? (
5153 - kernel_linux? (
5154 - >=sys-apps/sysvinit-2.86-r6[selinux?]
5155 - virtual/tmpfiles
5156 - )
5157 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
5158 - )
5159 - selinux? (
5160 - >=sec-policy/selinux-base-policy-2.20170204-r4
5161 - >=sec-policy/selinux-openrc-2.20170204-r4
5162 - )
5163 -"
5164 -
5165 -PDEPEND="netifrc? ( net-misc/netifrc )"
5166 -
5167 -src_prepare() {
5168 - default
5169 -
5170 - sed -i 's:0444:0644:' mk/sys.mk || die
5171 -
5172 - if [[ ${PV} == "9999" ]] ; then
5173 - local ver="git-${EGIT_VERSION:0:6}"
5174 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
5175 - fi
5176 -}
5177 -
5178 -src_compile() {
5179 - unset LIBDIR #266688
5180 -
5181 - MAKE_ARGS="${MAKE_ARGS}
5182 - LIBNAME=$(get_libdir)
5183 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
5184 - MKNET=$(usex newnet)
5185 - MKSELINUX=$(usex selinux)
5186 - MKAUDIT=$(usex audit)
5187 - MKPAM=$(usev pam)
5188 - MKSTATICLIBS=$(usex static-libs)"
5189 -
5190 - local brand="Unknown"
5191 - if use kernel_linux ; then
5192 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
5193 - brand="Linux"
5194 - elif use kernel_FreeBSD ; then
5195 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
5196 - brand="FreeBSD"
5197 - fi
5198 - export BRANDING="Gentoo ${brand}"
5199 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
5200 - export DEBUG=$(usev debug)
5201 - export MKTERMCAP=$(usev ncurses)
5202 -
5203 - tc-export CC AR RANLIB
5204 - emake ${MAKE_ARGS}
5205 -}
5206 -
5207 -# set_config <file> <option name> <yes value> <no value> test
5208 -# a value of "#" will just comment out the option
5209 -set_config() {
5210 - local file="${ED}/$1" var=$2 val com
5211 - eval "${@:5}" && val=$3 || val=$4
5212 - [[ ${val} == "#" ]] && com="#" && val='\2'
5213 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
5214 -}
5215 -
5216 -set_config_yes_no() {
5217 - set_config "$1" "$2" YES NO "${@:3}"
5218 -}
5219 -
5220 -src_install() {
5221 - emake ${MAKE_ARGS} DESTDIR="${D}" install
5222 -
5223 - # move the shared libs back to /usr so ldscript can install
5224 - # more of a minimal set of files
5225 - # disabled for now due to #270646
5226 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
5227 - #gen_usr_ldscript -a einfo rc
5228 - gen_usr_ldscript libeinfo.so
5229 - gen_usr_ldscript librc.so
5230 -
5231 - if ! use kernel_linux; then
5232 - keepdir /$(get_libdir)/rc/init.d
5233 - fi
5234 - keepdir /$(get_libdir)/rc/tmp
5235 -
5236 - # Backup our default runlevels
5237 - dodir /usr/share/"${PN}"
5238 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
5239 - rm -rf "${ED}"/etc/runlevels
5240 -
5241 - # Setup unicode defaults for silly unicode users
5242 - set_config_yes_no /etc/rc.conf unicode use unicode
5243 -
5244 - # Cater to the norm
5245 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
5246 -
5247 - # On HPPA, do not run consolefont by default (bug #222889)
5248 - if use hppa; then
5249 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
5250 - fi
5251 -
5252 - # Support for logfile rotation
5253 - insinto /etc/logrotate.d
5254 - newins "${FILESDIR}"/openrc.logrotate openrc
5255 -
5256 - # install gentoo pam.d files
5257 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
5258 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
5259 -
5260 - # install documentation
5261 - dodoc ChangeLog *.md
5262 - if use newnet; then
5263 - dodoc README.newnet
5264 - fi
5265 -}
5266 -
5267 -add_boot_init() {
5268 - local initd=$1
5269 - local runlevel=${2:-boot}
5270 - # if the initscript is not going to be installed and is not
5271 - # currently installed, return
5272 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
5273 - || return
5274 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
5275 -
5276 - # if runlevels dont exist just yet, then create it but still flag
5277 - # to pkg_postinst that it needs real setup #277323
5278 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
5279 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
5280 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
5281 - fi
5282 -
5283 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
5284 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
5285 -}
5286 -add_boot_init_mit_config() {
5287 - local config=$1 initd=$2
5288 - if [[ -e ${EROOT}${config} ]] ; then
5289 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
5290 - add_boot_init ${initd}
5291 - fi
5292 - fi
5293 -}
5294 -
5295 -pkg_preinst() {
5296 - local f LIBDIR=$(get_libdir)
5297 -
5298 - # avoid default thrashing in conf.d files when possible #295406
5299 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
5300 - (
5301 - unset hostname HOSTNAME
5302 - source "${EROOT}"etc/conf.d/hostname
5303 - : ${hostname:=${HOSTNAME}}
5304 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
5305 - )
5306 - fi
5307 -
5308 - # set default interactive shell to sulogin if it exists
5309 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
5310 -
5311 - # termencoding was added in 0.2.1 and needed in boot
5312 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
5313 -
5314 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
5315 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
5316 -
5317 - if ! has_version ">=sys-apps/openrc-0.11"; then
5318 - add_boot_init sysfs sysinit
5319 - fi
5320 -
5321 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
5322 - migrate_udev_mount_script
5323 - add_boot_init tmpfiles.setup boot
5324 - fi
5325 -
5326 - # these were added in 0.12.
5327 - if ! has_version ">=sys-apps/openrc-0.12"; then
5328 - add_boot_init loopback
5329 - add_boot_init tmpfiles.dev sysinit
5330 -
5331 - # ensure existing /etc/conf.d/net is not removed
5332 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
5333 - # this needs to stay in openrc ebuilds for a long time. :(
5334 - # Added in 0.12.
5335 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
5336 - einfo "Modifying conf.d/net to keep it from being removed"
5337 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
5338 -
5339 -# The network scripts are now part of net-misc/netifrc
5340 -# In order to avoid sys-apps/${P} from removing this file, this comment was
5341 -# added; you can safely remove this comment. Please see
5342 -# /usr/share/doc/netifrc*/README* for more information.
5343 -EOF
5344 - fi
5345 - fi
5346 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
5347 -
5348 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
5349 - add_boot_init mtab
5350 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
5351 - ewarn "${EROOT}etc/mtab will be replaced with a"
5352 - ewarn "symbolic link to /proc/self/mounts on the next"
5353 - ewarn "reboot."
5354 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
5355 - ewarn "if you do not want this to happen."
5356 - fi
5357 - fi
5358 -}
5359 -
5360 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
5361 -migrate_udev_mount_script() {
5362 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
5363 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
5364 - add_boot_init udev-mount sysinit
5365 - fi
5366 - return 0
5367 -}
5368 -
5369 -pkg_postinst() {
5370 - local LIBDIR=$(get_libdir)
5371 -
5372 - # Make our runlevels if they don't exist
5373 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
5374 - einfo "Copying across default runlevels"
5375 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
5376 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
5377 - else
5378 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
5379 - mkdir -p "${EROOT}"etc/runlevels/sysinit
5380 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
5381 - "${EROOT}"etc/runlevels/sysinit
5382 - fi
5383 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
5384 - mkdir -p "${EROOT}"etc/runlevels/shutdown
5385 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
5386 - "${EROOT}"etc/runlevels/shutdown
5387 - fi
5388 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
5389 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
5390 - "${EROOT}"etc/runlevels
5391 - fi
5392 - fi
5393 -
5394 - if use hppa; then
5395 - elog "Setting the console font does not work on all HPPA consoles."
5396 - elog "You can still enable it by running:"
5397 - elog "# rc-update add consolefont boot"
5398 - fi
5399 -
5400 - # Handle the conf.d/local.{start,stop} -> local.d transition
5401 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
5402 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
5403 - elog "files to ${EROOT}etc/local.d"
5404 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
5405 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
5406 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
5407 - fi
5408 -
5409 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
5410 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
5411 - ewarn "The dependency data could not be migrated to /run/openrc."
5412 - ewarn "This means you need to reboot your system."
5413 - fi
5414 - fi
5415 -
5416 - # update the dependency tree after touching all files #224171
5417 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
5418 -
5419 - if ! use newnet && ! use netifrc; then
5420 - ewarn "You have emerged OpenRc without network support. This"
5421 - ewarn "means you need to SET UP a network manager such as"
5422 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
5423 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
5424 - ewarn "Or, you have the option of emerging openrc with the newnet"
5425 - ewarn "use flag and configuring /etc/conf.d/network and"
5426 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
5427 - ewarn
5428 - fi
5429 -
5430 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
5431 - ewarn "Please add the network service to your boot runlevel"
5432 - ewarn "as soon as possible. Not doing so could leave you with a system"
5433 - ewarn "without networking."
5434 - ewarn
5435 - fi
5436 -}
5437
5438 diff --git a/sys-apps/openrc/openrc-0.34.8.ebuild b/sys-apps/openrc/openrc-0.34.8.ebuild
5439 deleted file mode 100644
5440 index 7c2ce709177..00000000000
5441 --- a/sys-apps/openrc/openrc-0.34.8.ebuild
5442 +++ /dev/null
5443 @@ -1,329 +0,0 @@
5444 -# Copyright 1999-2017 Gentoo Foundation
5445 -# Distributed under the terms of the GNU General Public License v2
5446 -
5447 -EAPI=6
5448 -
5449 -inherit flag-o-matic pam toolchain-funcs
5450 -
5451 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
5452 -HOMEPAGE="https://github.com/openrc/openrc/"
5453 -
5454 -if [[ ${PV} == "9999" ]]; then
5455 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
5456 - inherit git-r3
5457 -else
5458 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
5459 - KEYWORDS="alpha amd64 ~arm ~arm64 ~hppa ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
5460 -fi
5461 -
5462 -LICENSE="BSD-2"
5463 -SLOT="0"
5464 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
5465 - unicode kernel_linux kernel_FreeBSD"
5466 -
5467 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
5468 - ncurses? ( sys-libs/ncurses:0= )
5469 - pam? (
5470 - sys-auth/pambase
5471 - virtual/pam
5472 - )
5473 - audit? ( sys-process/audit )
5474 - kernel_linux? (
5475 - sys-process/psmisc
5476 - !<sys-process/procps-3.3.9-r2
5477 - )
5478 - selinux? (
5479 - sys-apps/policycoreutils
5480 - >=sys-libs/libselinux-2.6
5481 - )
5482 - !<sys-apps/baselayout-2.1-r1
5483 - !<sys-fs/udev-init-scripts-27"
5484 -DEPEND="${COMMON_DEPEND}
5485 - virtual/os-headers
5486 - ncurses? ( virtual/pkgconfig )"
5487 -RDEPEND="${COMMON_DEPEND}
5488 - !prefix? (
5489 - kernel_linux? (
5490 - >=sys-apps/sysvinit-2.86-r6[selinux?]
5491 - virtual/tmpfiles
5492 - )
5493 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
5494 - )
5495 - selinux? (
5496 - >=sec-policy/selinux-base-policy-2.20170204-r4
5497 - >=sec-policy/selinux-openrc-2.20170204-r4
5498 - )
5499 -"
5500 -
5501 -PDEPEND="netifrc? ( net-misc/netifrc )"
5502 -
5503 -src_prepare() {
5504 - default
5505 -
5506 - sed -i 's:0444:0644:' mk/sys.mk || die
5507 -
5508 - if [[ ${PV} == "9999" ]] ; then
5509 - local ver="git-${EGIT_VERSION:0:6}"
5510 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
5511 - fi
5512 -}
5513 -
5514 -src_compile() {
5515 - unset LIBDIR #266688
5516 -
5517 - MAKE_ARGS="${MAKE_ARGS}
5518 - LIBNAME=$(get_libdir)
5519 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
5520 - MKNET=$(usex newnet)
5521 - MKSELINUX=$(usex selinux)
5522 - MKAUDIT=$(usex audit)
5523 - MKPAM=$(usev pam)
5524 - MKSTATICLIBS=$(usex static-libs)"
5525 -
5526 - local brand="Unknown"
5527 - if use kernel_linux ; then
5528 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
5529 - brand="Linux"
5530 - elif use kernel_FreeBSD ; then
5531 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
5532 - brand="FreeBSD"
5533 - fi
5534 - export BRANDING="Gentoo ${brand}"
5535 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
5536 - export DEBUG=$(usev debug)
5537 - export MKTERMCAP=$(usev ncurses)
5538 -
5539 - tc-export CC AR RANLIB
5540 - emake ${MAKE_ARGS}
5541 -}
5542 -
5543 -# set_config <file> <option name> <yes value> <no value> test
5544 -# a value of "#" will just comment out the option
5545 -set_config() {
5546 - local file="${ED}/$1" var=$2 val com
5547 - eval "${@:5}" && val=$3 || val=$4
5548 - [[ ${val} == "#" ]] && com="#" && val='\2'
5549 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
5550 -}
5551 -
5552 -set_config_yes_no() {
5553 - set_config "$1" "$2" YES NO "${@:3}"
5554 -}
5555 -
5556 -src_install() {
5557 - emake ${MAKE_ARGS} DESTDIR="${D}" install
5558 -
5559 - # move the shared libs back to /usr so ldscript can install
5560 - # more of a minimal set of files
5561 - # disabled for now due to #270646
5562 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
5563 - #gen_usr_ldscript -a einfo rc
5564 - gen_usr_ldscript libeinfo.so
5565 - gen_usr_ldscript librc.so
5566 -
5567 - if ! use kernel_linux; then
5568 - keepdir /$(get_libdir)/rc/init.d
5569 - fi
5570 - keepdir /$(get_libdir)/rc/tmp
5571 -
5572 - # Backup our default runlevels
5573 - dodir /usr/share/"${PN}"
5574 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
5575 - rm -rf "${ED}"/etc/runlevels
5576 -
5577 - # Setup unicode defaults for silly unicode users
5578 - set_config_yes_no /etc/rc.conf unicode use unicode
5579 -
5580 - # Cater to the norm
5581 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
5582 -
5583 - # On HPPA, do not run consolefont by default (bug #222889)
5584 - if use hppa; then
5585 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
5586 - fi
5587 -
5588 - # Support for logfile rotation
5589 - insinto /etc/logrotate.d
5590 - newins "${FILESDIR}"/openrc.logrotate openrc
5591 -
5592 - # install gentoo pam.d files
5593 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
5594 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
5595 -
5596 - # install documentation
5597 - dodoc ChangeLog *.md
5598 - if use newnet; then
5599 - dodoc README.newnet
5600 - fi
5601 -}
5602 -
5603 -add_boot_init() {
5604 - local initd=$1
5605 - local runlevel=${2:-boot}
5606 - # if the initscript is not going to be installed and is not
5607 - # currently installed, return
5608 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
5609 - || return
5610 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
5611 -
5612 - # if runlevels dont exist just yet, then create it but still flag
5613 - # to pkg_postinst that it needs real setup #277323
5614 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
5615 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
5616 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
5617 - fi
5618 -
5619 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
5620 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
5621 -}
5622 -add_boot_init_mit_config() {
5623 - local config=$1 initd=$2
5624 - if [[ -e ${EROOT}${config} ]] ; then
5625 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
5626 - add_boot_init ${initd}
5627 - fi
5628 - fi
5629 -}
5630 -
5631 -pkg_preinst() {
5632 - local f LIBDIR=$(get_libdir)
5633 -
5634 - # avoid default thrashing in conf.d files when possible #295406
5635 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
5636 - (
5637 - unset hostname HOSTNAME
5638 - source "${EROOT}"etc/conf.d/hostname
5639 - : ${hostname:=${HOSTNAME}}
5640 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
5641 - )
5642 - fi
5643 -
5644 - # set default interactive shell to sulogin if it exists
5645 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
5646 -
5647 - # termencoding was added in 0.2.1 and needed in boot
5648 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
5649 -
5650 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
5651 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
5652 -
5653 - if ! has_version ">=sys-apps/openrc-0.11"; then
5654 - add_boot_init sysfs sysinit
5655 - fi
5656 -
5657 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
5658 - migrate_udev_mount_script
5659 - add_boot_init tmpfiles.setup boot
5660 - fi
5661 -
5662 - # these were added in 0.12.
5663 - if ! has_version ">=sys-apps/openrc-0.12"; then
5664 - add_boot_init loopback
5665 - add_boot_init tmpfiles.dev sysinit
5666 -
5667 - # ensure existing /etc/conf.d/net is not removed
5668 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
5669 - # this needs to stay in openrc ebuilds for a long time. :(
5670 - # Added in 0.12.
5671 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
5672 - einfo "Modifying conf.d/net to keep it from being removed"
5673 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
5674 -
5675 -# The network scripts are now part of net-misc/netifrc
5676 -# In order to avoid sys-apps/${P} from removing this file, this comment was
5677 -# added; you can safely remove this comment. Please see
5678 -# /usr/share/doc/netifrc*/README* for more information.
5679 -EOF
5680 - fi
5681 - fi
5682 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
5683 -
5684 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
5685 - add_boot_init mtab
5686 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
5687 - ewarn "${EROOT}etc/mtab will be replaced with a"
5688 - ewarn "symbolic link to /proc/self/mounts on the next"
5689 - ewarn "reboot."
5690 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
5691 - ewarn "if you do not want this to happen."
5692 - fi
5693 - fi
5694 -}
5695 -
5696 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
5697 -migrate_udev_mount_script() {
5698 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
5699 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
5700 - add_boot_init udev-mount sysinit
5701 - fi
5702 - return 0
5703 -}
5704 -
5705 -pkg_postinst() {
5706 - local LIBDIR=$(get_libdir)
5707 -
5708 - # Make our runlevels if they don't exist
5709 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
5710 - einfo "Copying across default runlevels"
5711 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
5712 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
5713 - else
5714 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
5715 - mkdir -p "${EROOT}"etc/runlevels/sysinit
5716 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
5717 - "${EROOT}"etc/runlevels/sysinit
5718 - fi
5719 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
5720 - mkdir -p "${EROOT}"etc/runlevels/shutdown
5721 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
5722 - "${EROOT}"etc/runlevels/shutdown
5723 - fi
5724 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
5725 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
5726 - "${EROOT}"etc/runlevels
5727 - fi
5728 - fi
5729 -
5730 - if use hppa; then
5731 - elog "Setting the console font does not work on all HPPA consoles."
5732 - elog "You can still enable it by running:"
5733 - elog "# rc-update add consolefont boot"
5734 - fi
5735 -
5736 - # Handle the conf.d/local.{start,stop} -> local.d transition
5737 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
5738 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
5739 - elog "files to ${EROOT}etc/local.d"
5740 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
5741 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
5742 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
5743 - fi
5744 -
5745 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
5746 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
5747 - ewarn "The dependency data could not be migrated to /run/openrc."
5748 - ewarn "This means you need to reboot your system."
5749 - fi
5750 - fi
5751 -
5752 - # update the dependency tree after touching all files #224171
5753 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
5754 -
5755 - if ! use newnet && ! use netifrc; then
5756 - ewarn "You have emerged OpenRc without network support. This"
5757 - ewarn "means you need to SET UP a network manager such as"
5758 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
5759 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
5760 - ewarn "Or, you have the option of emerging openrc with the newnet"
5761 - ewarn "use flag and configuring /etc/conf.d/network and"
5762 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
5763 - ewarn
5764 - fi
5765 -
5766 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
5767 - ewarn "Please add the network service to your boot runlevel"
5768 - ewarn "as soon as possible. Not doing so could leave you with a system"
5769 - ewarn "without networking."
5770 - ewarn
5771 - fi
5772 -}
5773
5774 diff --git a/sys-apps/openrc/openrc-0.34.9.ebuild b/sys-apps/openrc/openrc-0.34.9.ebuild
5775 deleted file mode 100644
5776 index f54f45f0fd3..00000000000
5777 --- a/sys-apps/openrc/openrc-0.34.9.ebuild
5778 +++ /dev/null
5779 @@ -1,329 +0,0 @@
5780 -# Copyright 1999-2017 Gentoo Foundation
5781 -# Distributed under the terms of the GNU General Public License v2
5782 -
5783 -EAPI=6
5784 -
5785 -inherit flag-o-matic pam toolchain-funcs
5786 -
5787 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
5788 -HOMEPAGE="https://github.com/openrc/openrc/"
5789 -
5790 -if [[ ${PV} == "9999" ]]; then
5791 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
5792 - inherit git-r3
5793 -else
5794 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
5795 - KEYWORDS="alpha amd64 ~arm ~arm64 hppa ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
5796 -fi
5797 -
5798 -LICENSE="BSD-2"
5799 -SLOT="0"
5800 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
5801 - unicode kernel_linux kernel_FreeBSD"
5802 -
5803 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
5804 - ncurses? ( sys-libs/ncurses:0= )
5805 - pam? (
5806 - sys-auth/pambase
5807 - virtual/pam
5808 - )
5809 - audit? ( sys-process/audit )
5810 - kernel_linux? (
5811 - sys-process/psmisc
5812 - !<sys-process/procps-3.3.9-r2
5813 - )
5814 - selinux? (
5815 - sys-apps/policycoreutils
5816 - >=sys-libs/libselinux-2.6
5817 - )
5818 - !<sys-apps/baselayout-2.1-r1
5819 - !<sys-fs/udev-init-scripts-27"
5820 -DEPEND="${COMMON_DEPEND}
5821 - virtual/os-headers
5822 - ncurses? ( virtual/pkgconfig )"
5823 -RDEPEND="${COMMON_DEPEND}
5824 - !prefix? (
5825 - kernel_linux? (
5826 - >=sys-apps/sysvinit-2.86-r6[selinux?]
5827 - virtual/tmpfiles
5828 - )
5829 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
5830 - )
5831 - selinux? (
5832 - >=sec-policy/selinux-base-policy-2.20170204-r4
5833 - >=sec-policy/selinux-openrc-2.20170204-r4
5834 - )
5835 -"
5836 -
5837 -PDEPEND="netifrc? ( net-misc/netifrc )"
5838 -
5839 -src_prepare() {
5840 - default
5841 -
5842 - sed -i 's:0444:0644:' mk/sys.mk || die
5843 -
5844 - if [[ ${PV} == "9999" ]] ; then
5845 - local ver="git-${EGIT_VERSION:0:6}"
5846 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
5847 - fi
5848 -}
5849 -
5850 -src_compile() {
5851 - unset LIBDIR #266688
5852 -
5853 - MAKE_ARGS="${MAKE_ARGS}
5854 - LIBNAME=$(get_libdir)
5855 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
5856 - MKNET=$(usex newnet)
5857 - MKSELINUX=$(usex selinux)
5858 - MKAUDIT=$(usex audit)
5859 - MKPAM=$(usev pam)
5860 - MKSTATICLIBS=$(usex static-libs)"
5861 -
5862 - local brand="Unknown"
5863 - if use kernel_linux ; then
5864 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
5865 - brand="Linux"
5866 - elif use kernel_FreeBSD ; then
5867 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
5868 - brand="FreeBSD"
5869 - fi
5870 - export BRANDING="Gentoo ${brand}"
5871 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
5872 - export DEBUG=$(usev debug)
5873 - export MKTERMCAP=$(usev ncurses)
5874 -
5875 - tc-export CC AR RANLIB
5876 - emake ${MAKE_ARGS}
5877 -}
5878 -
5879 -# set_config <file> <option name> <yes value> <no value> test
5880 -# a value of "#" will just comment out the option
5881 -set_config() {
5882 - local file="${ED}/$1" var=$2 val com
5883 - eval "${@:5}" && val=$3 || val=$4
5884 - [[ ${val} == "#" ]] && com="#" && val='\2'
5885 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
5886 -}
5887 -
5888 -set_config_yes_no() {
5889 - set_config "$1" "$2" YES NO "${@:3}"
5890 -}
5891 -
5892 -src_install() {
5893 - emake ${MAKE_ARGS} DESTDIR="${D}" install
5894 -
5895 - # move the shared libs back to /usr so ldscript can install
5896 - # more of a minimal set of files
5897 - # disabled for now due to #270646
5898 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
5899 - #gen_usr_ldscript -a einfo rc
5900 - gen_usr_ldscript libeinfo.so
5901 - gen_usr_ldscript librc.so
5902 -
5903 - if ! use kernel_linux; then
5904 - keepdir /$(get_libdir)/rc/init.d
5905 - fi
5906 - keepdir /$(get_libdir)/rc/tmp
5907 -
5908 - # Backup our default runlevels
5909 - dodir /usr/share/"${PN}"
5910 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
5911 - rm -rf "${ED}"/etc/runlevels
5912 -
5913 - # Setup unicode defaults for silly unicode users
5914 - set_config_yes_no /etc/rc.conf unicode use unicode
5915 -
5916 - # Cater to the norm
5917 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
5918 -
5919 - # On HPPA, do not run consolefont by default (bug #222889)
5920 - if use hppa; then
5921 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
5922 - fi
5923 -
5924 - # Support for logfile rotation
5925 - insinto /etc/logrotate.d
5926 - newins "${FILESDIR}"/openrc.logrotate openrc
5927 -
5928 - # install gentoo pam.d files
5929 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
5930 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
5931 -
5932 - # install documentation
5933 - dodoc ChangeLog *.md
5934 - if use newnet; then
5935 - dodoc README.newnet
5936 - fi
5937 -}
5938 -
5939 -add_boot_init() {
5940 - local initd=$1
5941 - local runlevel=${2:-boot}
5942 - # if the initscript is not going to be installed and is not
5943 - # currently installed, return
5944 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
5945 - || return
5946 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
5947 -
5948 - # if runlevels dont exist just yet, then create it but still flag
5949 - # to pkg_postinst that it needs real setup #277323
5950 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
5951 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
5952 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
5953 - fi
5954 -
5955 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
5956 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
5957 -}
5958 -add_boot_init_mit_config() {
5959 - local config=$1 initd=$2
5960 - if [[ -e ${EROOT}${config} ]] ; then
5961 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
5962 - add_boot_init ${initd}
5963 - fi
5964 - fi
5965 -}
5966 -
5967 -pkg_preinst() {
5968 - local f LIBDIR=$(get_libdir)
5969 -
5970 - # avoid default thrashing in conf.d files when possible #295406
5971 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
5972 - (
5973 - unset hostname HOSTNAME
5974 - source "${EROOT}"etc/conf.d/hostname
5975 - : ${hostname:=${HOSTNAME}}
5976 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
5977 - )
5978 - fi
5979 -
5980 - # set default interactive shell to sulogin if it exists
5981 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
5982 -
5983 - # termencoding was added in 0.2.1 and needed in boot
5984 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
5985 -
5986 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
5987 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
5988 -
5989 - if ! has_version ">=sys-apps/openrc-0.11"; then
5990 - add_boot_init sysfs sysinit
5991 - fi
5992 -
5993 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
5994 - migrate_udev_mount_script
5995 - add_boot_init tmpfiles.setup boot
5996 - fi
5997 -
5998 - # these were added in 0.12.
5999 - if ! has_version ">=sys-apps/openrc-0.12"; then
6000 - add_boot_init loopback
6001 - add_boot_init tmpfiles.dev sysinit
6002 -
6003 - # ensure existing /etc/conf.d/net is not removed
6004 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
6005 - # this needs to stay in openrc ebuilds for a long time. :(
6006 - # Added in 0.12.
6007 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
6008 - einfo "Modifying conf.d/net to keep it from being removed"
6009 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
6010 -
6011 -# The network scripts are now part of net-misc/netifrc
6012 -# In order to avoid sys-apps/${P} from removing this file, this comment was
6013 -# added; you can safely remove this comment. Please see
6014 -# /usr/share/doc/netifrc*/README* for more information.
6015 -EOF
6016 - fi
6017 - fi
6018 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
6019 -
6020 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
6021 - add_boot_init mtab
6022 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
6023 - ewarn "${EROOT}etc/mtab will be replaced with a"
6024 - ewarn "symbolic link to /proc/self/mounts on the next"
6025 - ewarn "reboot."
6026 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
6027 - ewarn "if you do not want this to happen."
6028 - fi
6029 - fi
6030 -}
6031 -
6032 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
6033 -migrate_udev_mount_script() {
6034 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
6035 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
6036 - add_boot_init udev-mount sysinit
6037 - fi
6038 - return 0
6039 -}
6040 -
6041 -pkg_postinst() {
6042 - local LIBDIR=$(get_libdir)
6043 -
6044 - # Make our runlevels if they don't exist
6045 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
6046 - einfo "Copying across default runlevels"
6047 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
6048 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
6049 - else
6050 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
6051 - mkdir -p "${EROOT}"etc/runlevels/sysinit
6052 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
6053 - "${EROOT}"etc/runlevels/sysinit
6054 - fi
6055 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
6056 - mkdir -p "${EROOT}"etc/runlevels/shutdown
6057 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
6058 - "${EROOT}"etc/runlevels/shutdown
6059 - fi
6060 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
6061 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
6062 - "${EROOT}"etc/runlevels
6063 - fi
6064 - fi
6065 -
6066 - if use hppa; then
6067 - elog "Setting the console font does not work on all HPPA consoles."
6068 - elog "You can still enable it by running:"
6069 - elog "# rc-update add consolefont boot"
6070 - fi
6071 -
6072 - # Handle the conf.d/local.{start,stop} -> local.d transition
6073 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
6074 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
6075 - elog "files to ${EROOT}etc/local.d"
6076 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
6077 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
6078 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
6079 - fi
6080 -
6081 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
6082 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
6083 - ewarn "The dependency data could not be migrated to /run/openrc."
6084 - ewarn "This means you need to reboot your system."
6085 - fi
6086 - fi
6087 -
6088 - # update the dependency tree after touching all files #224171
6089 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
6090 -
6091 - if ! use newnet && ! use netifrc; then
6092 - ewarn "You have emerged OpenRc without network support. This"
6093 - ewarn "means you need to SET UP a network manager such as"
6094 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
6095 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
6096 - ewarn "Or, you have the option of emerging openrc with the newnet"
6097 - ewarn "use flag and configuring /etc/conf.d/network and"
6098 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
6099 - ewarn
6100 - fi
6101 -
6102 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
6103 - ewarn "Please add the network service to your boot runlevel"
6104 - ewarn "as soon as possible. Not doing so could leave you with a system"
6105 - ewarn "without networking."
6106 - ewarn
6107 - fi
6108 -}
6109
6110 diff --git a/sys-apps/openrc/openrc-0.34.ebuild b/sys-apps/openrc/openrc-0.34.ebuild
6111 deleted file mode 100644
6112 index 15376774cd7..00000000000
6113 --- a/sys-apps/openrc/openrc-0.34.ebuild
6114 +++ /dev/null
6115 @@ -1,329 +0,0 @@
6116 -# Copyright 1999-2017 Gentoo Foundation
6117 -# Distributed under the terms of the GNU General Public License v2
6118 -
6119 -EAPI=6
6120 -
6121 -inherit flag-o-matic pam toolchain-funcs
6122 -
6123 -DESCRIPTION="OpenRC manages the services, startup and shutdown of a host"
6124 -HOMEPAGE="https://github.com/openrc/openrc/"
6125 -
6126 -if [[ ${PV} == "9999" ]]; then
6127 - EGIT_REPO_URI="https://github.com/OpenRC/${PN}.git"
6128 - inherit git-r3
6129 -else
6130 - SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
6131 - KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd"
6132 -fi
6133 -
6134 -LICENSE="BSD-2"
6135 -SLOT="0"
6136 -IUSE="audit debug ncurses pam newnet prefix +netifrc selinux static-libs
6137 - unicode kernel_linux kernel_FreeBSD"
6138 -
6139 -COMMON_DEPEND="kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) )
6140 - ncurses? ( sys-libs/ncurses:0= )
6141 - pam? (
6142 - sys-auth/pambase
6143 - virtual/pam
6144 - )
6145 - audit? ( sys-process/audit )
6146 - kernel_linux? (
6147 - sys-process/psmisc
6148 - !<sys-process/procps-3.3.9-r2
6149 - )
6150 - selinux? (
6151 - sys-apps/policycoreutils
6152 - >=sys-libs/libselinux-2.6
6153 - )
6154 - !<sys-apps/baselayout-2.1-r1
6155 - !<sys-fs/udev-init-scripts-27"
6156 -DEPEND="${COMMON_DEPEND}
6157 - virtual/os-headers
6158 - ncurses? ( virtual/pkgconfig )"
6159 -RDEPEND="${COMMON_DEPEND}
6160 - !prefix? (
6161 - kernel_linux? (
6162 - >=sys-apps/sysvinit-2.86-r6[selinux?]
6163 - virtual/tmpfiles
6164 - )
6165 - kernel_FreeBSD? ( sys-freebsd/freebsd-sbin )
6166 - )
6167 - selinux? (
6168 - >=sec-policy/selinux-base-policy-2.20170204-r4
6169 - >=sec-policy/selinux-openrc-2.20170204-r4
6170 - )
6171 -"
6172 -
6173 -PDEPEND="netifrc? ( net-misc/netifrc )"
6174 -
6175 -src_prepare() {
6176 - default
6177 -
6178 - sed -i 's:0444:0644:' mk/sys.mk || die
6179 -
6180 - if [[ ${PV} == "9999" ]] ; then
6181 - local ver="git-${EGIT_VERSION:0:6}"
6182 - sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/gitver.mk || die
6183 - fi
6184 -}
6185 -
6186 -src_compile() {
6187 - unset LIBDIR #266688
6188 -
6189 - MAKE_ARGS="${MAKE_ARGS}
6190 - LIBNAME=$(get_libdir)
6191 - LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc
6192 - MKNET=$(usex newnet)
6193 - MKSELINUX=$(usex selinux)
6194 - MKAUDIT=$(usex audit)
6195 - MKPAM=$(usev pam)
6196 - MKSTATICLIBS=$(usex static-libs)"
6197 -
6198 - local brand="Unknown"
6199 - if use kernel_linux ; then
6200 - MAKE_ARGS="${MAKE_ARGS} OS=Linux"
6201 - brand="Linux"
6202 - elif use kernel_FreeBSD ; then
6203 - MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD"
6204 - brand="FreeBSD"
6205 - fi
6206 - export BRANDING="Gentoo ${brand}"
6207 - use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}"
6208 - export DEBUG=$(usev debug)
6209 - export MKTERMCAP=$(usev ncurses)
6210 -
6211 - tc-export CC AR RANLIB
6212 - emake ${MAKE_ARGS}
6213 -}
6214 -
6215 -# set_config <file> <option name> <yes value> <no value> test
6216 -# a value of "#" will just comment out the option
6217 -set_config() {
6218 - local file="${ED}/$1" var=$2 val com
6219 - eval "${@:5}" && val=$3 || val=$4
6220 - [[ ${val} == "#" ]] && com="#" && val='\2'
6221 - sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}"
6222 -}
6223 -
6224 -set_config_yes_no() {
6225 - set_config "$1" "$2" YES NO "${@:3}"
6226 -}
6227 -
6228 -src_install() {
6229 - emake ${MAKE_ARGS} DESTDIR="${D}" install
6230 -
6231 - # move the shared libs back to /usr so ldscript can install
6232 - # more of a minimal set of files
6233 - # disabled for now due to #270646
6234 - #mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die
6235 - #gen_usr_ldscript -a einfo rc
6236 - gen_usr_ldscript libeinfo.so
6237 - gen_usr_ldscript librc.so
6238 -
6239 - if ! use kernel_linux; then
6240 - keepdir /$(get_libdir)/rc/init.d
6241 - fi
6242 - keepdir /$(get_libdir)/rc/tmp
6243 -
6244 - # Backup our default runlevels
6245 - dodir /usr/share/"${PN}"
6246 - cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die
6247 - rm -rf "${ED}"/etc/runlevels
6248 -
6249 - # Setup unicode defaults for silly unicode users
6250 - set_config_yes_no /etc/rc.conf unicode use unicode
6251 -
6252 - # Cater to the norm
6253 - set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')'
6254 -
6255 - # On HPPA, do not run consolefont by default (bug #222889)
6256 - if use hppa; then
6257 - rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont
6258 - fi
6259 -
6260 - # Support for logfile rotation
6261 - insinto /etc/logrotate.d
6262 - newins "${FILESDIR}"/openrc.logrotate openrc
6263 -
6264 - # install gentoo pam.d files
6265 - newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon
6266 - newpamd "${FILESDIR}"/start-stop-daemon.pam supervise-daemon
6267 -
6268 - # install documentation
6269 - dodoc ChangeLog *.md
6270 - if use newnet; then
6271 - dodoc README.newnet
6272 - fi
6273 -}
6274 -
6275 -add_boot_init() {
6276 - local initd=$1
6277 - local runlevel=${2:-boot}
6278 - # if the initscript is not going to be installed and is not
6279 - # currently installed, return
6280 - [[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \
6281 - || return
6282 - [[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return
6283 -
6284 - # if runlevels dont exist just yet, then create it but still flag
6285 - # to pkg_postinst that it needs real setup #277323
6286 - if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then
6287 - mkdir -p "${EROOT}"etc/runlevels/${runlevel}
6288 - touch "${EROOT}"etc/runlevels/.add_boot_init.created
6289 - fi
6290 -
6291 - elog "Auto-adding '${initd}' service to your ${runlevel} runlevel"
6292 - ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd}
6293 -}
6294 -add_boot_init_mit_config() {
6295 - local config=$1 initd=$2
6296 - if [[ -e ${EROOT}${config} ]] ; then
6297 - if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then
6298 - add_boot_init ${initd}
6299 - fi
6300 - fi
6301 -}
6302 -
6303 -pkg_preinst() {
6304 - local f LIBDIR=$(get_libdir)
6305 -
6306 - # avoid default thrashing in conf.d files when possible #295406
6307 - if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then
6308 - (
6309 - unset hostname HOSTNAME
6310 - source "${EROOT}"etc/conf.d/hostname
6311 - : ${hostname:=${HOSTNAME}}
6312 - [[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}"
6313 - )
6314 - fi
6315 -
6316 - # set default interactive shell to sulogin if it exists
6317 - set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin
6318 -
6319 - # termencoding was added in 0.2.1 and needed in boot
6320 - has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding
6321 -
6322 - # swapfiles was added in 0.9.9 and needed in boot (february 2012)
6323 - has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles
6324 -
6325 - if ! has_version ">=sys-apps/openrc-0.11"; then
6326 - add_boot_init sysfs sysinit
6327 - fi
6328 -
6329 - if ! has_version ">=sys-apps/openrc-0.11.3" ; then
6330 - migrate_udev_mount_script
6331 - add_boot_init tmpfiles.setup boot
6332 - fi
6333 -
6334 - # these were added in 0.12.
6335 - if ! has_version ">=sys-apps/openrc-0.12"; then
6336 - add_boot_init loopback
6337 - add_boot_init tmpfiles.dev sysinit
6338 -
6339 - # ensure existing /etc/conf.d/net is not removed
6340 - # undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier
6341 - # this needs to stay in openrc ebuilds for a long time. :(
6342 - # Added in 0.12.
6343 - if [[ -f "${EROOT}"etc/conf.d/net ]]; then
6344 - einfo "Modifying conf.d/net to keep it from being removed"
6345 - cat <<-EOF >>"${EROOT}"etc/conf.d/net
6346 -
6347 -# The network scripts are now part of net-misc/netifrc
6348 -# In order to avoid sys-apps/${P} from removing this file, this comment was
6349 -# added; you can safely remove this comment. Please see
6350 -# /usr/share/doc/netifrc*/README* for more information.
6351 -EOF
6352 - fi
6353 - fi
6354 - has_version ">=sys-apps/openrc-0.14" || add_boot_init binfmt
6355 -
6356 - if ! has_version ">=sys-apps/openrc-0.18.3"; then
6357 - add_boot_init mtab
6358 - if [[ -f "${EROOT}"etc/mtab ]] && [[ ! -L "${EROOT}"etc/mtab ]]; then
6359 - ewarn "${EROOT}etc/mtab will be replaced with a"
6360 - ewarn "symbolic link to /proc/self/mounts on the next"
6361 - ewarn "reboot."
6362 - ewarn "Change the setting in ${EROOT}etc/conf.d/mtab"
6363 - ewarn "if you do not want this to happen."
6364 - fi
6365 - fi
6366 -}
6367 -
6368 -# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev.
6369 -migrate_udev_mount_script() {
6370 - if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \
6371 - ! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then
6372 - add_boot_init udev-mount sysinit
6373 - fi
6374 - return 0
6375 -}
6376 -
6377 -pkg_postinst() {
6378 - local LIBDIR=$(get_libdir)
6379 -
6380 - # Make our runlevels if they don't exist
6381 - if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then
6382 - einfo "Copying across default runlevels"
6383 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc
6384 - rm -f "${EROOT}"etc/runlevels/.add_boot_init.created
6385 - else
6386 - if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then
6387 - mkdir -p "${EROOT}"etc/runlevels/sysinit
6388 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \
6389 - "${EROOT}"etc/runlevels/sysinit
6390 - fi
6391 - if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then
6392 - mkdir -p "${EROOT}"etc/runlevels/shutdown
6393 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \
6394 - "${EROOT}"etc/runlevels/shutdown
6395 - fi
6396 - if [[ ! -e "${EROOT}"etc/runlevels/nonetwork/local ]]; then
6397 - cp -RPp "${EROOT}"usr/share/${PN}/runlevels/nonetwork \
6398 - "${EROOT}"etc/runlevels
6399 - fi
6400 - fi
6401 -
6402 - if use hppa; then
6403 - elog "Setting the console font does not work on all HPPA consoles."
6404 - elog "You can still enable it by running:"
6405 - elog "# rc-update add consolefont boot"
6406 - fi
6407 -
6408 - # Handle the conf.d/local.{start,stop} -> local.d transition
6409 - if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then
6410 - elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}"
6411 - elog "files to ${EROOT}etc/local.d"
6412 - mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start
6413 - mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop
6414 - chmod +x "${EROOT}"etc/local.d/*{start,stop}
6415 - fi
6416 -
6417 - if use kernel_linux && [[ "${EROOT}" = "/" ]]; then
6418 - if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then
6419 - ewarn "The dependency data could not be migrated to /run/openrc."
6420 - ewarn "This means you need to reboot your system."
6421 - fi
6422 - fi
6423 -
6424 - # update the dependency tree after touching all files #224171
6425 - [[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u
6426 -
6427 - if ! use newnet && ! use netifrc; then
6428 - ewarn "You have emerged OpenRc without network support. This"
6429 - ewarn "means you need to SET UP a network manager such as"
6430 - ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd,"
6431 - ewarn "net-misc/NetworkManager, or net-vpn/badvpn."
6432 - ewarn "Or, you have the option of emerging openrc with the newnet"
6433 - ewarn "use flag and configuring /etc/conf.d/network and"
6434 - ewarn "/etc/conf.d/staticroute if you only use static interfaces."
6435 - ewarn
6436 - fi
6437 -
6438 - if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then
6439 - ewarn "Please add the network service to your boot runlevel"
6440 - ewarn "as soon as possible. Not doing so could leave you with a system"
6441 - ewarn "without networking."
6442 - ewarn
6443 - fi
6444 -}