Remove OpenRC, unused and superseded by systemd.
This commit is contained in:
parent
f151ae9f47
commit
7bc34a91b3
10 changed files with 0 additions and 539 deletions
|
@ -1 +0,0 @@
|
||||||
OpenRC
|
|
|
@ -1,18 +0,0 @@
|
||||||
# Template file for 'OpenRC-devel'.
|
|
||||||
#
|
|
||||||
short_desc="${sourcepkg} development files"
|
|
||||||
long_desc="${long_desc}
|
|
||||||
|
|
||||||
This package contains files for development, headers, static libs, etc."
|
|
||||||
|
|
||||||
Add_dependency run glibc-devel
|
|
||||||
Add_dependency run OpenRC
|
|
||||||
|
|
||||||
do_install()
|
|
||||||
{
|
|
||||||
mkdir -p ${DESTDIR}/usr/lib ${DESTDIR}/lib ${DESTDIR}/usr/share/man
|
|
||||||
mv ${SRCPKGDESTDIR}/usr/include ${DESTDIR}/usr
|
|
||||||
mv ${SRCPKGDESTDIR}/usr/lib/lib*.*a ${DESTDIR}/usr/lib
|
|
||||||
mv ${SRCPKGDESTDIR}/usr/lib/pkgconfig ${DESTDIR}/usr/lib
|
|
||||||
mv ${SRCPKGDESTDIR}/usr/share/man/man3 ${DESTDIR}/usr/share/man
|
|
||||||
}
|
|
|
@ -1,3 +0,0 @@
|
||||||
libc.so.6
|
|
||||||
libutil.so.1
|
|
||||||
libdl.so.2
|
|
|
@ -1,5 +0,0 @@
|
||||||
/var/log/rc.log {
|
|
||||||
sharedscripts
|
|
||||||
copytruncate
|
|
||||||
missingok
|
|
||||||
}
|
|
|
@ -1,9 +0,0 @@
|
||||||
#
|
|
||||||
# Sets the system locale in /etc/profile.d/locale.sh
|
|
||||||
# through the environmental variable LANG.
|
|
||||||
#
|
|
||||||
# Please note that the init.d script by default will use the UTF8
|
|
||||||
# variant for the selected locale, so be aware that non-UTF8 locales
|
|
||||||
# won't be supported without modifications to the init.d script.
|
|
||||||
#
|
|
||||||
system_locale="en_US"
|
|
|
@ -1,28 +0,0 @@
|
||||||
#!/sbin/runscript
|
|
||||||
|
|
||||||
: ${system_locale:=en_US}
|
|
||||||
description="Sets a system locale"
|
|
||||||
|
|
||||||
depend()
|
|
||||||
{
|
|
||||||
need localmount termencoding
|
|
||||||
after bootmisc
|
|
||||||
keyword noopenvz noprefix nouml novserver noxenu
|
|
||||||
}
|
|
||||||
|
|
||||||
start()
|
|
||||||
{
|
|
||||||
: >/etc/profile.d/locale.sh
|
|
||||||
chmod 755 /etc/profile.d/locale.sh
|
|
||||||
|
|
||||||
# Check if requested locale was already created
|
|
||||||
if ! $(locale -a|grep -q "${system_locale}.utf8"); then
|
|
||||||
[ ! -d /usr/lib/locale ] && mkdir -p /usr/lib/locale
|
|
||||||
ebegin "Building locale [${system_locale}] [UTF-8]"
|
|
||||||
localedef -i ${system_locale} -f UTF-8 ${system_locale}
|
|
||||||
eend $?
|
|
||||||
fi
|
|
||||||
# Set user defined locale
|
|
||||||
einfo "Setting system locale [${system_locale}] [UTF-8]"
|
|
||||||
echo "export LANG=${system_locale}.UTF-8" >> /etc/profile.d/locale.sh
|
|
||||||
}
|
|
|
@ -1,11 +0,0 @@
|
||||||
--- mk/sys.mk.orig 2010-02-27 06:43:02.813461209 +0100
|
|
||||||
+++ mk/sys.mk 2010-02-27 06:43:39.839467068 +0100
|
|
||||||
@@ -35,7 +35,7 @@ LIBDIR?= ${UPREFIX}/${LIBNAME}
|
|
||||||
LIBMODE?= 0444
|
|
||||||
SHLIBDIR?= ${PREFIX}/${LIBNAME}
|
|
||||||
|
|
||||||
-LIBEXECDIR?= ${PREFIX}/libexec/rc
|
|
||||||
+LIBEXECDIR?= ${PREFIX}/lib/rc
|
|
||||||
|
|
||||||
MANPREFIX?= ${UPREFIX}/share
|
|
||||||
MANDIR?= ${MANPREFIX}/man
|
|
|
@ -1,298 +0,0 @@
|
||||||
xbps changes:
|
|
||||||
|
|
||||||
* Installs a "locale" service into the "boot" runlevel to set
|
|
||||||
a global system locale.
|
|
||||||
* Adds consolefont by default in "boot" runlevel.
|
|
||||||
* Removes hardcoded rpath for bins/lib.
|
|
||||||
* Modified inittab to pass correct parameters to reboot(8).
|
|
||||||
* Sets unicode, rc_logger and rc_shell in /etc/rc.conf by default.
|
|
||||||
* Sets windowkeys and fix_euro in /etc/conf.d/keymaps by default.
|
|
||||||
* The bootmisc service no longer cleans up /var/run, as it is now mounted tmpfs
|
|
||||||
(symlinked to /run, which is tmpfs).
|
|
||||||
* The mtab service now symlinks /proc/self/mounts to /etc/mtab.
|
|
||||||
* mount_svcdir() doesn't mount any tmpfs or ramfs anymore, rather mounts an
|
|
||||||
tmpfs in /run if not already mounted and creates a compat symlink for /dev/shm.
|
|
||||||
* Backported a patch to skip unmounting the /run mountpoint from upstream
|
|
||||||
git repo (Gentoo).
|
|
||||||
|
|
||||||
--- runlevels/Makefile.Linux.orig 2009-05-07 15:48:37.075825332 +0000
|
|
||||||
+++ runlevels/Makefile.Linux 2009-05-07 15:48:52.008557039 +0000
|
|
||||||
@@ -1,3 +1,3 @@
|
|
||||||
SYSINIT+= devfs dmesg
|
|
||||||
-BOOT+= hwclock keymaps modules mtab procfs termencoding
|
|
||||||
+BOOT+= consolefont hwclock keymaps modules mtab procfs termencoding locale
|
|
||||||
SHUTDOWN+= killprocs mount-ro
|
|
||||||
--- init.d/Makefile.Linux.orig 2009-05-07 15:55:26.156910483 +0000
|
|
||||||
+++ init.d/Makefile.Linux 2009-05-07 15:55:35.682853819 +0000
|
|
||||||
@@ -2,7 +2,7 @@ NET_LO= net.lo
|
|
||||||
|
|
||||||
SRCS+= devfs.in dmesg.in hwclock.in consolefont.in keymaps.in killprocs.in \
|
|
||||||
modules.in mount-ro.in mtab.in numlock.in procfs.in sysfs.in \
|
|
||||||
- termencoding.in
|
|
||||||
+ termencoding.in locale.in
|
|
||||||
|
|
||||||
.SUFFIXES: .Linux.in
|
|
||||||
|
|
||||||
--- support/sysvinit/inittab.orig 2009-05-07 12:03:07.533948107 +0000
|
|
||||||
+++ support/sysvinit/inittab 2009-05-07 12:04:45.178070711 +0000
|
|
||||||
@@ -18,7 +18,7 @@ l3:3:wait:/sbin/rc default
|
|
||||||
l4:4:wait:/sbin/rc default
|
|
||||||
l5:5:wait:/sbin/rc default
|
|
||||||
l6:6:wait:/sbin/rc reboot
|
|
||||||
-l6r:6:wait:/sbin/reboot -dk
|
|
||||||
+l6r:6:wait:/sbin/reboot -dfi
|
|
||||||
#z6:6:respawn:/sbin/sulogin
|
|
||||||
|
|
||||||
# new-style single-user
|
|
||||||
.Linux.in:
|
|
||||||
--- conf.d/keymaps.orig 2009-10-09 17:09:02.537481085 +0200
|
|
||||||
+++ conf.d/keymaps 2009-10-09 17:12:19.694535631 +0200
|
|
||||||
@@ -1,10 +1,14 @@
|
|
||||||
# Use KEYMAP to specify the default console keymap. There is a complete tree
|
|
||||||
# of keymaps in /usr/share/keymaps to choose from.
|
|
||||||
-keymap="us"
|
|
||||||
+#
|
|
||||||
+# Please note that is mandatory to also specify the keyboard layout model,
|
|
||||||
+# i.e qwerty, dvorak, etc; because otherwise loadkeys(1) will use the first
|
|
||||||
+# one it finds and some keymaps do have the same name.
|
|
||||||
+keymap="qwerty/us"
|
|
||||||
|
|
||||||
# Should we first load the 'windowkeys' console keymap? Most x86 users will
|
|
||||||
# say "yes" here. Note that non-x86 users should leave it as "no".
|
|
||||||
-windowkeys="NO"
|
|
||||||
+windowkeys="yes"
|
|
||||||
|
|
||||||
# The maps to load for extended keyboards. Most users will leave this as is.
|
|
||||||
extended_keymaps=""
|
|
||||||
@@ -18,4 +22,4 @@ dumpkeys_charset=""
|
|
||||||
|
|
||||||
# Some fonts map AltGr-E to the currency symbol ¤ instead of the Euro €
|
|
||||||
# To fix this, set to "yes"
|
|
||||||
-fix_euro="NO"
|
|
||||||
+fix_euro="yes"
|
|
||||||
--- mk/lib.mk.orig 2009-10-21 11:00:57.000000000 +0200
|
|
||||||
+++ mk/lib.mk 2009-10-21 11:01:17.000000000 +0200
|
|
||||||
@@ -32,7 +32,7 @@ lib${LIB}.a: ${OBJS} ${STATICOBJS}
|
|
||||||
${SHLIB_NAME}: ${VERSION_MAP}
|
|
||||||
LDFLAGS+= -Wl,--version-script=${VERSION_MAP}
|
|
||||||
# We need to ensure we use libraries in /lib
|
|
||||||
-LDFLAGS+= -L/${LIBNAME} -Wl,-rpath=/${LIBNAME}
|
|
||||||
+LDFLAGS+= -L/${LIBNAME}
|
|
||||||
|
|
||||||
${SHLIB_NAME}: ${SOBJS}
|
|
||||||
@${ECHO} building shared library $@
|
|
||||||
--- etc/rc.conf.in.orig 2009-12-05 03:30:48.675483763 +0100
|
|
||||||
+++ etc/rc.conf.in 2009-12-05 03:31:13.034222373 +0100
|
|
||||||
@@ -18,7 +18,7 @@
|
|
||||||
# If not specified we use $SHELL, otherwise the one specified in /etc/passwd,
|
|
||||||
# otherwise /bin/sh
|
|
||||||
# Linux users could specify /sbin/sulogin
|
|
||||||
-#rc_shell=/bin/sh
|
|
||||||
+rc_shell=/sbin/sulogin
|
|
||||||
|
|
||||||
# Do we allow any started service in the runlevel to satisfy the depedency
|
|
||||||
# or do we want all of them regardless of state? For example, if net.eth0
|
|
||||||
@@ -44,7 +44,7 @@
|
|
||||||
# /var/log/rc.log
|
|
||||||
# NOTE: Linux systems require the devfs service to be started before
|
|
||||||
# logging can take place and as such cannot log the sysinit runlevel.
|
|
||||||
-#rc_logger="YES"
|
|
||||||
+rc_logger="YES"
|
|
||||||
|
|
||||||
# By default we filter the environment for our running scripts. To allow other
|
|
||||||
# variables through, add them here. Use a * to allow all variables through.
|
|
||||||
@@ -73,7 +73,7 @@
|
|
||||||
# There variables are shared between many init scripts
|
|
||||||
|
|
||||||
# Set unicode to YES to turn on unicode support for keyboards and screens.
|
|
||||||
-#unicode="NO"
|
|
||||||
+unicode="YES"
|
|
||||||
|
|
||||||
# Network fstypes. Below is the default.
|
|
||||||
net_fs_list="afs cifs coda davfs fuse fuse.sshfs gfs glusterfs lustre ncpfs nfs nfs4 ocfs2 shfs smbfs"
|
|
||||||
--- init.d/bootmisc.in.orig 2011-01-16 12:45:10.633395765 +0100
|
|
||||||
+++ init.d/bootmisc.in 2011-01-16 12:46:00.591163353 +0100
|
|
||||||
@@ -97,31 +97,6 @@ start()
|
|
||||||
done
|
|
||||||
[ -e /var/log/wtmp ] || mkutmp /var/log/wtmp
|
|
||||||
eend 0
|
|
||||||
-
|
|
||||||
- ebegin "Cleaning /var/run"
|
|
||||||
- for x in $(find /var/run ! -type d ! -name utmp \
|
|
||||||
- ! -name random-seed ! -name dev.db \
|
|
||||||
- ! -name ld-elf.so.hints ! -name ld.so.hints);
|
|
||||||
- do
|
|
||||||
- # Clean stale sockets
|
|
||||||
- if [ -S "$x" ]; then
|
|
||||||
- if type fuser >/dev/null 2>&1; then
|
|
||||||
- fuser "$x" >/dev/null 2>&1 || rm -- "$x"
|
|
||||||
- else
|
|
||||||
- rm -- "$x"
|
|
||||||
- fi
|
|
||||||
- fi
|
|
||||||
- [ ! -f "$x" ] && continue
|
|
||||||
- # Do not remove pidfiles of already running daemons
|
|
||||||
- case "$x" in
|
|
||||||
- *.pid)
|
|
||||||
- start-stop-daemon --test --quiet \
|
|
||||||
- --stop --pidfile "$x" && continue
|
|
||||||
- ;;
|
|
||||||
- esac
|
|
||||||
- rm -f -- "$x"
|
|
||||||
- done
|
|
||||||
- eend 0
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Clean up /tmp directories
|
|
||||||
--- init.d/devfs.in.orig 2011-02-10 06:15:24.000000000 +0100
|
|
||||||
+++ init.d/devfs.in 2011-04-29 18:12:48.983999871 +0200
|
|
||||||
@@ -13,7 +13,6 @@ start() {
|
|
||||||
# Mount required stuff as user may not have then in /etc/fstab
|
|
||||||
for x in \
|
|
||||||
"devpts /dev/pts 0755 ,gid=5,mode=0620 devpts" \
|
|
||||||
- "tmpfs /dev/shm 1777 ,nodev shm" \
|
|
||||||
; do
|
|
||||||
set -- $x
|
|
||||||
grep -Eq "[[:space:]]+$1$" /proc/filesystems || continue
|
|
||||||
--- sh/init.sh.Linux.in.orig 2011-02-10 06:15:24.000000000 +0100
|
|
||||||
+++ sh/init.sh.Linux.in 2011-05-04 13:03:07.481471247 +0200
|
|
||||||
@@ -3,59 +3,22 @@
|
|
||||||
# Copyright (c) 2007-2009 Roy Marples <roy@marples.name>
|
|
||||||
# All rights reserved. Released under the 2-clause BSD license.
|
|
||||||
|
|
||||||
-# This basically mounts $RC_SVCDIR as a ramdisk.
|
|
||||||
-# The tricky part is finding something our kernel supports
|
|
||||||
-# tmpfs and ramfs are easy, so force one or the other.
|
|
||||||
-svcdir_restorecon()
|
|
||||||
-{
|
|
||||||
- local rc=0
|
|
||||||
- if [ -x /usr/sbin/selinuxenabled -a -c /selinux/null ] &&
|
|
||||||
- selinuxenabled; then
|
|
||||||
- restorecon $RC_SVCDIR
|
|
||||||
- rc=$?
|
|
||||||
- fi
|
|
||||||
- return $rc
|
|
||||||
-}
|
|
||||||
-
|
|
||||||
mount_svcdir()
|
|
||||||
{
|
|
||||||
- # mount from fstab if we can
|
|
||||||
- fstabinfo --mount "$RC_SVCDIR" && return 0
|
|
||||||
-
|
|
||||||
- local fs= fsopts="-o rw,noexec,nodev,nosuid"
|
|
||||||
- local svcsize=${rc_svcsize:-1024}
|
|
||||||
-
|
|
||||||
- # Some buggy kernels report tmpfs even when not present :(
|
|
||||||
- if grep -Eq "[[:space:]]+tmpfs$" /proc/filesystems; then
|
|
||||||
- local tmpfsopts="${fsopts},mode=755,size=${svcsize}k"
|
|
||||||
- mount -n -t tmpfs $tmpfsopts rc-svcdir "$RC_SVCDIR"
|
|
||||||
- if [ $? -eq 0 ]; then
|
|
||||||
- svcdir_restorecon
|
|
||||||
- [ $? -eq 0 ] && return 0
|
|
||||||
- fi
|
|
||||||
- fi
|
|
||||||
-
|
|
||||||
- if grep -Eq "[[:space:]]+ramfs$" /proc/filesystems; then
|
|
||||||
- fs="ramfs"
|
|
||||||
- # ramfs has no special options
|
|
||||||
- elif [ -e /dev/ram0 ] \
|
|
||||||
- && grep -Eq "[[:space:]]+ext2$" /proc/filesystems; then
|
|
||||||
- devdir="/dev/ram0"
|
|
||||||
- fs="ext2"
|
|
||||||
- dd if=/dev/zero of="$devdir" bs=1k count="$svcsize"
|
|
||||||
- mkfs -t "$fs" -i 1024 -vm0 "$devdir" "$svcsize"
|
|
||||||
- else
|
|
||||||
- echo
|
|
||||||
- eerror "OpenRC requires tmpfs, ramfs or a ramdisk + ext2"
|
|
||||||
- eerror "compiled into the kernel"
|
|
||||||
- echo
|
|
||||||
- return 1
|
|
||||||
- fi
|
|
||||||
+ # Mount /run as tmpfs if not mounted already.
|
|
||||||
+ mountinfo -q /run || mount -t tmpfs -o mode=0755,nosuid,nodev tmpfs /run
|
|
||||||
|
|
||||||
- mount -n -t "$fs" $fsopts rc-svcdir "$RC_SVCDIR"
|
|
||||||
- if [ $? -eq 0 ]; then
|
|
||||||
- svcdir_restorecon
|
|
||||||
- [ $? -eq 0 ] && return 0
|
|
||||||
+ for d in init.d udev; do
|
|
||||||
+ [ ! -d /run/${d} ] && mkdir -m0755 /run/${d}
|
|
||||||
+ done
|
|
||||||
+ for d in lock tmp shm; do
|
|
||||||
+ [ ! -d /run/${d} ] && mkdir -m1777 /run/${d}
|
|
||||||
+ done
|
|
||||||
+
|
|
||||||
+ # Create /dev/shm -> /run/shm compat symlink.
|
|
||||||
+ if [ "$(readlink -f /dev/shm)" != "/run/shm" ]; then
|
|
||||||
+ rm -rf /dev/shm
|
|
||||||
+ ln -sf /run/shm /dev/shm
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
--- init.d/localmount.in.orig 2011-02-10 06:15:24.000000000 +0100
|
|
||||||
+++ init.d/localmount.in 2011-05-20 09:44:24.445841901 +0200
|
|
||||||
@@ -34,7 +34,7 @@ start()
|
|
||||||
stop()
|
|
||||||
{
|
|
||||||
# We never unmount / or /dev or $RC_SVCDIR
|
|
||||||
- local x= no_umounts_r="/|/dev|/dev/.*|${RC_SVCDIR}"
|
|
||||||
+ local x= no_umounts_r="/|/dev|/dev/.*"
|
|
||||||
no_umounts_r="${no_umounts_r}|/bin|/sbin|/lib|/libexec"
|
|
||||||
# RC_NO_UMOUNTS is an env var that can be set by plugins
|
|
||||||
OIFS=$IFS SIFS=${IFS-y}
|
|
||||||
@@ -49,7 +49,7 @@ stop()
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "$RC_UNAME" = Linux ]; then
|
|
||||||
- no_umounts_r="$no_umounts_r|/proc|/proc/.*|/sys|/sys/.*"
|
|
||||||
+ no_umounts_r="$no_umounts_r|/proc|/proc/.*|/run|/sys|/sys/.*|/cow|/rofs|/cdrom"
|
|
||||||
fi
|
|
||||||
no_umounts_r="^($no_umounts_r)$"
|
|
||||||
|
|
||||||
--- init.d/mount-ro.in.orig 2011-05-20 09:45:08.199841890 +0200
|
|
||||||
+++ init.d/mount-ro.in 2011-05-20 09:45:33.285841883 +0200
|
|
||||||
@@ -19,7 +19,7 @@ start()
|
|
||||||
# We need the do_unmount function
|
|
||||||
. "$RC_LIBEXECDIR"/sh/rc-mount.sh
|
|
||||||
eindent
|
|
||||||
- local m="/dev|/dev/.*|/proc|/proc.*|/sys|/sys/.*|${RC_SVCDIR}" x= fs=
|
|
||||||
+ local m="/dev|/dev/.*|/proc|/proc.*|/sys|/sys/.*|/run|/cow|/rofs|/cdrom" x= fs=
|
|
||||||
m="$m|/bin|/sbin|/lib|/libexec"
|
|
||||||
# RC_NO_UMOUNTS is an env var that can be set by plugins
|
|
||||||
local OIFS=$IFS SIFS=${IFS-y} IFS=$IFS
|
|
||||||
--- init.d/mtab.in.orig 2011-06-25 16:16:49.284716701 +0200
|
|
||||||
+++ init.d/mtab.in 2011-06-25 16:18:13.986716755 +0200
|
|
||||||
@@ -6,31 +6,11 @@ description="Update /etc/mtab to match w
|
|
||||||
|
|
||||||
depend()
|
|
||||||
{
|
|
||||||
- need root
|
|
||||||
+ need root
|
|
||||||
keyword -prefix
|
|
||||||
}
|
|
||||||
|
|
||||||
start()
|
|
||||||
{
|
|
||||||
- # /etc/mtab could be a symlink to /proc/mounts
|
|
||||||
- if [ ! -w /etc/mtab -a -L /etc/mtab ]; then
|
|
||||||
- eeinfo "Skipping mtab update (non writeable symlink)"
|
|
||||||
- return 0
|
|
||||||
- fi
|
|
||||||
-
|
|
||||||
- ebegin "Updating /etc/mtab"
|
|
||||||
- if ! echo 2>/dev/null >/etc/mtab; then
|
|
||||||
- ewend 1 "/etc/mtab is not updateable"
|
|
||||||
- return 0
|
|
||||||
- fi
|
|
||||||
-
|
|
||||||
- # With / as tmpfs we cannot umount -at tmpfs in localmount as that
|
|
||||||
- # makes / readonly and dismounts all tmpfs even if in use which is
|
|
||||||
- # not good. Luckily, umount uses /etc/mtab instead of /proc/mounts
|
|
||||||
- # which allows this hack to work.
|
|
||||||
- grep -v "^[^ ]* / tmpfs " /proc/mounts > /etc/mtab
|
|
||||||
-
|
|
||||||
- # Remove stale backups
|
|
||||||
- rm -f /etc/mtab~ /etc/mtab~~
|
|
||||||
- eend 0
|
|
||||||
+ ln -sf /proc/self/mounts /etc/mtab
|
|
||||||
}
|
|
|
@ -1,84 +0,0 @@
|
||||||
Replace 'ifconfig' uses to use 'ip' command from iproute2.
|
|
||||||
|
|
||||||
--- conf.d/network.Linux.orig 2011-06-18 20:56:50.593211799 +0200
|
|
||||||
+++ conf.d/network.Linux 2011-06-18 20:57:50.352207353 +0200
|
|
||||||
@@ -3,14 +3,12 @@
|
|
||||||
#defaultroute="gw 192.168.0.1"
|
|
||||||
#defaultroute6="gw 2001:a:b:c"
|
|
||||||
|
|
||||||
-# ifconfig under Linux is not that powerful and doesn't easily handle
|
|
||||||
-# multiple addresses
|
|
||||||
-# On the other hand, ip (iproute2) is quite powerful and is also supported
|
|
||||||
+# ip (iproute2) is quite powerful and is the default method.
|
|
||||||
#ip_eth0="192.168.0.10/24; 192.168.10.10/24"
|
|
||||||
|
|
||||||
# You can also use ip to add the default route.
|
|
||||||
-#defaultiproute="via 192.168.0.1"
|
|
||||||
-#defaultiproute6="via 2001:a:b:c"
|
|
||||||
+#defaultroute="via 192.168.0.1"
|
|
||||||
+#defaultroute6="via 2001:a:b:c"
|
|
||||||
|
|
||||||
# ip doesn't handle MTU like ifconfig, but we can do it like so
|
|
||||||
#ifup_eth0="ip link set \$int mtu 1500"
|
|
||||||
--- init.d/network.in.orig 2011-06-18 20:42:08.035277498 +0200
|
|
||||||
+++ init.d/network.in 2011-06-18 20:55:54.240215997 +0200
|
|
||||||
@@ -46,7 +46,7 @@ sys_interfaces()
|
|
||||||
i=${w%%:*}
|
|
||||||
[ "$i" != "$w" ] || continue
|
|
||||||
if [ "$cmd" = u ]; then
|
|
||||||
- ifconfig "$i" | grep -q "[ ]*UP" || continue
|
|
||||||
+ ip link show "$i" | grep -q "[ ]*UP" || continue
|
|
||||||
fi
|
|
||||||
printf "%s " "$i"
|
|
||||||
done </proc/net/dev
|
|
||||||
@@ -222,9 +222,7 @@ start()
|
|
||||||
einfo "Starting network"
|
|
||||||
routeflush
|
|
||||||
if [ "$RC_UNAME" = "Linux" ]; then
|
|
||||||
- ifconfig lo 127.0.0.1 netmask 255.0.0.0 || cr=1
|
|
||||||
- route add -net 127.0.0.0 netmask 255.0.0.0 \
|
|
||||||
- gw 127.0.0.1 reject 2>/dev/null
|
|
||||||
+ ip link set up dev lo
|
|
||||||
else
|
|
||||||
ifconfig lo0 127.0.0.1 netmask 255.0.0.0 || cr=1
|
|
||||||
route -q add -inet 127.0.0.0 -netmask 255.0.0.0 \
|
|
||||||
@@ -290,26 +288,13 @@ start()
|
|
||||||
|
|
||||||
if [ -n "$defaultroute" ]; then
|
|
||||||
ebegin "Setting default route $defaultroute"
|
|
||||||
- route add default $defaultroute
|
|
||||||
- eend $?
|
|
||||||
- elif [ -n "$defaultiproute" ]; then
|
|
||||||
- ebegin "Setting default route $defaultiproute"
|
|
||||||
- ip route add default $defaultiproute
|
|
||||||
+ ip route add default $defaultroute
|
|
||||||
eend $?
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ -n "$defaultroute6" ]; then
|
|
||||||
ebegin "Setting default route $defaultroute6"
|
|
||||||
- if [ "$RC_UNAME" = Linux ]; then
|
|
||||||
- routecmd="route -A inet6 add"
|
|
||||||
- else
|
|
||||||
- routecmd="route -inet6 add"
|
|
||||||
- fi
|
|
||||||
- $routecmd default $defaultroute6
|
|
||||||
- eend $?
|
|
||||||
- elif [ -n "$defaultiproute6" ]; then
|
|
||||||
- ebegin "Setting default route $defaultiproute6"
|
|
||||||
- ip -f inet6 route add default $defaultiproute6
|
|
||||||
+ ip -f inet6 route add default $defaultroute6
|
|
||||||
eend $?
|
|
||||||
fi
|
|
||||||
|
|
||||||
@@ -343,8 +328,8 @@ stop()
|
|
||||||
# fail to add things correctly on restart
|
|
||||||
ip address flush dev "$int" 2>/dev/null
|
|
||||||
fi
|
|
||||||
- ifconfig "$int" down 2>/dev/null
|
|
||||||
- ifconfig "$int" destroy 2>/dev/null
|
|
||||||
+ ip link set dev "$int" down 2>/dev/null
|
|
||||||
+ ip link delete "$int" 2>/dev/null
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
eoutdent
|
|
|
@ -1,82 +0,0 @@
|
||||||
# Template file for 'OpenRC'
|
|
||||||
pkgname=OpenRC
|
|
||||||
version=20110211
|
|
||||||
revision=15
|
|
||||||
wrksrc=openrc-${version}
|
|
||||||
distfiles="http://xbps.nopcode.org/distfiles/openrc-$version.tar.bz2"
|
|
||||||
short_desc="Universal init system"
|
|
||||||
maintainer="Juan RP <xtraeme@gmail.com>"
|
|
||||||
homepage="http://roy.marples.name/projects/openrc"
|
|
||||||
license="BSD"
|
|
||||||
checksum=16840a9635648e501e2f94464f6cf1c26b6bbdbbc7e3d9a1f8466117271885e1
|
|
||||||
long_desc="
|
|
||||||
OpenRC is a dependency based init system that works with the system
|
|
||||||
provided init program, normally /sbin/init. It is not a replacement for
|
|
||||||
/sbin/init. OpenRC is 100% compatible with Gentoo init scripts, which
|
|
||||||
means you can probably find one for the daemons you want to start in the
|
|
||||||
Gentoo Portage Tree. OpenRC also provides an init script that runs BSD
|
|
||||||
rc.d style scripts too, making it easy to port your BSD system to OpenRC."
|
|
||||||
|
|
||||||
keep_empty_dirs=yes
|
|
||||||
conf_files="
|
|
||||||
/etc/rc.conf
|
|
||||||
/etc/conf.d/bootmisc
|
|
||||||
/etc/conf.d/consolefont
|
|
||||||
/etc/conf.d/dmesg
|
|
||||||
/etc/conf.d/fsck
|
|
||||||
/etc/conf.d/hostname
|
|
||||||
/etc/conf.d/hwclock
|
|
||||||
/etc/conf.d/keymaps
|
|
||||||
/etc/conf.d/locale
|
|
||||||
/etc/conf.d/network
|
|
||||||
/etc/conf.d/localmount
|
|
||||||
/etc/conf.d/modules
|
|
||||||
/etc/conf.d/staticroute
|
|
||||||
/etc/conf.d/urandom
|
|
||||||
/etc/inittab"
|
|
||||||
|
|
||||||
subpackages="$pkgname-devel"
|
|
||||||
|
|
||||||
Add_dependency run psmisc
|
|
||||||
Add_dependency run sysvinit
|
|
||||||
Add_dependency build coreutils
|
|
||||||
|
|
||||||
_version="0.7.0-${version} #${revision}"
|
|
||||||
_branding="Void GNU/Linux"
|
|
||||||
|
|
||||||
do_build()
|
|
||||||
{
|
|
||||||
# Install the "locale" service
|
|
||||||
cp ${FILESDIR}/locale.rc ${wrksrc}/init.d/locale.in
|
|
||||||
|
|
||||||
# Fix path for kbd stuff.
|
|
||||||
for f in init.d/consolefont.in conf.d/consolefont; do
|
|
||||||
sed -i -e "s|/usr/share|/lib/kbd|g" ${wrksrc}/${f}
|
|
||||||
done
|
|
||||||
|
|
||||||
make ${makejobs} VERSION="${_version}" BRANDING="${_branding}"
|
|
||||||
}
|
|
||||||
|
|
||||||
do_install()
|
|
||||||
{
|
|
||||||
make DESTDIR=${DESTDIR} VERSION="${_version}" \
|
|
||||||
BRANDING="${_branding}" install
|
|
||||||
|
|
||||||
install -D -m755 ${wrksrc}/support/sysvinit/inittab \
|
|
||||||
${DESTDIR}/etc/inittab
|
|
||||||
install -D -m644 ${FILESDIR}/$pkgname.logrotate \
|
|
||||||
${DESTDIR}/etc/logrotate.d/OpenRC
|
|
||||||
install -D -m644 ${FILESDIR}/locale.confd \
|
|
||||||
${DESTDIR}/etc/conf.d/locale
|
|
||||||
#
|
|
||||||
# Create a fake rc.d directory with links to mimic old sysvinit
|
|
||||||
# runlevel stuff.
|
|
||||||
install -d ${DESTDIR}/etc/init.d/fake-rc.d
|
|
||||||
for f in 0 1 2 3 4 5 6; do
|
|
||||||
cd ${DESTDIR}/etc/init.d && ln -s fake-rc.d rc${f}.d
|
|
||||||
done
|
|
||||||
|
|
||||||
chmod 755 ${DESTDIR}/lib/lib*
|
|
||||||
chmod 755 ${DESTDIR}/usr/lib/lib*
|
|
||||||
rmdir ${DESTDIR}/lib/rc/init.d
|
|
||||||
}
|
|
Loading…
Reference in a new issue