[OpenWrt-Devel] [PATCH 2/2] dnsmasq: fix dependency problems of the dnsmasq-full variant.
Yousong Zhou
yszhou4tech at gmail.com
Tue Dec 23 08:09:40 EST 2014
This patch tries to
- Let the DHCPv6 feature depend on CONFIG_IPV6.
- Conditionally select libnettle, kmod-ipv6, kmod-ipt-ipset only if the
corresponding features are enabled.
- Install `trust-anchors.conf` only if DNSSEC is selected.
Big thanks goes to Frank Schäfer <fschaefer.oss at googlemail.com> for
providing necessary information on connections and dependency relations
between these CONFIGs and packages.
Signed-off-by: Yousong Zhou <yszhou4tech at gmail.com>
---
package/network/services/dnsmasq/Makefile | 37 ++++++++++++++++-------------
1 file changed, 20 insertions(+), 17 deletions(-)
diff --git a/package/network/services/dnsmasq/Makefile b/package/network/services/dnsmasq/Makefile
index 1153428..02d4535 100644
--- a/package/network/services/dnsmasq/Makefile
+++ b/package/network/services/dnsmasq/Makefile
@@ -47,7 +47,7 @@ endef
define Package/dnsmasq-full
$(call Package/dnsmasq/Default)
TITLE += (with DNSSEC, DHCPv6, Auth DNS, IPSET)
- DEPENDS:=@IPV6 +kmod-ipv6 +libnettle
+ DEPENDS:=+PACKAGE_dnsmasq_full_dnssec:libnettle +PACKAGE_dnsmasq_full_dhcpv6:kmod-ipv6 +PACKAGE_dnsmasq_full_ipset:kmod-ipt-ipset
VARIANT:=full
endef
@@ -64,7 +64,8 @@ endef
define Package/dnsmasq-full/description
$(call Package/dnsmasq/description)
-This is a variant with DHCPv6, DNSSEC, Authroitative DNS and IPSET support
+This is a fully configurable variant with DHCPv6, DNSSEC, Authroitative DNS and
+IPSET support enabled by default.
endef
define Package/dnsmasq/conffiles
@@ -73,21 +74,21 @@ define Package/dnsmasq/conffiles
endef
define Package/dnsmasq/config/Default
- if PACKAGE_$(1)-$(2)
- config PACKAGE_dnsmasq_$(2)_dhcpv6
- bool "Build with DHCPv6 support."
- default y
- config PACKAGE_dnsmasq_$(2)_dnssec
- bool "Build with DNSSEC support."
- default y
- config PACKAGE_dnsmasq_$(2)_auth
- bool "Build with the facility to act as an authoritative DNS server."
- default y
- config PACKAGE_dnsmasq_$(2)_ipset
- bool "Build with ipset support."
- select PACKAGE_kmod-ipt-ipset
- default y
- endif
+ if PACKAGE_$(1)-$(2)
+ config PACKAGE_dnsmasq_$(2)_dhcpv6
+ bool "Build with DHCPv6 support."
+ depends on IPV6
+ default y
+ config PACKAGE_dnsmasq_$(2)_dnssec
+ bool "Build with DNSSEC support."
+ default y
+ config PACKAGE_dnsmasq_$(2)_auth
+ bool "Build with the facility to act as an authoritative DNS server."
+ default y
+ config PACKAGE_dnsmasq_$(2)_ipset
+ bool "Build with ipset support."
+ default y
+ endif
endef
Package/dnsmasq-full/config=$(call Package/dnsmasq/config/Default,dnsmasq,full)
@@ -137,8 +138,10 @@ Package/dnsmasq-dhcpv6/install = $(Package/dnsmasq/install)
define Package/dnsmasq-full/install
$(call Package/dnsmasq/install,$(1))
+ifneq ($(CONFIG_PACKAGE_dnsmasq_full_dnssec),)
$(INSTALL_DIR) $(1)/usr/share/dnsmasq
$(INSTALL_DATA) $(PKG_BUILD_DIR)/trust-anchors.conf $(1)/usr/share/dnsmasq
+endif
endef
$(eval $(call BuildPackage,dnsmasq))
--
1.7.10.4
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
More information about the openwrt-devel
mailing list