* [Buildroot] [PATCH 1/2] dhcp: Fix config files paths
@ 2014-08-04 18:19 Benoît Thébaudeau
2014-08-04 18:19 ` [Buildroot] [PATCH 2/2] dhcp: Fix IPv6 " Benoît Thébaudeau
2014-08-04 19:34 ` [Buildroot] [PATCH 1/2] dhcp: Fix config " Thomas Petazzoni
0 siblings, 2 replies; 3+ messages in thread
From: Benoît Thébaudeau @ 2014-08-04 18:19 UTC (permalink / raw)
To: buildroot
The built dhcp binaries and the installed startup scripts used configuration
files under /etc/, but the configuration files were installed under /etc/dhcp/.
Fix everything to have configuration files under /etc/dhcp/.
Signed-off-by: Beno?t Th?baudeau <benoit.thebaudeau@advansee.com>
---
package/dhcp/S80dhcp-server | 2 +-
package/dhcp/dhcp.mk | 5 ++++-
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/package/dhcp/S80dhcp-server b/package/dhcp/S80dhcp-server
index 98bd3cc..5280c31 100755
--- a/package/dhcp/S80dhcp-server
+++ b/package/dhcp/S80dhcp-server
@@ -9,7 +9,7 @@ INTERFACES=""
# Sanity checks
test -f /usr/sbin/dhcpd || exit 0
-test -f /etc/dhcpd.conf || exit 0
+test -f /etc/dhcp/dhcpd.conf || exit 0
test -n "$INTERFACES" || exit 0
case "$1" in
diff --git a/package/dhcp/dhcp.mk b/package/dhcp/dhcp.mk
index 1044f89..32dbea0 100644
--- a/package/dhcp/dhcp.mk
+++ b/package/dhcp/dhcp.mk
@@ -9,7 +9,10 @@ DHCP_SITE = http://ftp.isc.org/isc/dhcp/$(DHCP_VERSION)
DHCP_INSTALL_STAGING = YES
DHCP_LICENSE = ISC
DHCP_LICENSE_FILES = LICENSE
-DHCP_CONF_ENV = ac_cv_file__dev_random=yes
+DHCP_CONF_ENV = \
+ CPPFLAGS='-D_PATH_DHCPD_CONF=\"/etc/dhcp/dhcpd.conf\" \
+ -D_PATH_DHCLIENT_CONF=\"/etc/dhcp/dhclient.conf\"' \
+ ac_cv_file__dev_random=yes
DHCP_CONF_OPT = \
--localstatedir=/var/lib/dhcp \
--with-srv-lease-file=/var/lib/dhcp/dhcpd.leases \
--
1.9.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [Buildroot] [PATCH 2/2] dhcp: Fix IPv6 files paths
2014-08-04 18:19 [Buildroot] [PATCH 1/2] dhcp: Fix config files paths Benoît Thébaudeau
@ 2014-08-04 18:19 ` Benoît Thébaudeau
2014-08-04 19:34 ` [Buildroot] [PATCH 1/2] dhcp: Fix config " Thomas Petazzoni
1 sibling, 0 replies; 3+ messages in thread
From: Benoît Thébaudeau @ 2014-08-04 18:19 UTC (permalink / raw)
To: buildroot
Use IPv6 file locations consistent with those set for IPv4 instead of keeping
the defaults, which use different locations.
Signed-off-by: Beno?t Th?baudeau <benoit.thebaudeau@advansee.com>
---
package/dhcp/dhcp.mk | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/package/dhcp/dhcp.mk b/package/dhcp/dhcp.mk
index 32dbea0..464ed56 100644
--- a/package/dhcp/dhcp.mk
+++ b/package/dhcp/dhcp.mk
@@ -16,10 +16,15 @@ DHCP_CONF_ENV = \
DHCP_CONF_OPT = \
--localstatedir=/var/lib/dhcp \
--with-srv-lease-file=/var/lib/dhcp/dhcpd.leases \
+ --with-srv6-lease-file=/var/lib/dhcp/dhcpd6.leases \
--with-cli-lease-file=/var/lib/dhcp/dhclient.leases \
+ --with-cli6-lease-file=/var/lib/dhcp/dhclient6.leases \
--with-srv-pid-file=/var/run/dhcpd.pid \
+ --with-srv6-pid-file=/var/run/dhcpd6.pid \
--with-cli-pid-file=/var/run/dhclient.pid \
- --with-relay-pid-file=/var/run/dhcrelay.pid
+ --with-cli6-pid-file=/var/run/dhclient6.pid \
+ --with-relay-pid-file=/var/run/dhcrelay.pid \
+ --with-relay6-pid-file=/var/run/dhcrelay6.pid
ifeq ($(BR2_PACKAGE_DHCP_SERVER_DELAYED_ACK),y)
DHCP_CONF_OPT += --enable-delayed-ack
--
1.9.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [Buildroot] [PATCH 1/2] dhcp: Fix config files paths
2014-08-04 18:19 [Buildroot] [PATCH 1/2] dhcp: Fix config files paths Benoît Thébaudeau
2014-08-04 18:19 ` [Buildroot] [PATCH 2/2] dhcp: Fix IPv6 " Benoît Thébaudeau
@ 2014-08-04 19:34 ` Thomas Petazzoni
1 sibling, 0 replies; 3+ messages in thread
From: Thomas Petazzoni @ 2014-08-04 19:34 UTC (permalink / raw)
To: buildroot
Dear Beno?t Th?baudeau,
On Mon, 4 Aug 2014 20:19:03 +0200, Beno?t Th?baudeau wrote:
> The built dhcp binaries and the installed startup scripts used configuration
> files under /etc/, but the configuration files were installed under /etc/dhcp/.
> Fix everything to have configuration files under /etc/dhcp/.
>
> Signed-off-by: Beno?t Th?baudeau <benoit.thebaudeau@advansee.com>
> ---
> package/dhcp/S80dhcp-server | 2 +-
> package/dhcp/dhcp.mk | 5 ++++-
> 2 files changed, 5 insertions(+), 2 deletions(-)
Both patches applied, thanks.
As Gustavo rightfully pointed out, it would be nice to be able to
define the value of INTERFACES without modifying the init script
itself, for example using a /etc/default/dhcpd file. But this needs to
be part of a more global work on our initscripts and skeleton.
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-08-04 19:34 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-08-04 18:19 [Buildroot] [PATCH 1/2] dhcp: Fix config files paths Benoît Thébaudeau
2014-08-04 18:19 ` [Buildroot] [PATCH 2/2] dhcp: Fix IPv6 " Benoît Thébaudeau
2014-08-04 19:34 ` [Buildroot] [PATCH 1/2] dhcp: Fix config " Thomas Petazzoni
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox