1 |
williamh 13/10/31 02:02:22 |
2 |
|
3 |
Modified: ChangeLog |
4 |
Added: openrc-0.12.4.ebuild |
5 |
Log: |
6 |
version bump for vserver fixes and starting a port to GNU/kFreeBSD for Debian. |
7 |
|
8 |
(Portage version: 2.2.1/cvs/Linux i686, signed Manifest commit with key 0x30C46538) |
9 |
|
10 |
Revision Changes Path |
11 |
1.286 sys-apps/openrc/ChangeLog |
12 |
|
13 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-apps/openrc/ChangeLog?rev=1.286&view=markup |
14 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-apps/openrc/ChangeLog?rev=1.286&content-type=text/plain |
15 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-apps/openrc/ChangeLog?r1=1.285&r2=1.286 |
16 |
|
17 |
Index: ChangeLog |
18 |
=================================================================== |
19 |
RCS file: /var/cvsroot/gentoo-x86/sys-apps/openrc/ChangeLog,v |
20 |
retrieving revision 1.285 |
21 |
retrieving revision 1.286 |
22 |
diff -u -r1.285 -r1.286 |
23 |
--- ChangeLog 21 Oct 2013 19:03:34 -0000 1.285 |
24 |
+++ ChangeLog 31 Oct 2013 02:02:22 -0000 1.286 |
25 |
@@ -1,6 +1,11 @@ |
26 |
# ChangeLog for sys-apps/openrc |
27 |
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 |
28 |
-# $Header: /var/cvsroot/gentoo-x86/sys-apps/openrc/ChangeLog,v 1.285 2013/10/21 19:03:34 williamh Exp $ |
29 |
+# $Header: /var/cvsroot/gentoo-x86/sys-apps/openrc/ChangeLog,v 1.286 2013/10/31 02:02:22 williamh Exp $ |
30 |
+ |
31 |
+*openrc-0.12.4 (31 Oct 2013) |
32 |
+ |
33 |
+ 31 Oct 2013; William Hubbs <williamh@g.o> +openrc-0.12.4.ebuild: |
34 |
+ version bump for vserver fixes and starting a port to GNU/kFreeBSD for Debian. |
35 |
|
36 |
21 Oct 2013; William Hubbs <williamh@g.o> openrc-9999.ebuild: |
37 |
bring back gen_usr_ldscript calls for libeinfo |
38 |
|
39 |
|
40 |
|
41 |
1.1 sys-apps/openrc/openrc-0.12.4.ebuild |
42 |
|
43 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-apps/openrc/openrc-0.12.4.ebuild?rev=1.1&view=markup |
44 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-apps/openrc/openrc-0.12.4.ebuild?rev=1.1&content-type=text/plain |
45 |
|
46 |
Index: openrc-0.12.4.ebuild |
47 |
=================================================================== |
48 |
# Copyright 1999-2013 Gentoo Foundation |
49 |
# Distributed under the terms of the GNU General Public License v2 |
50 |
# $Header: /var/cvsroot/gentoo-x86/sys-apps/openrc/openrc-0.12.4.ebuild,v 1.1 2013/10/31 02:02:22 williamh Exp $ |
51 |
|
52 |
EAPI=5 |
53 |
|
54 |
inherit eutils flag-o-matic multilib pam toolchain-funcs |
55 |
|
56 |
DESCRIPTION="OpenRC manages the services, startup and shutdown of a host" |
57 |
HOMEPAGE="http://www.gentoo.org/proj/en/base/openrc/" |
58 |
|
59 |
if [[ ${PV} == "9999" ]]; then |
60 |
EGIT_REPO_URI="git://github.com/OpenRC/${PN}.git" |
61 |
inherit git-2 |
62 |
else |
63 |
SRC_URI="http://dev.gentoo.org/~williamh/dist/${P}.tar.bz2" |
64 |
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd" |
65 |
fi |
66 |
|
67 |
LICENSE="BSD-2" |
68 |
SLOT="0" |
69 |
IUSE="debug elibc_glibc ncurses pam newnet prefix +netifrc selinux static-libs |
70 |
tools unicode kernel_linux kernel_FreeBSD" |
71 |
|
72 |
COMMON_DEPEND=">=sys-apps/baselayout-2.1-r1 |
73 |
kernel_FreeBSD? ( || ( >=sys-freebsd/freebsd-ubin-9.0_rc sys-process/fuser-bsd ) ) |
74 |
elibc_glibc? ( >=sys-libs/glibc-2.5 ) |
75 |
ncurses? ( sys-libs/ncurses ) |
76 |
pam? ( sys-auth/pambase ) |
77 |
tools? ( dev-lang/perl ) |
78 |
kernel_linux? ( |
79 |
sys-process/psmisc |
80 |
) |
81 |
selinux? ( sec-policy/selinux-openrc ) |
82 |
!<sys-fs/udev-init-scripts-17 |
83 |
!<sys-fs/udev-133" |
84 |
DEPEND="${COMMON_DEPEND} |
85 |
virtual/os-headers |
86 |
ncurses? ( virtual/pkgconfig )" |
87 |
RDEPEND="${COMMON_DEPEND} |
88 |
!prefix? ( |
89 |
kernel_linux? ( || ( >=sys-apps/sysvinit-2.86-r6 sys-process/runit ) ) |
90 |
kernel_FreeBSD? ( sys-freebsd/freebsd-sbin ) |
91 |
)" |
92 |
|
93 |
PDEPEND="netifrc? ( net-misc/netifrc )" |
94 |
|
95 |
src_prepare() { |
96 |
sed -i 's:0444:0644:' mk/sys.mk || die |
97 |
|
98 |
if [[ ${PV} == "9999" ]] ; then |
99 |
local ver="git-${EGIT_VERSION:0:6}" |
100 |
sed -i "/^GITVER[[:space:]]*=/s:=.*:=${ver}:" mk/git.mk || die |
101 |
fi |
102 |
|
103 |
# Allow user patches to be applied without modifying the ebuild |
104 |
epatch_user |
105 |
} |
106 |
|
107 |
src_compile() { |
108 |
unset LIBDIR #266688 |
109 |
|
110 |
MAKE_ARGS="${MAKE_ARGS} |
111 |
LIBNAME=$(get_libdir) |
112 |
LIBEXECDIR=${EPREFIX}/$(get_libdir)/rc |
113 |
MKSELINUX=$(usex selinux) |
114 |
MKSTATICLIBS=$(usex static-libs) |
115 |
MKTOOLS=$(usex tools)" |
116 |
|
117 |
local brand="Unknown" |
118 |
if use kernel_linux ; then |
119 |
MAKE_ARGS="${MAKE_ARGS} OS=Linux" |
120 |
brand="Linux" |
121 |
elif use kernel_FreeBSD ; then |
122 |
MAKE_ARGS="${MAKE_ARGS} OS=FreeBSD" |
123 |
brand="FreeBSD" |
124 |
fi |
125 |
export BRANDING="Gentoo ${brand}" |
126 |
use newnet || MAKE_ARGS="${MAKE_ARGS} MKNET=oldnet" |
127 |
use prefix && MAKE_ARGS="${MAKE_ARGS} MKPREFIX=yes PREFIX=${EPREFIX}" |
128 |
export DEBUG=$(usev debug) |
129 |
export MKPAM=$(usev pam) |
130 |
export MKTERMCAP=$(usev ncurses) |
131 |
|
132 |
tc-export CC AR RANLIB |
133 |
emake ${MAKE_ARGS} |
134 |
} |
135 |
|
136 |
# set_config <file> <option name> <yes value> <no value> test |
137 |
# a value of "#" will just comment out the option |
138 |
set_config() { |
139 |
local file="${ED}/$1" var=$2 val com |
140 |
eval "${@:5}" && val=$3 || val=$4 |
141 |
[[ ${val} == "#" ]] && com="#" && val='\2' |
142 |
sed -i -r -e "/^#?${var}=/{s:=([\"'])?([^ ]*)\1?:=\1${val}\1:;s:^#?:${com}:}" "${file}" |
143 |
} |
144 |
|
145 |
set_config_yes_no() { |
146 |
set_config "$1" "$2" YES NO "${@:3}" |
147 |
} |
148 |
|
149 |
src_install() { |
150 |
emake ${MAKE_ARGS} DESTDIR="${D}" install |
151 |
|
152 |
# move the shared libs back to /usr so ldscript can install |
153 |
# more of a minimal set of files |
154 |
# disabled for now due to #270646 |
155 |
#mv "${ED}"/$(get_libdir)/lib{einfo,rc}* "${ED}"/usr/$(get_libdir)/ || die |
156 |
#gen_usr_ldscript -a einfo rc |
157 |
gen_usr_ldscript libeinfo.so |
158 |
gen_usr_ldscript librc.so |
159 |
|
160 |
if ! use kernel_linux; then |
161 |
keepdir /$(get_libdir)/rc/init.d |
162 |
fi |
163 |
keepdir /$(get_libdir)/rc/tmp |
164 |
|
165 |
# Backup our default runlevels |
166 |
dodir /usr/share/"${PN}" |
167 |
cp -PR "${ED}"/etc/runlevels "${ED}"/usr/share/${PN} || die |
168 |
rm -rf "${ED}"/etc/runlevels |
169 |
|
170 |
# Setup unicode defaults for silly unicode users |
171 |
set_config_yes_no /etc/rc.conf unicode use unicode |
172 |
|
173 |
# Cater to the norm |
174 |
set_config_yes_no /etc/conf.d/keymaps windowkeys '(' use x86 '||' use amd64 ')' |
175 |
|
176 |
# On HPPA, do not run consolefont by default (bug #222889) |
177 |
if use hppa; then |
178 |
rm -f "${ED}"/usr/share/openrc/runlevels/boot/consolefont |
179 |
fi |
180 |
|
181 |
# Support for logfile rotation |
182 |
insinto /etc/logrotate.d |
183 |
newins "${FILESDIR}"/openrc.logrotate openrc |
184 |
|
185 |
# install the gentoo pam.d file |
186 |
newpamd "${FILESDIR}"/start-stop-daemon.pam start-stop-daemon |
187 |
|
188 |
# install documentation |
189 |
dodoc README.busybox |
190 |
if use newnet; then |
191 |
dodoc README.newnet |
192 |
fi |
193 |
} |
194 |
|
195 |
add_boot_init() { |
196 |
local initd=$1 |
197 |
local runlevel=${2:-boot} |
198 |
# if the initscript is not going to be installed and is not |
199 |
# currently installed, return |
200 |
[[ -e "${ED}"/etc/init.d/${initd} || -e "${EROOT}"etc/init.d/${initd} ]] \ |
201 |
|| return |
202 |
[[ -e "${EROOT}"etc/runlevels/${runlevel}/${initd} ]] && return |
203 |
|
204 |
# if runlevels dont exist just yet, then create it but still flag |
205 |
# to pkg_postinst that it needs real setup #277323 |
206 |
if [[ ! -d "${EROOT}"etc/runlevels/${runlevel} ]] ; then |
207 |
mkdir -p "${EROOT}"etc/runlevels/${runlevel} |
208 |
touch "${EROOT}"etc/runlevels/.add_boot_init.created |
209 |
fi |
210 |
|
211 |
elog "Auto-adding '${initd}' service to your ${runlevel} runlevel" |
212 |
ln -snf /etc/init.d/${initd} "${EROOT}"etc/runlevels/${runlevel}/${initd} |
213 |
} |
214 |
add_boot_init_mit_config() { |
215 |
local config=$1 initd=$2 |
216 |
if [[ -e ${EROOT}${config} ]] ; then |
217 |
if [[ -n $(sed -e 's:#.*::' -e '/^[[:space:]]*$/d' "${EROOT}"${config}) ]] ; then |
218 |
add_boot_init ${initd} |
219 |
fi |
220 |
fi |
221 |
} |
222 |
|
223 |
pkg_preinst() { |
224 |
local f LIBDIR=$(get_libdir) |
225 |
|
226 |
# avoid default thrashing in conf.d files when possible #295406 |
227 |
if [[ -e "${EROOT}"etc/conf.d/hostname ]] ; then |
228 |
( |
229 |
unset hostname HOSTNAME |
230 |
source "${EROOT}"etc/conf.d/hostname |
231 |
: ${hostname:=${HOSTNAME}} |
232 |
[[ -n ${hostname} ]] && set_config /etc/conf.d/hostname hostname "${hostname}" |
233 |
) |
234 |
fi |
235 |
|
236 |
# set default interactive shell to sulogin if it exists |
237 |
set_config /etc/rc.conf rc_shell /sbin/sulogin "#" test -e /sbin/sulogin |
238 |
|
239 |
# termencoding was added in 0.2.1 and needed in boot |
240 |
has_version ">=sys-apps/openrc-0.2.1" || add_boot_init termencoding |
241 |
|
242 |
# swapfiles was added in 0.9.9 and needed in boot (february 2012) |
243 |
has_version ">=sys-apps/openrc-0.9.9" || add_boot_init swapfiles |
244 |
|
245 |
if ! has_version ">=sys-apps/openrc-0.11"; then |
246 |
add_boot_init sysfs sysinit |
247 |
fi |
248 |
|
249 |
if ! has_version ">=sys-apps/openrc-0.11.3" ; then |
250 |
migrate_udev_mount_script |
251 |
add_boot_init tmpfiles.setup boot |
252 |
fi |
253 |
|
254 |
# these were added in 0.12. |
255 |
if ! has_version ">=sys-apps/openrc-0.12"; then |
256 |
add_boot_init loopback |
257 |
add_boot_init tmpfiles.dev sysinit |
258 |
|
259 |
# ensure existing /etc/conf.d/net is not removed |
260 |
# undoes the hack to get around CONFIG_PROTECT in openrc-0.11.8 and earlier |
261 |
# this needs to stay in openrc ebuilds for a long time. :( |
262 |
# Added in 0.12. |
263 |
if [[ -f "${EROOT}"etc/conf.d/net ]]; then |
264 |
einfo "Modifying conf.d/net to keep it from being removed" |
265 |
cat <<-EOF >>"${EROOT}"etc/conf.d/net |
266 |
|
267 |
# The network scripts are now part of net-misc/netifrc |
268 |
# In order to avoid sys-apps/${P} from removing this file, this comment was |
269 |
# added; you can safely remove this comment. Please see |
270 |
# /usr/share/doc/netifrc*/README* for more information. |
271 |
EOF |
272 |
fi |
273 |
fi |
274 |
} |
275 |
|
276 |
# >=OpenRC-0.11.3 requires udev-mount to be in the sysinit runlevel with udev. |
277 |
migrate_udev_mount_script() { |
278 |
if [ -e "${EROOT}"etc/runlevels/sysinit/udev -a \ |
279 |
! -e "${EROOT}"etc/runlevels/sysinit/udev-mount ]; then |
280 |
add_boot_init udev-mount sysinit |
281 |
fi |
282 |
return 0 |
283 |
} |
284 |
|
285 |
pkg_postinst() { |
286 |
local LIBDIR=$(get_libdir) |
287 |
|
288 |
# Make our runlevels if they don't exist |
289 |
if [[ ! -e "${EROOT}"etc/runlevels ]] || [[ -e "${EROOT}"etc/runlevels/.add_boot_init.created ]] ; then |
290 |
einfo "Copying across default runlevels" |
291 |
cp -RPp "${EROOT}"usr/share/${PN}/runlevels "${EROOT}"etc |
292 |
rm -f "${EROOT}"etc/runlevels/.add_boot_init.created |
293 |
else |
294 |
if [[ ! -e "${EROOT}"etc/runlevels/sysinit/devfs ]] ; then |
295 |
mkdir -p "${EROOT}"etc/runlevels/sysinit |
296 |
cp -RPp "${EROOT}"usr/share/${PN}/runlevels/sysinit/* \ |
297 |
"${EROOT}"etc/runlevels/sysinit |
298 |
fi |
299 |
if [[ ! -e "${EROOT}"etc/runlevels/shutdown/mount-ro ]] ; then |
300 |
mkdir -p "${EROOT}"etc/runlevels/shutdown |
301 |
cp -RPp "${EROOT}"usr/share/${PN}/runlevels/shutdown/* \ |
302 |
"${EROOT}"etc/runlevels/shutdown |
303 |
fi |
304 |
fi |
305 |
|
306 |
if use hppa; then |
307 |
elog "Setting the console font does not work on all HPPA consoles." |
308 |
elog "You can still enable it by running:" |
309 |
elog "# rc-update add consolefont boot" |
310 |
fi |
311 |
|
312 |
# Handle the conf.d/local.{start,stop} -> local.d transition |
313 |
if path_exists -o "${EROOT}"etc/conf.d/local.{start,stop} ; then |
314 |
elog "Moving your ${EROOT}etc/conf.d/local.{start,stop}" |
315 |
elog "files to ${EROOT}etc/local.d" |
316 |
mv "${EROOT}"etc/conf.d/local.start "${EROOT}"etc/local.d/baselayout1.start |
317 |
mv "${EROOT}"etc/conf.d/local.stop "${EROOT}"etc/local.d/baselayout1.stop |
318 |
chmod +x "${EROOT}"etc/local.d/*{start,stop} |
319 |
fi |
320 |
|
321 |
if use kernel_linux && [[ "${EROOT}" = "/" ]]; then |
322 |
if ! /$(get_libdir)/rc/sh/migrate-to-run.sh; then |
323 |
ewarn "The dependency data could not be migrated to /run/openrc." |
324 |
ewarn "This means you need to reboot your system." |
325 |
fi |
326 |
fi |
327 |
|
328 |
# update the dependency tree after touching all files #224171 |
329 |
[[ "${EROOT}" = "/" ]] && "${EROOT}/${LIBDIR}"/rc/bin/rc-depend -u |
330 |
|
331 |
if ! use newnet && ! use netifrc; then |
332 |
ewarn "You have emerged OpenRc without network support. This" |
333 |
ewarn "means you need to SET UP a network manager such as" |
334 |
ewarn " net-misc/netifrc, net-misc/dhcpcd, net-misc/wicd," |
335 |
ewarn "net-misc/NetworkManager, or net-misc/badvpn." |
336 |
ewarn "Or, you have the option of emerging openrc with the newnet" |
337 |
ewarn "use flag and configuring /etc/conf.d/network and" |
338 |
ewarn "/etc/conf.d/staticroute if you only use static interfaces." |
339 |
fi |
340 |
|
341 |
if use newnet && [ ! -e "${EROOT}"etc/runlevels/boot/network ]; then |
342 |
ewarn "Please add the network service to your boot runlevel" |
343 |
ewarn "as soon as possible. Not doing so could leave you with a system" |
344 |
ewarn "without networking." |
345 |
fi |
346 |
|
347 |
ewarn "In this version of OpenRC, the loopback interface no longer" |
348 |
ewarn "satisfies the net virtual." |
349 |
ewarn "If you have services now which do not start because of this," |
350 |
ewarn "They can be fixed by adding rc_need=\"!net\"" |
351 |
ewarn "to the ${EROOT}etc/conf.d/<servicename> file." |
352 |
ewarn "You should also file a bug against the service asking that" |
353 |
ewarn "need net be dropped from the dependencies." |
354 |
ewarn "The bug you file should block the following tracker:" |
355 |
ewarn "https://bugs.gentoo.org/show_bug.cgi?id=439092" |
356 |
|
357 |
ewarn "This version of OpenRC doesn't enable nfs mounts automatically any" |
358 |
ewarn "longer. In order to mount nfs file systems, you must use the" |
359 |
ewarn "nfsmount service from the nfs-utils package." |
360 |
ewarn "See bug https://bugs.gentoo.org/show_bug.cgi?id=427996 for" |
361 |
ewarn "more information on this." |
362 |
|
363 |
elog "You should now update all files in /etc, using etc-update" |
364 |
elog "or equivalent before restarting any services or this host." |
365 |
} |