Mercurial > hg > dhcpcd
changeset 243:16b9a7acc7a2 draft
Detect Slackware RC. Also rename ORC to OPENRC and BRC to BSDRC.
| author | Roy Marples <roy@marples.name> |
|---|---|
| date | Thu, 15 Nov 2007 23:58:16 +0000 |
| parents | 43bd36a18297 |
| children | 751506db9972 |
| files | Makefile README config.h |
| diffstat | 3 files changed, 16 insertions(+), 14 deletions(-) [+] |
line wrap: on
line diff
--- a/Makefile Thu Nov 15 17:58:39 2007 +0000 +++ b/Makefile Thu Nov 15 23:58:16 2007 +0000 @@ -66,9 +66,10 @@ # Work out how to restart services _RC_SH = if [ -n "$(HAVE_INIT)" ]; then \ [ "$(HAVE_INIT)" = "no" ] || echo "-DENABLE_$(HAVE_INIT)"; \ - elif [ -x /sbin/runscript ]; then echo "-DENABLE_ORC"; \ + elif [ -x /sbin/runscript ]; then echo "-DENABLE_OPENRC"; \ elif [ -x /sbin/service ]; then echo "-DENABLE_SERVICE"; \ - elif [ -d /etc/rc.d ]; then echo "-DENABLE_BRC"; \ + elif [ -x /etc/rc.d/rc.S -a -x /etc/rc.d/rc.M ]; then echo "-DENABLE_SLACKRC"; \ + elif [ -d /etc/rc.d ]; then echo "-DENABLE_BSDRC"; \ elif [ -d /etc/init.d ]; then echo "-DENABLE_SYSV"; \ fi _RC != $(_RC_SH)
--- a/README Thu Nov 15 17:58:39 2007 +0000 +++ b/README Thu Nov 15 23:58:16 2007 +0000 @@ -21,9 +21,10 @@ We try and detect how to restart ntp and ypbind, you can override this with HAVE_INIT=no or force one of these values -ORC (OpenRC as used by Gentoo (forked from baselayout)) -BRC (BSD RC system - /etc/rc.d/ntpd restart ) +OPENRC (OpenRC as used by Gentoo (forked from baselayout)) +BSDRC (BSD RC system - /etc/rc.d/ntpd restart ) SERVICE (RedHat service command - service ntpd restart) +SLACKRC (Slackware RC system - /etc/rc.d/rc.ntpd restart) SYSV (SYSV style - /etc/init.d/ntpd restart) You can change the default dir where dhcpcd stores it's .info files with
--- a/config.h Thu Nov 15 17:58:39 2007 +0000 +++ b/config.h Thu Nov 15 23:58:16 2007 +0000 @@ -63,25 +63,25 @@ #define INFOFILE INFODIR "/" PACKAGE "-%s.info" #define DUIDFILE INFODIR "/" PACKAGE ".duid" -/* ORC is Open Run Control, forked from Gentoo's baselayout package - * BRC is BSD style Run Control - * SRC is Slackware Run Control - * SERVICE is RedHat +/* OPENRC is Open Run Control, forked from Gentoo's baselayout package + * BSDRC is BSD style Run Control + * SLACKRC is Slackware Run Control + * SERVICE is RedHat service command * SYSV should cover everthing else */ -#ifdef ENABLE_ORC -# define SERVICE "ORC" +#ifdef ENABLE_OPENRC +# define SERVICE "OPENRC" # define NISSERVICE ETCDIR "/init.d/ypbind" # define NISRESTARTARGS "--nodeps", "--quiet", "conditionalrestart" # define NTPSERVICE ETCDIR "/init.d/ntpd" # define NTPRESTARTARGS "--nodeps", "--quiet", "conditionalrestart" -#elif ENABLE_BRC -# define SERVICE "BRC" +#elif ENABLE_BSDRC +# define SERVICE "BSDRC" # define NISSERVICE ETCDIR "/rc.d/ypbind" # define NISRESTARTARGS "restart" # define NTPSERVICE ETCDIR "/rc.d/ntpd" # define NTPRESTARTARGS "restart" -#elif ENABLE_SRC -# define SERVICE "SRC" +#elif ENABLE_SLACKRC +# define SERVICE "SLACKRC" # define NISSERVICE ETCDIR "/rc.d/rc.ypbind" # define NISRESTARTARGS "restart" # define NTPSERVICE ETCDIR "/rc.d/rc.ntpd"
