From bd91423d53b21b66a2434bece523ac0dcc33e26a Mon Sep 17 00:00:00 2001 From: Christian Ruppert Date: Mon, 27 Jun 2011 19:24:47 +0200 Subject: [PATCH] remove the link at @SYSCONFDIR@/init.d/functions.sh Note by WilliamH: This patch originally put a new script at @sysconfdir@/init.d/functions.sh which announced that using it was deprecated, but we need to not do that because gentoo linux needs @sysconfdir@/init.d/functions.sh. This gives gentoo a way to provide this script for its core functionality. --- man/Makefile | 2 ++ man/{einfo.3 => einfo.3.in} | 2 +- man/{rc_runlevel.3 => rc_runlevel.3.in} | 2 +- sh/Makefile | 3 --- sh/gendepends.sh.in | 2 +- sh/runscript.sh.in | 2 +- 6 files changed, 6 insertions(+), 7 deletions(-) rename man/{einfo.3 => einfo.3.in} (99%) rename man/{rc_runlevel.3 => rc_runlevel.3.in} (98%) diff --git a/man/Makefile b/man/Makefile index 5a63da8..5e32356 100644 --- a/man/Makefile +++ b/man/Makefile @@ -1,3 +1,4 @@ +SRCS=einfo.3.in rc_runlevel.3.in MAN3= einfo.3 \ rc_config.3 rc_deptree.3 rc_find_pids.3 rc_plugin_hook.3 \ rc_runlevel.3 rc_service.3 rc_stringlist.3 @@ -18,6 +19,7 @@ MAKE_LINKS= suffix=$${man\#*.}; \ MK= ../mk include ${MK}/sys.mk +include ${MK}/scripts.mk include ${MK}/gitignore.mk all: diff --git a/man/einfo.3 b/man/einfo.3.in similarity index 99% rename from man/einfo.3 rename to man/einfo.3.in index 43fde8b..7904387 100644 --- a/man/einfo.3 +++ b/man/einfo.3.in @@ -194,7 +194,7 @@ and .Fn einfovn family of functions work, so they do print. .Sh FILES -.Pa /etc/init.d/functions.sh +.Pa @LIBEXECDIR@/sh/functions.sh is provided by OpenRC, which allows shell scripts to use the above functions. For historical reasons our verbose functions are prefixed with v instead of suffixed. So einfov becomes veinfo, einfovn becomes veinfon. diff --git a/man/rc_runlevel.3 b/man/rc_runlevel.3.in similarity index 98% rename from man/rc_runlevel.3 rename to man/rc_runlevel.3.in index 87dbb54..8b58974 100644 --- a/man/rc_runlevel.3 +++ b/man/rc_runlevel.3.in @@ -53,7 +53,7 @@ should by freed by calling .Fn rc_stringlist_free when done. .Sh FILES -.Pa /etc/init.d/functions.sh +.Pa @LIBEXECDIR@/sh/functions.sh is provided by OpenRC, which allows shell scripts to use the above functions. For historical reasons our verbose functions are prefixed with v instead of suffixed. So einfov becomes veinfo, einfovn becomes veinfon. diff --git a/sh/Makefile b/sh/Makefile index 73d4641..91b1601 100644 --- a/sh/Makefile +++ b/sh/Makefile @@ -12,9 +12,6 @@ include Makefile.${OS} include ${MK}/scripts.mk _installafter: - ${INSTALL} -d ${DESTDIR}/${INITDIR} - @# Put functions.sh into init for backwards compat - ln -snf ${LIBEXECDIR}/sh/functions.sh ${DESTDIR}/${INITDIR} || exit $$? check test:: ./runtests.sh diff --git a/sh/gendepends.sh.in b/sh/gendepends.sh.in index 95a7b48..44b2c07 100644 --- a/sh/gendepends.sh.in +++ b/sh/gendepends.sh.in @@ -4,7 +4,7 @@ # Copyright (c) 2007-2009 Roy Marples # All rights reserved. Released under the 2-clause BSD license. -. @SYSCONFDIR@/init.d/functions.sh +. @LIBEXECDIR@/sh/functions.sh . @LIBEXECDIR@/sh/rc-functions.sh config() { diff --git a/sh/runscript.sh.in b/sh/runscript.sh.in index 71935a0..faffd46 100644 --- a/sh/runscript.sh.in +++ b/sh/runscript.sh.in @@ -28,7 +28,7 @@ if [ ! -e ${RC_SVCDIR}/softlevel ]; then exit 1 fi -sourcex "@SYSCONFDIR@/init.d/functions.sh" +sourcex "@LIBEXECDIR@/sh/functions.sh" sourcex "@LIBEXECDIR@/sh/rc-functions.sh" # Support LiveCD foo -- 1.7.3.4