From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 63747138873 for ; Fri, 24 Oct 2014 16:02:41 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 28E0AE0877; Fri, 24 Oct 2014 16:02:39 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 653F5E0874 for ; Fri, 24 Oct 2014 16:02:37 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 3A9953403B6 for ; Fri, 24 Oct 2014 16:02:36 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 3D1998A25 for ; Fri, 24 Oct 2014 16:02:33 +0000 (UTC) From: "William Hubbs" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "William Hubbs" Message-ID: <1414166355.4ba30c5a1bb0571e7d79f30c29525f206bed12e5.williamh@OpenRC> Subject: [gentoo-commits] proj/openrc:openrc-0.13.x commit in: conf.d/, init.d/, sh/, etc/, mk/ X-VCS-Repository: proj/openrc X-VCS-Files: conf.d/network.GNU.in conf.d/staticroute.GNU.in etc/rc.conf.GNU init.d/sysctl.GNU.in mk/os-GNU.mk sh/init.sh.GNU.in X-VCS-Directories: mk/ sh/ init.d/ etc/ conf.d/ X-VCS-Committer: williamh X-VCS-Committer-Name: William Hubbs X-VCS-Revision: 4ba30c5a1bb0571e7d79f30c29525f206bed12e5 X-VCS-Branch: openrc-0.13.x Date: Fri, 24 Oct 2014 16:02:33 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: e7423f8d-ac28-4952-a3af-703f00997c43 X-Archives-Hash: c4fef32093df4ed27322a705105494de commit: 4ba30c5a1bb0571e7d79f30c29525f206bed12e5 Author: Svante Signell gmail com> AuthorDate: Wed Oct 22 19:25:00 2014 +0000 Commit: William Hubbs gentoo org> CommitDate: Fri Oct 24 15:59:15 2014 +0000 URL: http://sources.gentoo.org/gitweb/?p=proj/openrc.git;a=commit;h=4ba30c5a add missing files for GNU/Hurd --- conf.d/network.GNU.in | 4 ++++ conf.d/staticroute.GNU.in | 7 +++++++ etc/rc.conf.GNU | 14 ++++++++++++++ init.d/sysctl.GNU.in | 32 ++++++++++++++++++++++++++++++++ mk/os-GNU.mk | 8 ++++++++ sh/init.sh.GNU.in | 38 ++++++++++++++++++++++++++++++++++++++ 6 files changed, 103 insertions(+) diff --git a/conf.d/network.GNU.in b/conf.d/network.GNU.in new file mode 100644 index 0000000..78aa412 --- /dev/null +++ b/conf.d/network.GNU.in @@ -0,0 +1,4 @@ + +# You can assign a default route +#defaultroute="gw 192.168.0.1" +#defaultroute6="gw 2001:a:b:c" diff --git a/conf.d/staticroute.GNU.in b/conf.d/staticroute.GNU.in new file mode 100644 index 0000000..58d77e3 --- /dev/null +++ b/conf.d/staticroute.GNU.in @@ -0,0 +1,7 @@ +# Separate multiple routes using ; or new lines. +# /etc/route.conf(5) takes precedence over this configuration. + +# Example static routes. See route(8) for syntax. +# FIXME: "net ..." not supported +#staticroute="net 192.168.0.0 -netmask 255.255.255.0 --address 10.73.1.1 +#net 192.168.1.0 -netmask 255.255.255.0 --address 10.73.1.1" diff --git a/etc/rc.conf.GNU b/etc/rc.conf.GNU new file mode 100644 index 0000000..a9f054a --- /dev/null +++ b/etc/rc.conf.GNU @@ -0,0 +1,14 @@ +############################################################################## +# GNU/Hurd SPECIFIC OPTIONS + +# This is the subsystem type. Valid options on GNU/Hurd: +# "" - nothing special +# "subhurd" - Hurd subhurds (to be checked) +# If this is commented out, automatic detection will be used. +# +# This should be set to the value representing the environment this file is +# PRESENTLY in, not the virtualization the environment is capable of. +#rc_sys="" +# This is the number of tty's used in most of the rc-scripts (like +# consolefont, numlock, etc ...) +#rc_tty_number=6? diff --git a/init.d/sysctl.GNU.in b/init.d/sysctl.GNU.in new file mode 100644 index 0000000..7139824 --- /dev/null +++ b/init.d/sysctl.GNU.in @@ -0,0 +1,32 @@ +#!@PREFIX@/sbin/runscript +# Copyright (c) 2007-2009 Roy Marples +# Released under the 2-clause BSD license. +#FIXME: Modify for GNU/Hurd + +depend() +{ + before bootmisc logger + keyword -prefix +} + +start() +{ + [ -e /etc/sysctl.conf ] || return 0 + local retval=0 var= comments= conf= + ebegin "Configuring kernel parameters" + eindent + for conf in @SYSCONFDIR@/sysctl.conf @SYSCONFDIR@/sysctl.d/*.conf; do + if [ -r "$conf" ]; then + vebegin "applying $conf" + while read var comments; do + case "$var" in + ""|"#"*) continue;; + esac + sysctl -w "$var" >/dev/null || retval=1 + done < "$conf" + veend $retval + fi + done + eoutdent + eend $retval "Some errors were encountered" +} diff --git a/mk/os-GNU.mk b/mk/os-GNU.mk new file mode 100644 index 0000000..bbaba2b --- /dev/null +++ b/mk/os-GNU.mk @@ -0,0 +1,8 @@ +# Copyright (c) 2008 Roy Marples +# Released under the 2-clause BSD license. + +SFX= .GNU.in +PKG_PREFIX?= /usr + +CPPFLAGS+= -D_BSD_SOURCE -D_XOPEN_SOURCE=700 -DMAXPATHLEN=4096 -DMAX_PATH=4096 +LIBDL= -Wl,-Bdynamic -ldl diff --git a/sh/init.sh.GNU.in b/sh/init.sh.GNU.in new file mode 100644 index 0000000..5ba051d --- /dev/null +++ b/sh/init.sh.GNU.in @@ -0,0 +1,38 @@ +#!@SHELL@ +# Copyright (c) 2007-2009 Roy Marples +# Copyright (c) 2014 Svante Signell +# Released under the 2-clause BSD license. + +if [ ! -d /run ]; then + ebegin "Creating /run" + mkdir -p /run + eend $? +fi + +if [ -L $RC_SVCDIR ]; then + rm $RC_SVCDIR +fi + +if ! mountinfo -q /run; then + ebegin "Mounting /run" + if ! fstabinfo --mount /run; then + mount -t tmpfs -o mode=0755,no-suid,size=10% tmpfs /run + if [ $? != 0 ]; then + eerror "Unable to mount tmpfs on /run." + eerror "Can't continue." + exit 1 + fi + fi + eend +fi + +ebegin "Creating $RC_SVCDIR" +mkdir -p $RC_SVCDIR +eend $? + +if [ -e "$RC_LIBEXECDIR"/cache/deptree ]; then + cp -p "$RC_LIBEXECDIR"/cache/* "$RC_SVCDIR" 2>/dev/null +fi + +echo sysinit >"$RC_SVCDIR"/softlevel +exit 0