From: Roy Marples Date: Tue, 22 Dec 2015 22:50:34 +0000 (+0000) Subject: Grudgingly accede to the vocal minority that dhcpcd should not attempt to X-Git-Tag: v6.10.0~26 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9ac8f9f8119346661ca36cb241f95bfefb76f0d7;p=thirdparty%2Fdhcpcd.git Grudgingly accede to the vocal minority that dhcpcd should not attempt to start wpa_supplicant by default on a wireless interface, even if a wpa_ctrl interface is configured for it and wpa_supplicant is not yet started. --- diff --git a/Makefile b/Makefile index e4a25668..cbd09bc9 100644 --- a/Makefile +++ b/Makefile @@ -41,6 +41,7 @@ SUBDIRS= dhcpcd-hooks ${MKDIRS} SED_RUNDIR= -e 's:@RUNDIR@:${RUNDIR}:g' SED_DBDIR= -e 's:@DBDIR@:${DBDIR}:g' SED_LIBDIR= -e 's:@LIBDIR@:${LIBDIR}:g' +SED_DATADIR= -e 's:@DATADIR@:${DATADIR}:g' SED_HOOKDIR= -e 's:@HOOKDIR@:${HOOKDIR}:g' SED_SERVICEEXISTS= -e 's:@SERVICEEXISTS@:${SERVICEEXISTS}:g' SED_SERVICECMD= -e 's:@SERVICECMD@:${SERVICECMD}:g' @@ -67,7 +68,7 @@ CLEANFILES+= *.tar.xz .in: ${SED} ${SED_RUNDIR} ${SED_DBDIR} ${SED_LIBDIR} ${SED_HOOKDIR} \ - ${SED_SYS} ${SED_SCRIPT} \ + ${SED_SYS} ${SED_SCRIPT} ${SED_DATADIR} \ ${SED_SERVICEEXISTS} ${SED_SERVICECMD} ${SED_SERVICESTATUS} \ $< > $@ diff --git a/README b/README index bfc31b1d..bbc6e039 100644 --- a/README +++ b/README @@ -120,11 +120,10 @@ gmake-4 or any BSD make. Hooks ----- Not all the hooks in dhcpcd-hooks are installed by default. -By default we install 01-test, 02-dump, 10-mtu, 10-wpa_supplicant, -15-timezone, 20-resolv.conf, 29-lookup-hostname and 30-hostname. -The other hooks, 15-timezone, 29-lookup-hostname are installed -to $(datadir)/dhcpcd/hooks by default and need to be copied to -$(libexecdir)/dhcpcd-hooks for use. +By default we install 01-test, 02-dump, 10-mtu, 20-resolv.conf and 30-hostname. +The other hooks, 10-wpa_supplicant, 15-timezone, 29-lookup-hostname +are installed to $(datadir)/dhcpcd/hooks by default and need to be +copied to $(libexecdir)/dhcpcd-hooks for use. The configure program attempts to find hooks for systems you have installed. To add more simply ./configure -with-hook=ntp.conf diff --git a/dhcpcd-hooks/Makefile b/dhcpcd-hooks/Makefile index 5f3087b6..a5a3e768 100644 --- a/dhcpcd-hooks/Makefile +++ b/dhcpcd-hooks/Makefile @@ -4,13 +4,14 @@ include ${TOP}/iconfig.mk SCRIPTSDIR= ${LIBEXECDIR}/dhcpcd-hooks SCRIPTS= 01-test 02-dump -SCRIPTS+= 10-wpa_supplicant 20-resolv.conf +SCRIPTS+= 20-resolv.conf SCRIPTS+= 30-hostname SCRIPTS+= ${HOOKSCRIPTS} # Some hooks should not be installed by default FILESDIR= ${DATADIR}/dhcpcd/hooks -FILES= 15-timezone +FILES= 10-wpa_supplicant +FILES+= 15-timezone FILES+= 29-lookup-hostname 50-ypbind: 50-ypbind.in diff --git a/dhcpcd.8.in b/dhcpcd.8.in index 8f7b1916..5b8ab160 100644 --- a/dhcpcd.8.in +++ b/dhcpcd.8.in @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd December 4, 2015 +.Dd December 22, 2015 .Dt DHCPCD 8 .Os .Sh NAME @@ -205,8 +205,6 @@ in a lexical order. The default installation supplies the scripts .Pa 01-test , .Pa 02-dump , -.Pa 10-wpa_supplicant , -.Pa 15-timezone , .Pa 20-resolv.conf and .Pa 30-hostname . @@ -218,6 +216,19 @@ See for details on how these scripts work. .Nm currently ignores the exit code of the script. +.Pp +More scripts are supplied in +.Pa @DATADIR@/dhcpcd/hooks +and need to be copied to +.Pa @HOOKDIR@ +if you intend to use them. +For example, you could install +.Pa 10-wpa_supplicant +so that +.Nm +can ensure that +.Xr wpa_supplicant 8 +is always running on a hot-plugged wireless interface. .Ss Fine tuning You can fine-tune the behaviour of .Nm @@ -377,7 +388,8 @@ If is not running, then it starts up as normal. This may also cause .Xr wpa_supplicant 8 -to reload its configuration for each interface as well. +to reload its configuration for each interface as well if the +relevant hook script has been installed. .It Fl N , Fl Fl renew Op Ar interface Notifies .Nm @@ -391,8 +403,6 @@ Unlike the .Fl n , Fl Fl rebind option above, the configuration for .Nm -and -.Xr wpa_supplicant 8 is not reloaded. .It Fl o , Fl Fl option Ar option Request the DHCP