All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/8] log4cplus: move meta-oe pkg to core
@ 2020-09-01 15:22 akuster
  2020-09-01 15:22 ` [PATCH 2/8] kea: Move from meta-networking akuster
                   ` (7 more replies)
  0 siblings, 8 replies; 24+ messages in thread
From: akuster @ 2020-09-01 15:22 UTC (permalink / raw)
  To: openembedded-core

pkg need for kea

Signed-off-by: Armin Kuster <akuster808@gmail.com>
---
 .../log4cplus/log4cplus_2.0.5.bb              | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)
 create mode 100644 meta/recipes-devtools/log4cplus/log4cplus_2.0.5.bb

diff --git a/meta/recipes-devtools/log4cplus/log4cplus_2.0.5.bb b/meta/recipes-devtools/log4cplus/log4cplus_2.0.5.bb
new file mode 100644
index 00000000000..967ac7623a3
--- /dev/null
+++ b/meta/recipes-devtools/log4cplus/log4cplus_2.0.5.bb
@@ -0,0 +1,19 @@
+SUMMARY = "log4cplus provides a simple C++ logging API for log management"
+SECTION = "libs"
+HOMEPAGE = "http://sourceforge.net/projects/log4cplus/"
+BUGTRACKER = "http://sourceforge.net/p/log4cplus/bugs/"
+
+LICENSE = "Apache-2.0 & BSD-2-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=41e8e060c26822886b592ab4765c756b"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/project/${BPN}/${BPN}-stable/${PV}/${BP}.tar.gz \
+          "
+SRC_URI[md5sum] = "71dd956bf686195127559671f1426cff"
+SRC_URI[sha256sum] = "c07115c23219390633798def30b7b51a0f79fdeb857e4b49632f17746d0ceb97"
+
+UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/log4cplus/files/log4cplus-stable/"
+UPSTREAM_CHECK_REGEX = "log4cplus-stable/(?P<pver>\d+(\.\d+)+)/"
+
+inherit autotools pkgconfig
+
+BBCLASSEXTEND = "native"
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [PATCH 2/8] kea: Move from meta-networking
  2020-09-01 15:22 [PATCH 1/8] log4cplus: move meta-oe pkg to core akuster
@ 2020-09-01 15:22 ` akuster
  2020-09-01 15:22 ` [PATCH 3/8] maintainers.inc: Add me as kea & log4plus maintainer akuster
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 24+ messages in thread
From: akuster @ 2020-09-01 15:22 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Armin Kuster <akuster808@gmail.com>
---
 .../kea/files/0001-remove-AC_TRY_RUN.patch    | 34 ++++++++++
 .../kea/files/kea-dhcp-ddns.service           | 13 ++++
 .../kea/files/kea-dhcp4.service               | 13 ++++
 .../kea/files/kea-dhcp6.service               | 13 ++++
 meta/recipes-connectivity/kea/kea_1.7.7.bb    | 67 +++++++++++++++++++
 5 files changed, 140 insertions(+)
 create mode 100644 meta/recipes-connectivity/kea/files/0001-remove-AC_TRY_RUN.patch
 create mode 100644 meta/recipes-connectivity/kea/files/kea-dhcp-ddns.service
 create mode 100644 meta/recipes-connectivity/kea/files/kea-dhcp4.service
 create mode 100644 meta/recipes-connectivity/kea/files/kea-dhcp6.service
 create mode 100644 meta/recipes-connectivity/kea/kea_1.7.7.bb

diff --git a/meta/recipes-connectivity/kea/files/0001-remove-AC_TRY_RUN.patch b/meta/recipes-connectivity/kea/files/0001-remove-AC_TRY_RUN.patch
new file mode 100644
index 00000000000..d7ca9ff8fa5
--- /dev/null
+++ b/meta/recipes-connectivity/kea/files/0001-remove-AC_TRY_RUN.patch
@@ -0,0 +1,34 @@
+From 9d6b8321c5b46199baca907f3d42bdcaaf1958a8 Mon Sep 17 00:00:00 2001
+From: Mingli Yu <mingli.yu@windriver.com>
+Date: Thu, 23 May 2019 23:59:42 -0700
+Subject: [PATCH] remove AC_TRY_RUN
+
+AC_TRY_RUN doesn't work in cross compile env,
+use AC_COMPILE_IFELSE instead to fix below configure
+error:
+ | checking for usuable C++11 regex... configure: error: in `/builddir/tmp/work/core2-64-poky-linux/kea/1.5.0-r0/build':
+ | configure: error: cannot run test program while cross compiling
+
+Upstream-Status: Inappropriate [oe specific]
+
+Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index c880b77..dd40c7c 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -580,7 +580,7 @@ AC_TRY_COMPILE([
+         AC_MSG_RESULT(no))
+ 
+ AC_MSG_CHECKING(for usuable C++11 regex)
+-AC_TRY_RUN([
++AC_COMPILE_IFELSE([
+ #include <regex>
+ #include <iostream>
+ int main() {
+-- 
+2.21.0
+
diff --git a/meta/recipes-connectivity/kea/files/kea-dhcp-ddns.service b/meta/recipes-connectivity/kea/files/kea-dhcp-ddns.service
new file mode 100644
index 00000000000..91aa2eb14f0
--- /dev/null
+++ b/meta/recipes-connectivity/kea/files/kea-dhcp-ddns.service
@@ -0,0 +1,13 @@
+[Unit]
+Description=Kea DHCP-DDNS Server
+Wants=network-online.target
+After=network-online.target
+After=time-sync.target
+
+[Service]
+ExecStartPre=@BASE_BINDIR@/mkdir -p @LOCALSTATEDIR@/run/kea/
+ExecStartPre=@BASE_BINDIR@/mkdir -p @LOCALSTATEDIR@/kea
+ExecStart=@SBINDIR@/kea-dhcp-ddns -c @SYSCONFDIR@/kea/kea-dhcp-ddns.conf
+
+[Install]
+WantedBy=multi-user.target
diff --git a/meta/recipes-connectivity/kea/files/kea-dhcp4.service b/meta/recipes-connectivity/kea/files/kea-dhcp4.service
new file mode 100644
index 00000000000..b851ea71c53
--- /dev/null
+++ b/meta/recipes-connectivity/kea/files/kea-dhcp4.service
@@ -0,0 +1,13 @@
+[Unit]
+Description=Kea DHCPv4 Server
+Wants=network-online.target
+After=network-online.target
+After=time-sync.target
+
+[Service]
+ExecStartPre=@BASE_BINDIR@/mkdir -p @LOCALSTATEDIR@/run/kea/
+ExecStartPre=@BASE_BINDIR@/mkdir -p @LOCALSTATEDIR@/lib/kea
+ExecStart=@SBINDIR@/kea-dhcp4 -c @SYSCONFDIR@/kea/kea-dhcp4.conf
+
+[Install]
+WantedBy=multi-user.target
diff --git a/meta/recipes-connectivity/kea/files/kea-dhcp6.service b/meta/recipes-connectivity/kea/files/kea-dhcp6.service
new file mode 100644
index 00000000000..0f9f0ef8d98
--- /dev/null
+++ b/meta/recipes-connectivity/kea/files/kea-dhcp6.service
@@ -0,0 +1,13 @@
+[Unit]
+Description=Kea DHCPv6 Server
+Wants=network-online.target
+After=network-online.target
+After=time-sync.target
+
+[Service]
+ExecStartPre=@BASE_BINDIR@/mkdir -p @LOCALSTATEDIR@/run/kea/
+ExecStartPre=@BASE_BINDIR@/mkdir -p @LOCALSTATEDIR@/lib/kea
+ExecStart=@SBINDIR@/kea-dhcp6 -c @SYSCONFDIR@/kea/kea-dhcp6.conf
+
+[Install]
+WantedBy=multi-user.target
diff --git a/meta/recipes-connectivity/kea/kea_1.7.7.bb b/meta/recipes-connectivity/kea/kea_1.7.7.bb
new file mode 100644
index 00000000000..e25f8e6fb0b
--- /dev/null
+++ b/meta/recipes-connectivity/kea/kea_1.7.7.bb
@@ -0,0 +1,67 @@
+SUMMARY = "ISC Kea DHCP Server"
+DESCRIPTION = "Kea is the next generation of DHCP software developed by ISC. It supports both DHCPv4 and DHCPv6 protocols along with their extensions, e.g. prefix delegation and dynamic updates to DNS."
+HOMEPAGE = "http://kea.isc.org"
+SECTION = "connectivity"
+LICENSE = "MPL-2.0 & Apache-2.0"
+LIC_FILES_CHKSUM = "file://COPYING;md5=68d95543d2096459290a4e6b9ceccffa"
+
+DEPENDS += "kea-native"
+
+SRC_URI = "\
+    http://ftp.isc.org/isc/kea/${PV}/${BP}.tar.gz \
+    file://0001-remove-AC_TRY_RUN.patch \
+    file://kea-dhcp4.service \
+    file://kea-dhcp6.service \
+    file://kea-dhcp-ddns.service \
+"
+SRC_URI[md5sum] = "4f8d1251fd41ef2e822a4eb3f0797d46"
+SRC_URI[sha256sum] = "0bba8b045672884a928ff4b2a8575ac5ba420eb6ba47a9338f1932bc38dcf866"
+
+inherit autotools systemd
+
+SYSTEMD_SERVICE_${PN} = "kea-dhcp4.service kea-dhcp6.service kea-dhcp-ddns.service"
+SYSTEMD_AUTO_ENABLE = "disable"
+
+DEBUG_OPTIMIZATION_remove_mips = " -Og"
+DEBUG_OPTIMIZATION_append_mips = " -O"
+BUILD_OPTIMIZATION_remove_mips = " -Og"
+BUILD_OPTIMIZATION_append_mips = " -O"
+
+DEBUG_OPTIMIZATION_remove_mipsel = " -Og"
+DEBUG_OPTIMIZATION_append_mipsel = " -O"
+BUILD_OPTIMIZATION_remove_mipsel = " -Og"
+BUILD_OPTIMIZATION_append_mipsel = " -O"
+
+do_configure_prepend_class-target() {
+    mkdir -p ${B}/src/lib/log/compiler/
+    ln -sf ${STAGING_BINDIR_NATIVE}/kea-msg-compiler ${B}/src/lib/log/compiler/kea-msg-compiler
+    # replace abs_top_builddir to avoid introducing the build path
+    # don't expand the abs_top_builddir on the target as the abs_top_builddir is meanlingless on the target
+    find ${S} -type f -name *.sh.in | xargs sed -i  "s:@abs_top_builddir@:@abs_top_builddir_placeholder@:g"
+    sed -i "s:@abs_top_srcdir@:@abs_top_srcdir_placeholder@:g" ${S}/src/bin/admin/kea-admin.in
+}
+
+do_install_append_class-target() {
+    install -d ${D}${systemd_system_unitdir}
+    install -m 0644 ${WORKDIR}/kea-dhcp*service ${D}${systemd_system_unitdir}
+    sed -i -e 's,@SBINDIR@,${sbindir},g' -e 's,@BASE_BINDIR@,${base_bindir},g' \
+           -e 's,@LOCALSTATEDIR@,${localstatedir},g' -e 's,@SYSCONFDIR@,${sysconfdir},g' \
+           ${D}${systemd_system_unitdir}/kea-dhcp*service
+}
+
+do_install_append() {
+    rm -rf "${D}${localstatedir}"
+}
+
+PACKAGECONFIG ??= "openssl log4cplus boost"
+
+PACKAGECONFIG[openssl] = "--with-openssl=${STAGING_DIR_TARGET}${prefix},,openssl,openssl"
+PACKAGECONFIG[log4cplus] = "--with-log4cplus=${STAGING_DIR_TARGET}${prefix},,log4cplus,log4cplus"
+PACKAGECONFIG[boost] = "--with-boost-libs=-lboost_system,,boost,boost"
+
+FILES_${PN}-staticdev += "${libdir}/kea/hooks/*.a ${libdir}/hooks/*.a"
+FILES_${PN} += "${libdir}/hooks/*.so"
+
+BBCLASSEXTEND += "native"
+
+PARALLEL_MAKEINST = ""
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [PATCH 3/8] maintainers.inc: Add me as kea & log4plus maintainer.
  2020-09-01 15:22 [PATCH 1/8] log4cplus: move meta-oe pkg to core akuster
  2020-09-01 15:22 ` [PATCH 2/8] kea: Move from meta-networking akuster
@ 2020-09-01 15:22 ` akuster
  2020-09-01 15:22 ` [PATCH 4/8] dhcpd: move from meta-network need a client akuster
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 24+ messages in thread
From: akuster @ 2020-09-01 15:22 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Armin Kuster <akuster808@gmail.com>
---
 meta/conf/distro/include/maintainers.inc | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/meta/conf/distro/include/maintainers.inc b/meta/conf/distro/include/maintainers.inc
index c3a1f273328..b83be2c5f9e 100644
--- a/meta/conf/distro/include/maintainers.inc
+++ b/meta/conf/distro/include/maintainers.inc
@@ -287,6 +287,7 @@ RECIPE_MAINTAINER_pn-json-c = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-json-glib = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-jquery = "Joshua Watt <JPEWhacker@gmail.com>"
 RECIPE_MAINTAINER_pn-kbd = "Alexander Kanavin <alex.kanavin@gmail.com>"
+RECIPE_MAINTAINER_pn-kea = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-kern-tools-native = "Bruce Ashfield <bruce.ashfield@gmail.com>"
 RECIPE_MAINTAINER_pn-kernel-devsrc = "Bruce Ashfield <bruce.ashfield@gmail.com>"
 RECIPE_MAINTAINER_pn-kexec-tools = "Armin Kuster <akuster808@gmail.com>"
@@ -450,6 +451,7 @@ RECIPE_MAINTAINER_pn-linux-yocto-rt = "Bruce Ashfield <bruce.ashfield@gmail.com>
 RECIPE_MAINTAINER_pn-linux-yocto-tiny = "Bruce Ashfield <bruce.ashfield@gmail.com>"
 RECIPE_MAINTAINER_pn-llvm = "Khem Raj <raj.khem@gmail.com>"
 RECIPE_MAINTAINER_pn-logrotate = "Yi Zhao <yi.zhao@windriver.com>"
+RECIPE_MAINTAINER_pn-log4cplus = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-lrzsz = "Anuj Mittal <anuj.mittal@intel.com>"
 RECIPE_MAINTAINER_pn-lsb-release = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-lsof = "Ross Burton <ross.burton@arm.com>"
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [PATCH 4/8] dhcpd: move from meta-network need a client
  2020-09-01 15:22 [PATCH 1/8] log4cplus: move meta-oe pkg to core akuster
  2020-09-01 15:22 ` [PATCH 2/8] kea: Move from meta-networking akuster
  2020-09-01 15:22 ` [PATCH 3/8] maintainers.inc: Add me as kea & log4plus maintainer akuster
@ 2020-09-01 15:22 ` akuster
  2020-09-02  1:38   ` [OE-core] " Chen Qi
  2020-09-01 15:22 ` [PATCH 5/8] maintainers.inc: Add me as dhcpd maintainer akuster
                   ` (4 subsequent siblings)
  7 siblings, 1 reply; 24+ messages in thread
From: akuster @ 2020-09-01 15:22 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Armin Kuster <akuster808@gmail.com>
---
 .../dhcpcd/dhcpcd_9.1.4.bb                    | 28 ++++++++++++
 ...e-INCLUDEDIR-to-prevent-build-issues.patch | 45 +++++++++++++++++++
 2 files changed, 73 insertions(+)
 create mode 100644 meta/recipes-connectivity/dhcpcd/dhcpcd_9.1.4.bb
 create mode 100644 meta/recipes-connectivity/dhcpcd/files/0001-remove-INCLUDEDIR-to-prevent-build-issues.patch

diff --git a/meta/recipes-connectivity/dhcpcd/dhcpcd_9.1.4.bb b/meta/recipes-connectivity/dhcpcd/dhcpcd_9.1.4.bb
new file mode 100644
index 00000000000..defd3420f02
--- /dev/null
+++ b/meta/recipes-connectivity/dhcpcd/dhcpcd_9.1.4.bb
@@ -0,0 +1,28 @@
+SECTION = "console/network"
+SUMMARY = "dhcpcd - a DHCP client"
+DESCRIPTION = "dhcpcd runs on your machine and silently configures your \
+               computer to work on the attached networks without trouble \
+               and mostly without configuration."
+
+HOMEPAGE = "http://roy.marples.name/projects/dhcpcd/"
+
+LICENSE = "BSD-2-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=9674cc803c5d71306941e6e8b5c002f2"
+
+UPSTREAM_CHECK_URI = "https://roy.marples.name/downloads/dhcpcd/"
+
+SRC_URI = "http://roy.marples.name/downloads/${BPN}/${BPN}-${PV}.tar.xz \
+           file://0001-remove-INCLUDEDIR-to-prevent-build-issues.patch"
+
+SRC_URI[sha256sum] = "5fe133e5497d8af6d26bd6e6b8dd48ab12d124d6cc4cefe6de6536ff97f76820"
+
+inherit pkgconfig autotools-brokensep
+
+PACKAGECONFIG ?= "udev ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}"
+
+PACKAGECONFIG[udev] = "--with-udev,--without-udev,udev,udev"
+PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6"
+
+EXTRA_OECONF = "--enable-ipv4"
+
+FILES_${PN}-dbg += "${libdir}/dhcpcd/dev/.debug"
diff --git a/meta/recipes-connectivity/dhcpcd/files/0001-remove-INCLUDEDIR-to-prevent-build-issues.patch b/meta/recipes-connectivity/dhcpcd/files/0001-remove-INCLUDEDIR-to-prevent-build-issues.patch
new file mode 100644
index 00000000000..37d2344438a
--- /dev/null
+++ b/meta/recipes-connectivity/dhcpcd/files/0001-remove-INCLUDEDIR-to-prevent-build-issues.patch
@@ -0,0 +1,45 @@
+From aa9e3982c1e75ad49945a62f5e262279c7a905a4 Mon Sep 17 00:00:00 2001
+From: Stefano Cappa <stefano.cappa.ks89@gmail.com>
+Date: Sun, 13 Jan 2019 01:50:52 +0100
+Subject: [PATCH] remove INCLUDEDIR to prevent build issues
+
+Upstream-Status: Pending
+
+Signed-off-by: Stefano Cappa <stefano.cappa.ks89@gmail.com>
+---
+ configure | 5 -----
+ 1 file changed, 5 deletions(-)
+
+diff --git a/configure b/configure
+index 6c81e0db..32dea2b4 100755
+--- a/configure
++++ b/configure
+@@ -20,7 +20,6 @@ BUILD=
+ HOST=
+ HOSTCC=
+ TARGET=
+-INCLUDEDIR=
+ DEBUG=
+ FORK=
+ STATIC=
+@@ -72,7 +71,6 @@ for x do
+ 	--mandir) MANDIR=$var;;
+ 	--datadir) DATADIR=$var;;
+ 	--with-ccopts|CFLAGS) CFLAGS=$var;;
+-	-I|--includedir) INCLUDEDIR="$INCLUDEDIR${INCLUDEDIR:+ }-I$var";;
+ 	CC) CC=$var;;
+ 	CPPFLAGS) CPPFLAGS=$var;;
+ 	PKG_CONFIG) PKG_CONFIG=$var;;
+@@ -309,9 +307,6 @@ if [ -n "$CPPFLAGS" ]; then
+ 	echo "CPPFLAGS=" >>$CONFIG_MK
+ 	echo "CPPFLAGS+=	$CPPFLAGS" >>$CONFIG_MK
+ fi
+-if [ -n "$INCLUDEDIR" ]; then
+-	echo "CPPFLAGS+=	$INCLUDEDIR" >>$CONFIG_MK
+-fi
+ if [ -n "$LDFLAGS" ]; then
+ 	echo "LDFLAGS=" >>$CONFIG_MK
+ 	echo "LDFLAGS+=	$LDFLAGS" >>$CONFIG_MK
+-- 
+2.17.2 (Apple Git-113)
+
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [PATCH 5/8] maintainers.inc: Add me as dhcpd maintainer
  2020-09-01 15:22 [PATCH 1/8] log4cplus: move meta-oe pkg to core akuster
                   ` (2 preceding siblings ...)
  2020-09-01 15:22 ` [PATCH 4/8] dhcpd: move from meta-network need a client akuster
@ 2020-09-01 15:22 ` akuster
  2020-09-01 15:22 ` [PATCH 6/8] dhcp: remove from core akuster
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 24+ messages in thread
From: akuster @ 2020-09-01 15:22 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Armin Kuster <akuster808@gmail.com>
---
 meta/conf/distro/include/maintainers.inc | 1 +
 1 file changed, 1 insertion(+)

diff --git a/meta/conf/distro/include/maintainers.inc b/meta/conf/distro/include/maintainers.inc
index b83be2c5f9e..27e3474da8b 100644
--- a/meta/conf/distro/include/maintainers.inc
+++ b/meta/conf/distro/include/maintainers.inc
@@ -144,6 +144,7 @@ RECIPE_MAINTAINER_pn-dejagnu = "Nathan Rossi <nathan@nathanrossi.com>"
 RECIPE_MAINTAINER_pn-depmodwrapper-cross = "Unassigned <unassigned@yoctoproject.org>"
 RECIPE_MAINTAINER_pn-desktop-file-utils = "Alexander Kanavin <alex.kanavin@gmail.com>"
 RECIPE_MAINTAINER_pn-dhcp = "Hongxu Jia <hongxu.jia@windriver.com>"
+RECIPE_MAINTAINER_pn-dhcpd = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-diffoscope = "Joshua Watt <JPEWhacker@gmail.com>"
 RECIPE_MAINTAINER_pn-diffstat = "Chen Qi <Qi.Chen@windriver.com>"
 RECIPE_MAINTAINER_pn-diffutils = "Chen Qi <Qi.Chen@windriver.com>"
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [PATCH 6/8] dhcp: remove from core
  2020-09-01 15:22 [PATCH 1/8] log4cplus: move meta-oe pkg to core akuster
                   ` (3 preceding siblings ...)
  2020-09-01 15:22 ` [PATCH 5/8] maintainers.inc: Add me as dhcpd maintainer akuster
@ 2020-09-01 15:22 ` akuster
  2020-09-01 18:10   ` [OE-core] " Khem Raj
  2020-10-21  1:34   ` Paul Eggleton
  2020-09-01 15:22 ` [PATCH 7/8] bind: Add 9.16.x akuster
                   ` (2 subsequent siblings)
  7 siblings, 2 replies; 24+ messages in thread
From: akuster @ 2020-09-01 15:22 UTC (permalink / raw)
  To: openembedded-core

update maintainers.inc too

Signed-off-by: Armin Kuster <akuster808@gmail.com>
---
 meta/conf/distro/include/maintainers.inc      |   1 -
 meta/recipes-connectivity/dhcp/dhcp.inc       | 149 ------------------
 ...TH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch |  27 ----
 ...-limitation-in-linux-dhclient-script.patch |  65 --------
 .../dhcp/dhcp/0002-dhclient-dbus.patch        | 117 --------------
 .../dhcp/dhcp/0003-link-with-lcrypto.patch    |  35 ----
 .../dhcp/0004-Fix-out-of-tree-builds.patch    |  95 -----------
 ...invoke-dhclient-script-failed-on-Rea.patch |  36 -----
 ...gument-to-make-the-libxml2-dependenc.patch |  62 --------
 ...move-dhclient-script-bash-dependency.patch |  28 ----
 ...ct-the-intention-for-xml2-lib-search.patch |  34 ----
 .../dhcp/dhcp/0013-fixup_use_libbind.patch    |  64 --------
 meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb  |  23 ---
 .../dhcp/files/default-relay                  |  12 --
 .../dhcp/files/default-server                 |   7 -
 .../dhcp/files/dhclient-systemd-wrapper       |  39 -----
 .../dhcp/files/dhclient.conf                  |  50 ------
 .../dhcp/files/dhclient.service               |  13 --
 .../dhcp/files/dhcpd.conf                     | 108 -------------
 .../dhcp/files/dhcpd.service                  |  15 --
 .../dhcp/files/dhcpd6.service                 |  15 --
 .../dhcp/files/dhcrelay.service               |  10 --
 .../dhcp/files/init-relay                     |  44 ------
 .../dhcp/files/init-server                    |  44 ------
 24 files changed, 1093 deletions(-)
 delete mode 100644 meta/recipes-connectivity/dhcp/dhcp.inc
 delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch
 delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0001-workaround-busybox-limitation-in-linux-dhclient-script.patch
 delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch
 delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch
 delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch
 delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch
 delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch
 delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0009-remove-dhclient-script-bash-dependency.patch
 delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch
 delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch
 delete mode 100644 meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb
 delete mode 100644 meta/recipes-connectivity/dhcp/files/default-relay
 delete mode 100644 meta/recipes-connectivity/dhcp/files/default-server
 delete mode 100644 meta/recipes-connectivity/dhcp/files/dhclient-systemd-wrapper
 delete mode 100644 meta/recipes-connectivity/dhcp/files/dhclient.conf
 delete mode 100644 meta/recipes-connectivity/dhcp/files/dhclient.service
 delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcpd.conf
 delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcpd.service
 delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcpd6.service
 delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcrelay.service
 delete mode 100644 meta/recipes-connectivity/dhcp/files/init-relay
 delete mode 100644 meta/recipes-connectivity/dhcp/files/init-server

diff --git a/meta/conf/distro/include/maintainers.inc b/meta/conf/distro/include/maintainers.inc
index 27e3474da8b..a55dbfa13c9 100644
--- a/meta/conf/distro/include/maintainers.inc
+++ b/meta/conf/distro/include/maintainers.inc
@@ -143,7 +143,6 @@ RECIPE_MAINTAINER_pn-debianutils = "Yi Zhao <yi.zhao@windriver.com>"
 RECIPE_MAINTAINER_pn-dejagnu = "Nathan Rossi <nathan@nathanrossi.com>"
 RECIPE_MAINTAINER_pn-depmodwrapper-cross = "Unassigned <unassigned@yoctoproject.org>"
 RECIPE_MAINTAINER_pn-desktop-file-utils = "Alexander Kanavin <alex.kanavin@gmail.com>"
-RECIPE_MAINTAINER_pn-dhcp = "Hongxu Jia <hongxu.jia@windriver.com>"
 RECIPE_MAINTAINER_pn-dhcpd = "Armin Kuster <akuster808@gmail.com>"
 RECIPE_MAINTAINER_pn-diffoscope = "Joshua Watt <JPEWhacker@gmail.com>"
 RECIPE_MAINTAINER_pn-diffstat = "Chen Qi <Qi.Chen@windriver.com>"
diff --git a/meta/recipes-connectivity/dhcp/dhcp.inc b/meta/recipes-connectivity/dhcp/dhcp.inc
deleted file mode 100644
index d46130d49b9..00000000000
--- a/meta/recipes-connectivity/dhcp/dhcp.inc
+++ /dev/null
@@ -1,149 +0,0 @@
-SECTION = "console/network"
-SUMMARY = "Internet Software Consortium DHCP package"
-DESCRIPTION = "DHCP (Dynamic Host Configuration Protocol) is a protocol \
-which allows individual devices on an IP network to get their own \
-network configuration information from a server.  DHCP helps make it \
-easier to administer devices."
-
-HOMEPAGE = "http://www.isc.org/"
-
-LICENSE = "ISC"
-LIC_FILES_CHKSUM = "file://LICENSE;beginline=4;md5=004a4db50a1e20972e924a8618747c01"
-
-DEPENDS = "openssl bind"
-
-SRC_URI = "http://ftp.isc.org/isc/dhcp/${PV}/dhcp-${PV}.tar.gz \
-           file://init-relay file://default-relay \
-           file://init-server file://default-server \
-           file://dhclient.conf file://dhcpd.conf \
-           file://dhclient-systemd-wrapper \
-           file://dhclient.service \
-           file://dhcpd.service file://dhcrelay.service \
-           file://dhcpd6.service \
-           "
-UPSTREAM_CHECK_URI = "http://ftp.isc.org/isc/dhcp/"
-UPSTREAM_CHECK_REGEX = "(?P<pver>\d+\.\d+\.(\d+?))/"
-
-inherit autotools-brokensep systemd useradd update-rc.d
-
-USERADD_PACKAGES = "${PN}-server"
-USERADD_PARAM_${PN}-server = "--system --no-create-home --home-dir /var/run/${BPN} --shell /bin/false --user-group ${BPN}"
-
-SYSTEMD_PACKAGES = "${PN}-server ${PN}-relay ${PN}-client"
-SYSTEMD_SERVICE_${PN}-server = "dhcpd.service dhcpd6.service"
-SYSTEMD_AUTO_ENABLE_${PN}-server = "disable"
-
-SYSTEMD_SERVICE_${PN}-relay = "dhcrelay.service"
-SYSTEMD_AUTO_ENABLE_${PN}-relay = "disable"
-
-SYSTEMD_SERVICE_${PN}-client = "dhclient.service"
-SYSTEMD_AUTO_ENABLE_${PN}-client = "disable"
-
-INITSCRIPT_PACKAGES = "dhcp-server"
-INITSCRIPT_NAME_dhcp-server = "dhcp-server"
-INITSCRIPT_PARAMS_dhcp-server = "defaults"
-
-CFLAGS += "-D_GNU_SOURCE"
-EXTRA_OECONF = "--with-srv-lease-file=${localstatedir}/lib/dhcp/dhcpd.leases \
-                --with-srv6-lease-file=${localstatedir}/lib/dhcp/dhcpd6.leases \
-                --with-cli-lease-file=${localstatedir}/lib/dhcp/dhclient.leases \
-                --with-cli6-lease-file=${localstatedir}/lib/dhcp/dhclient6.leases \
-                --enable-paranoia --disable-static \
-                --with-randomdev=/dev/random \
-                --with-libbind=${STAGING_DIR_HOST} \
-		--enable-libtool \
-               "
-
-#Enable shared libs per dhcp README
-do_configure_prepend () {
-	cp configure.ac+lt configure.ac
-}
-
-do_install_append () {
-	install -d ${D}${sysconfdir}/init.d
-	install -d ${D}${sysconfdir}/default
-	install -d ${D}${sysconfdir}/dhcp
-	install -m 0755 ${WORKDIR}/init-relay ${D}${sysconfdir}/init.d/dhcp-relay
-	install -m 0644 ${WORKDIR}/default-relay ${D}${sysconfdir}/default/dhcp-relay
-	install -m 0755 ${WORKDIR}/init-server ${D}${sysconfdir}/init.d/dhcp-server
-	install -m 0644 ${WORKDIR}/default-server ${D}${sysconfdir}/default/dhcp-server
-
-	rm -f ${D}${sysconfdir}/dhclient.conf*
-	rm -f ${D}${sysconfdir}/dhcpd.conf*
-	install -m 0644 ${WORKDIR}/dhclient.conf ${D}${sysconfdir}/dhcp/dhclient.conf
-	install -m 0644 ${WORKDIR}/dhcpd.conf ${D}${sysconfdir}/dhcp/dhcpd.conf
-
-	install -d ${D}${base_sbindir}/
-	if [ "${sbindir}" != "${base_sbindir}" ]; then
-		mv ${D}${sbindir}/dhclient ${D}${base_sbindir}/
-	fi
-	install -m 0755 ${S}/client/scripts/linux ${D}${base_sbindir}/dhclient-script
-
-	# Install systemd unit files
-	install -d ${D}${systemd_unitdir}/system
-	install -m 0644 ${WORKDIR}/dhcpd.service ${D}${systemd_unitdir}/system
-	install -m 0644 ${WORKDIR}/dhcpd6.service ${D}${systemd_unitdir}/system
-	install -m 0644 ${WORKDIR}/dhcrelay.service ${D}${systemd_unitdir}/system
-	sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/dhcpd*.service ${D}${systemd_unitdir}/system/dhcrelay.service
-	sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' ${D}${systemd_unitdir}/system/dhcpd*.service
-	sed -i -e 's,@base_bindir@,${base_bindir},g' ${D}${systemd_unitdir}/system/dhcpd*.service
-	sed -i -e 's,@localstatedir@,${localstatedir},g' ${D}${systemd_unitdir}/system/dhcpd*.service
-	sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' ${D}${systemd_unitdir}/system/dhcrelay.service
-
-	install -d ${D}${base_sbindir}
-	install -m 0755 ${WORKDIR}/dhclient-systemd-wrapper ${D}${base_sbindir}/dhclient-systemd-wrapper
-	install -m 0644 ${WORKDIR}/dhclient.service ${D}${systemd_unitdir}/system
-	sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' ${D}${systemd_unitdir}/system/dhclient.service
-	sed -i -e 's,@BASE_SBINDIR@,${base_sbindir},g' ${D}${systemd_unitdir}/system/dhclient.service
-}
-
-PACKAGES += "dhcp-libs dhcp-server dhcp-server-config dhcp-client dhcp-relay dhcp-omshell"
-
-PACKAGES_remove = "${PN}"
-RDEPENDS_${PN}-client += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'iproute2', '', d)}"
-RDEPENDS_${PN}-dev = ""
-RDEPENDS_${PN}-staticdev = ""
-FILES_${PN}-libs = "${libdir}/libdhcpctl.so.0* ${libdir}/libomapi.so.0* ${libdir}/libdhcp.so.0*"
-
-FILES_${PN}-server = "${sbindir}/dhcpd ${sysconfdir}/init.d/dhcp-server"
-RRECOMMENDS_${PN}-server = "dhcp-server-config"
-
-FILES_${PN}-server-config = "${sysconfdir}/default/dhcp-server ${sysconfdir}/dhcp/dhcpd.conf"
-
-FILES_${PN}-relay = "${sbindir}/dhcrelay ${sysconfdir}/init.d/dhcp-relay ${sysconfdir}/default/dhcp-relay"
-
-FILES_${PN}-client = "${base_sbindir}/dhclient \
-                      ${base_sbindir}/dhclient-script \
-                      ${sysconfdir}/dhcp/dhclient.conf \
-                      ${base_sbindir}/dhclient-systemd-wrapper \
-                     "
-
-FILES_${PN}-omshell = "${bindir}/omshell"
-
-pkg_postinst_dhcp-server() {
-    mkdir -p $D/${localstatedir}/lib/dhcp
-    touch $D/${localstatedir}/lib/dhcp/dhcpd.leases
-    touch $D/${localstatedir}/lib/dhcp/dhcpd6.leases
-}
-
-pkg_postinst_dhcp-client() {
-    mkdir -p $D/${localstatedir}/lib/dhcp
-}
-
-pkg_postrm_dhcp-server() {
-    rm -f $D/${localstatedir}/lib/dhcp/dhcpd.leases
-    rm -f $D/${localstatedir}/lib/dhcp/dhcpd6.leases
-
-    if ! rmdir $D/${localstatedir}/lib/dhcp 2>/dev/null; then
-        echo "Not removing ${localstatedir}/lib/dhcp as it is non-empty."
-    fi
-}
-
-pkg_postrm_dhcp-client() {
-    rm -f $D/${localstatedir}/lib/dhcp/dhclient.leases
-    rm -f $D/${localstatedir}/lib/dhcp/dhclient6.leases
-
-    if ! rmdir $D/${localstatedir}/lib/dhcp 2>/dev/null; then
-        echo "Not removing ${localstatedir}/lib/dhcp as it is non-empty."
-    fi
-}
diff --git a/meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch b/meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch
deleted file mode 100644
index d1b57f0bb41..00000000000
--- a/meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 7cc29144535a622fc671dc86eb1da65b0473a7c4 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Tue, 15 Aug 2017 16:14:22 +0800
-Subject: [PATCH 01/11] define macro _PATH_DHCPD_CONF and _PATH_DHCLIENT_CONF
-
-Upstream-Status: Inappropriate [OE specific]
-
-Rebase to 4.3.6
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- includes/site.h | 3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
-Index: dhcp-4.4.1/includes/site.h
-===================================================================
---- dhcp-4.4.1.orig/includes/site.h
-+++ dhcp-4.4.1/includes/site.h
-@@ -148,7 +148,8 @@
- /* Define this if you want the dhcpd.conf file to go somewhere other than
-    the default location.   By default, it goes in /etc/dhcpd.conf. */
- 
--/* #define _PATH_DHCPD_CONF	"/etc/dhcpd.conf" */
-+#define _PATH_DHCPD_CONF	"/etc/dhcp/dhcpd.conf"
-+#define _PATH_DHCLIENT_CONF	"/etc/dhcp/dhclient.conf"
- 
- /* Network API definitions.   You do not need to choose one of these - if
-    you don't choose, one will be chosen for you in your system's config
diff --git a/meta/recipes-connectivity/dhcp/dhcp/0001-workaround-busybox-limitation-in-linux-dhclient-script.patch b/meta/recipes-connectivity/dhcp/dhcp/0001-workaround-busybox-limitation-in-linux-dhclient-script.patch
deleted file mode 100644
index 2359381b938..00000000000
--- a/meta/recipes-connectivity/dhcp/dhcp/0001-workaround-busybox-limitation-in-linux-dhclient-script.patch
+++ /dev/null
@@ -1,65 +0,0 @@
-From eec0503cfc36f63d777f5cb3f2719cecedcb8468 Mon Sep 17 00:00:00 2001
-From: Haris Okanovic <haris.okanovic@ni.com>
-Date: Mon, 7 Jan 2019 13:22:09 -0600
-Subject: [PATCH] Workaround busybox limitation in Linux dhclient-script
-
-Busybox is a lightweight implementation of coreutils commonly used on
-space-constrained embedded Linux distributions. It's implementation of
-chown and chmod doesn't provide a "--reference" option added to
-client/scripts/linux as of commit 9261cb14. This change works around
-that limitation by using stat to read ownership and permissions flags
-and simple chown/chmod calls supported in both coreutils and busybox.
-
-    modified:   client/scripts/linux
-
-Signed-off-by: Haris Okanovic <haris.okanovic@ni.com>
-Upstream-Status: Pending [ISC-Bugs #48771]
----
- client/scripts/linux | 17 +++++++++++++----
- 1 file changed, 13 insertions(+), 4 deletions(-)
-
-diff --git a/client/scripts/linux b/client/scripts/linux
-index 0c429697..2435a44b 100755
---- a/client/scripts/linux
-+++ b/client/scripts/linux
-@@ -32,6 +32,17 @@
- # if your system holds ip tool in a non-standard location.
- ip=/sbin/ip
- 
-+chown_chmod_by_reference() {
-+    local reference_file="$1"
-+    local target_file="$2"
-+
-+    local owner=$(stat -c "%u:%g" "$reference_file")
-+    local perm=$(stat -c "%a" "$reference_file")
-+
-+    chown "$owner" "$target_file"
-+    chmod "$perm" "$target_file"
-+}
-+
- # update /etc/resolv.conf based on received values
- # This updated version mostly follows Debian script by Andrew Pollock et al.
- make_resolv_conf() {
-@@ -74,8 +85,7 @@ make_resolv_conf() {
-         fi
- 
- 	if [ -f /etc/resolv.conf ]; then
--	    chown --reference=/etc/resolv.conf $new_resolv_conf
--	    chmod --reference=/etc/resolv.conf $new_resolv_conf
-+	    chown_chmod_by_reference /etc/resolv.conf $new_resolv_conf
- 	fi
-         mv -f $new_resolv_conf /etc/resolv.conf
-     # DHCPv6
-@@ -101,8 +111,7 @@ make_resolv_conf() {
-         fi
- 
- 	if [ -f /etc/resolv.conf ]; then
--            chown --reference=/etc/resolv.conf $new_resolv_conf
--            chmod --reference=/etc/resolv.conf $new_resolv_conf
-+	    chown_chmod_by_reference /etc/resolv.conf $new_resolv_conf
- 	fi
-         mv -f $new_resolv_conf /etc/resolv.conf
-     fi
--- 
-2.20.0
-
diff --git a/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch b/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch
deleted file mode 100644
index 101c33f677a..00000000000
--- a/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch
+++ /dev/null
@@ -1,117 +0,0 @@
-From be7540d31c356e80ee02e90e8bf162b7ac6e5ba5 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Tue, 15 Aug 2017 14:56:56 +0800
-Subject: [PATCH 02/11] dhclient dbus
-
-Upstream-Status: Inappropriate [distribution]
-
-Rebase to 4.3.6
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- client/scripts/bsdos   | 5 +++++
- client/scripts/freebsd | 5 +++++
- client/scripts/linux   | 5 +++++
- client/scripts/netbsd  | 5 +++++
- client/scripts/openbsd | 5 +++++
- client/scripts/solaris | 5 +++++
- 6 files changed, 30 insertions(+)
-
-diff --git a/client/scripts/bsdos b/client/scripts/bsdos
-index d69d0d8..095b143 100755
---- a/client/scripts/bsdos
-+++ b/client/scripts/bsdos
-@@ -45,6 +45,11 @@ exit_with_hooks() {
-     . /etc/dhclient-exit-hooks
-   fi
- # probably should do something with exit status of the local script
-+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
-+    dbus-send --system --dest=com.redhat.dhcp \
-+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
-+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
-+  fi
-   exit $exit_status
- }
- 
-diff --git a/client/scripts/freebsd b/client/scripts/freebsd
-index 8f3e2a2..ad7fb44 100755
---- a/client/scripts/freebsd
-+++ b/client/scripts/freebsd
-@@ -89,6 +89,11 @@ exit_with_hooks() {
-     . /etc/dhclient-exit-hooks
-   fi
- # probably should do something with exit status of the local script
-+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
-+    dbus-send --system --dest=com.redhat.dhcp \
-+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
-+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
-+  fi
-   exit $exit_status
- }
- 
-diff --git a/client/scripts/linux b/client/scripts/linux
-index 5fb1612..3d447b6 100755
---- a/client/scripts/linux
-+++ b/client/scripts/linux
-@@ -174,6 +174,11 @@ exit_with_hooks() {
-         exit_status=$?
-     fi
- 
-+    if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
-+        dbus-send --system --dest=com.redhat.dhcp \
-+           --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
-+           'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
-+    fi
-     exit $exit_status
- }
- 
-diff --git a/client/scripts/netbsd b/client/scripts/netbsd
-index 07383b7..aaba8e8 100755
---- a/client/scripts/netbsd
-+++ b/client/scripts/netbsd
-@@ -45,6 +45,11 @@ exit_with_hooks() {
-     . /etc/dhclient-exit-hooks
-   fi
- # probably should do something with exit status of the local script
-+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
-+    dbus-send --system --dest=com.redhat.dhcp \
-+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
-+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
-+  fi
-   exit $exit_status
- }
- 
-diff --git a/client/scripts/openbsd b/client/scripts/openbsd
-index e7f4746..56b980c 100644
---- a/client/scripts/openbsd
-+++ b/client/scripts/openbsd
-@@ -45,6 +45,11 @@ exit_with_hooks() {
-     . /etc/dhclient-exit-hooks
-   fi
- # probably should do something with exit status of the local script
-+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
-+    dbus-send --system --dest=com.redhat.dhcp \
-+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
-+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
-+  fi
-   exit $exit_status
- }
- 
-diff --git a/client/scripts/solaris b/client/scripts/solaris
-index af553b9..4a2aa69 100755
---- a/client/scripts/solaris
-+++ b/client/scripts/solaris
-@@ -26,6 +26,11 @@ exit_with_hooks() {
-     . /etc/dhclient-exit-hooks
-   fi
- # probably should do something with exit status of the local script
-+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
-+    dbus-send --system --dest=com.redhat.dhcp \
-+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
-+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
-+  fi
-   exit $exit_status
- }
- 
--- 
-1.8.3.1
-
diff --git a/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch b/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch
deleted file mode 100644
index 5b35933a54a..00000000000
--- a/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From d80bd792323dbd56269309f85b4506eb6b1b60e9 Mon Sep 17 00:00:00 2001
-From: Andrei Gherzan <andrei@gherzan.ro>
-Date: Tue, 15 Aug 2017 15:05:47 +0800
-Subject: [PATCH 03/11] link with lcrypto
-
-From 4.2.0 final release, -lcrypto check was removed and we compile
-static libraries
-from bind that are linked to libcrypto. This is why i added a patch in
-order to add
--lcrypto to LIBS.
-
-Upstream-Status: Pending
-Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
-
-Rebase to 4.3.6
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- configure.ac | 4 ++++
- 1 file changed, 4 insertions(+)
-
-Index: dhcp-4.4.1/configure.ac
-===================================================================
---- dhcp-4.4.1.orig/configure.ac
-+++ dhcp-4.4.1/configure.ac
-@@ -612,6 +612,10 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]],
- # Look for optional headers.
- AC_CHECK_HEADERS(sys/socket.h net/if_dl.h net/if6.h regex.h)
- 
-+# find an MD5 library
-+AC_SEARCH_LIBS(MD5_Init, [crypto])
-+AC_SEARCH_LIBS(MD5Init, [crypto])
-+
- # Solaris needs some libraries for functions
- AC_SEARCH_LIBS(socket, [socket])
- AC_SEARCH_LIBS(inet_ntoa, [nsl])
diff --git a/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch b/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch
deleted file mode 100644
index 7b57730ffb7..00000000000
--- a/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch
+++ /dev/null
@@ -1,95 +0,0 @@
-From cccec0344d68dac4100b6f260ee24e7c2da9dfda Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Tue, 15 Aug 2017 15:08:22 +0800
-Subject: [PATCH 04/11] Fix out of tree builds
-
-Upstream-Status: Pending
-
-RP 2013/03/21
-
-Rebase to 4.3.6
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- client/Makefile.am  | 4 ++--
- common/Makefile.am  | 3 ++-
- dhcpctl/Makefile.am | 2 ++
- omapip/Makefile.am  | 1 +
- relay/Makefile.am   | 2 +-
- server/Makefile.am  | 2 +-
- 6 files changed, 9 insertions(+), 5 deletions(-)
-
-Index: dhcp-4.4.1/common/Makefile.am
-===================================================================
---- dhcp-4.4.1.orig/common/Makefile.am
-+++ dhcp-4.4.1/common/Makefile.am
-@@ -1,4 +1,5 @@
--AM_CPPFLAGS = -I$(top_srcdir) -DLOCALSTATEDIR='"@localstatedir@"'
-+AM_CPPFLAGS = -I$(top_srcdir)/includes -I$(top_srcdir) -DLOCALSTATEDIR='"@localstatedir@"'
-+
- AM_CFLAGS = $(LDAP_CFLAGS)
- 
- lib_LIBRARIES = libdhcp.a
-Index: dhcp-4.4.1/dhcpctl/Makefile.am
-===================================================================
---- dhcp-4.4.1.orig/dhcpctl/Makefile.am
-+++ dhcp-4.4.1/dhcpctl/Makefile.am
-@@ -3,6 +3,8 @@ BINDLIBDNSDIR=@BINDLIBDNSDIR@
- BINDLIBISCCFGDIR=@BINDLIBISCCFGDIR@
- BINDLIBISCDIR=@BINDLIBISCDIR@
- 
-+AM_CPPFLAGS = -I$(top_srcdir)/includes -I$(top_srcdir)
-+
- bin_PROGRAMS = omshell
- lib_LIBRARIES = libdhcpctl.a
- noinst_PROGRAMS = cltest
-Index: dhcp-4.4.1/server/Makefile.am
-===================================================================
---- dhcp-4.4.1.orig/server/Makefile.am
-+++ dhcp-4.4.1/server/Makefile.am
-@@ -4,7 +4,7 @@
- # production code. Sadly, we are not there yet.
- SUBDIRS = . tests
- 
--AM_CPPFLAGS = -I.. -DLOCALSTATEDIR='"@localstatedir@"'
-+AM_CPPFLAGS = -I$(top_srcdir) -DLOCALSTATEDIR='"@localstatedir@"' -I$(top_srcdir)/includes
- 
- dist_sysconf_DATA = dhcpd.conf.example
- sbin_PROGRAMS = dhcpd
-Index: dhcp-4.4.1/client/Makefile.am
-===================================================================
---- dhcp-4.4.1.orig/client/Makefile.am
-+++ dhcp-4.4.1/client/Makefile.am
-@@ -5,7 +5,7 @@
- SUBDIRS = . tests
- 
- AM_CPPFLAGS = -DCLIENT_PATH='"PATH=$(sbindir):/sbin:/bin:/usr/sbin:/usr/bin"'
--AM_CPPFLAGS += -DLOCALSTATEDIR='"$(localstatedir)"'
-+AM_CPPFLAGS += -DLOCALSTATEDIR='"$(localstatedir)"' -I$(top_srcdir)/includes
- 
- dist_sysconf_DATA = dhclient.conf.example
- sbin_PROGRAMS = dhclient
-Index: dhcp-4.4.1/omapip/Makefile.am
-===================================================================
---- dhcp-4.4.1.orig/omapip/Makefile.am
-+++ dhcp-4.4.1/omapip/Makefile.am
-@@ -2,6 +2,7 @@ BINDLIBIRSDIR=@BINDLIBIRSDIR@
- BINDLIBDNSDIR=@BINDLIBDNSDIR@
- BINDLIBISCCFGDIR=@BINDLIBISCCFGDIR@
- BINDLIBISCDIR=@BINDLIBISCDIR@
-+AM_CPPFLAGS = -I$(top_srcdir)/includes
- 
- lib_LIBRARIES = libomapi.a
- noinst_PROGRAMS = svtest
-Index: dhcp-4.4.1/relay/Makefile.am
-===================================================================
---- dhcp-4.4.1.orig/relay/Makefile.am
-+++ dhcp-4.4.1/relay/Makefile.am
-@@ -1,6 +1,6 @@
- SUBDIRS = . tests
-
--AM_CPPFLAGS = -DLOCALSTATEDIR='"@localstatedir@"'
-+AM_CPPFLAGS = -DLOCALSTATEDIR='"@localstatedir@"' -I$(top_srcdir)/includes
-
- sbin_PROGRAMS = dhcrelay
- dhcrelay_SOURCES = dhcrelay.c
diff --git a/meta/recipes-connectivity/dhcp/dhcp/0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch b/meta/recipes-connectivity/dhcp/dhcp/0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch
deleted file mode 100644
index dd56381b1dc..00000000000
--- a/meta/recipes-connectivity/dhcp/dhcp/0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From 2e8ff0e4f6d39e346ea86b8c514ab4ccc78fa359 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Tue, 15 Aug 2017 15:24:14 +0800
-Subject: [PATCH 05/11] dhcp-client: fix invoke dhclient-script failed on
- Read-only file system
-
-In read-only file system, '/etc' is on the readonly partition,
-and '/etc/resolv.conf' is symlinked to a separate writable
-partition.
-
-In this situation, we create temp files 'resolv.conf.dhclient-new'
-in /tmp dir.
-
-Upstream-Status: Pending
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- client/scripts/linux | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/client/scripts/linux b/client/scripts/linux
-index 3d447b6..3122a75 100755
---- a/client/scripts/linux
-+++ b/client/scripts/linux
-@@ -40,7 +40,7 @@ make_resolv_conf() {
-     # DHCPv4
-     if [ -n "$new_domain_search" ] || [ -n "$new_domain_name" ] ||
-        [ -n "$new_domain_name_servers" ]; then
--        new_resolv_conf=/etc/resolv.conf.dhclient-new
-+        new_resolv_conf=/tmp/resolv.conf.dhclient-new
-         rm -f $new_resolv_conf
- 
-         if [ -n "$new_domain_name" ]; then
--- 
-1.8.3.1
-
diff --git a/meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch b/meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch
deleted file mode 100644
index feb0754fff4..00000000000
--- a/meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch
+++ /dev/null
@@ -1,62 +0,0 @@
-From 7107511fd209f08f9a96f8938041ae48f3295895 Mon Sep 17 00:00:00 2001
-From: Christopher Larson <chris_larson@mentor.com>
-Date: Tue, 15 Aug 2017 16:17:49 +0800
-Subject: [PATCH 07/11] Add configure argument to make the libxml2 dependency
- explicit and determinisitic.
-
-Upstream-Status: Pending
-
-Signed-off-by: Christopher Larson <chris_larson@mentor.com>
-
-Rebase to 4.3.6
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- configure.ac | 11 +++++++++++
- 1 file changed, 11 insertions(+)
-
-Index: dhcp-4.4.1/configure.ac
-===================================================================
---- dhcp-4.4.1.orig/configure.ac
-+++ dhcp-4.4.1/configure.ac
-@@ -642,6 +642,17 @@ if test "$have_nanosleep" = "rt"; then
- 	LIBS="-lrt $LIBS"
- fi
- 
-+AC_ARG_WITH(libxml2,
-+	AS_HELP_STRING([--with-libxml2], [link against libxml2. this is needed if bind was built with xml2 support enabled]),
-+	with_libxml2="$withval", with_libxml2="no")
-+
-+if test x$with_libxml2 != xno; then
-+	AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],
-+		[if test x$with_libxml2 != xauto; then
-+			AC_MSG_FAILURE([*** Cannot find xmlTextWriterStartElement with -lxml2 and libxml2 was requested])
-+		fi])
-+fi
-+
- # check for /dev/random (declares HAVE_DEV_RANDOM)
- AC_MSG_CHECKING(for random device)
- AC_ARG_WITH(randomdev,
-Index: dhcp-4.4.1/configure.ac+lt
-===================================================================
---- dhcp-4.4.1.orig/configure.ac+lt
-+++ dhcp-4.4.1/configure.ac+lt
-@@ -909,6 +909,18 @@ elif test "$want_libtool" = "yes" -a "$u
- fi
- AM_CONDITIONAL(INSTALL_BIND, test "$want_install_bind" = "yes")
- 
-+AC_ARG_WITH(libxml2,
-+	AS_HELP_STRING([--with-libxml2], [link against libxml2. this is needed if bind was built with xml2 support enabled]),
-+	with_libxml2="$withval", with_libxml2="no")
-+
-+if test x$with_libxml2 != xno; then
-+	AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],,
-+		[if test x$with_libxml2 != xauto; then
-+			AC_MSG_FAILURE([*** Cannot find xmlTextWriterStartElement with -lxml2 and libxml2 was requested])
-+		fi])
-+fi
-+
-+
- # OpenLDAP support.
- AC_ARG_WITH(ldap,
-     AS_HELP_STRING([--with-ldap],[enable OpenLDAP support in dhcpd (default is no)]),
diff --git a/meta/recipes-connectivity/dhcp/dhcp/0009-remove-dhclient-script-bash-dependency.patch b/meta/recipes-connectivity/dhcp/dhcp/0009-remove-dhclient-script-bash-dependency.patch
deleted file mode 100644
index 912b6d6312c..00000000000
--- a/meta/recipes-connectivity/dhcp/dhcp/0009-remove-dhclient-script-bash-dependency.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From f3f8b7726e50e24ef3edf5fa5a17e31d39118d7e Mon Sep 17 00:00:00 2001
-From: Andre McCurdy <armccurdy@gmail.com>
-Date: Tue, 15 Aug 2017 15:49:31 +0800
-Subject: [PATCH 09/11] remove dhclient-script bash dependency
-
-Upstream-Status: Inappropriate [OE specific]
-
-Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
-
-Rebase to 4.3.6
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- client/scripts/linux | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/client/scripts/linux b/client/scripts/linux
-index 3122a75..1712d7d 100755
---- a/client/scripts/linux
-+++ b/client/scripts/linux
-@@ -1,4 +1,4 @@
--#!/bin/bash
-+#!/bin/sh
- # dhclient-script for Linux. Dan Halbert, March, 1997.
- # Updated for Linux 2.[12] by Brian J. Murrell, January 1999.
- # No guarantees about this. I'm a novice at the details of Linux
--- 
-1.8.3.1
-
diff --git a/meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch b/meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch
deleted file mode 100644
index 39ba65fbc46..00000000000
--- a/meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From 501543b3ef715488a142e3d301ff2733aa33eec7 Mon Sep 17 00:00:00 2001
-From: Awais Belal <awais_belal@mentor.com>
-Date: Wed, 25 Oct 2017 21:00:05 +0500
-Subject: [PATCH] dhcp: correct the intention for xml2 lib search
-
-A missing case breaks the build when libxml2 is
-required and found appropriately. The third argument
-to the function AC_SEARCH_LIB is action-if-found which
-was mistakenly been used for the case where the library
-is not found and hence breaks the configure phase
-where it shoud actually pass.
-We now pass on silently when action-if-found is
-executed.
-
-Upstream-Status: Pending
-
-Signed-off-by: Awais Belal <awais_belal@mentor.com>
----
- configure.ac | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-Index: dhcp-4.4.1/configure.ac
-===================================================================
---- dhcp-4.4.1.orig/configure.ac
-+++ dhcp-4.4.1/configure.ac
-@@ -647,7 +647,7 @@ AC_ARG_WITH(libxml2,
- 	with_libxml2="$withval", with_libxml2="no")
- 
- if test x$with_libxml2 != xno; then
--	AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],
-+	AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],,
- 		[if test x$with_libxml2 != xauto; then
- 			AC_MSG_FAILURE([*** Cannot find xmlTextWriterStartElement with -lxml2 and libxml2 was requested])
- 		fi])
diff --git a/meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch b/meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch
deleted file mode 100644
index fcec010bd01..00000000000
--- a/meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch
+++ /dev/null
@@ -1,64 +0,0 @@
-lib and include path is hardcoded for use_libbind 
-
-use libdir and includedir vars
-
-Upstream-Status: Pending
-Signed-off-by: Armin Kuster <akuster808@gmail.com>
-
-Index: dhcp-4.4.1/configure.ac+lt
-===================================================================
---- dhcp-4.4.1.orig/configure.ac+lt
-+++ dhcp-4.4.1/configure.ac+lt
-@@ -801,22 +801,22 @@ no)
- 	if test ! -d "$use_libbind"; then
- 		AC_MSG_ERROR([Cannot find bind directory at $use_libbind])
- 	fi
--	if test ! -d "$use_libbind/include" -o \
--	        ! -f "$use_libbind/include/isc/buffer.h"
-+	if test ! -d "$use_libbind/$includedir" -o \
-+	        ! -f "$use_libbind/$includedir/isc/buffer.h"
- 	then
--		AC_MSG_ERROR([Cannot find bind includes at $use_libbind/include])
-+		AC_MSG_ERROR([Cannot find bind includes at $use_libbind/$includedir])
- 	fi
--	if test	! -d "$use_libbind/lib" -o \
--	        \( ! -f "$use_libbind/lib/libisc.a" -a \
--		   ! -f	"$use_libbind/lib/libisc.la" \)
-+	if test	! -d "$use_libbind/$libdir" -o \
-+	        \( ! -f "$use_libbind/$libdir/libisc.a" -a \
-+		   ! -f	"$use_libbind/$libdir/libisc.la" \)
- 	then
--		AC_MSG_ERROR([Cannot find bind libraries at $use_libbind/lib])
-+		AC_MSG_ERROR([Cannot find bind libraries at $use_libbind/$libdir])
- 	fi
- 	BINDDIR="$use_libbind"
--	BINDLIBIRSDIR="$BINDDIR/lib"
--	BINDLIBDNSDIR="$BINDDIR/lib"
--	BINDLIBISCCFGDIR="$BINDDIR/lib"
--	BINDLIBISCDIR="$BINDDIR/lib"	
-+	BINDLIBIRSDIR="$BINDDIR/$libdir"
-+	BINDLIBDNSDIR="$BINDDIR/$libdir"
-+	BINDLIBISCCFGDIR="$BINDDIR/$libdir"
-+	BINDLIBISCDIR="$BINDDIR/$libdir"
- 	DISTCHECK_LIBBIND_CONFIGURE_FLAG="--with-libbind=$use_libbind"
- 	;;
- esac
-@@ -856,14 +856,14 @@ AC_ARG_ENABLE(libtool,
- 
- if test "$use_libbind" != "no"; then
- 	if test "$want_libtool" = "yes" -a \
--	        ! -f "$use_libbind/lib/libisc.la"
-+	        ! -f "$use_libbind/$libdir/libisc.la"
- 	then
--		AC_MSG_ERROR([Cannot find dynamic libraries at $use_libbind/lib])
-+		AC_MSG_ERROR([Cannot find dynamic libraries at $use_libbind/$libdir])
- 	fi
- 	if test "$want_libtool" = "no" -a \
--	        ! -f "$use_libbind/lib/libisc.a"
-+	        ! -f "$use_libbind/$libdir/libisc.a"
- 	then
--		AC_MSG_ERROR([Cannot find static libraries at $use_libbind/lib])
-+		AC_MSG_ERROR([Cannot find static libraries at $use_libbind/$libdir])
- 	fi
- fi
- 
diff --git a/meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb b/meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb
deleted file mode 100644
index cf4af826099..00000000000
--- a/meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb
+++ /dev/null
@@ -1,23 +0,0 @@
-require dhcp.inc
-
-SRC_URI += "file://0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch \
-            file://0002-dhclient-dbus.patch \
-            file://0003-link-with-lcrypto.patch \
-            file://0004-Fix-out-of-tree-builds.patch \
-            file://0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch \
-            file://0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch \
-            file://0009-remove-dhclient-script-bash-dependency.patch \
-            file://0012-dhcp-correct-the-intention-for-xml2-lib-search.patch \
-            file://0013-fixup_use_libbind.patch \
-            file://0001-workaround-busybox-limitation-in-linux-dhclient-script.patch \
-"
-
-SRC_URI[md5sum] = "2afdaf8498dc1edaf3012efdd589b3e1"
-SRC_URI[sha256sum] = "1a7ccd64a16e5e68f7b5e0f527fd07240a2892ea53fe245620f4f5f607004521"
-
-LDFLAGS_append = " -pthread"
-
-PACKAGECONFIG ?= ""
-PACKAGECONFIG[bind-httpstats] = "--with-libxml2,--without-libxml2,libxml2"
-
-CFLAGS += "-fcommon"
diff --git a/meta/recipes-connectivity/dhcp/files/default-relay b/meta/recipes-connectivity/dhcp/files/default-relay
deleted file mode 100644
index 7961f014bef..00000000000
--- a/meta/recipes-connectivity/dhcp/files/default-relay
+++ /dev/null
@@ -1,12 +0,0 @@
-# Defaults for dhcp-relay initscript
-# sourced by /etc/init.d/dhcp-relay
-
-# What servers should the DHCP relay forward requests to?
-# e.g: SERVERS="192.168.0.1"
-SERVERS=""
-
-# On what interfaces should the DHCP relay (dhrelay) serve DHCP requests?
-INTERFACES=""
-
-# Additional options that are passed to the DHCP relay daemon?
-OPTIONS=""
diff --git a/meta/recipes-connectivity/dhcp/files/default-server b/meta/recipes-connectivity/dhcp/files/default-server
deleted file mode 100644
index 0385d169922..00000000000
--- a/meta/recipes-connectivity/dhcp/files/default-server
+++ /dev/null
@@ -1,7 +0,0 @@
-# Defaults for dhcp initscript
-# sourced by /etc/init.d/dhcp-server
-# installed at /etc/default/dhcp-server by the maintainer scripts
-
-# On what interfaces should the DHCP server (dhcpd) serve DHCP requests?
-#       Separate multiple interfaces with spaces, e.g. "eth0 eth1".
-INTERFACES=""
diff --git a/meta/recipes-connectivity/dhcp/files/dhclient-systemd-wrapper b/meta/recipes-connectivity/dhcp/files/dhclient-systemd-wrapper
deleted file mode 100644
index 7d0e224a1df..00000000000
--- a/meta/recipes-connectivity/dhcp/files/dhclient-systemd-wrapper
+++ /dev/null
@@ -1,39 +0,0 @@
-#!/bin/sh
-
-# In case the interface is used for nfs, skip it.
-nfsroot=0
-interfaces=""
-exec 9<&0 < /proc/mounts
-while read dev mtpt fstype rest; do
-    if test $mtpt = "/" ; then
-        case $fstype in
-            nfs | nfs4)
-                nfsroot=1
-                nfs_addr=`echo $rest | sed -e 's/^.*addr=\([0-9.]*\).*$/\1/'`
-                break
-                ;;
-            *)
-                ;;
-        esac
-    fi
-done
-exec 0<&9 9<&-
-
-if [ $nfsroot -eq 0 ]; then
-    interfaces="$INTERFACES"
-else
-    if [ -x /bin/ip -o -x /sbin/ip ] ; then
-	nfs_iface=`ip route get $nfs_addr | grep dev | sed -e 's/^.*dev \([-a-z0-9.]*\).*$/\1/'`
-    fi
-    for i in $INTERFACES; do
-	if test "x$i" = "x$nfs_iface"; then
-            echo "dhclient skipping nfsroot interface $i"
-	else
-	    interfaces="$interfaces $i"
-	fi
-    done
-fi
-
-if test "x$interfaces" != "x"; then
-    /sbin/dhclient -d -cf /etc/dhcp/dhclient.conf -q -lf /var/lib/dhcp/dhclient.leases $interfaces
-fi
diff --git a/meta/recipes-connectivity/dhcp/files/dhclient.conf b/meta/recipes-connectivity/dhcp/files/dhclient.conf
deleted file mode 100644
index 0e6dcf96c21..00000000000
--- a/meta/recipes-connectivity/dhcp/files/dhclient.conf
+++ /dev/null
@@ -1,50 +0,0 @@
-# Configuration file for /sbin/dhclient, which is included in Debian's
-#	dhcp3-client package.
-#
-# This is a sample configuration file for dhclient. See dhclient.conf's
-#	man page for more information about the syntax of this file
-#	and a more comprehensive list of the parameters understood by
-#	dhclient.
-#
-# Normally, if the DHCP server provides reasonable information and does
-#	not leave anything out (like the domain name, for example), then
-#	few changes must be made to this file, if any.
-#
-
-#send host-name "andare.fugue.com";
-#send dhcp-client-identifier 1:0:a0:24:ab:fb:9c;
-#send dhcp-lease-time 3600;
-#supersede domain-name "fugue.com home.vix.com";
-#prepend domain-name-servers 127.0.0.1;
-request subnet-mask, broadcast-address, time-offset, routers,
-	domain-name, domain-name-servers, host-name,
-	netbios-name-servers, netbios-scope;
-#require subnet-mask, domain-name-servers;
-#timeout 60;
-#retry 60;
-#reboot 10;
-#select-timeout 5;
-#initial-interval 2;
-#script "/etc/dhcp3/dhclient-script";
-#media "-link0 -link1 -link2", "link0 link1";
-#reject 192.33.137.209;
-
-#alias {
-#  interface "eth0";
-#  fixed-address 192.5.5.213;
-#  option subnet-mask 255.255.255.255;
-#}
-
-#lease {
-#  interface "eth0";
-#  fixed-address 192.33.137.200;
-#  medium "link0 link1";
-#  option host-name "andare.swiftmedia.com";
-#  option subnet-mask 255.255.255.0;
-#  option broadcast-address 192.33.137.255;
-#  option routers 192.33.137.250;
-#  option domain-name-servers 127.0.0.1;
-#  renew 2 2000/1/12 00:00:01;
-#  rebind 2 2000/1/12 00:00:01;
-#  expire 2 2000/1/12 00:00:01;
-#}
diff --git a/meta/recipes-connectivity/dhcp/files/dhclient.service b/meta/recipes-connectivity/dhcp/files/dhclient.service
deleted file mode 100644
index 9ddb4d1dfe9..00000000000
--- a/meta/recipes-connectivity/dhcp/files/dhclient.service
+++ /dev/null
@@ -1,13 +0,0 @@
-[Unit]
-Description=Dynamic Host Configuration Protocol (DHCP)
-Wants=network.target
-Before=network.target
-After=systemd-udevd.service
-
-[Service]
-EnvironmentFile=-@SYSCONFDIR@/default/dhcp-client
-ExecStart=@BASE_SBINDIR@/dhclient-systemd-wrapper
-RemainAfterExit=yes
-
-[Install]
-WantedBy=multi-user.target
diff --git a/meta/recipes-connectivity/dhcp/files/dhcpd.conf b/meta/recipes-connectivity/dhcp/files/dhcpd.conf
deleted file mode 100644
index 0001c0f00e2..00000000000
--- a/meta/recipes-connectivity/dhcp/files/dhcpd.conf
+++ /dev/null
@@ -1,108 +0,0 @@
-#
-# Sample configuration file for ISC dhcpd for Debian
-#
-# $Id: dhcpd.conf,v 1.1.1.1 2002/05/21 00:07:44 peloy Exp $
-#
-
-# The ddns-updates-style parameter controls whether or not the server will
-# attempt to do a DNS update when a lease is confirmed. We default to the
-# behavior of the version 2 packages ('none', since DHCP v2 didn't
-# have support for DDNS.)
-ddns-update-style none;
-
-# option definitions common to all supported networks...
-option domain-name "example.org";
-option domain-name-servers ns1.example.org, ns2.example.org;
-
-default-lease-time 600;
-max-lease-time 7200;
-
-# If this DHCP server is the official DHCP server for the local
-# network, the authoritative directive should be uncommented.
-#authoritative;
-
-# Use this to send dhcp log messages to a different log file (you also
-# have to hack syslog.conf to complete the redirection).
-log-facility local7;
-
-# No service will be given on this subnet, but declaring it helps the 
-# DHCP server to understand the network topology.
-
-#subnet 10.152.187.0 netmask 255.255.255.0 {
-#}
-
-# This is a very basic subnet declaration.
-
-#subnet 10.254.239.0 netmask 255.255.255.224 {
-#  range 10.254.239.10 10.254.239.20;
-#  option routers rtr-239-0-1.example.org, rtr-239-0-2.example.org;
-#}
-
-# This declaration allows BOOTP clients to get dynamic addresses,
-# which we don't really recommend.
-
-#subnet 10.254.239.32 netmask 255.255.255.224 {
-#  range dynamic-bootp 10.254.239.40 10.254.239.60;
-#  option broadcast-address 10.254.239.31;
-#  option routers rtr-239-32-1.example.org;
-#}
-
-# A slightly different configuration for an internal subnet.
-#subnet 10.5.5.0 netmask 255.255.255.224 {
-#  range 10.5.5.26 10.5.5.30;
-#  option domain-name-servers ns1.internal.example.org;
-#  option domain-name "internal.example.org";
-#  option routers 10.5.5.1;
-#  option broadcast-address 10.5.5.31;
-#  default-lease-time 600;
-#  max-lease-time 7200;
-#}
-
-# Hosts which require special configuration options can be listed in
-# host statements.   If no address is specified, the address will be
-# allocated dynamically (if possible), but the host-specific information
-# will still come from the host declaration.
-
-#host passacaglia {
-#  hardware ethernet 0:0:c0:5d:bd:95;
-#  filename "vmunix.passacaglia";
-#  server-name "toccata.fugue.com";
-#}
-
-# Fixed IP addresses can also be specified for hosts.   These addresses
-# should not also be listed as being available for dynamic assignment.
-# Hosts for which fixed IP addresses have been specified can boot using
-# BOOTP or DHCP.   Hosts for which no fixed address is specified can only
-# be booted with DHCP, unless there is an address range on the subnet
-# to which a BOOTP client is connected which has the dynamic-bootp flag
-# set.
-#host fantasia {
-#  hardware ethernet 08:00:07:26:c0:a5;
-#  fixed-address fantasia.fugue.com;
-#}
-
-# You can declare a class of clients and then do address allocation
-# based on that.   The example below shows a case where all clients
-# in a certain class get addresses on the 10.17.224/24 subnet, and all
-# other clients get addresses on the 10.0.29/24 subnet.
-
-#class "foo" {
-#  match if substring (option vendor-class-identifier, 0, 4) = "SUNW";
-#}
-
-#shared-network 224-29 {
-#  subnet 10.17.224.0 netmask 255.255.255.0 {
-#    option routers rtr-224.example.org;
-#  }
-#  subnet 10.0.29.0 netmask 255.255.255.0 {
-#    option routers rtr-29.example.org;
-#  }
-#  pool {
-#    allow members of "foo";
-#    range 10.17.224.10 10.17.224.250;
-#  }
-#  pool {
-#    deny members of "foo";
-#    range 10.0.29.10 10.0.29.230;
-#  }
-#}
diff --git a/meta/recipes-connectivity/dhcp/files/dhcpd.service b/meta/recipes-connectivity/dhcp/files/dhcpd.service
deleted file mode 100644
index ae4f93eca5b..00000000000
--- a/meta/recipes-connectivity/dhcp/files/dhcpd.service
+++ /dev/null
@@ -1,15 +0,0 @@
-[Unit]
-Description=DHCPv4 Server Daemon
-Documentation=man:dhcpd(8) man:dhcpd.conf(5)
-After=network.target
-After=time-sync.target
-
-[Service]
-PIDFile=@localstatedir@/run/dhcpd.pid
-EnvironmentFile=@SYSCONFDIR@/default/dhcp-server
-EnvironmentFile=-@SYSCONFDIR@/sysconfig/dhcp-server
-ExecStartPre=@base_bindir@/touch @localstatedir@/lib/dhcp/dhcpd.leases
-ExecStart=@SBINDIR@/dhcpd -f -cf @SYSCONFDIR@/dhcp/dhcpd.conf -pf @localstatedir@/run/dhcpd.pid $DHCPDARGS -q $INTERFACES
-
-[Install]
-WantedBy=multi-user.target
diff --git a/meta/recipes-connectivity/dhcp/files/dhcpd6.service b/meta/recipes-connectivity/dhcp/files/dhcpd6.service
deleted file mode 100644
index 52a6224dc2c..00000000000
--- a/meta/recipes-connectivity/dhcp/files/dhcpd6.service
+++ /dev/null
@@ -1,15 +0,0 @@
-[Unit]
-Description=DHCPv6 Server Daemon
-Documentation=man:dhcpd(8) man:dhcpd.conf(5)
-After=network.target
-After=time-sync.target
-
-[Service]
-PIDFile=@localstatedir@/run/dhcpd6.pid
-EnvironmentFile=@SYSCONFDIR@/default/dhcp-server
-EnvironmentFile=-@SYSCONFDIR@/sysconfig/dhcpd6
-ExecStartPre=@base_bindir@/touch @localstatedir@/lib/dhcp/dhcpd6.leases
-ExecStart=@SBINDIR@/dhcpd -f -6 -cf @SYSCONFDIR@/dhcp/dhcpd6.conf -pf @localstatedir@/run/dhcpd6.pid $DHCPDARGS -q $INTERFACES
-
-[Install]
-WantedBy=multi-user.target
diff --git a/meta/recipes-connectivity/dhcp/files/dhcrelay.service b/meta/recipes-connectivity/dhcp/files/dhcrelay.service
deleted file mode 100644
index 15ff927d346..00000000000
--- a/meta/recipes-connectivity/dhcp/files/dhcrelay.service
+++ /dev/null
@@ -1,10 +0,0 @@
-[Unit]
-Description=DHCP Relay Agent Daemon
-After=network.target
-
-[Service]
-EnvironmentFile=@SYSCONFDIR@/default/dhcp-relay
-ExecStart=@SBINDIR@/dhcrelay -d --no-pid -q $SERVERS
-
-[Install]
-WantedBy=multi-user.target
diff --git a/meta/recipes-connectivity/dhcp/files/init-relay b/meta/recipes-connectivity/dhcp/files/init-relay
deleted file mode 100644
index 019a7e84cf4..00000000000
--- a/meta/recipes-connectivity/dhcp/files/init-relay
+++ /dev/null
@@ -1,44 +0,0 @@
-#!/bin/sh
-#
-# $Id: dhcp3-relay,v 1.1 2004/04/16 15:41:08 ml Exp $
-#
-
-# It is not safe to start if we don't have a default configuration...
-if [ ! -f /etc/default/dhcp-relay ]; then
-	echo "/etc/default/dhcp-relay does not exist! - Aborting..."
-	echo "create this file to fix the problem."
-	exit 1
-fi
-
-# Read init script configuration (interfaces the daemon should listen on
-# and the DHCP server we should forward requests to.)
-. /etc/default/dhcp-relay
-
-# Build command line for interfaces (will be passed to dhrelay below.)
-IFCMD=""
-if test "$INTERFACES" != ""; then
-	for I in $INTERFACES; do
-		IFCMD=${IFCMD}"-i "${I}" "
-	done
-fi
-
-DHCRELAYPID=/var/run/dhcrelay.pid
-
-case "$1" in
-	start)
-		start-stop-daemon -S -x /usr/sbin/dhcrelay -- -q $OPTIONS $IFCMD $SERVERS
-		;;
-	stop)
-		start-stop-daemon -K -x /usr/sbin/dhcrelay
-		;;
-	restart | force-reload)
-		$0 stop
-		sleep 2
-		$0 start
-		;;
-	*)
-		echo "Usage: /etc/init.d/dhcp-relay {start|stop|restart|force-reload}"
-		exit 1 
-esac
-
-exit 0
diff --git a/meta/recipes-connectivity/dhcp/files/init-server b/meta/recipes-connectivity/dhcp/files/init-server
deleted file mode 100644
index 5e693adf785..00000000000
--- a/meta/recipes-connectivity/dhcp/files/init-server
+++ /dev/null
@@ -1,44 +0,0 @@
-#!/bin/sh
-#
-# $Id: dhcp3-server.init.d,v 1.4 2003/07/13 19:12:41 mdz Exp $
-#
-
-test -f /usr/sbin/dhcpd || exit 0
-
-# It is not safe to start if we don't have a default configuration...
-if [ ! -f /etc/default/dhcp-server ]; then
-	echo "/etc/default/dhcp-server does not exist! - Aborting..."
-	exit 0
-fi
-
-# Read init script configuration (so far only interfaces the daemon
-# should listen on.)
-. /etc/default/dhcp-server
-
-case "$1" in
-	start)
-		echo -n "Starting DHCP server: "
-		test -d /var/lib/dhcp/ || mkdir -p /var/lib/dhcp/
-		test -f /var/lib/dhcp/dhcpd.leases || touch /var/lib/dhcp/dhcpd.leases	
-		start-stop-daemon -S -x /usr/sbin/dhcpd -- -q $INTERFACES -user dhcp -group dhcp
-		echo "."
-		;;
-	stop)
-		echo -n "Stopping DHCP server: dhcpd3"
-		start-stop-daemon -K -x /usr/sbin/dhcpd
-		echo "."
-		;;
-	restart | force-reload)
-		$0 stop
-		sleep 2
-		$0 start
-		if [ "$?" != "0" ]; then
-			exit 1
-		fi
-		;;
-	*)
-		echo "Usage: /etc/init.d/dhcp-server {start|stop|restart|force-reload}"
-		exit 1 
-esac
-
-exit 0
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [PATCH 7/8] bind: Add 9.16.x
  2020-09-01 15:22 [PATCH 1/8] log4cplus: move meta-oe pkg to core akuster
                   ` (4 preceding siblings ...)
  2020-09-01 15:22 ` [PATCH 6/8] dhcp: remove from core akuster
@ 2020-09-01 15:22 ` akuster
  2020-09-04  8:39   ` [OE-core] " Andrey Zhizhikin
  2020-09-01 15:22 ` [PATCH 8/8] bind: 9.11 remove akuster
  2020-09-01 15:32 ` ✗ patchtest: failure for "log4cplus: move meta-oe pkg to..." and 7 more Patchwork
  7 siblings, 1 reply; 24+ messages in thread
From: akuster @ 2020-09-01 15:22 UTC (permalink / raw)
  To: openembedded-core

Removed obsolete packageconfig options

License change to MPL-2.0
https://gitlab.isc.org/isc-projects/bind9/blob/master/LICENSE

Refreshed:
bind-ensure-searching-for-json-headers-searches-sysr.patch
0001-named-lwresd-V-and-start-log-hide-build-options.patch
bind-ensure-searching-for-json-headers-searches-sysr.patch

Drop obsolete patch: 0001-configure.in-remove-useless-L-use_openssl-lib.patch

Signed-off-by: Armin Kuster <akuster808@gmail.com>
---
 ...1-avoid-start-failure-with-bind-user.patch |  27 ++
 ...d-V-and-start-log-hide-build-options.patch |  35 ++
 ...ching-for-json-headers-searches-sysr.patch |  47 +++
 .../bind/bind-9.16.5/bind9                    |   2 +
 .../bind/bind-9.16.5/conf.patch               | 330 ++++++++++++++++++
 .../bind/bind-9.16.5/generate-rndc-key.sh     |   8 +
 ...t.d-add-support-for-read-only-rootfs.patch |  65 ++++
 .../make-etc-initd-bind-stop-work.patch       |  42 +++
 .../bind/bind-9.16.5/named.service            |  22 ++
 meta/recipes-connectivity/bind/bind_9.16.5.bb | 125 +++++++
 10 files changed, 703 insertions(+)
 create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
 create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
 create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
 create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind9
 create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
 create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
 create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
 create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
 create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/named.service
 create mode 100644 meta/recipes-connectivity/bind/bind_9.16.5.bb

diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
new file mode 100644
index 00000000000..8db96ec049c
--- /dev/null
+++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
@@ -0,0 +1,27 @@
+From 31dde3562f287429eea94b77250d184818b49063 Mon Sep 17 00:00:00 2001
+From: Chen Qi <Qi.Chen@windriver.com>
+Date: Mon, 15 Oct 2018 16:55:09 +0800
+Subject: [PATCH] avoid start failure with bind user
+
+Upstream-Status: Pending
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ init.d | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/init.d b/init.d
+index b2eec60..6e03936 100644
+--- a/init.d
++++ b/init.d
+@@ -57,6 +57,7 @@ case "$1" in
+ 	modprobe capability >/dev/null 2>&1 || true
+ 	if [ ! -f /etc/bind/rndc.key ]; then
+ 	    /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
++	    chown root:bind /etc/bind/rndc.key >/dev/null 2>&1 || true
+ 	    chmod 0640 /etc/bind/rndc.key
+ 	fi
+ 	if [ -f /var/run/named/named.pid ]; then
+-- 
+2.7.4
+
diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
new file mode 100644
index 00000000000..5bcc16c9b2b
--- /dev/null
+++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
@@ -0,0 +1,35 @@
+From a3af4a405baf5ff582e82aaba392dd9667d94bdc Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Mon, 27 Aug 2018 21:24:20 +0800
+Subject: [PATCH] `named/lwresd -V' and start log hide build options
+
+The build options expose build path directories, so hide them.
+[snip]
+$ named -V
+|built by make with *** (options are hidden)
+[snip]
+
+Upstream-Status: Inappropriate [oe-core specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+
+Refreshed for 9.16.0
+Signed-off-by: Armin Kuster <akuster@mvista.com>
+
+---
+ bin/named/include/named/globals.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+Index: bind-9.16.0/bin/named/include/named/globals.h
+===================================================================
+--- bind-9.16.0.orig/bin/named/include/named/globals.h
++++ bind-9.16.0/bin/named/include/named/globals.h
+@@ -69,7 +69,7 @@ EXTERN const char *named_g_version     I
+ EXTERN const char *named_g_product     INIT(PRODUCT);
+ EXTERN const char *named_g_description INIT(DESCRIPTION);
+ EXTERN const char *named_g_srcid       INIT(SRCID);
+-EXTERN const char *named_g_configargs  INIT(CONFIGARGS);
++EXTERN const char *named_g_configargs  INIT("*** (options are hidden)");
+ EXTERN const char *named_g_builder     INIT(BUILDER);
+ EXTERN in_port_t named_g_port	       INIT(0);
+ EXTERN isc_dscp_t named_g_dscp	       INIT(-1);
diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
new file mode 100644
index 00000000000..f9cdc7ca4df
--- /dev/null
+++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
@@ -0,0 +1,47 @@
+From edda20fb5a6e88548f85e39d34d6c074306e15bc Mon Sep 17 00:00:00 2001
+From: Paul Gortmaker <paul.gortmaker@windriver.com>
+Date: Tue, 9 Jun 2015 11:22:00 -0400
+Subject: [PATCH] bind: ensure searching for json headers searches sysroot
+
+Bind can fail configure by detecting headers w/o libs[1], or
+it can fail the host contamination check as per below:
+
+ERROR: This autoconf log indicates errors, it looked at host include and/or library paths while determining system capabilities.
+Rerun configure task after fixing this. The path was 'build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/build'
+ERROR: Function failed: do_qa_configure
+ERROR: Logfile of failure stored in: build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/temp/log.do_configure.5242
+ERROR: Task 5 (meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure) failed with exit code '1'
+NOTE: Tasks Summary: Attempted 773 tasks of which 768 didn't need to be rerun and 1 failed.
+No currently running tasks (773 of 781)
+
+Summary: 1 task failed:
+  /meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure
+
+One way to fix it would be to unconditionally disable json in bind
+configure[2] but here we fix it by using the path to where we would
+put the header if we had json in the sysroot, in case someone wants
+to make use of the combination some day.
+
+[1] https://trac.macports.org/ticket/45305
+[2] https://trac.macports.org/changeset/126406
+
+Upstream-Status: Inappropriate [OE Specific]
+Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
+
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+Index: bind-9.16.4/configure.ac
+===================================================================
+--- bind-9.16.4.orig/configure.ac
++++ bind-9.16.4/configure.ac
+@@ -1232,7 +1232,7 @@ case "$use_lmdb" in
+ 		LMDB_LIBS=""
+ 		;;
+ 	auto|yes)
+-		for d in /usr /usr/local /opt/local
++		for d in "${STAGING_INCDIR}"
+ 		do
+ 			if test -f "${d}/include/lmdb.h"
+ 			then
diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind9 b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
new file mode 100644
index 00000000000..968679ff7f7
--- /dev/null
+++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
@@ -0,0 +1,2 @@
+# startup options for the server
+OPTIONS="-u bind"
diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
new file mode 100644
index 00000000000..aad345f9fcf
--- /dev/null
+++ b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
@@ -0,0 +1,330 @@
+Upstream-Status: Inappropriate [configuration]
+
+the patch is imported from openembedded project
+
+11/30/2010 - Qing He <qing.he@intel.com>
+
+diff -urN bind-9.3.1.orig/conf/db.0 bind-9.3.1/conf/db.0
+--- bind-9.3.1.orig/conf/db.0	1970-01-01 01:00:00.000000000 +0100
++++ bind-9.3.1/conf/db.0	2005-07-10 22:14:00.000000000 +0200
+@@ -0,0 +1,12 @@
++;
++; BIND reverse data file for broadcast zone
++;
++$TTL	604800
++@	IN	SOA	localhost. root.localhost. (
++			      1		; Serial
++			 604800		; Refresh
++			  86400		; Retry
++			2419200		; Expire
++			 604800 )	; Negative Cache TTL
++;
++@	IN	NS	localhost.
+diff -urN bind-9.3.1.orig/conf/db.127 bind-9.3.1/conf/db.127
+--- bind-9.3.1.orig/conf/db.127	1970-01-01 01:00:00.000000000 +0100
++++ bind-9.3.1/conf/db.127	2005-07-10 22:14:00.000000000 +0200
+@@ -0,0 +1,13 @@
++;
++; BIND reverse data file for local loopback interface
++;
++$TTL	604800
++@	IN	SOA	localhost. root.localhost. (
++			      1		; Serial
++			 604800		; Refresh
++			  86400		; Retry
++			2419200		; Expire
++			 604800 )	; Negative Cache TTL
++;
++@	IN	NS	localhost.
++1.0.0	IN	PTR	localhost.
+diff -urN bind-9.3.1.orig/conf/db.empty bind-9.3.1/conf/db.empty
+--- bind-9.3.1.orig/conf/db.empty	1970-01-01 01:00:00.000000000 +0100
++++ bind-9.3.1/conf/db.empty	2005-07-10 22:14:00.000000000 +0200
+@@ -0,0 +1,14 @@
++; BIND reverse data file for empty rfc1918 zone
++;
++; DO NOT EDIT THIS FILE - it is used for multiple zones.
++; Instead, copy it, edit named.conf, and use that copy.
++;
++$TTL	86400
++@	IN	SOA	localhost. root.localhost. (
++			      1		; Serial
++			 604800		; Refresh
++			  86400		; Retry
++			2419200		; Expire
++			  86400 )	; Negative Cache TTL
++;
++@	IN	NS	localhost.
+diff -urN bind-9.3.1.orig/conf/db.255 bind-9.3.1/conf/db.255
+--- bind-9.3.1.orig/conf/db.255	1970-01-01 01:00:00.000000000 +0100
++++ bind-9.3.1/conf/db.255	2005-07-10 22:14:00.000000000 +0200
+@@ -0,0 +1,12 @@
++;
++; BIND reserve data file for broadcast zone
++;
++$TTL	604800
++@	IN	SOA	localhost. root.localhost. (
++			      1		; Serial
++			 604800		; Refresh
++			  86400		; Retry
++			2419200		; Expire
++			 604800 )	; Negative Cache TTL
++;
++@	IN	NS	localhost.
+diff -urN bind-9.3.1.orig/conf/db.local bind-9.3.1/conf/db.local
+--- bind-9.3.1.orig/conf/db.local	1970-01-01 01:00:00.000000000 +0100
++++ bind-9.3.1/conf/db.local	2005-07-10 22:14:00.000000000 +0200
+@@ -0,0 +1,13 @@
++;
++; BIND data file for local loopback interface
++;
++$TTL	604800
++@	IN	SOA	localhost. root.localhost. (
++			      1		; Serial
++			 604800		; Refresh
++			  86400		; Retry
++			2419200		; Expire
++			 604800 )	; Negative Cache TTL
++;
++@	IN	NS	localhost.
++@	IN	A	127.0.0.1
+diff -urN bind-9.3.1.orig/conf/db.root bind-9.3.1/conf/db.root
+--- bind-9.3.1.orig/conf/db.root	1970-01-01 01:00:00.000000000 +0100
++++ bind-9.3.1/conf/db.root	2005-07-10 22:14:00.000000000 +0200
+@@ -0,0 +1,45 @@
++
++; <<>> DiG 9.2.3 <<>> ns . @a.root-servers.net.
++;; global options:  printcmd
++;; Got answer:
++;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 18944
++;; flags: qr aa rd; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 13
++
++;; QUESTION SECTION:
++;.				IN	NS
++
++;; ANSWER SECTION:
++.			518400	IN	NS	A.ROOT-SERVERS.NET.
++.			518400	IN	NS	B.ROOT-SERVERS.NET.
++.			518400	IN	NS	C.ROOT-SERVERS.NET.
++.			518400	IN	NS	D.ROOT-SERVERS.NET.
++.			518400	IN	NS	E.ROOT-SERVERS.NET.
++.			518400	IN	NS	F.ROOT-SERVERS.NET.
++.			518400	IN	NS	G.ROOT-SERVERS.NET.
++.			518400	IN	NS	H.ROOT-SERVERS.NET.
++.			518400	IN	NS	I.ROOT-SERVERS.NET.
++.			518400	IN	NS	J.ROOT-SERVERS.NET.
++.			518400	IN	NS	K.ROOT-SERVERS.NET.
++.			518400	IN	NS	L.ROOT-SERVERS.NET.
++.			518400	IN	NS	M.ROOT-SERVERS.NET.
++
++;; ADDITIONAL SECTION:
++A.ROOT-SERVERS.NET.	3600000	IN	A	198.41.0.4
++B.ROOT-SERVERS.NET.	3600000	IN	A	192.228.79.201
++C.ROOT-SERVERS.NET.	3600000	IN	A	192.33.4.12
++D.ROOT-SERVERS.NET.	3600000	IN	A	128.8.10.90
++E.ROOT-SERVERS.NET.	3600000	IN	A	192.203.230.10
++F.ROOT-SERVERS.NET.	3600000	IN	A	192.5.5.241
++G.ROOT-SERVERS.NET.	3600000	IN	A	192.112.36.4
++H.ROOT-SERVERS.NET.	3600000	IN	A	128.63.2.53
++I.ROOT-SERVERS.NET.	3600000	IN	A	192.36.148.17
++J.ROOT-SERVERS.NET.	3600000	IN	A	192.58.128.30
++K.ROOT-SERVERS.NET.	3600000	IN	A	193.0.14.129
++L.ROOT-SERVERS.NET.	3600000	IN	A	198.32.64.12
++M.ROOT-SERVERS.NET.	3600000	IN	A	202.12.27.33
++
++;; Query time: 81 msec
++;; SERVER: 198.41.0.4#53(a.root-servers.net.)
++;; WHEN: Sun Feb  1 11:27:14 2004
++;; MSG SIZE  rcvd: 436
++
+diff -urN bind-9.3.1.orig/conf/named.conf bind-9.3.1/conf/named.conf
+--- bind-9.3.1.orig/conf/named.conf	1970-01-01 01:00:00.000000000 +0100
++++ bind-9.3.1/conf/named.conf	2005-07-10 22:33:46.000000000 +0200
+@@ -0,0 +1,49 @@
++// This is the primary configuration file for the BIND DNS server named.
++//
++// If you are just adding zones, please do that in /etc/bind/named.conf.local
++
++include "/etc/bind/named.conf.options";
++
++// prime the server with knowledge of the root servers
++zone "." {
++	type hint;
++	file "/etc/bind/db.root";
++};
++
++// be authoritative for the localhost forward and reverse zones, and for
++// broadcast zones as per RFC 1912
++
++zone "localhost" {
++	type master;
++	file "/etc/bind/db.local";
++};
++
++zone "127.in-addr.arpa" {
++	type master;
++	file "/etc/bind/db.127";
++};
++
++zone "0.in-addr.arpa" {
++	type master;
++	file "/etc/bind/db.0";
++};
++
++zone "255.in-addr.arpa" {
++	type master;
++	file "/etc/bind/db.255";
++};
++
++// zone "com" { type delegation-only; };
++// zone "net" { type delegation-only; };
++
++// From the release notes:
++//  Because many of our users are uncomfortable receiving undelegated answers
++//  from root or top level domains, other than a few for whom that behaviour
++//  has been trusted and expected for quite some length of time, we have now
++//  introduced the "root-delegations-only" feature which applies delegation-only
++//  logic to all top level domains, and to the root domain.  An exception list
++//  should be specified, including "MUSEUM" and "DE", and any other top level
++//  domains from whom undelegated responses are expected and trusted.
++// root-delegation-only exclude { "DE"; "MUSEUM"; };
++
++include "/etc/bind/named.conf.local";
+diff -urN bind-9.3.1.orig/conf/named.conf.local bind-9.3.1/conf/named.conf.local
+--- bind-9.3.1.orig/conf/named.conf.local	1970-01-01 01:00:00.000000000 +0100
++++ bind-9.3.1/conf/named.conf.local	2005-07-10 22:14:06.000000000 +0200
+@@ -0,0 +1,8 @@
++//
++// Do any local configuration here
++//
++
++// Consider adding the 1918 zones here, if they are not used in your
++// organization
++//include "/etc/bind/zones.rfc1918";
++
+diff -urN bind-9.3.1.orig/conf/named.conf.options bind-9.3.1/conf/named.conf.options
+--- bind-9.3.1.orig/conf/named.conf.options	1970-01-01 01:00:00.000000000 +0100
++++ bind-9.3.1/conf/named.conf.options	2005-07-10 22:14:06.000000000 +0200
+@@ -0,0 +1,24 @@
++options {
++	directory "/var/cache/bind";
++
++	// If there is a firewall between you and nameservers you want
++	// to talk to, you might need to uncomment the query-source
++	// directive below.  Previous versions of BIND always asked
++	// questions using port 53, but BIND 8.1 and later use an unprivileged
++	// port by default.
++
++	// query-source address * port 53;
++
++	// If your ISP provided one or more IP addresses for stable 
++	// nameservers, you probably want to use them as forwarders.  
++	// Uncomment the following block, and insert the addresses replacing 
++	// the all-0's placeholder.
++
++	// forwarders {
++	// 	0.0.0.0;
++	// };
++
++	auth-nxdomain no;    # conform to RFC1035
++
++};
++
+diff -urN bind-9.3.1.orig/conf/zones.rfc1918 bind-9.3.1/conf/zones.rfc1918
+--- bind-9.3.1.orig/conf/zones.rfc1918	1970-01-01 01:00:00.000000000 +0100
++++ bind-9.3.1/conf/zones.rfc1918	2005-07-10 22:14:10.000000000 +0200
+@@ -0,0 +1,20 @@
++zone "10.in-addr.arpa"      { type master; file "/etc/bind/db.empty"; };
++ 
++zone "16.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++zone "17.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++zone "18.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++zone "19.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++zone "20.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++zone "21.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++zone "22.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++zone "23.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++zone "24.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++zone "25.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++zone "26.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++zone "27.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++zone "28.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++zone "29.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++zone "30.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++zone "31.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
++
++zone "168.192.in-addr.arpa" { type master; file "/etc/bind/db.empty"; };
+diff -urN bind-9.3.1.orig/init.d bind-9.3.1/init.d
+--- bind-9.3.1.orig/init.d	1970-01-01 01:00:00.000000000 +0100
++++ bind-9.3.1/init.d	2005-07-10 23:09:58.000000000 +0200
+@@ -0,0 +1,70 @@
++#!/bin/sh
++
++PATH=/sbin:/bin:/usr/sbin:/usr/bin
++
++# for a chrooted server: "-u bind -t /var/lib/named"
++# Don't modify this line, change or create /etc/default/bind9.
++OPTIONS=""
++
++test -f /etc/default/bind9 && . /etc/default/bind9
++
++test -x /usr/sbin/rndc || exit 0
++
++case "$1" in
++    start)
++	echo -n "Starting domain name service: named"
++
++	modprobe capability >/dev/null 2>&1 || true
++	if [ ! -f /etc/bind/rndc.key ]; then
++	    /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
++	    chmod 0640 /etc/bind/rndc.key
++	fi
++	if [ -f /var/run/named/named.pid ]; then
++	    ps `cat /var/run/named/named.pid` > /dev/null && exit 1
++	fi
++
++	# dirs under /var/run can go away on reboots.
++	mkdir -p /var/run/named
++	mkdir -p /var/cache/bind
++	chmod 775 /var/run/named
++	chown root:bind /var/run/named >/dev/null 2>&1 || true
++
++	if [ ! -x /usr/sbin/named ]; then
++	    echo "named binary missing - not starting"
++	    exit 1
++	fi
++	if start-stop-daemon --start --quiet --exec /usr/sbin/named \
++		--pidfile /var/run/named/named.pid -- $OPTIONS; then
++	    if [ -x /sbin/resolvconf ] ; then
++		echo "nameserver 127.0.0.1" | /sbin/resolvconf -a lo
++	    fi
++	fi
++	echo "."	
++    ;;
++
++    stop)
++	echo -n "Stopping domain name service: named"
++	if [ -x /sbin/resolvconf ]; then
++	    /sbin/resolvconf -d lo
++	fi
++	/usr/sbin/rndc stop >/dev/null 2>&1
++	echo "."	
++    ;;
++
++    reload)
++	/usr/sbin/rndc reload
++    ;;
++
++    restart|force-reload)
++	$0 stop
++	sleep 2
++	$0 start
++    ;;
++    
++    *)
++	echo "Usage: /etc/init.d/bind {start|stop|reload|restart|force-reload}" >&2
++	exit 1
++    ;;
++esac
++
++exit 0
diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
new file mode 100644
index 00000000000..ef915c0ae5a
--- /dev/null
+++ b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
@@ -0,0 +1,8 @@
+#!/bin/sh
+
+if [ ! -s /etc/bind/rndc.key ]; then
+    echo -n "Generating /etc/bind/rndc.key:"
+    /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
+    chown root:bind /etc/bind/rndc.key
+    chmod 0640 /etc/bind/rndc.key
+fi
diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
new file mode 100644
index 00000000000..11db95ede12
--- /dev/null
+++ b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
@@ -0,0 +1,65 @@
+Subject: init.d: add support for read-only rootfs
+
+Upstream-Status: Inappropriate [oe specific]
+
+Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
+---
+ init.d |   40 ++++++++++++++++++++++++++++++++++++++++
+ 1 file changed, 40 insertions(+)
+
+diff --git a/init.d b/init.d
+index 0111ed4..24677c8 100644
+--- a/init.d
++++ b/init.d
+@@ -6,8 +6,48 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin
+ # Don't modify this line, change or create /etc/default/bind9.
+ OPTIONS=""
+ 
++test -f /etc/default/rcS && . /etc/default/rcS
+ test -f /etc/default/bind9 && . /etc/default/bind9
+ 
++# This function is here because it's possible that /var and / are on different partitions.
++is_on_read_only_partition () {
++    DIRECTORY=$1
++    dir=`readlink -f $DIRECTORY`
++    while true; do
++	if [ ! -d "$dir" ]; then
++	    echo "ERROR: $dir is not a directory"
++	    exit 1
++	else
++	    for flag in `awk -v dir=$dir '{ if ($2 == dir) { print "FOUND"; split($4,FLAGS,",") } }; \
++		END { for (f in FLAGS) print FLAGS[f] }' < /proc/mounts`; do
++		[ "$flag" = "FOUND" ] && partition="read-write"
++		[ "$flag" = "ro" ] && { partition="read-only"; break; }
++	    done
++	    if [ "$dir" = "/" -o -n "$partition" ]; then
++		break
++	    else
++		dir=`dirname $dir`
++	    fi
++	fi
++    done
++    [ "$partition" = "read-only" ] && echo "yes" || echo "no"
++}
++
++bind_mount () {
++    olddir=$1
++    newdir=$2
++    mkdir -p $olddir
++    cp -a $newdir/* $olddir
++    mount --bind $olddir $newdir
++}
++
++# Deal with read-only rootfs
++if [ "$ROOTFS_READ_ONLY" = "yes" ]; then
++    [ "$VERBOSE" != "no" ] && echo "WARN: start bind service in read-only rootfs"
++    [ `is_on_read_only_partition /etc/bind` = "yes" ] && bind_mount /var/volatile/bind/etc /etc/bind
++    [ `is_on_read_only_partition /var/named` = "yes" ] && bind_mount /var/volatile/bind/named /var/named
++fi
++
+ test -x /usr/sbin/rndc || exit 0
+ 
+ case "$1" in
+-- 
+1.7.9.5
+
diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
new file mode 100644
index 00000000000..146f3e35db6
--- /dev/null
+++ b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
@@ -0,0 +1,42 @@
+bind: make "/etc/init.d/bind stop" work
+
+Upstream-Status: Inappropriate [configuration]
+
+Add some configurations, make rndc command be able to controls
+the named daemon.
+
+Signed-off-by: Roy Li <rongqing.li@windriver.com>
+---
+ conf/named.conf |    5 +++++
+ conf/rndc.conf  |    5 +++++
+ 2 files changed, 10 insertions(+), 0 deletions(-)
+ create mode 100644 conf/rndc.conf
+
+diff --git a/conf/named.conf b/conf/named.conf
+index 95829cf..c8899e7 100644
+--- a/conf/named.conf
++++ b/conf/named.conf
+@@ -47,3 +47,8 @@ zone "255.in-addr.arpa" {
+ // root-delegation-only exclude { "DE"; "MUSEUM"; };
+ 
+ include "/etc/bind/named.conf.local";
++include "/etc/bind/rndc.key" ;
++controls {
++	inet 127.0.0.1 allow { localhost; }
++	keys { rndc-key; };
++};
+diff --git a/conf/rndc.conf b/conf/rndc.conf
+new file mode 100644
+index 0000000..a0b481d
+--- /dev/null
++++ b/conf/rndc.conf
+@@ -0,0 +1,5 @@
++include "/etc/bind/rndc.key";
++options {
++	default-server  localhost;
++	default-key     rndc-key;
++};
+
+-- 
+1.7.5.4
+
diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/named.service b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
new file mode 100644
index 00000000000..cda56ef0150
--- /dev/null
+++ b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
@@ -0,0 +1,22 @@
+[Unit]
+Description=Berkeley Internet Name Domain (DNS)
+Wants=nss-lookup.target
+Before=nss-lookup.target
+After=network.target
+
+[Service]
+Type=forking
+EnvironmentFile=-/etc/default/bind9
+PIDFile=/run/named/named.pid
+
+ExecStartPre=@SBINDIR@/generate-rndc-key.sh
+ExecStart=@SBINDIR@/named $OPTIONS
+
+ExecReload=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc reload > /dev/null 2>&1 || @BASE_BINDIR@/kill -HUP $MAINPID'
+
+ExecStop=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc stop > /dev/null 2>&1 || @BASE_BINDIR@/kill -TERM $MAINPID'
+
+PrivateTmp=true
+
+[Install]
+WantedBy=multi-user.target
diff --git a/meta/recipes-connectivity/bind/bind_9.16.5.bb b/meta/recipes-connectivity/bind/bind_9.16.5.bb
new file mode 100644
index 00000000000..9c20ccc6fa2
--- /dev/null
+++ b/meta/recipes-connectivity/bind/bind_9.16.5.bb
@@ -0,0 +1,125 @@
+SUMMARY = "ISC Internet Domain Name Server"
+HOMEPAGE = "http://www.isc.org/sw/bind/"
+SECTION = "console/network"
+
+LICENSE = "MPL-2.0"
+LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=188b8d0644bd6835df43b84e3f180be1"
+
+DEPENDS = "openssl libcap zlib libuv"
+
+SRC_URI = "https://ftp.isc.org/isc/bind9/${PV}/${BPN}-${PV}.tar.xz \
+           file://conf.patch \
+           file://named.service \
+           file://bind9 \
+           file://generate-rndc-key.sh \
+           file://make-etc-initd-bind-stop-work.patch \
+           file://init.d-add-support-for-read-only-rootfs.patch \
+           file://bind-ensure-searching-for-json-headers-searches-sysr.patch \
+           file://0001-named-lwresd-V-and-start-log-hide-build-options.patch \
+           file://0001-avoid-start-failure-with-bind-user.patch \
+           "
+
+SRC_URI[sha256sum] = "6378b3e51fef11a8be4794dc48e8111ba92d211c0dfd129a0c296ed06a3dc075"
+
+UPSTREAM_CHECK_URI = "https://ftp.isc.org/isc/bind9/"
+# stay at 9.16 follow the ESV versions divisible by 4
+UPSTREAM_CHECK_REGEX = "(?P<pver>9.(16|20|24|28)(\.\d+)+(-P\d+)*)/"
+
+inherit autotools update-rc.d systemd useradd pkgconfig multilib_script multilib_header
+
+MULTILIB_SCRIPTS = "${PN}:${bindir}/bind9-config ${PN}:${bindir}/isc-config.sh"
+
+# PACKAGECONFIGs readline and libedit should NOT be set at same time
+PACKAGECONFIG ?= "readline"
+PACKAGECONFIG[httpstats] = "--with-libxml2=${STAGING_DIR_HOST}${prefix},--without-libxml2,libxml2"
+PACKAGECONFIG[readline] = "--with-readline=-lreadline,,readline"
+PACKAGECONFIG[libedit] = "--with-readline=-ledit,,libedit"
+PACKAGECONFIG[python3] = "--with-python=yes --with-python-install-dir=${PYTHON_SITEPACKAGES_DIR} , --without-python, python3-ply-native,"
+
+EXTRA_OECONF = " --with-libtool --disable-devpoll --enable-epoll \
+                 --with-gssapi=no --with-lmdb=no --with-zlib \
+                 --sysconfdir=${sysconfdir}/bind \
+                 --with-openssl=${STAGING_DIR_HOST}${prefix} \
+               "
+LDFLAGS_append = " -lz"
+
+inherit ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3native distutils3-base', '', d)}
+
+# dhcp needs .la so keep them
+REMOVE_LIBTOOL_LA = "0"
+
+USERADD_PACKAGES = "${PN}"
+USERADD_PARAM_${PN} = "--system --home ${localstatedir}/cache/bind --no-create-home \
+                       --user-group bind"
+
+INITSCRIPT_NAME = "bind"
+INITSCRIPT_PARAMS = "defaults"
+
+SYSTEMD_SERVICE_${PN} = "named.service"
+
+do_install_append() {
+
+	rmdir "${D}${localstatedir}/run"
+	rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
+	install -d -o bind "${D}${localstatedir}/cache/bind"
+	install -d "${D}${sysconfdir}/bind"
+	install -d "${D}${sysconfdir}/init.d"
+	install -m 644 ${S}/conf/* "${D}${sysconfdir}/bind/"
+	install -m 755 "${S}/init.d" "${D}${sysconfdir}/init.d/bind"
+        if ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'true', 'false', d)}; then
+		sed -i -e '1s,#!.*python3,#! /usr/bin/python3,' \
+		${D}${sbindir}/dnssec-coverage \
+		${D}${sbindir}/dnssec-checkds \
+		${D}${sbindir}/dnssec-keymgr
+	fi
+
+	# Install systemd related files
+	install -d ${D}${sbindir}
+	install -m 755 ${WORKDIR}/generate-rndc-key.sh ${D}${sbindir}
+	install -d ${D}${systemd_unitdir}/system
+	install -m 0644 ${WORKDIR}/named.service ${D}${systemd_unitdir}/system
+	sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
+	       -e 's,@SBINDIR@,${sbindir},g' \
+	       ${D}${systemd_unitdir}/system/named.service
+
+	install -d ${D}${sysconfdir}/default
+	install -m 0644 ${WORKDIR}/bind9 ${D}${sysconfdir}/default
+
+	if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
+		install -d ${D}${sysconfdir}/tmpfiles.d
+		echo "d /run/named 0755 bind bind - -" > ${D}${sysconfdir}/tmpfiles.d/bind.conf
+	fi
+
+    oe_multilib_header isc/platform.h
+}
+
+CONFFILES_${PN} = " \
+	${sysconfdir}/bind/named.conf \
+	${sysconfdir}/bind/named.conf.local \
+	${sysconfdir}/bind/named.conf.options \
+	${sysconfdir}/bind/db.0 \
+	${sysconfdir}/bind/db.127 \
+	${sysconfdir}/bind/db.empty \
+	${sysconfdir}/bind/db.local \
+	${sysconfdir}/bind/db.root \
+	"
+
+ALTERNATIVE_${PN}-utils = "nslookup"
+ALTERNATIVE_LINK_NAME[nslookup] = "${bindir}/nslookup"
+ALTERNATIVE_PRIORITY = "100"
+
+PACKAGE_BEFORE_PN += "${PN}-utils"
+FILES_${PN}-utils = "${bindir}/host ${bindir}/dig ${bindir}/mdig ${bindir}/nslookup ${bindir}/nsupdate"
+FILES_${PN}-dev += "${bindir}/isc-config.h"
+FILES_${PN} += "${sbindir}/generate-rndc-key.sh"
+
+PACKAGE_BEFORE_PN += "${PN}-libs"
+FILES_${PN}-libs = "${libdir}/*.so* ${libdir}/named/*.so*"
+FILES_${PN}-staticdev += "${libdir}/*.la"
+
+PACKAGE_BEFORE_PN += "${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3-bind', '', d)}"
+FILES_python3-bind = "${sbindir}/dnssec-coverage ${sbindir}/dnssec-checkds \
+                ${sbindir}/dnssec-keymgr ${PYTHON_SITEPACKAGES_DIR}"
+
+RDEPENDS_${PN}-dev = ""
+RDEPENDS_python3-bind = "python3-core python3-ply"
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [PATCH 8/8] bind: 9.11 remove
  2020-09-01 15:22 [PATCH 1/8] log4cplus: move meta-oe pkg to core akuster
                   ` (5 preceding siblings ...)
  2020-09-01 15:22 ` [PATCH 7/8] bind: Add 9.16.x akuster
@ 2020-09-01 15:22 ` akuster
  2020-09-01 15:32 ` ✗ patchtest: failure for "log4cplus: move meta-oe pkg to..." and 7 more Patchwork
  7 siblings, 0 replies; 24+ messages in thread
From: akuster @ 2020-09-01 15:22 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Armin Kuster <akuster808@gmail.com>
---
 ...1-avoid-start-failure-with-bind-user.patch |  27 --
 ....in-remove-useless-L-use_openssl-lib.patch |  30 --
 ...d-V-and-start-log-hide-build-options.patch |  34 --
 ...ching-for-json-headers-searches-sysr.patch |  47 ---
 meta/recipes-connectivity/bind/bind/bind9     |   2 -
 .../recipes-connectivity/bind/bind/conf.patch | 330 ------------------
 .../bind/bind/generate-rndc-key.sh            |   8 -
 ...t.d-add-support-for-read-only-rootfs.patch |  65 ----
 .../bind/make-etc-initd-bind-stop-work.patch  |  42 ---
 .../bind/bind/named.service                   |  22 --
 .../recipes-connectivity/bind/bind_9.11.22.bb | 140 --------
 11 files changed, 747 deletions(-)
 delete mode 100644 meta/recipes-connectivity/bind/bind/0001-avoid-start-failure-with-bind-user.patch
 delete mode 100644 meta/recipes-connectivity/bind/bind/0001-configure.in-remove-useless-L-use_openssl-lib.patch
 delete mode 100644 meta/recipes-connectivity/bind/bind/0001-named-lwresd-V-and-start-log-hide-build-options.patch
 delete mode 100644 meta/recipes-connectivity/bind/bind/bind-ensure-searching-for-json-headers-searches-sysr.patch
 delete mode 100644 meta/recipes-connectivity/bind/bind/bind9
 delete mode 100644 meta/recipes-connectivity/bind/bind/conf.patch
 delete mode 100644 meta/recipes-connectivity/bind/bind/generate-rndc-key.sh
 delete mode 100644 meta/recipes-connectivity/bind/bind/init.d-add-support-for-read-only-rootfs.patch
 delete mode 100644 meta/recipes-connectivity/bind/bind/make-etc-initd-bind-stop-work.patch
 delete mode 100644 meta/recipes-connectivity/bind/bind/named.service
 delete mode 100644 meta/recipes-connectivity/bind/bind_9.11.22.bb

diff --git a/meta/recipes-connectivity/bind/bind/0001-avoid-start-failure-with-bind-user.patch b/meta/recipes-connectivity/bind/bind/0001-avoid-start-failure-with-bind-user.patch
deleted file mode 100644
index 8db96ec049c..00000000000
--- a/meta/recipes-connectivity/bind/bind/0001-avoid-start-failure-with-bind-user.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 31dde3562f287429eea94b77250d184818b49063 Mon Sep 17 00:00:00 2001
-From: Chen Qi <Qi.Chen@windriver.com>
-Date: Mon, 15 Oct 2018 16:55:09 +0800
-Subject: [PATCH] avoid start failure with bind user
-
-Upstream-Status: Pending
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- init.d | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/init.d b/init.d
-index b2eec60..6e03936 100644
---- a/init.d
-+++ b/init.d
-@@ -57,6 +57,7 @@ case "$1" in
- 	modprobe capability >/dev/null 2>&1 || true
- 	if [ ! -f /etc/bind/rndc.key ]; then
- 	    /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
-+	    chown root:bind /etc/bind/rndc.key >/dev/null 2>&1 || true
- 	    chmod 0640 /etc/bind/rndc.key
- 	fi
- 	if [ -f /var/run/named/named.pid ]; then
--- 
-2.7.4
-
diff --git a/meta/recipes-connectivity/bind/bind/0001-configure.in-remove-useless-L-use_openssl-lib.patch b/meta/recipes-connectivity/bind/bind/0001-configure.in-remove-useless-L-use_openssl-lib.patch
deleted file mode 100644
index 9d31b980807..00000000000
--- a/meta/recipes-connectivity/bind/bind/0001-configure.in-remove-useless-L-use_openssl-lib.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 2325a92f1896a2a7f586611686801b41fbc91b50 Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Mon, 27 Aug 2018 15:00:51 +0800
-Subject: [PATCH] configure.in: remove useless `-L$use_openssl/lib'
-
-Since `--with-openssl=${STAGING_DIR_HOST}${prefix}' is used in bind recipe,
-the `-L$use_openssl/lib' has a hardcoded suffix, removing it is harmless
-and helpful for clean up host build path in isc-config.sh
-
-Upstream-Status: Inappropriate [oe-core specific]
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
-
----
- configure.ac | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/configure.ac b/configure.ac
-index e85a5c6..2bbfc58 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -1631,7 +1631,7 @@ If you don't want OpenSSL, use --without-openssl])
- 				fi
- 				;;
- 			*)
--				DST_OPENSSL_LIBS="-L$use_openssl/lib -lcrypto"
-+				DST_OPENSSL_LIBS="-lcrypto"
- 				;;
- 			esac
- 		fi
diff --git a/meta/recipes-connectivity/bind/bind/0001-named-lwresd-V-and-start-log-hide-build-options.patch b/meta/recipes-connectivity/bind/bind/0001-named-lwresd-V-and-start-log-hide-build-options.patch
deleted file mode 100644
index 75908aa638f..00000000000
--- a/meta/recipes-connectivity/bind/bind/0001-named-lwresd-V-and-start-log-hide-build-options.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From a3af4a405baf5ff582e82aaba392dd9667d94bdc Mon Sep 17 00:00:00 2001
-From: Hongxu Jia <hongxu.jia@windriver.com>
-Date: Mon, 27 Aug 2018 21:24:20 +0800
-Subject: [PATCH] `named/lwresd -V' and start log hide build options
-
-The build options expose build path directories, so hide them.
-[snip]
-$ named -V
-|built by make with *** (options are hidden)
-[snip]
-
-Upstream-Status: Inappropriate [oe-core specific]
-
-Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
----
- bin/named/include/named/globals.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/bin/named/include/named/globals.h b/bin/named/include/named/globals.h
-index ba3457e..7741da7 100644
---- a/bin/named/include/named/globals.h
-+++ b/bin/named/include/named/globals.h
-@@ -68,7 +68,7 @@ EXTERN const char *		ns_g_version		INIT(VERSION);
- EXTERN const char *		ns_g_product		INIT(PRODUCT);
- EXTERN const char *		ns_g_description	INIT(DESCRIPTION);
- EXTERN const char *		ns_g_srcid		INIT(SRCID);
--EXTERN const char *		ns_g_configargs		INIT(CONFIGARGS);
-+EXTERN const char *		ns_g_configargs		INIT("*** (options are hidden)");
- EXTERN const char *		ns_g_builder		INIT(BUILDER);
- EXTERN in_port_t		ns_g_port		INIT(0);
- EXTERN isc_dscp_t		ns_g_dscp		INIT(-1);
--- 
-2.7.4
-
diff --git a/meta/recipes-connectivity/bind/bind/bind-ensure-searching-for-json-headers-searches-sysr.patch b/meta/recipes-connectivity/bind/bind/bind-ensure-searching-for-json-headers-searches-sysr.patch
deleted file mode 100644
index 84559e5f378..00000000000
--- a/meta/recipes-connectivity/bind/bind/bind-ensure-searching-for-json-headers-searches-sysr.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From edda20fb5a6e88548f85e39d34d6c074306e15bc Mon Sep 17 00:00:00 2001
-From: Paul Gortmaker <paul.gortmaker@windriver.com>
-Date: Tue, 9 Jun 2015 11:22:00 -0400
-Subject: [PATCH] bind: ensure searching for json headers searches sysroot
-
-Bind can fail configure by detecting headers w/o libs[1], or
-it can fail the host contamination check as per below:
-
-ERROR: This autoconf log indicates errors, it looked at host include and/or library paths while determining system capabilities.
-Rerun configure task after fixing this. The path was 'build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/build'
-ERROR: Function failed: do_qa_configure
-ERROR: Logfile of failure stored in: build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/temp/log.do_configure.5242
-ERROR: Task 5 (meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure) failed with exit code '1'
-NOTE: Tasks Summary: Attempted 773 tasks of which 768 didn't need to be rerun and 1 failed.
-No currently running tasks (773 of 781)
-
-Summary: 1 task failed:
-  /meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure
-
-One way to fix it would be to unconditionally disable json in bind
-configure[2] but here we fix it by using the path to where we would
-put the header if we had json in the sysroot, in case someone wants
-to make use of the combination some day.
-
-[1] https://trac.macports.org/ticket/45305
-[2] https://trac.macports.org/changeset/126406
-
-Upstream-Status: Inappropriate [OE Specific]
-Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
-
----
- configure.ac | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/configure.ac b/configure.ac
-index 17392fd..e85a5c6 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -2449,7 +2449,7 @@ case "$use_libjson" in
- 		libjson_libs=""
- 		;;
- 	auto|yes)
--		for d in /usr /usr/local /opt/local
-+		for d in "${STAGING_INCDIR}"
- 		do
- 			if test -f "${d}/include/json/json.h"
- 			then
diff --git a/meta/recipes-connectivity/bind/bind/bind9 b/meta/recipes-connectivity/bind/bind/bind9
deleted file mode 100644
index 968679ff7f7..00000000000
--- a/meta/recipes-connectivity/bind/bind/bind9
+++ /dev/null
@@ -1,2 +0,0 @@
-# startup options for the server
-OPTIONS="-u bind"
diff --git a/meta/recipes-connectivity/bind/bind/conf.patch b/meta/recipes-connectivity/bind/bind/conf.patch
deleted file mode 100644
index aad345f9fcf..00000000000
--- a/meta/recipes-connectivity/bind/bind/conf.patch
+++ /dev/null
@@ -1,330 +0,0 @@
-Upstream-Status: Inappropriate [configuration]
-
-the patch is imported from openembedded project
-
-11/30/2010 - Qing He <qing.he@intel.com>
-
-diff -urN bind-9.3.1.orig/conf/db.0 bind-9.3.1/conf/db.0
---- bind-9.3.1.orig/conf/db.0	1970-01-01 01:00:00.000000000 +0100
-+++ bind-9.3.1/conf/db.0	2005-07-10 22:14:00.000000000 +0200
-@@ -0,0 +1,12 @@
-+;
-+; BIND reverse data file for broadcast zone
-+;
-+$TTL	604800
-+@	IN	SOA	localhost. root.localhost. (
-+			      1		; Serial
-+			 604800		; Refresh
-+			  86400		; Retry
-+			2419200		; Expire
-+			 604800 )	; Negative Cache TTL
-+;
-+@	IN	NS	localhost.
-diff -urN bind-9.3.1.orig/conf/db.127 bind-9.3.1/conf/db.127
---- bind-9.3.1.orig/conf/db.127	1970-01-01 01:00:00.000000000 +0100
-+++ bind-9.3.1/conf/db.127	2005-07-10 22:14:00.000000000 +0200
-@@ -0,0 +1,13 @@
-+;
-+; BIND reverse data file for local loopback interface
-+;
-+$TTL	604800
-+@	IN	SOA	localhost. root.localhost. (
-+			      1		; Serial
-+			 604800		; Refresh
-+			  86400		; Retry
-+			2419200		; Expire
-+			 604800 )	; Negative Cache TTL
-+;
-+@	IN	NS	localhost.
-+1.0.0	IN	PTR	localhost.
-diff -urN bind-9.3.1.orig/conf/db.empty bind-9.3.1/conf/db.empty
---- bind-9.3.1.orig/conf/db.empty	1970-01-01 01:00:00.000000000 +0100
-+++ bind-9.3.1/conf/db.empty	2005-07-10 22:14:00.000000000 +0200
-@@ -0,0 +1,14 @@
-+; BIND reverse data file for empty rfc1918 zone
-+;
-+; DO NOT EDIT THIS FILE - it is used for multiple zones.
-+; Instead, copy it, edit named.conf, and use that copy.
-+;
-+$TTL	86400
-+@	IN	SOA	localhost. root.localhost. (
-+			      1		; Serial
-+			 604800		; Refresh
-+			  86400		; Retry
-+			2419200		; Expire
-+			  86400 )	; Negative Cache TTL
-+;
-+@	IN	NS	localhost.
-diff -urN bind-9.3.1.orig/conf/db.255 bind-9.3.1/conf/db.255
---- bind-9.3.1.orig/conf/db.255	1970-01-01 01:00:00.000000000 +0100
-+++ bind-9.3.1/conf/db.255	2005-07-10 22:14:00.000000000 +0200
-@@ -0,0 +1,12 @@
-+;
-+; BIND reserve data file for broadcast zone
-+;
-+$TTL	604800
-+@	IN	SOA	localhost. root.localhost. (
-+			      1		; Serial
-+			 604800		; Refresh
-+			  86400		; Retry
-+			2419200		; Expire
-+			 604800 )	; Negative Cache TTL
-+;
-+@	IN	NS	localhost.
-diff -urN bind-9.3.1.orig/conf/db.local bind-9.3.1/conf/db.local
---- bind-9.3.1.orig/conf/db.local	1970-01-01 01:00:00.000000000 +0100
-+++ bind-9.3.1/conf/db.local	2005-07-10 22:14:00.000000000 +0200
-@@ -0,0 +1,13 @@
-+;
-+; BIND data file for local loopback interface
-+;
-+$TTL	604800
-+@	IN	SOA	localhost. root.localhost. (
-+			      1		; Serial
-+			 604800		; Refresh
-+			  86400		; Retry
-+			2419200		; Expire
-+			 604800 )	; Negative Cache TTL
-+;
-+@	IN	NS	localhost.
-+@	IN	A	127.0.0.1
-diff -urN bind-9.3.1.orig/conf/db.root bind-9.3.1/conf/db.root
---- bind-9.3.1.orig/conf/db.root	1970-01-01 01:00:00.000000000 +0100
-+++ bind-9.3.1/conf/db.root	2005-07-10 22:14:00.000000000 +0200
-@@ -0,0 +1,45 @@
-+
-+; <<>> DiG 9.2.3 <<>> ns . @a.root-servers.net.
-+;; global options:  printcmd
-+;; Got answer:
-+;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 18944
-+;; flags: qr aa rd; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 13
-+
-+;; QUESTION SECTION:
-+;.				IN	NS
-+
-+;; ANSWER SECTION:
-+.			518400	IN	NS	A.ROOT-SERVERS.NET.
-+.			518400	IN	NS	B.ROOT-SERVERS.NET.
-+.			518400	IN	NS	C.ROOT-SERVERS.NET.
-+.			518400	IN	NS	D.ROOT-SERVERS.NET.
-+.			518400	IN	NS	E.ROOT-SERVERS.NET.
-+.			518400	IN	NS	F.ROOT-SERVERS.NET.
-+.			518400	IN	NS	G.ROOT-SERVERS.NET.
-+.			518400	IN	NS	H.ROOT-SERVERS.NET.
-+.			518400	IN	NS	I.ROOT-SERVERS.NET.
-+.			518400	IN	NS	J.ROOT-SERVERS.NET.
-+.			518400	IN	NS	K.ROOT-SERVERS.NET.
-+.			518400	IN	NS	L.ROOT-SERVERS.NET.
-+.			518400	IN	NS	M.ROOT-SERVERS.NET.
-+
-+;; ADDITIONAL SECTION:
-+A.ROOT-SERVERS.NET.	3600000	IN	A	198.41.0.4
-+B.ROOT-SERVERS.NET.	3600000	IN	A	192.228.79.201
-+C.ROOT-SERVERS.NET.	3600000	IN	A	192.33.4.12
-+D.ROOT-SERVERS.NET.	3600000	IN	A	128.8.10.90
-+E.ROOT-SERVERS.NET.	3600000	IN	A	192.203.230.10
-+F.ROOT-SERVERS.NET.	3600000	IN	A	192.5.5.241
-+G.ROOT-SERVERS.NET.	3600000	IN	A	192.112.36.4
-+H.ROOT-SERVERS.NET.	3600000	IN	A	128.63.2.53
-+I.ROOT-SERVERS.NET.	3600000	IN	A	192.36.148.17
-+J.ROOT-SERVERS.NET.	3600000	IN	A	192.58.128.30
-+K.ROOT-SERVERS.NET.	3600000	IN	A	193.0.14.129
-+L.ROOT-SERVERS.NET.	3600000	IN	A	198.32.64.12
-+M.ROOT-SERVERS.NET.	3600000	IN	A	202.12.27.33
-+
-+;; Query time: 81 msec
-+;; SERVER: 198.41.0.4#53(a.root-servers.net.)
-+;; WHEN: Sun Feb  1 11:27:14 2004
-+;; MSG SIZE  rcvd: 436
-+
-diff -urN bind-9.3.1.orig/conf/named.conf bind-9.3.1/conf/named.conf
---- bind-9.3.1.orig/conf/named.conf	1970-01-01 01:00:00.000000000 +0100
-+++ bind-9.3.1/conf/named.conf	2005-07-10 22:33:46.000000000 +0200
-@@ -0,0 +1,49 @@
-+// This is the primary configuration file for the BIND DNS server named.
-+//
-+// If you are just adding zones, please do that in /etc/bind/named.conf.local
-+
-+include "/etc/bind/named.conf.options";
-+
-+// prime the server with knowledge of the root servers
-+zone "." {
-+	type hint;
-+	file "/etc/bind/db.root";
-+};
-+
-+// be authoritative for the localhost forward and reverse zones, and for
-+// broadcast zones as per RFC 1912
-+
-+zone "localhost" {
-+	type master;
-+	file "/etc/bind/db.local";
-+};
-+
-+zone "127.in-addr.arpa" {
-+	type master;
-+	file "/etc/bind/db.127";
-+};
-+
-+zone "0.in-addr.arpa" {
-+	type master;
-+	file "/etc/bind/db.0";
-+};
-+
-+zone "255.in-addr.arpa" {
-+	type master;
-+	file "/etc/bind/db.255";
-+};
-+
-+// zone "com" { type delegation-only; };
-+// zone "net" { type delegation-only; };
-+
-+// From the release notes:
-+//  Because many of our users are uncomfortable receiving undelegated answers
-+//  from root or top level domains, other than a few for whom that behaviour
-+//  has been trusted and expected for quite some length of time, we have now
-+//  introduced the "root-delegations-only" feature which applies delegation-only
-+//  logic to all top level domains, and to the root domain.  An exception list
-+//  should be specified, including "MUSEUM" and "DE", and any other top level
-+//  domains from whom undelegated responses are expected and trusted.
-+// root-delegation-only exclude { "DE"; "MUSEUM"; };
-+
-+include "/etc/bind/named.conf.local";
-diff -urN bind-9.3.1.orig/conf/named.conf.local bind-9.3.1/conf/named.conf.local
---- bind-9.3.1.orig/conf/named.conf.local	1970-01-01 01:00:00.000000000 +0100
-+++ bind-9.3.1/conf/named.conf.local	2005-07-10 22:14:06.000000000 +0200
-@@ -0,0 +1,8 @@
-+//
-+// Do any local configuration here
-+//
-+
-+// Consider adding the 1918 zones here, if they are not used in your
-+// organization
-+//include "/etc/bind/zones.rfc1918";
-+
-diff -urN bind-9.3.1.orig/conf/named.conf.options bind-9.3.1/conf/named.conf.options
---- bind-9.3.1.orig/conf/named.conf.options	1970-01-01 01:00:00.000000000 +0100
-+++ bind-9.3.1/conf/named.conf.options	2005-07-10 22:14:06.000000000 +0200
-@@ -0,0 +1,24 @@
-+options {
-+	directory "/var/cache/bind";
-+
-+	// If there is a firewall between you and nameservers you want
-+	// to talk to, you might need to uncomment the query-source
-+	// directive below.  Previous versions of BIND always asked
-+	// questions using port 53, but BIND 8.1 and later use an unprivileged
-+	// port by default.
-+
-+	// query-source address * port 53;
-+
-+	// If your ISP provided one or more IP addresses for stable 
-+	// nameservers, you probably want to use them as forwarders.  
-+	// Uncomment the following block, and insert the addresses replacing 
-+	// the all-0's placeholder.
-+
-+	// forwarders {
-+	// 	0.0.0.0;
-+	// };
-+
-+	auth-nxdomain no;    # conform to RFC1035
-+
-+};
-+
-diff -urN bind-9.3.1.orig/conf/zones.rfc1918 bind-9.3.1/conf/zones.rfc1918
---- bind-9.3.1.orig/conf/zones.rfc1918	1970-01-01 01:00:00.000000000 +0100
-+++ bind-9.3.1/conf/zones.rfc1918	2005-07-10 22:14:10.000000000 +0200
-@@ -0,0 +1,20 @@
-+zone "10.in-addr.arpa"      { type master; file "/etc/bind/db.empty"; };
-+ 
-+zone "16.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+zone "17.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+zone "18.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+zone "19.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+zone "20.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+zone "21.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+zone "22.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+zone "23.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+zone "24.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+zone "25.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+zone "26.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+zone "27.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+zone "28.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+zone "29.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+zone "30.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+zone "31.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
-+
-+zone "168.192.in-addr.arpa" { type master; file "/etc/bind/db.empty"; };
-diff -urN bind-9.3.1.orig/init.d bind-9.3.1/init.d
---- bind-9.3.1.orig/init.d	1970-01-01 01:00:00.000000000 +0100
-+++ bind-9.3.1/init.d	2005-07-10 23:09:58.000000000 +0200
-@@ -0,0 +1,70 @@
-+#!/bin/sh
-+
-+PATH=/sbin:/bin:/usr/sbin:/usr/bin
-+
-+# for a chrooted server: "-u bind -t /var/lib/named"
-+# Don't modify this line, change or create /etc/default/bind9.
-+OPTIONS=""
-+
-+test -f /etc/default/bind9 && . /etc/default/bind9
-+
-+test -x /usr/sbin/rndc || exit 0
-+
-+case "$1" in
-+    start)
-+	echo -n "Starting domain name service: named"
-+
-+	modprobe capability >/dev/null 2>&1 || true
-+	if [ ! -f /etc/bind/rndc.key ]; then
-+	    /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
-+	    chmod 0640 /etc/bind/rndc.key
-+	fi
-+	if [ -f /var/run/named/named.pid ]; then
-+	    ps `cat /var/run/named/named.pid` > /dev/null && exit 1
-+	fi
-+
-+	# dirs under /var/run can go away on reboots.
-+	mkdir -p /var/run/named
-+	mkdir -p /var/cache/bind
-+	chmod 775 /var/run/named
-+	chown root:bind /var/run/named >/dev/null 2>&1 || true
-+
-+	if [ ! -x /usr/sbin/named ]; then
-+	    echo "named binary missing - not starting"
-+	    exit 1
-+	fi
-+	if start-stop-daemon --start --quiet --exec /usr/sbin/named \
-+		--pidfile /var/run/named/named.pid -- $OPTIONS; then
-+	    if [ -x /sbin/resolvconf ] ; then
-+		echo "nameserver 127.0.0.1" | /sbin/resolvconf -a lo
-+	    fi
-+	fi
-+	echo "."	
-+    ;;
-+
-+    stop)
-+	echo -n "Stopping domain name service: named"
-+	if [ -x /sbin/resolvconf ]; then
-+	    /sbin/resolvconf -d lo
-+	fi
-+	/usr/sbin/rndc stop >/dev/null 2>&1
-+	echo "."	
-+    ;;
-+
-+    reload)
-+	/usr/sbin/rndc reload
-+    ;;
-+
-+    restart|force-reload)
-+	$0 stop
-+	sleep 2
-+	$0 start
-+    ;;
-+    
-+    *)
-+	echo "Usage: /etc/init.d/bind {start|stop|reload|restart|force-reload}" >&2
-+	exit 1
-+    ;;
-+esac
-+
-+exit 0
diff --git a/meta/recipes-connectivity/bind/bind/generate-rndc-key.sh b/meta/recipes-connectivity/bind/bind/generate-rndc-key.sh
deleted file mode 100644
index ef915c0ae5a..00000000000
--- a/meta/recipes-connectivity/bind/bind/generate-rndc-key.sh
+++ /dev/null
@@ -1,8 +0,0 @@
-#!/bin/sh
-
-if [ ! -s /etc/bind/rndc.key ]; then
-    echo -n "Generating /etc/bind/rndc.key:"
-    /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
-    chown root:bind /etc/bind/rndc.key
-    chmod 0640 /etc/bind/rndc.key
-fi
diff --git a/meta/recipes-connectivity/bind/bind/init.d-add-support-for-read-only-rootfs.patch b/meta/recipes-connectivity/bind/bind/init.d-add-support-for-read-only-rootfs.patch
deleted file mode 100644
index 11db95ede12..00000000000
--- a/meta/recipes-connectivity/bind/bind/init.d-add-support-for-read-only-rootfs.patch
+++ /dev/null
@@ -1,65 +0,0 @@
-Subject: init.d: add support for read-only rootfs
-
-Upstream-Status: Inappropriate [oe specific]
-
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- init.d |   40 ++++++++++++++++++++++++++++++++++++++++
- 1 file changed, 40 insertions(+)
-
-diff --git a/init.d b/init.d
-index 0111ed4..24677c8 100644
---- a/init.d
-+++ b/init.d
-@@ -6,8 +6,48 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin
- # Don't modify this line, change or create /etc/default/bind9.
- OPTIONS=""
- 
-+test -f /etc/default/rcS && . /etc/default/rcS
- test -f /etc/default/bind9 && . /etc/default/bind9
- 
-+# This function is here because it's possible that /var and / are on different partitions.
-+is_on_read_only_partition () {
-+    DIRECTORY=$1
-+    dir=`readlink -f $DIRECTORY`
-+    while true; do
-+	if [ ! -d "$dir" ]; then
-+	    echo "ERROR: $dir is not a directory"
-+	    exit 1
-+	else
-+	    for flag in `awk -v dir=$dir '{ if ($2 == dir) { print "FOUND"; split($4,FLAGS,",") } }; \
-+		END { for (f in FLAGS) print FLAGS[f] }' < /proc/mounts`; do
-+		[ "$flag" = "FOUND" ] && partition="read-write"
-+		[ "$flag" = "ro" ] && { partition="read-only"; break; }
-+	    done
-+	    if [ "$dir" = "/" -o -n "$partition" ]; then
-+		break
-+	    else
-+		dir=`dirname $dir`
-+	    fi
-+	fi
-+    done
-+    [ "$partition" = "read-only" ] && echo "yes" || echo "no"
-+}
-+
-+bind_mount () {
-+    olddir=$1
-+    newdir=$2
-+    mkdir -p $olddir
-+    cp -a $newdir/* $olddir
-+    mount --bind $olddir $newdir
-+}
-+
-+# Deal with read-only rootfs
-+if [ "$ROOTFS_READ_ONLY" = "yes" ]; then
-+    [ "$VERBOSE" != "no" ] && echo "WARN: start bind service in read-only rootfs"
-+    [ `is_on_read_only_partition /etc/bind` = "yes" ] && bind_mount /var/volatile/bind/etc /etc/bind
-+    [ `is_on_read_only_partition /var/named` = "yes" ] && bind_mount /var/volatile/bind/named /var/named
-+fi
-+
- test -x /usr/sbin/rndc || exit 0
- 
- case "$1" in
--- 
-1.7.9.5
-
diff --git a/meta/recipes-connectivity/bind/bind/make-etc-initd-bind-stop-work.patch b/meta/recipes-connectivity/bind/bind/make-etc-initd-bind-stop-work.patch
deleted file mode 100644
index 146f3e35db6..00000000000
--- a/meta/recipes-connectivity/bind/bind/make-etc-initd-bind-stop-work.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-bind: make "/etc/init.d/bind stop" work
-
-Upstream-Status: Inappropriate [configuration]
-
-Add some configurations, make rndc command be able to controls
-the named daemon.
-
-Signed-off-by: Roy Li <rongqing.li@windriver.com>
----
- conf/named.conf |    5 +++++
- conf/rndc.conf  |    5 +++++
- 2 files changed, 10 insertions(+), 0 deletions(-)
- create mode 100644 conf/rndc.conf
-
-diff --git a/conf/named.conf b/conf/named.conf
-index 95829cf..c8899e7 100644
---- a/conf/named.conf
-+++ b/conf/named.conf
-@@ -47,3 +47,8 @@ zone "255.in-addr.arpa" {
- // root-delegation-only exclude { "DE"; "MUSEUM"; };
- 
- include "/etc/bind/named.conf.local";
-+include "/etc/bind/rndc.key" ;
-+controls {
-+	inet 127.0.0.1 allow { localhost; }
-+	keys { rndc-key; };
-+};
-diff --git a/conf/rndc.conf b/conf/rndc.conf
-new file mode 100644
-index 0000000..a0b481d
---- /dev/null
-+++ b/conf/rndc.conf
-@@ -0,0 +1,5 @@
-+include "/etc/bind/rndc.key";
-+options {
-+	default-server  localhost;
-+	default-key     rndc-key;
-+};
-
--- 
-1.7.5.4
-
diff --git a/meta/recipes-connectivity/bind/bind/named.service b/meta/recipes-connectivity/bind/bind/named.service
deleted file mode 100644
index cda56ef0150..00000000000
--- a/meta/recipes-connectivity/bind/bind/named.service
+++ /dev/null
@@ -1,22 +0,0 @@
-[Unit]
-Description=Berkeley Internet Name Domain (DNS)
-Wants=nss-lookup.target
-Before=nss-lookup.target
-After=network.target
-
-[Service]
-Type=forking
-EnvironmentFile=-/etc/default/bind9
-PIDFile=/run/named/named.pid
-
-ExecStartPre=@SBINDIR@/generate-rndc-key.sh
-ExecStart=@SBINDIR@/named $OPTIONS
-
-ExecReload=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc reload > /dev/null 2>&1 || @BASE_BINDIR@/kill -HUP $MAINPID'
-
-ExecStop=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc stop > /dev/null 2>&1 || @BASE_BINDIR@/kill -TERM $MAINPID'
-
-PrivateTmp=true
-
-[Install]
-WantedBy=multi-user.target
diff --git a/meta/recipes-connectivity/bind/bind_9.11.22.bb b/meta/recipes-connectivity/bind/bind_9.11.22.bb
deleted file mode 100644
index 7128bd3870c..00000000000
--- a/meta/recipes-connectivity/bind/bind_9.11.22.bb
+++ /dev/null
@@ -1,140 +0,0 @@
-SUMMARY = "ISC Internet Domain Name Server"
-HOMEPAGE = "http://www.isc.org/sw/bind/"
-SECTION = "console/network"
-
-LICENSE = "ISC & BSD"
-LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=bf39058a7f64b2a934ce14dc9ec1dd45"
-
-DEPENDS = "openssl libcap zlib"
-
-SRC_URI = "https://ftp.isc.org/isc/bind9/${PV}/${BPN}-${PV}.tar.gz \
-           file://conf.patch \
-           file://named.service \
-           file://bind9 \
-           file://generate-rndc-key.sh \
-           file://make-etc-initd-bind-stop-work.patch \
-           file://init.d-add-support-for-read-only-rootfs.patch \
-           file://bind-ensure-searching-for-json-headers-searches-sysr.patch \
-           file://0001-configure.in-remove-useless-L-use_openssl-lib.patch \
-           file://0001-named-lwresd-V-and-start-log-hide-build-options.patch \
-           file://0001-avoid-start-failure-with-bind-user.patch \
-           "
-
-SRC_URI[sha256sum] = "afc6d8015006f1cabf699ff19f517bb8fd9c1811e5231f26baf51c3550262ac9"
-
-UPSTREAM_CHECK_URI = "https://ftp.isc.org/isc/bind9/"
-# stay at 9.11 until 9.16, from 9.16 follow the ESV versions divisible by 4
-UPSTREAM_CHECK_REGEX = "(?P<pver>9.(11|16|20|24|28)(\.\d+)+(-P\d+)*)/"
-
-# BIND >= 9.11.2 need dhcpd >= 4.4.0,
-# don't report it here since dhcpd is already recent enough.
-CVE_CHECK_WHITELIST += "CVE-2019-6470"
-
-inherit autotools update-rc.d systemd useradd pkgconfig multilib_script multilib_header
-
-MULTILIB_SCRIPTS = "${PN}:${bindir}/bind9-config ${PN}:${bindir}/isc-config.sh"
-
-# PACKAGECONFIGs readline and libedit should NOT be set at same time
-PACKAGECONFIG ?= "readline"
-PACKAGECONFIG[httpstats] = "--with-libxml2=${STAGING_DIR_HOST}${prefix},--without-libxml2,libxml2"
-PACKAGECONFIG[readline] = "--with-readline=-lreadline,,readline"
-PACKAGECONFIG[libedit] = "--with-readline=-ledit,,libedit"
-PACKAGECONFIG[urandom] = "--with-randomdev=/dev/urandom,--with-randomdev=/dev/random,,"
-PACKAGECONFIG[python3] = "--with-python=yes --with-python-install-dir=${PYTHON_SITEPACKAGES_DIR} , --without-python, python3-ply-native,"
-
-ENABLE_IPV6 = "--enable-ipv6=${@bb.utils.contains('DISTRO_FEATURES', 'ipv6', 'yes', 'no', d)}"
-EXTRA_OECONF = " ${ENABLE_IPV6} --with-libtool --enable-threads \
-                 --disable-devpoll --enable-epoll --with-gost=no \
-                 --with-gssapi=no --with-ecdsa=yes --with-eddsa=no \
-                 --with-lmdb=no \
-                 --sysconfdir=${sysconfdir}/bind \
-                 --with-openssl=${STAGING_DIR_HOST}${prefix} \
-               "
-
-inherit ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3native distutils3-base', '', d)}
-
-# dhcp needs .la so keep them
-REMOVE_LIBTOOL_LA = "0"
-
-USERADD_PACKAGES = "${PN}"
-USERADD_PARAM_${PN} = "--system --home ${localstatedir}/cache/bind --no-create-home \
-                       --user-group bind"
-
-INITSCRIPT_NAME = "bind"
-INITSCRIPT_PARAMS = "defaults"
-
-SYSTEMD_SERVICE_${PN} = "named.service"
-
-do_install_prepend() {
-	# clean host path in isc-config.sh before the hardlink created
-	# by "make install":
-	#   bind9-config -> isc-config.sh
-	sed -i -e "s,${STAGING_LIBDIR},${libdir}," ${B}/isc-config.sh
-}
-
-do_install_append() {
-
-	rmdir "${D}${localstatedir}/run"
-	rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
-	install -d -o bind "${D}${localstatedir}/cache/bind"
-	install -d "${D}${sysconfdir}/bind"
-	install -d "${D}${sysconfdir}/init.d"
-	install -m 644 ${S}/conf/* "${D}${sysconfdir}/bind/"
-	install -m 755 "${S}/init.d" "${D}${sysconfdir}/init.d/bind"
-        if ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'true', 'false', d)}; then
-		sed -i -e '1s,#!.*python3,#! /usr/bin/python3,' \
-		${D}${sbindir}/dnssec-coverage \
-		${D}${sbindir}/dnssec-checkds \
-		${D}${sbindir}/dnssec-keymgr
-	fi
-
-	# Install systemd related files
-	install -d ${D}${sbindir}
-	install -m 755 ${WORKDIR}/generate-rndc-key.sh ${D}${sbindir}
-	install -d ${D}${systemd_unitdir}/system
-	install -m 0644 ${WORKDIR}/named.service ${D}${systemd_unitdir}/system
-	sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
-	       -e 's,@SBINDIR@,${sbindir},g' \
-	       ${D}${systemd_unitdir}/system/named.service
-
-	install -d ${D}${sysconfdir}/default
-	install -m 0644 ${WORKDIR}/bind9 ${D}${sysconfdir}/default
-
-	if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
-		install -d ${D}${sysconfdir}/tmpfiles.d
-		echo "d /run/named 0755 bind bind - -" > ${D}${sysconfdir}/tmpfiles.d/bind.conf
-	fi
-
-    oe_multilib_header isc/platform.h
-}
-
-CONFFILES_${PN} = " \
-	${sysconfdir}/bind/named.conf \
-	${sysconfdir}/bind/named.conf.local \
-	${sysconfdir}/bind/named.conf.options \
-	${sysconfdir}/bind/db.0 \
-	${sysconfdir}/bind/db.127 \
-	${sysconfdir}/bind/db.empty \
-	${sysconfdir}/bind/db.local \
-	${sysconfdir}/bind/db.root \
-	"
-
-ALTERNATIVE_${PN}-utils = "nslookup"
-ALTERNATIVE_LINK_NAME[nslookup] = "${bindir}/nslookup"
-ALTERNATIVE_PRIORITY = "100"
-
-PACKAGE_BEFORE_PN += "${PN}-utils"
-FILES_${PN}-utils = "${bindir}/host ${bindir}/dig ${bindir}/mdig ${bindir}/nslookup ${bindir}/nsupdate"
-FILES_${PN}-dev += "${bindir}/isc-config.h"
-FILES_${PN} += "${sbindir}/generate-rndc-key.sh"
-
-PACKAGE_BEFORE_PN += "${PN}-libs"
-FILES_${PN}-libs = "${libdir}/*.so*"
-FILES_${PN}-staticdev += "${libdir}/*.la"
-
-PACKAGE_BEFORE_PN += "${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3-bind', '', d)}"
-FILES_python3-bind = "${sbindir}/dnssec-coverage ${sbindir}/dnssec-checkds \
-                ${sbindir}/dnssec-keymgr ${PYTHON_SITEPACKAGES_DIR}"
-
-RDEPENDS_${PN}-dev = ""
-RDEPENDS_python3-bind = "python3-core python3-ply"
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 24+ messages in thread

* ✗ patchtest: failure for "log4cplus: move meta-oe pkg to..." and 7 more
  2020-09-01 15:22 [PATCH 1/8] log4cplus: move meta-oe pkg to core akuster
                   ` (6 preceding siblings ...)
  2020-09-01 15:22 ` [PATCH 8/8] bind: 9.11 remove akuster
@ 2020-09-01 15:32 ` Patchwork
  7 siblings, 0 replies; 24+ messages in thread
From: Patchwork @ 2020-09-01 15:32 UTC (permalink / raw)
  To: Armin Kuster; +Cc: openembedded-core

== Series Details ==

Series: "log4cplus: move meta-oe pkg to..." and 7 more
Revision: 1
URL   : https://patchwork.openembedded.org/series/25890/
State : failure

== Summary ==


Thank you for submitting this patch series to OpenEmbedded Core. This is
an automated response. Several tests have been executed on the proposed
series by patchtest resulting in the following failures:



* Issue             A patch file has been added, but does not have a Signed-off-by tag [test_signed_off_by_presence] 
  Suggested fix    Sign off the added patch file (meta/recipes-connectivity/bind/bind-9.16.5/conf.patch)



If you believe any of these test results are incorrect, please reply to the
mailing list (openembedded-core@lists.openembedded.org) raising your concerns.
Otherwise we would appreciate you correcting the issues and submitting a new
version of the patchset if applicable. Please ensure you add/increment the
version number when sending the new version (i.e. [PATCH] -> [PATCH v2] ->
[PATCH v3] -> ...).

---
Guidelines:     https://www.openembedded.org/wiki/Commit_Patch_Message_Guidelines
Test framework: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest
Test suite:     http://git.yoctoproject.org/cgit/cgit.cgi/patchtest-oe


^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [OE-core] [PATCH 6/8] dhcp: remove from core
  2020-09-01 15:22 ` [PATCH 6/8] dhcp: remove from core akuster
@ 2020-09-01 18:10   ` Khem Raj
  2020-09-01 19:15     ` Diego Sueiro
  2020-09-01 20:39     ` akuster
  2020-10-21  1:34   ` Paul Eggleton
  1 sibling, 2 replies; 24+ messages in thread
From: Khem Raj @ 2020-09-01 18:10 UTC (permalink / raw)
  To: akuster; +Cc: Patches and discussions about the oe-core layer

it seems its used by
build-appliance-image and packagegroup-core-base-utils so you need to
take care of that as well. in meta-networking networkmanager recipe
depends on it too which I think I can take care.

On Tue, Sep 1, 2020 at 8:23 AM akuster <akuster808@gmail.com> wrote:
>
> update maintainers.inc too
>
> Signed-off-by: Armin Kuster <akuster808@gmail.com>
> ---
>  meta/conf/distro/include/maintainers.inc      |   1 -
>  meta/recipes-connectivity/dhcp/dhcp.inc       | 149 ------------------
>  ...TH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch |  27 ----
>  ...-limitation-in-linux-dhclient-script.patch |  65 --------
>  .../dhcp/dhcp/0002-dhclient-dbus.patch        | 117 --------------
>  .../dhcp/dhcp/0003-link-with-lcrypto.patch    |  35 ----
>  .../dhcp/0004-Fix-out-of-tree-builds.patch    |  95 -----------
>  ...invoke-dhclient-script-failed-on-Rea.patch |  36 -----
>  ...gument-to-make-the-libxml2-dependenc.patch |  62 --------
>  ...move-dhclient-script-bash-dependency.patch |  28 ----
>  ...ct-the-intention-for-xml2-lib-search.patch |  34 ----
>  .../dhcp/dhcp/0013-fixup_use_libbind.patch    |  64 --------
>  meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb  |  23 ---
>  .../dhcp/files/default-relay                  |  12 --
>  .../dhcp/files/default-server                 |   7 -
>  .../dhcp/files/dhclient-systemd-wrapper       |  39 -----
>  .../dhcp/files/dhclient.conf                  |  50 ------
>  .../dhcp/files/dhclient.service               |  13 --
>  .../dhcp/files/dhcpd.conf                     | 108 -------------
>  .../dhcp/files/dhcpd.service                  |  15 --
>  .../dhcp/files/dhcpd6.service                 |  15 --
>  .../dhcp/files/dhcrelay.service               |  10 --
>  .../dhcp/files/init-relay                     |  44 ------
>  .../dhcp/files/init-server                    |  44 ------
>  24 files changed, 1093 deletions(-)
>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp.inc
>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch
>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0001-workaround-busybox-limitation-in-linux-dhclient-script.patch
>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch
>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch
>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch
>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch
>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch
>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0009-remove-dhclient-script-bash-dependency.patch
>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch
>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch
>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb
>  delete mode 100644 meta/recipes-connectivity/dhcp/files/default-relay
>  delete mode 100644 meta/recipes-connectivity/dhcp/files/default-server
>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhclient-systemd-wrapper
>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhclient.conf
>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhclient.service
>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcpd.conf
>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcpd.service
>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcpd6.service
>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcrelay.service
>  delete mode 100644 meta/recipes-connectivity/dhcp/files/init-relay
>  delete mode 100644 meta/recipes-connectivity/dhcp/files/init-server
>
> diff --git a/meta/conf/distro/include/maintainers.inc b/meta/conf/distro/include/maintainers.inc
> index 27e3474da8b..a55dbfa13c9 100644
> --- a/meta/conf/distro/include/maintainers.inc
> +++ b/meta/conf/distro/include/maintainers.inc
> @@ -143,7 +143,6 @@ RECIPE_MAINTAINER_pn-debianutils = "Yi Zhao <yi.zhao@windriver.com>"
>  RECIPE_MAINTAINER_pn-dejagnu = "Nathan Rossi <nathan@nathanrossi.com>"
>  RECIPE_MAINTAINER_pn-depmodwrapper-cross = "Unassigned <unassigned@yoctoproject.org>"
>  RECIPE_MAINTAINER_pn-desktop-file-utils = "Alexander Kanavin <alex.kanavin@gmail.com>"
> -RECIPE_MAINTAINER_pn-dhcp = "Hongxu Jia <hongxu.jia@windriver.com>"
>  RECIPE_MAINTAINER_pn-dhcpd = "Armin Kuster <akuster808@gmail.com>"
>  RECIPE_MAINTAINER_pn-diffoscope = "Joshua Watt <JPEWhacker@gmail.com>"
>  RECIPE_MAINTAINER_pn-diffstat = "Chen Qi <Qi.Chen@windriver.com>"
> diff --git a/meta/recipes-connectivity/dhcp/dhcp.inc b/meta/recipes-connectivity/dhcp/dhcp.inc
> deleted file mode 100644
> index d46130d49b9..00000000000
> --- a/meta/recipes-connectivity/dhcp/dhcp.inc
> +++ /dev/null
> @@ -1,149 +0,0 @@
> -SECTION = "console/network"
> -SUMMARY = "Internet Software Consortium DHCP package"
> -DESCRIPTION = "DHCP (Dynamic Host Configuration Protocol) is a protocol \
> -which allows individual devices on an IP network to get their own \
> -network configuration information from a server.  DHCP helps make it \
> -easier to administer devices."
> -
> -HOMEPAGE = "http://www.isc.org/"
> -
> -LICENSE = "ISC"
> -LIC_FILES_CHKSUM = "file://LICENSE;beginline=4;md5=004a4db50a1e20972e924a8618747c01"
> -
> -DEPENDS = "openssl bind"
> -
> -SRC_URI = "http://ftp.isc.org/isc/dhcp/${PV}/dhcp-${PV}.tar.gz \
> -           file://init-relay file://default-relay \
> -           file://init-server file://default-server \
> -           file://dhclient.conf file://dhcpd.conf \
> -           file://dhclient-systemd-wrapper \
> -           file://dhclient.service \
> -           file://dhcpd.service file://dhcrelay.service \
> -           file://dhcpd6.service \
> -           "
> -UPSTREAM_CHECK_URI = "http://ftp.isc.org/isc/dhcp/"
> -UPSTREAM_CHECK_REGEX = "(?P<pver>\d+\.\d+\.(\d+?))/"
> -
> -inherit autotools-brokensep systemd useradd update-rc.d
> -
> -USERADD_PACKAGES = "${PN}-server"
> -USERADD_PARAM_${PN}-server = "--system --no-create-home --home-dir /var/run/${BPN} --shell /bin/false --user-group ${BPN}"
> -
> -SYSTEMD_PACKAGES = "${PN}-server ${PN}-relay ${PN}-client"
> -SYSTEMD_SERVICE_${PN}-server = "dhcpd.service dhcpd6.service"
> -SYSTEMD_AUTO_ENABLE_${PN}-server = "disable"
> -
> -SYSTEMD_SERVICE_${PN}-relay = "dhcrelay.service"
> -SYSTEMD_AUTO_ENABLE_${PN}-relay = "disable"
> -
> -SYSTEMD_SERVICE_${PN}-client = "dhclient.service"
> -SYSTEMD_AUTO_ENABLE_${PN}-client = "disable"
> -
> -INITSCRIPT_PACKAGES = "dhcp-server"
> -INITSCRIPT_NAME_dhcp-server = "dhcp-server"
> -INITSCRIPT_PARAMS_dhcp-server = "defaults"
> -
> -CFLAGS += "-D_GNU_SOURCE"
> -EXTRA_OECONF = "--with-srv-lease-file=${localstatedir}/lib/dhcp/dhcpd.leases \
> -                --with-srv6-lease-file=${localstatedir}/lib/dhcp/dhcpd6.leases \
> -                --with-cli-lease-file=${localstatedir}/lib/dhcp/dhclient.leases \
> -                --with-cli6-lease-file=${localstatedir}/lib/dhcp/dhclient6.leases \
> -                --enable-paranoia --disable-static \
> -                --with-randomdev=/dev/random \
> -                --with-libbind=${STAGING_DIR_HOST} \
> -               --enable-libtool \
> -               "
> -
> -#Enable shared libs per dhcp README
> -do_configure_prepend () {
> -       cp configure.ac+lt configure.ac
> -}
> -
> -do_install_append () {
> -       install -d ${D}${sysconfdir}/init.d
> -       install -d ${D}${sysconfdir}/default
> -       install -d ${D}${sysconfdir}/dhcp
> -       install -m 0755 ${WORKDIR}/init-relay ${D}${sysconfdir}/init.d/dhcp-relay
> -       install -m 0644 ${WORKDIR}/default-relay ${D}${sysconfdir}/default/dhcp-relay
> -       install -m 0755 ${WORKDIR}/init-server ${D}${sysconfdir}/init.d/dhcp-server
> -       install -m 0644 ${WORKDIR}/default-server ${D}${sysconfdir}/default/dhcp-server
> -
> -       rm -f ${D}${sysconfdir}/dhclient.conf*
> -       rm -f ${D}${sysconfdir}/dhcpd.conf*
> -       install -m 0644 ${WORKDIR}/dhclient.conf ${D}${sysconfdir}/dhcp/dhclient.conf
> -       install -m 0644 ${WORKDIR}/dhcpd.conf ${D}${sysconfdir}/dhcp/dhcpd.conf
> -
> -       install -d ${D}${base_sbindir}/
> -       if [ "${sbindir}" != "${base_sbindir}" ]; then
> -               mv ${D}${sbindir}/dhclient ${D}${base_sbindir}/
> -       fi
> -       install -m 0755 ${S}/client/scripts/linux ${D}${base_sbindir}/dhclient-script
> -
> -       # Install systemd unit files
> -       install -d ${D}${systemd_unitdir}/system
> -       install -m 0644 ${WORKDIR}/dhcpd.service ${D}${systemd_unitdir}/system
> -       install -m 0644 ${WORKDIR}/dhcpd6.service ${D}${systemd_unitdir}/system
> -       install -m 0644 ${WORKDIR}/dhcrelay.service ${D}${systemd_unitdir}/system
> -       sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/dhcpd*.service ${D}${systemd_unitdir}/system/dhcrelay.service
> -       sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' ${D}${systemd_unitdir}/system/dhcpd*.service
> -       sed -i -e 's,@base_bindir@,${base_bindir},g' ${D}${systemd_unitdir}/system/dhcpd*.service
> -       sed -i -e 's,@localstatedir@,${localstatedir},g' ${D}${systemd_unitdir}/system/dhcpd*.service
> -       sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' ${D}${systemd_unitdir}/system/dhcrelay.service
> -
> -       install -d ${D}${base_sbindir}
> -       install -m 0755 ${WORKDIR}/dhclient-systemd-wrapper ${D}${base_sbindir}/dhclient-systemd-wrapper
> -       install -m 0644 ${WORKDIR}/dhclient.service ${D}${systemd_unitdir}/system
> -       sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' ${D}${systemd_unitdir}/system/dhclient.service
> -       sed -i -e 's,@BASE_SBINDIR@,${base_sbindir},g' ${D}${systemd_unitdir}/system/dhclient.service
> -}
> -
> -PACKAGES += "dhcp-libs dhcp-server dhcp-server-config dhcp-client dhcp-relay dhcp-omshell"
> -
> -PACKAGES_remove = "${PN}"
> -RDEPENDS_${PN}-client += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'iproute2', '', d)}"
> -RDEPENDS_${PN}-dev = ""
> -RDEPENDS_${PN}-staticdev = ""
> -FILES_${PN}-libs = "${libdir}/libdhcpctl.so.0* ${libdir}/libomapi.so.0* ${libdir}/libdhcp.so.0*"
> -
> -FILES_${PN}-server = "${sbindir}/dhcpd ${sysconfdir}/init.d/dhcp-server"
> -RRECOMMENDS_${PN}-server = "dhcp-server-config"
> -
> -FILES_${PN}-server-config = "${sysconfdir}/default/dhcp-server ${sysconfdir}/dhcp/dhcpd.conf"
> -
> -FILES_${PN}-relay = "${sbindir}/dhcrelay ${sysconfdir}/init.d/dhcp-relay ${sysconfdir}/default/dhcp-relay"
> -
> -FILES_${PN}-client = "${base_sbindir}/dhclient \
> -                      ${base_sbindir}/dhclient-script \
> -                      ${sysconfdir}/dhcp/dhclient.conf \
> -                      ${base_sbindir}/dhclient-systemd-wrapper \
> -                     "
> -
> -FILES_${PN}-omshell = "${bindir}/omshell"
> -
> -pkg_postinst_dhcp-server() {
> -    mkdir -p $D/${localstatedir}/lib/dhcp
> -    touch $D/${localstatedir}/lib/dhcp/dhcpd.leases
> -    touch $D/${localstatedir}/lib/dhcp/dhcpd6.leases
> -}
> -
> -pkg_postinst_dhcp-client() {
> -    mkdir -p $D/${localstatedir}/lib/dhcp
> -}
> -
> -pkg_postrm_dhcp-server() {
> -    rm -f $D/${localstatedir}/lib/dhcp/dhcpd.leases
> -    rm -f $D/${localstatedir}/lib/dhcp/dhcpd6.leases
> -
> -    if ! rmdir $D/${localstatedir}/lib/dhcp 2>/dev/null; then
> -        echo "Not removing ${localstatedir}/lib/dhcp as it is non-empty."
> -    fi
> -}
> -
> -pkg_postrm_dhcp-client() {
> -    rm -f $D/${localstatedir}/lib/dhcp/dhclient.leases
> -    rm -f $D/${localstatedir}/lib/dhcp/dhclient6.leases
> -
> -    if ! rmdir $D/${localstatedir}/lib/dhcp 2>/dev/null; then
> -        echo "Not removing ${localstatedir}/lib/dhcp as it is non-empty."
> -    fi
> -}
> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch b/meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch
> deleted file mode 100644
> index d1b57f0bb41..00000000000
> --- a/meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch
> +++ /dev/null
> @@ -1,27 +0,0 @@
> -From 7cc29144535a622fc671dc86eb1da65b0473a7c4 Mon Sep 17 00:00:00 2001
> -From: Hongxu Jia <hongxu.jia@windriver.com>
> -Date: Tue, 15 Aug 2017 16:14:22 +0800
> -Subject: [PATCH 01/11] define macro _PATH_DHCPD_CONF and _PATH_DHCLIENT_CONF
> -
> -Upstream-Status: Inappropriate [OE specific]
> -
> -Rebase to 4.3.6
> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
> ----
> - includes/site.h | 3 ++-
> - 1 file changed, 2 insertions(+), 1 deletion(-)
> -
> -Index: dhcp-4.4.1/includes/site.h
> -===================================================================
> ---- dhcp-4.4.1.orig/includes/site.h
> -+++ dhcp-4.4.1/includes/site.h
> -@@ -148,7 +148,8 @@
> - /* Define this if you want the dhcpd.conf file to go somewhere other than
> -    the default location.   By default, it goes in /etc/dhcpd.conf. */
> -
> --/* #define _PATH_DHCPD_CONF   "/etc/dhcpd.conf" */
> -+#define _PATH_DHCPD_CONF      "/etc/dhcp/dhcpd.conf"
> -+#define _PATH_DHCLIENT_CONF   "/etc/dhcp/dhclient.conf"
> -
> - /* Network API definitions.   You do not need to choose one of these - if
> -    you don't choose, one will be chosen for you in your system's config
> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0001-workaround-busybox-limitation-in-linux-dhclient-script.patch b/meta/recipes-connectivity/dhcp/dhcp/0001-workaround-busybox-limitation-in-linux-dhclient-script.patch
> deleted file mode 100644
> index 2359381b938..00000000000
> --- a/meta/recipes-connectivity/dhcp/dhcp/0001-workaround-busybox-limitation-in-linux-dhclient-script.patch
> +++ /dev/null
> @@ -1,65 +0,0 @@
> -From eec0503cfc36f63d777f5cb3f2719cecedcb8468 Mon Sep 17 00:00:00 2001
> -From: Haris Okanovic <haris.okanovic@ni.com>
> -Date: Mon, 7 Jan 2019 13:22:09 -0600
> -Subject: [PATCH] Workaround busybox limitation in Linux dhclient-script
> -
> -Busybox is a lightweight implementation of coreutils commonly used on
> -space-constrained embedded Linux distributions. It's implementation of
> -chown and chmod doesn't provide a "--reference" option added to
> -client/scripts/linux as of commit 9261cb14. This change works around
> -that limitation by using stat to read ownership and permissions flags
> -and simple chown/chmod calls supported in both coreutils and busybox.
> -
> -    modified:   client/scripts/linux
> -
> -Signed-off-by: Haris Okanovic <haris.okanovic@ni.com>
> -Upstream-Status: Pending [ISC-Bugs #48771]
> ----
> - client/scripts/linux | 17 +++++++++++++----
> - 1 file changed, 13 insertions(+), 4 deletions(-)
> -
> -diff --git a/client/scripts/linux b/client/scripts/linux
> -index 0c429697..2435a44b 100755
> ---- a/client/scripts/linux
> -+++ b/client/scripts/linux
> -@@ -32,6 +32,17 @@
> - # if your system holds ip tool in a non-standard location.
> - ip=/sbin/ip
> -
> -+chown_chmod_by_reference() {
> -+    local reference_file="$1"
> -+    local target_file="$2"
> -+
> -+    local owner=$(stat -c "%u:%g" "$reference_file")
> -+    local perm=$(stat -c "%a" "$reference_file")
> -+
> -+    chown "$owner" "$target_file"
> -+    chmod "$perm" "$target_file"
> -+}
> -+
> - # update /etc/resolv.conf based on received values
> - # This updated version mostly follows Debian script by Andrew Pollock et al.
> - make_resolv_conf() {
> -@@ -74,8 +85,7 @@ make_resolv_conf() {
> -         fi
> -
> -       if [ -f /etc/resolv.conf ]; then
> --          chown --reference=/etc/resolv.conf $new_resolv_conf
> --          chmod --reference=/etc/resolv.conf $new_resolv_conf
> -+          chown_chmod_by_reference /etc/resolv.conf $new_resolv_conf
> -       fi
> -         mv -f $new_resolv_conf /etc/resolv.conf
> -     # DHCPv6
> -@@ -101,8 +111,7 @@ make_resolv_conf() {
> -         fi
> -
> -       if [ -f /etc/resolv.conf ]; then
> --            chown --reference=/etc/resolv.conf $new_resolv_conf
> --            chmod --reference=/etc/resolv.conf $new_resolv_conf
> -+          chown_chmod_by_reference /etc/resolv.conf $new_resolv_conf
> -       fi
> -         mv -f $new_resolv_conf /etc/resolv.conf
> -     fi
> ---
> -2.20.0
> -
> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch b/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch
> deleted file mode 100644
> index 101c33f677a..00000000000
> --- a/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch
> +++ /dev/null
> @@ -1,117 +0,0 @@
> -From be7540d31c356e80ee02e90e8bf162b7ac6e5ba5 Mon Sep 17 00:00:00 2001
> -From: Hongxu Jia <hongxu.jia@windriver.com>
> -Date: Tue, 15 Aug 2017 14:56:56 +0800
> -Subject: [PATCH 02/11] dhclient dbus
> -
> -Upstream-Status: Inappropriate [distribution]
> -
> -Rebase to 4.3.6
> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
> ----
> - client/scripts/bsdos   | 5 +++++
> - client/scripts/freebsd | 5 +++++
> - client/scripts/linux   | 5 +++++
> - client/scripts/netbsd  | 5 +++++
> - client/scripts/openbsd | 5 +++++
> - client/scripts/solaris | 5 +++++
> - 6 files changed, 30 insertions(+)
> -
> -diff --git a/client/scripts/bsdos b/client/scripts/bsdos
> -index d69d0d8..095b143 100755
> ---- a/client/scripts/bsdos
> -+++ b/client/scripts/bsdos
> -@@ -45,6 +45,11 @@ exit_with_hooks() {
> -     . /etc/dhclient-exit-hooks
> -   fi
> - # probably should do something with exit status of the local script
> -+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
> -+    dbus-send --system --dest=com.redhat.dhcp \
> -+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
> -+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
> -+  fi
> -   exit $exit_status
> - }
> -
> -diff --git a/client/scripts/freebsd b/client/scripts/freebsd
> -index 8f3e2a2..ad7fb44 100755
> ---- a/client/scripts/freebsd
> -+++ b/client/scripts/freebsd
> -@@ -89,6 +89,11 @@ exit_with_hooks() {
> -     . /etc/dhclient-exit-hooks
> -   fi
> - # probably should do something with exit status of the local script
> -+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
> -+    dbus-send --system --dest=com.redhat.dhcp \
> -+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
> -+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
> -+  fi
> -   exit $exit_status
> - }
> -
> -diff --git a/client/scripts/linux b/client/scripts/linux
> -index 5fb1612..3d447b6 100755
> ---- a/client/scripts/linux
> -+++ b/client/scripts/linux
> -@@ -174,6 +174,11 @@ exit_with_hooks() {
> -         exit_status=$?
> -     fi
> -
> -+    if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
> -+        dbus-send --system --dest=com.redhat.dhcp \
> -+           --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
> -+           'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
> -+    fi
> -     exit $exit_status
> - }
> -
> -diff --git a/client/scripts/netbsd b/client/scripts/netbsd
> -index 07383b7..aaba8e8 100755
> ---- a/client/scripts/netbsd
> -+++ b/client/scripts/netbsd
> -@@ -45,6 +45,11 @@ exit_with_hooks() {
> -     . /etc/dhclient-exit-hooks
> -   fi
> - # probably should do something with exit status of the local script
> -+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
> -+    dbus-send --system --dest=com.redhat.dhcp \
> -+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
> -+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
> -+  fi
> -   exit $exit_status
> - }
> -
> -diff --git a/client/scripts/openbsd b/client/scripts/openbsd
> -index e7f4746..56b980c 100644
> ---- a/client/scripts/openbsd
> -+++ b/client/scripts/openbsd
> -@@ -45,6 +45,11 @@ exit_with_hooks() {
> -     . /etc/dhclient-exit-hooks
> -   fi
> - # probably should do something with exit status of the local script
> -+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
> -+    dbus-send --system --dest=com.redhat.dhcp \
> -+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
> -+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
> -+  fi
> -   exit $exit_status
> - }
> -
> -diff --git a/client/scripts/solaris b/client/scripts/solaris
> -index af553b9..4a2aa69 100755
> ---- a/client/scripts/solaris
> -+++ b/client/scripts/solaris
> -@@ -26,6 +26,11 @@ exit_with_hooks() {
> -     . /etc/dhclient-exit-hooks
> -   fi
> - # probably should do something with exit status of the local script
> -+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
> -+    dbus-send --system --dest=com.redhat.dhcp \
> -+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
> -+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
> -+  fi
> -   exit $exit_status
> - }
> -
> ---
> -1.8.3.1
> -
> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch b/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch
> deleted file mode 100644
> index 5b35933a54a..00000000000
> --- a/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch
> +++ /dev/null
> @@ -1,35 +0,0 @@
> -From d80bd792323dbd56269309f85b4506eb6b1b60e9 Mon Sep 17 00:00:00 2001
> -From: Andrei Gherzan <andrei@gherzan.ro>
> -Date: Tue, 15 Aug 2017 15:05:47 +0800
> -Subject: [PATCH 03/11] link with lcrypto
> -
> -From 4.2.0 final release, -lcrypto check was removed and we compile
> -static libraries
> -from bind that are linked to libcrypto. This is why i added a patch in
> -order to add
> --lcrypto to LIBS.
> -
> -Upstream-Status: Pending
> -Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
> -
> -Rebase to 4.3.6
> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
> ----
> - configure.ac | 4 ++++
> - 1 file changed, 4 insertions(+)
> -
> -Index: dhcp-4.4.1/configure.ac
> -===================================================================
> ---- dhcp-4.4.1.orig/configure.ac
> -+++ dhcp-4.4.1/configure.ac
> -@@ -612,6 +612,10 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]],
> - # Look for optional headers.
> - AC_CHECK_HEADERS(sys/socket.h net/if_dl.h net/if6.h regex.h)
> -
> -+# find an MD5 library
> -+AC_SEARCH_LIBS(MD5_Init, [crypto])
> -+AC_SEARCH_LIBS(MD5Init, [crypto])
> -+
> - # Solaris needs some libraries for functions
> - AC_SEARCH_LIBS(socket, [socket])
> - AC_SEARCH_LIBS(inet_ntoa, [nsl])
> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch b/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch
> deleted file mode 100644
> index 7b57730ffb7..00000000000
> --- a/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch
> +++ /dev/null
> @@ -1,95 +0,0 @@
> -From cccec0344d68dac4100b6f260ee24e7c2da9dfda Mon Sep 17 00:00:00 2001
> -From: Hongxu Jia <hongxu.jia@windriver.com>
> -Date: Tue, 15 Aug 2017 15:08:22 +0800
> -Subject: [PATCH 04/11] Fix out of tree builds
> -
> -Upstream-Status: Pending
> -
> -RP 2013/03/21
> -
> -Rebase to 4.3.6
> -
> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
> ----
> - client/Makefile.am  | 4 ++--
> - common/Makefile.am  | 3 ++-
> - dhcpctl/Makefile.am | 2 ++
> - omapip/Makefile.am  | 1 +
> - relay/Makefile.am   | 2 +-
> - server/Makefile.am  | 2 +-
> - 6 files changed, 9 insertions(+), 5 deletions(-)
> -
> -Index: dhcp-4.4.1/common/Makefile.am
> -===================================================================
> ---- dhcp-4.4.1.orig/common/Makefile.am
> -+++ dhcp-4.4.1/common/Makefile.am
> -@@ -1,4 +1,5 @@
> --AM_CPPFLAGS = -I$(top_srcdir) -DLOCALSTATEDIR='"@localstatedir@"'
> -+AM_CPPFLAGS = -I$(top_srcdir)/includes -I$(top_srcdir) -DLOCALSTATEDIR='"@localstatedir@"'
> -+
> - AM_CFLAGS = $(LDAP_CFLAGS)
> -
> - lib_LIBRARIES = libdhcp.a
> -Index: dhcp-4.4.1/dhcpctl/Makefile.am
> -===================================================================
> ---- dhcp-4.4.1.orig/dhcpctl/Makefile.am
> -+++ dhcp-4.4.1/dhcpctl/Makefile.am
> -@@ -3,6 +3,8 @@ BINDLIBDNSDIR=@BINDLIBDNSDIR@
> - BINDLIBISCCFGDIR=@BINDLIBISCCFGDIR@
> - BINDLIBISCDIR=@BINDLIBISCDIR@
> -
> -+AM_CPPFLAGS = -I$(top_srcdir)/includes -I$(top_srcdir)
> -+
> - bin_PROGRAMS = omshell
> - lib_LIBRARIES = libdhcpctl.a
> - noinst_PROGRAMS = cltest
> -Index: dhcp-4.4.1/server/Makefile.am
> -===================================================================
> ---- dhcp-4.4.1.orig/server/Makefile.am
> -+++ dhcp-4.4.1/server/Makefile.am
> -@@ -4,7 +4,7 @@
> - # production code. Sadly, we are not there yet.
> - SUBDIRS = . tests
> -
> --AM_CPPFLAGS = -I.. -DLOCALSTATEDIR='"@localstatedir@"'
> -+AM_CPPFLAGS = -I$(top_srcdir) -DLOCALSTATEDIR='"@localstatedir@"' -I$(top_srcdir)/includes
> -
> - dist_sysconf_DATA = dhcpd.conf.example
> - sbin_PROGRAMS = dhcpd
> -Index: dhcp-4.4.1/client/Makefile.am
> -===================================================================
> ---- dhcp-4.4.1.orig/client/Makefile.am
> -+++ dhcp-4.4.1/client/Makefile.am
> -@@ -5,7 +5,7 @@
> - SUBDIRS = . tests
> -
> - AM_CPPFLAGS = -DCLIENT_PATH='"PATH=$(sbindir):/sbin:/bin:/usr/sbin:/usr/bin"'
> --AM_CPPFLAGS += -DLOCALSTATEDIR='"$(localstatedir)"'
> -+AM_CPPFLAGS += -DLOCALSTATEDIR='"$(localstatedir)"' -I$(top_srcdir)/includes
> -
> - dist_sysconf_DATA = dhclient.conf.example
> - sbin_PROGRAMS = dhclient
> -Index: dhcp-4.4.1/omapip/Makefile.am
> -===================================================================
> ---- dhcp-4.4.1.orig/omapip/Makefile.am
> -+++ dhcp-4.4.1/omapip/Makefile.am
> -@@ -2,6 +2,7 @@ BINDLIBIRSDIR=@BINDLIBIRSDIR@
> - BINDLIBDNSDIR=@BINDLIBDNSDIR@
> - BINDLIBISCCFGDIR=@BINDLIBISCCFGDIR@
> - BINDLIBISCDIR=@BINDLIBISCDIR@
> -+AM_CPPFLAGS = -I$(top_srcdir)/includes
> -
> - lib_LIBRARIES = libomapi.a
> - noinst_PROGRAMS = svtest
> -Index: dhcp-4.4.1/relay/Makefile.am
> -===================================================================
> ---- dhcp-4.4.1.orig/relay/Makefile.am
> -+++ dhcp-4.4.1/relay/Makefile.am
> -@@ -1,6 +1,6 @@
> - SUBDIRS = . tests
> -
> --AM_CPPFLAGS = -DLOCALSTATEDIR='"@localstatedir@"'
> -+AM_CPPFLAGS = -DLOCALSTATEDIR='"@localstatedir@"' -I$(top_srcdir)/includes
> -
> - sbin_PROGRAMS = dhcrelay
> - dhcrelay_SOURCES = dhcrelay.c
> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch b/meta/recipes-connectivity/dhcp/dhcp/0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch
> deleted file mode 100644
> index dd56381b1dc..00000000000
> --- a/meta/recipes-connectivity/dhcp/dhcp/0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch
> +++ /dev/null
> @@ -1,36 +0,0 @@
> -From 2e8ff0e4f6d39e346ea86b8c514ab4ccc78fa359 Mon Sep 17 00:00:00 2001
> -From: Hongxu Jia <hongxu.jia@windriver.com>
> -Date: Tue, 15 Aug 2017 15:24:14 +0800
> -Subject: [PATCH 05/11] dhcp-client: fix invoke dhclient-script failed on
> - Read-only file system
> -
> -In read-only file system, '/etc' is on the readonly partition,
> -and '/etc/resolv.conf' is symlinked to a separate writable
> -partition.
> -
> -In this situation, we create temp files 'resolv.conf.dhclient-new'
> -in /tmp dir.
> -
> -Upstream-Status: Pending
> -
> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
> ----
> - client/scripts/linux | 2 +-
> - 1 file changed, 1 insertion(+), 1 deletion(-)
> -
> -diff --git a/client/scripts/linux b/client/scripts/linux
> -index 3d447b6..3122a75 100755
> ---- a/client/scripts/linux
> -+++ b/client/scripts/linux
> -@@ -40,7 +40,7 @@ make_resolv_conf() {
> -     # DHCPv4
> -     if [ -n "$new_domain_search" ] || [ -n "$new_domain_name" ] ||
> -        [ -n "$new_domain_name_servers" ]; then
> --        new_resolv_conf=/etc/resolv.conf.dhclient-new
> -+        new_resolv_conf=/tmp/resolv.conf.dhclient-new
> -         rm -f $new_resolv_conf
> -
> -         if [ -n "$new_domain_name" ]; then
> ---
> -1.8.3.1
> -
> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch b/meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch
> deleted file mode 100644
> index feb0754fff4..00000000000
> --- a/meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch
> +++ /dev/null
> @@ -1,62 +0,0 @@
> -From 7107511fd209f08f9a96f8938041ae48f3295895 Mon Sep 17 00:00:00 2001
> -From: Christopher Larson <chris_larson@mentor.com>
> -Date: Tue, 15 Aug 2017 16:17:49 +0800
> -Subject: [PATCH 07/11] Add configure argument to make the libxml2 dependency
> - explicit and determinisitic.
> -
> -Upstream-Status: Pending
> -
> -Signed-off-by: Christopher Larson <chris_larson@mentor.com>
> -
> -Rebase to 4.3.6
> -
> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
> ----
> - configure.ac | 11 +++++++++++
> - 1 file changed, 11 insertions(+)
> -
> -Index: dhcp-4.4.1/configure.ac
> -===================================================================
> ---- dhcp-4.4.1.orig/configure.ac
> -+++ dhcp-4.4.1/configure.ac
> -@@ -642,6 +642,17 @@ if test "$have_nanosleep" = "rt"; then
> -       LIBS="-lrt $LIBS"
> - fi
> -
> -+AC_ARG_WITH(libxml2,
> -+      AS_HELP_STRING([--with-libxml2], [link against libxml2. this is needed if bind was built with xml2 support enabled]),
> -+      with_libxml2="$withval", with_libxml2="no")
> -+
> -+if test x$with_libxml2 != xno; then
> -+      AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],
> -+              [if test x$with_libxml2 != xauto; then
> -+                      AC_MSG_FAILURE([*** Cannot find xmlTextWriterStartElement with -lxml2 and libxml2 was requested])
> -+              fi])
> -+fi
> -+
> - # check for /dev/random (declares HAVE_DEV_RANDOM)
> - AC_MSG_CHECKING(for random device)
> - AC_ARG_WITH(randomdev,
> -Index: dhcp-4.4.1/configure.ac+lt
> -===================================================================
> ---- dhcp-4.4.1.orig/configure.ac+lt
> -+++ dhcp-4.4.1/configure.ac+lt
> -@@ -909,6 +909,18 @@ elif test "$want_libtool" = "yes" -a "$u
> - fi
> - AM_CONDITIONAL(INSTALL_BIND, test "$want_install_bind" = "yes")
> -
> -+AC_ARG_WITH(libxml2,
> -+      AS_HELP_STRING([--with-libxml2], [link against libxml2. this is needed if bind was built with xml2 support enabled]),
> -+      with_libxml2="$withval", with_libxml2="no")
> -+
> -+if test x$with_libxml2 != xno; then
> -+      AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],,
> -+              [if test x$with_libxml2 != xauto; then
> -+                      AC_MSG_FAILURE([*** Cannot find xmlTextWriterStartElement with -lxml2 and libxml2 was requested])
> -+              fi])
> -+fi
> -+
> -+
> - # OpenLDAP support.
> - AC_ARG_WITH(ldap,
> -     AS_HELP_STRING([--with-ldap],[enable OpenLDAP support in dhcpd (default is no)]),
> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0009-remove-dhclient-script-bash-dependency.patch b/meta/recipes-connectivity/dhcp/dhcp/0009-remove-dhclient-script-bash-dependency.patch
> deleted file mode 100644
> index 912b6d6312c..00000000000
> --- a/meta/recipes-connectivity/dhcp/dhcp/0009-remove-dhclient-script-bash-dependency.patch
> +++ /dev/null
> @@ -1,28 +0,0 @@
> -From f3f8b7726e50e24ef3edf5fa5a17e31d39118d7e Mon Sep 17 00:00:00 2001
> -From: Andre McCurdy <armccurdy@gmail.com>
> -Date: Tue, 15 Aug 2017 15:49:31 +0800
> -Subject: [PATCH 09/11] remove dhclient-script bash dependency
> -
> -Upstream-Status: Inappropriate [OE specific]
> -
> -Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
> -
> -Rebase to 4.3.6
> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
> ----
> - client/scripts/linux | 2 +-
> - 1 file changed, 1 insertion(+), 1 deletion(-)
> -
> -diff --git a/client/scripts/linux b/client/scripts/linux
> -index 3122a75..1712d7d 100755
> ---- a/client/scripts/linux
> -+++ b/client/scripts/linux
> -@@ -1,4 +1,4 @@
> --#!/bin/bash
> -+#!/bin/sh
> - # dhclient-script for Linux. Dan Halbert, March, 1997.
> - # Updated for Linux 2.[12] by Brian J. Murrell, January 1999.
> - # No guarantees about this. I'm a novice at the details of Linux
> ---
> -1.8.3.1
> -
> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch b/meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch
> deleted file mode 100644
> index 39ba65fbc46..00000000000
> --- a/meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch
> +++ /dev/null
> @@ -1,34 +0,0 @@
> -From 501543b3ef715488a142e3d301ff2733aa33eec7 Mon Sep 17 00:00:00 2001
> -From: Awais Belal <awais_belal@mentor.com>
> -Date: Wed, 25 Oct 2017 21:00:05 +0500
> -Subject: [PATCH] dhcp: correct the intention for xml2 lib search
> -
> -A missing case breaks the build when libxml2 is
> -required and found appropriately. The third argument
> -to the function AC_SEARCH_LIB is action-if-found which
> -was mistakenly been used for the case where the library
> -is not found and hence breaks the configure phase
> -where it shoud actually pass.
> -We now pass on silently when action-if-found is
> -executed.
> -
> -Upstream-Status: Pending
> -
> -Signed-off-by: Awais Belal <awais_belal@mentor.com>
> ----
> - configure.ac | 2 +-
> - 1 file changed, 1 insertion(+), 1 deletion(-)
> -
> -Index: dhcp-4.4.1/configure.ac
> -===================================================================
> ---- dhcp-4.4.1.orig/configure.ac
> -+++ dhcp-4.4.1/configure.ac
> -@@ -647,7 +647,7 @@ AC_ARG_WITH(libxml2,
> -       with_libxml2="$withval", with_libxml2="no")
> -
> - if test x$with_libxml2 != xno; then
> --      AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],
> -+      AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],,
> -               [if test x$with_libxml2 != xauto; then
> -                       AC_MSG_FAILURE([*** Cannot find xmlTextWriterStartElement with -lxml2 and libxml2 was requested])
> -               fi])
> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch b/meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch
> deleted file mode 100644
> index fcec010bd01..00000000000
> --- a/meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch
> +++ /dev/null
> @@ -1,64 +0,0 @@
> -lib and include path is hardcoded for use_libbind
> -
> -use libdir and includedir vars
> -
> -Upstream-Status: Pending
> -Signed-off-by: Armin Kuster <akuster808@gmail.com>
> -
> -Index: dhcp-4.4.1/configure.ac+lt
> -===================================================================
> ---- dhcp-4.4.1.orig/configure.ac+lt
> -+++ dhcp-4.4.1/configure.ac+lt
> -@@ -801,22 +801,22 @@ no)
> -       if test ! -d "$use_libbind"; then
> -               AC_MSG_ERROR([Cannot find bind directory at $use_libbind])
> -       fi
> --      if test ! -d "$use_libbind/include" -o \
> --              ! -f "$use_libbind/include/isc/buffer.h"
> -+      if test ! -d "$use_libbind/$includedir" -o \
> -+              ! -f "$use_libbind/$includedir/isc/buffer.h"
> -       then
> --              AC_MSG_ERROR([Cannot find bind includes at $use_libbind/include])
> -+              AC_MSG_ERROR([Cannot find bind includes at $use_libbind/$includedir])
> -       fi
> --      if test ! -d "$use_libbind/lib" -o \
> --              \( ! -f "$use_libbind/lib/libisc.a" -a \
> --                 ! -f "$use_libbind/lib/libisc.la" \)
> -+      if test ! -d "$use_libbind/$libdir" -o \
> -+              \( ! -f "$use_libbind/$libdir/libisc.a" -a \
> -+                 ! -f "$use_libbind/$libdir/libisc.la" \)
> -       then
> --              AC_MSG_ERROR([Cannot find bind libraries at $use_libbind/lib])
> -+              AC_MSG_ERROR([Cannot find bind libraries at $use_libbind/$libdir])
> -       fi
> -       BINDDIR="$use_libbind"
> --      BINDLIBIRSDIR="$BINDDIR/lib"
> --      BINDLIBDNSDIR="$BINDDIR/lib"
> --      BINDLIBISCCFGDIR="$BINDDIR/lib"
> --      BINDLIBISCDIR="$BINDDIR/lib"
> -+      BINDLIBIRSDIR="$BINDDIR/$libdir"
> -+      BINDLIBDNSDIR="$BINDDIR/$libdir"
> -+      BINDLIBISCCFGDIR="$BINDDIR/$libdir"
> -+      BINDLIBISCDIR="$BINDDIR/$libdir"
> -       DISTCHECK_LIBBIND_CONFIGURE_FLAG="--with-libbind=$use_libbind"
> -       ;;
> - esac
> -@@ -856,14 +856,14 @@ AC_ARG_ENABLE(libtool,
> -
> - if test "$use_libbind" != "no"; then
> -       if test "$want_libtool" = "yes" -a \
> --              ! -f "$use_libbind/lib/libisc.la"
> -+              ! -f "$use_libbind/$libdir/libisc.la"
> -       then
> --              AC_MSG_ERROR([Cannot find dynamic libraries at $use_libbind/lib])
> -+              AC_MSG_ERROR([Cannot find dynamic libraries at $use_libbind/$libdir])
> -       fi
> -       if test "$want_libtool" = "no" -a \
> --              ! -f "$use_libbind/lib/libisc.a"
> -+              ! -f "$use_libbind/$libdir/libisc.a"
> -       then
> --              AC_MSG_ERROR([Cannot find static libraries at $use_libbind/lib])
> -+              AC_MSG_ERROR([Cannot find static libraries at $use_libbind/$libdir])
> -       fi
> - fi
> -
> diff --git a/meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb b/meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb
> deleted file mode 100644
> index cf4af826099..00000000000
> --- a/meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb
> +++ /dev/null
> @@ -1,23 +0,0 @@
> -require dhcp.inc
> -
> -SRC_URI += "file://0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch \
> -            file://0002-dhclient-dbus.patch \
> -            file://0003-link-with-lcrypto.patch \
> -            file://0004-Fix-out-of-tree-builds.patch \
> -            file://0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch \
> -            file://0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch \
> -            file://0009-remove-dhclient-script-bash-dependency.patch \
> -            file://0012-dhcp-correct-the-intention-for-xml2-lib-search.patch \
> -            file://0013-fixup_use_libbind.patch \
> -            file://0001-workaround-busybox-limitation-in-linux-dhclient-script.patch \
> -"
> -
> -SRC_URI[md5sum] = "2afdaf8498dc1edaf3012efdd589b3e1"
> -SRC_URI[sha256sum] = "1a7ccd64a16e5e68f7b5e0f527fd07240a2892ea53fe245620f4f5f607004521"
> -
> -LDFLAGS_append = " -pthread"
> -
> -PACKAGECONFIG ?= ""
> -PACKAGECONFIG[bind-httpstats] = "--with-libxml2,--without-libxml2,libxml2"
> -
> -CFLAGS += "-fcommon"
> diff --git a/meta/recipes-connectivity/dhcp/files/default-relay b/meta/recipes-connectivity/dhcp/files/default-relay
> deleted file mode 100644
> index 7961f014bef..00000000000
> --- a/meta/recipes-connectivity/dhcp/files/default-relay
> +++ /dev/null
> @@ -1,12 +0,0 @@
> -# Defaults for dhcp-relay initscript
> -# sourced by /etc/init.d/dhcp-relay
> -
> -# What servers should the DHCP relay forward requests to?
> -# e.g: SERVERS="192.168.0.1"
> -SERVERS=""
> -
> -# On what interfaces should the DHCP relay (dhrelay) serve DHCP requests?
> -INTERFACES=""
> -
> -# Additional options that are passed to the DHCP relay daemon?
> -OPTIONS=""
> diff --git a/meta/recipes-connectivity/dhcp/files/default-server b/meta/recipes-connectivity/dhcp/files/default-server
> deleted file mode 100644
> index 0385d169922..00000000000
> --- a/meta/recipes-connectivity/dhcp/files/default-server
> +++ /dev/null
> @@ -1,7 +0,0 @@
> -# Defaults for dhcp initscript
> -# sourced by /etc/init.d/dhcp-server
> -# installed at /etc/default/dhcp-server by the maintainer scripts
> -
> -# On what interfaces should the DHCP server (dhcpd) serve DHCP requests?
> -#       Separate multiple interfaces with spaces, e.g. "eth0 eth1".
> -INTERFACES=""
> diff --git a/meta/recipes-connectivity/dhcp/files/dhclient-systemd-wrapper b/meta/recipes-connectivity/dhcp/files/dhclient-systemd-wrapper
> deleted file mode 100644
> index 7d0e224a1df..00000000000
> --- a/meta/recipes-connectivity/dhcp/files/dhclient-systemd-wrapper
> +++ /dev/null
> @@ -1,39 +0,0 @@
> -#!/bin/sh
> -
> -# In case the interface is used for nfs, skip it.
> -nfsroot=0
> -interfaces=""
> -exec 9<&0 < /proc/mounts
> -while read dev mtpt fstype rest; do
> -    if test $mtpt = "/" ; then
> -        case $fstype in
> -            nfs | nfs4)
> -                nfsroot=1
> -                nfs_addr=`echo $rest | sed -e 's/^.*addr=\([0-9.]*\).*$/\1/'`
> -                break
> -                ;;
> -            *)
> -                ;;
> -        esac
> -    fi
> -done
> -exec 0<&9 9<&-
> -
> -if [ $nfsroot -eq 0 ]; then
> -    interfaces="$INTERFACES"
> -else
> -    if [ -x /bin/ip -o -x /sbin/ip ] ; then
> -       nfs_iface=`ip route get $nfs_addr | grep dev | sed -e 's/^.*dev \([-a-z0-9.]*\).*$/\1/'`
> -    fi
> -    for i in $INTERFACES; do
> -       if test "x$i" = "x$nfs_iface"; then
> -            echo "dhclient skipping nfsroot interface $i"
> -       else
> -           interfaces="$interfaces $i"
> -       fi
> -    done
> -fi
> -
> -if test "x$interfaces" != "x"; then
> -    /sbin/dhclient -d -cf /etc/dhcp/dhclient.conf -q -lf /var/lib/dhcp/dhclient.leases $interfaces
> -fi
> diff --git a/meta/recipes-connectivity/dhcp/files/dhclient.conf b/meta/recipes-connectivity/dhcp/files/dhclient.conf
> deleted file mode 100644
> index 0e6dcf96c21..00000000000
> --- a/meta/recipes-connectivity/dhcp/files/dhclient.conf
> +++ /dev/null
> @@ -1,50 +0,0 @@
> -# Configuration file for /sbin/dhclient, which is included in Debian's
> -#      dhcp3-client package.
> -#
> -# This is a sample configuration file for dhclient. See dhclient.conf's
> -#      man page for more information about the syntax of this file
> -#      and a more comprehensive list of the parameters understood by
> -#      dhclient.
> -#
> -# Normally, if the DHCP server provides reasonable information and does
> -#      not leave anything out (like the domain name, for example), then
> -#      few changes must be made to this file, if any.
> -#
> -
> -#send host-name "andare.fugue.com";
> -#send dhcp-client-identifier 1:0:a0:24:ab:fb:9c;
> -#send dhcp-lease-time 3600;
> -#supersede domain-name "fugue.com home.vix.com";
> -#prepend domain-name-servers 127.0.0.1;
> -request subnet-mask, broadcast-address, time-offset, routers,
> -       domain-name, domain-name-servers, host-name,
> -       netbios-name-servers, netbios-scope;
> -#require subnet-mask, domain-name-servers;
> -#timeout 60;
> -#retry 60;
> -#reboot 10;
> -#select-timeout 5;
> -#initial-interval 2;
> -#script "/etc/dhcp3/dhclient-script";
> -#media "-link0 -link1 -link2", "link0 link1";
> -#reject 192.33.137.209;
> -
> -#alias {
> -#  interface "eth0";
> -#  fixed-address 192.5.5.213;
> -#  option subnet-mask 255.255.255.255;
> -#}
> -
> -#lease {
> -#  interface "eth0";
> -#  fixed-address 192.33.137.200;
> -#  medium "link0 link1";
> -#  option host-name "andare.swiftmedia.com";
> -#  option subnet-mask 255.255.255.0;
> -#  option broadcast-address 192.33.137.255;
> -#  option routers 192.33.137.250;
> -#  option domain-name-servers 127.0.0.1;
> -#  renew 2 2000/1/12 00:00:01;
> -#  rebind 2 2000/1/12 00:00:01;
> -#  expire 2 2000/1/12 00:00:01;
> -#}
> diff --git a/meta/recipes-connectivity/dhcp/files/dhclient.service b/meta/recipes-connectivity/dhcp/files/dhclient.service
> deleted file mode 100644
> index 9ddb4d1dfe9..00000000000
> --- a/meta/recipes-connectivity/dhcp/files/dhclient.service
> +++ /dev/null
> @@ -1,13 +0,0 @@
> -[Unit]
> -Description=Dynamic Host Configuration Protocol (DHCP)
> -Wants=network.target
> -Before=network.target
> -After=systemd-udevd.service
> -
> -[Service]
> -EnvironmentFile=-@SYSCONFDIR@/default/dhcp-client
> -ExecStart=@BASE_SBINDIR@/dhclient-systemd-wrapper
> -RemainAfterExit=yes
> -
> -[Install]
> -WantedBy=multi-user.target
> diff --git a/meta/recipes-connectivity/dhcp/files/dhcpd.conf b/meta/recipes-connectivity/dhcp/files/dhcpd.conf
> deleted file mode 100644
> index 0001c0f00e2..00000000000
> --- a/meta/recipes-connectivity/dhcp/files/dhcpd.conf
> +++ /dev/null
> @@ -1,108 +0,0 @@
> -#
> -# Sample configuration file for ISC dhcpd for Debian
> -#
> -# $Id: dhcpd.conf,v 1.1.1.1 2002/05/21 00:07:44 peloy Exp $
> -#
> -
> -# The ddns-updates-style parameter controls whether or not the server will
> -# attempt to do a DNS update when a lease is confirmed. We default to the
> -# behavior of the version 2 packages ('none', since DHCP v2 didn't
> -# have support for DDNS.)
> -ddns-update-style none;
> -
> -# option definitions common to all supported networks...
> -option domain-name "example.org";
> -option domain-name-servers ns1.example.org, ns2.example.org;
> -
> -default-lease-time 600;
> -max-lease-time 7200;
> -
> -# If this DHCP server is the official DHCP server for the local
> -# network, the authoritative directive should be uncommented.
> -#authoritative;
> -
> -# Use this to send dhcp log messages to a different log file (you also
> -# have to hack syslog.conf to complete the redirection).
> -log-facility local7;
> -
> -# No service will be given on this subnet, but declaring it helps the
> -# DHCP server to understand the network topology.
> -
> -#subnet 10.152.187.0 netmask 255.255.255.0 {
> -#}
> -
> -# This is a very basic subnet declaration.
> -
> -#subnet 10.254.239.0 netmask 255.255.255.224 {
> -#  range 10.254.239.10 10.254.239.20;
> -#  option routers rtr-239-0-1.example.org, rtr-239-0-2.example.org;
> -#}
> -
> -# This declaration allows BOOTP clients to get dynamic addresses,
> -# which we don't really recommend.
> -
> -#subnet 10.254.239.32 netmask 255.255.255.224 {
> -#  range dynamic-bootp 10.254.239.40 10.254.239.60;
> -#  option broadcast-address 10.254.239.31;
> -#  option routers rtr-239-32-1.example.org;
> -#}
> -
> -# A slightly different configuration for an internal subnet.
> -#subnet 10.5.5.0 netmask 255.255.255.224 {
> -#  range 10.5.5.26 10.5.5.30;
> -#  option domain-name-servers ns1.internal.example.org;
> -#  option domain-name "internal.example.org";
> -#  option routers 10.5.5.1;
> -#  option broadcast-address 10.5.5.31;
> -#  default-lease-time 600;
> -#  max-lease-time 7200;
> -#}
> -
> -# Hosts which require special configuration options can be listed in
> -# host statements.   If no address is specified, the address will be
> -# allocated dynamically (if possible), but the host-specific information
> -# will still come from the host declaration.
> -
> -#host passacaglia {
> -#  hardware ethernet 0:0:c0:5d:bd:95;
> -#  filename "vmunix.passacaglia";
> -#  server-name "toccata.fugue.com";
> -#}
> -
> -# Fixed IP addresses can also be specified for hosts.   These addresses
> -# should not also be listed as being available for dynamic assignment.
> -# Hosts for which fixed IP addresses have been specified can boot using
> -# BOOTP or DHCP.   Hosts for which no fixed address is specified can only
> -# be booted with DHCP, unless there is an address range on the subnet
> -# to which a BOOTP client is connected which has the dynamic-bootp flag
> -# set.
> -#host fantasia {
> -#  hardware ethernet 08:00:07:26:c0:a5;
> -#  fixed-address fantasia.fugue.com;
> -#}
> -
> -# You can declare a class of clients and then do address allocation
> -# based on that.   The example below shows a case where all clients
> -# in a certain class get addresses on the 10.17.224/24 subnet, and all
> -# other clients get addresses on the 10.0.29/24 subnet.
> -
> -#class "foo" {
> -#  match if substring (option vendor-class-identifier, 0, 4) = "SUNW";
> -#}
> -
> -#shared-network 224-29 {
> -#  subnet 10.17.224.0 netmask 255.255.255.0 {
> -#    option routers rtr-224.example.org;
> -#  }
> -#  subnet 10.0.29.0 netmask 255.255.255.0 {
> -#    option routers rtr-29.example.org;
> -#  }
> -#  pool {
> -#    allow members of "foo";
> -#    range 10.17.224.10 10.17.224.250;
> -#  }
> -#  pool {
> -#    deny members of "foo";
> -#    range 10.0.29.10 10.0.29.230;
> -#  }
> -#}
> diff --git a/meta/recipes-connectivity/dhcp/files/dhcpd.service b/meta/recipes-connectivity/dhcp/files/dhcpd.service
> deleted file mode 100644
> index ae4f93eca5b..00000000000
> --- a/meta/recipes-connectivity/dhcp/files/dhcpd.service
> +++ /dev/null
> @@ -1,15 +0,0 @@
> -[Unit]
> -Description=DHCPv4 Server Daemon
> -Documentation=man:dhcpd(8) man:dhcpd.conf(5)
> -After=network.target
> -After=time-sync.target
> -
> -[Service]
> -PIDFile=@localstatedir@/run/dhcpd.pid
> -EnvironmentFile=@SYSCONFDIR@/default/dhcp-server
> -EnvironmentFile=-@SYSCONFDIR@/sysconfig/dhcp-server
> -ExecStartPre=@base_bindir@/touch @localstatedir@/lib/dhcp/dhcpd.leases
> -ExecStart=@SBINDIR@/dhcpd -f -cf @SYSCONFDIR@/dhcp/dhcpd.conf -pf @localstatedir@/run/dhcpd.pid $DHCPDARGS -q $INTERFACES
> -
> -[Install]
> -WantedBy=multi-user.target
> diff --git a/meta/recipes-connectivity/dhcp/files/dhcpd6.service b/meta/recipes-connectivity/dhcp/files/dhcpd6.service
> deleted file mode 100644
> index 52a6224dc2c..00000000000
> --- a/meta/recipes-connectivity/dhcp/files/dhcpd6.service
> +++ /dev/null
> @@ -1,15 +0,0 @@
> -[Unit]
> -Description=DHCPv6 Server Daemon
> -Documentation=man:dhcpd(8) man:dhcpd.conf(5)
> -After=network.target
> -After=time-sync.target
> -
> -[Service]
> -PIDFile=@localstatedir@/run/dhcpd6.pid
> -EnvironmentFile=@SYSCONFDIR@/default/dhcp-server
> -EnvironmentFile=-@SYSCONFDIR@/sysconfig/dhcpd6
> -ExecStartPre=@base_bindir@/touch @localstatedir@/lib/dhcp/dhcpd6.leases
> -ExecStart=@SBINDIR@/dhcpd -f -6 -cf @SYSCONFDIR@/dhcp/dhcpd6.conf -pf @localstatedir@/run/dhcpd6.pid $DHCPDARGS -q $INTERFACES
> -
> -[Install]
> -WantedBy=multi-user.target
> diff --git a/meta/recipes-connectivity/dhcp/files/dhcrelay.service b/meta/recipes-connectivity/dhcp/files/dhcrelay.service
> deleted file mode 100644
> index 15ff927d346..00000000000
> --- a/meta/recipes-connectivity/dhcp/files/dhcrelay.service
> +++ /dev/null
> @@ -1,10 +0,0 @@
> -[Unit]
> -Description=DHCP Relay Agent Daemon
> -After=network.target
> -
> -[Service]
> -EnvironmentFile=@SYSCONFDIR@/default/dhcp-relay
> -ExecStart=@SBINDIR@/dhcrelay -d --no-pid -q $SERVERS
> -
> -[Install]
> -WantedBy=multi-user.target
> diff --git a/meta/recipes-connectivity/dhcp/files/init-relay b/meta/recipes-connectivity/dhcp/files/init-relay
> deleted file mode 100644
> index 019a7e84cf4..00000000000
> --- a/meta/recipes-connectivity/dhcp/files/init-relay
> +++ /dev/null
> @@ -1,44 +0,0 @@
> -#!/bin/sh
> -#
> -# $Id: dhcp3-relay,v 1.1 2004/04/16 15:41:08 ml Exp $
> -#
> -
> -# It is not safe to start if we don't have a default configuration...
> -if [ ! -f /etc/default/dhcp-relay ]; then
> -       echo "/etc/default/dhcp-relay does not exist! - Aborting..."
> -       echo "create this file to fix the problem."
> -       exit 1
> -fi
> -
> -# Read init script configuration (interfaces the daemon should listen on
> -# and the DHCP server we should forward requests to.)
> -. /etc/default/dhcp-relay
> -
> -# Build command line for interfaces (will be passed to dhrelay below.)
> -IFCMD=""
> -if test "$INTERFACES" != ""; then
> -       for I in $INTERFACES; do
> -               IFCMD=${IFCMD}"-i "${I}" "
> -       done
> -fi
> -
> -DHCRELAYPID=/var/run/dhcrelay.pid
> -
> -case "$1" in
> -       start)
> -               start-stop-daemon -S -x /usr/sbin/dhcrelay -- -q $OPTIONS $IFCMD $SERVERS
> -               ;;
> -       stop)
> -               start-stop-daemon -K -x /usr/sbin/dhcrelay
> -               ;;
> -       restart | force-reload)
> -               $0 stop
> -               sleep 2
> -               $0 start
> -               ;;
> -       *)
> -               echo "Usage: /etc/init.d/dhcp-relay {start|stop|restart|force-reload}"
> -               exit 1
> -esac
> -
> -exit 0
> diff --git a/meta/recipes-connectivity/dhcp/files/init-server b/meta/recipes-connectivity/dhcp/files/init-server
> deleted file mode 100644
> index 5e693adf785..00000000000
> --- a/meta/recipes-connectivity/dhcp/files/init-server
> +++ /dev/null
> @@ -1,44 +0,0 @@
> -#!/bin/sh
> -#
> -# $Id: dhcp3-server.init.d,v 1.4 2003/07/13 19:12:41 mdz Exp $
> -#
> -
> -test -f /usr/sbin/dhcpd || exit 0
> -
> -# It is not safe to start if we don't have a default configuration...
> -if [ ! -f /etc/default/dhcp-server ]; then
> -       echo "/etc/default/dhcp-server does not exist! - Aborting..."
> -       exit 0
> -fi
> -
> -# Read init script configuration (so far only interfaces the daemon
> -# should listen on.)
> -. /etc/default/dhcp-server
> -
> -case "$1" in
> -       start)
> -               echo -n "Starting DHCP server: "
> -               test -d /var/lib/dhcp/ || mkdir -p /var/lib/dhcp/
> -               test -f /var/lib/dhcp/dhcpd.leases || touch /var/lib/dhcp/dhcpd.leases
> -               start-stop-daemon -S -x /usr/sbin/dhcpd -- -q $INTERFACES -user dhcp -group dhcp
> -               echo "."
> -               ;;
> -       stop)
> -               echo -n "Stopping DHCP server: dhcpd3"
> -               start-stop-daemon -K -x /usr/sbin/dhcpd
> -               echo "."
> -               ;;
> -       restart | force-reload)
> -               $0 stop
> -               sleep 2
> -               $0 start
> -               if [ "$?" != "0" ]; then
> -                       exit 1
> -               fi
> -               ;;
> -       *)
> -               echo "Usage: /etc/init.d/dhcp-server {start|stop|restart|force-reload}"
> -               exit 1
> -esac
> -
> -exit 0
> --
> 2.17.1
>
> 

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [OE-core] [PATCH 6/8] dhcp: remove from core
  2020-09-01 18:10   ` [OE-core] " Khem Raj
@ 2020-09-01 19:15     ` Diego Sueiro
  2020-09-02 15:05       ` Richard Purdie
  2020-09-01 20:39     ` akuster
  1 sibling, 1 reply; 24+ messages in thread
From: Diego Sueiro @ 2020-09-01 19:15 UTC (permalink / raw)
  To: raj.khem, akuster; +Cc: Patches and discussions about the oe-core layer, nd


>-----Original Message-----
>From: openembedded-core@lists.openembedded.org <openembedded-
>core@lists.openembedded.org> On Behalf Of Khem Raj via
>lists.openembedded.org
>Sent: 01 September 2020 19:11
>To: akuster <akuster808@gmail.com>
>Cc: Patches and discussions about the oe-core layer <openembedded-
>core@lists.openembedded.org>
>Subject: Re: [OE-core] [PATCH 6/8] dhcp: remove from core
>
>it seems its used by
>build-appliance-image and packagegroup-core-base-utils so you need to
>take care of that as well. in meta-networking networkmanager recipe
>depends on it too which I think I can take care.
>

Armin,
You added a new recipe for a dhcp client but what is the alternative for the dhcp server in oe-core?

>On Tue, Sep 1, 2020 at 8:23 AM akuster <akuster808@gmail.com> wrote:
>>
>> update maintainers.inc too
>>
>> Signed-off-by: Armin Kuster <akuster808@gmail.com>
>> ---
>>  meta/conf/distro/include/maintainers.inc      |   1 -
>>  meta/recipes-connectivity/dhcp/dhcp.inc       | 149 ------------------
>>  ...TH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch |  27 ----
>>  ...-limitation-in-linux-dhclient-script.patch |  65 --------
>>  .../dhcp/dhcp/0002-dhclient-dbus.patch        | 117 --------------
>>  .../dhcp/dhcp/0003-link-with-lcrypto.patch    |  35 ----
>>  .../dhcp/0004-Fix-out-of-tree-builds.patch    |  95 -----------
>>  ...invoke-dhclient-script-failed-on-Rea.patch |  36 -----
>>  ...gument-to-make-the-libxml2-dependenc.patch |  62 --------
>>  ...move-dhclient-script-bash-dependency.patch |  28 ----
>>  ...ct-the-intention-for-xml2-lib-search.patch |  34 ----
>>  .../dhcp/dhcp/0013-fixup_use_libbind.patch    |  64 --------
>>  meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb  |  23 ---
>>  .../dhcp/files/default-relay                  |  12 --
>>  .../dhcp/files/default-server                 |   7 -
>>  .../dhcp/files/dhclient-systemd-wrapper       |  39 -----
>>  .../dhcp/files/dhclient.conf                  |  50 ------
>>  .../dhcp/files/dhclient.service               |  13 --
>>  .../dhcp/files/dhcpd.conf                     | 108 -------------
>>  .../dhcp/files/dhcpd.service                  |  15 --
>>  .../dhcp/files/dhcpd6.service                 |  15 --
>>  .../dhcp/files/dhcrelay.service               |  10 --
>>  .../dhcp/files/init-relay                     |  44 ------
>>  .../dhcp/files/init-server                    |  44 ------
>>  24 files changed, 1093 deletions(-)
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp.inc
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0001-define-
>macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0001-
>workaround-busybox-limitation-in-linux-dhclient-script.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-
>dbus.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0003-link-with-
>lcrypto.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-
>tree-builds.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0005-dhcp-
>client-fix-invoke-dhclient-script-failed-on-Rea.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0007-Add-
>configure-argument-to-make-the-libxml2-dependenc.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0009-remove-
>dhclient-script-bash-dependency.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-
>correct-the-intention-for-xml2-lib-search.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0013-
>fixup_use_libbind.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/default-relay
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/default-server
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhclient-
>systemd-wrapper
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhclient.conf
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhclient.service
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcpd.conf
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcpd.service
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcpd6.service
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcrelay.service
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/init-relay
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/init-server
>>
>> diff --git a/meta/conf/distro/include/maintainers.inc
>b/meta/conf/distro/include/maintainers.inc
>> index 27e3474da8b..a55dbfa13c9 100644
>> --- a/meta/conf/distro/include/maintainers.inc
>> +++ b/meta/conf/distro/include/maintainers.inc
>> @@ -143,7 +143,6 @@ RECIPE_MAINTAINER_pn-debianutils = "Yi Zhao
><yi.zhao@windriver.com>"
>>  RECIPE_MAINTAINER_pn-dejagnu = "Nathan Rossi
><nathan@nathanrossi.com>"
>>  RECIPE_MAINTAINER_pn-depmodwrapper-cross = "Unassigned
><unassigned@yoctoproject.org>"
>>  RECIPE_MAINTAINER_pn-desktop-file-utils = "Alexander Kanavin
><alex.kanavin@gmail.com>"
>> -RECIPE_MAINTAINER_pn-dhcp = "Hongxu Jia <hongxu.jia@windriver.com>"
>>  RECIPE_MAINTAINER_pn-dhcpd = "Armin Kuster <akuster808@gmail.com>"
>>  RECIPE_MAINTAINER_pn-diffoscope = "Joshua Watt
><JPEWhacker@gmail.com>"
>>  RECIPE_MAINTAINER_pn-diffstat = "Chen Qi <Qi.Chen@windriver.com>"
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp.inc b/meta/recipes-
>connectivity/dhcp/dhcp.inc
>> deleted file mode 100644
>> index d46130d49b9..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp.inc
>> +++ /dev/null
>> @@ -1,149 +0,0 @@
>> -SECTION = "console/network"
>> -SUMMARY = "Internet Software Consortium DHCP package"
>> -DESCRIPTION = "DHCP (Dynamic Host Configuration Protocol) is a protocol \
>> -which allows individual devices on an IP network to get their own \
>> -network configuration information from a server.  DHCP helps make it \
>> -easier to administer devices."
>> -
>> -HOMEPAGE = "http://www.isc.org/"
>> -
>> -LICENSE = "ISC"
>> -LIC_FILES_CHKSUM =
>"file://LICENSE;beginline=4;md5=004a4db50a1e20972e924a8618747c01"
>> -
>> -DEPENDS = "openssl bind"
>> -
>> -SRC_URI = "http://ftp.isc.org/isc/dhcp/${PV}/dhcp-${PV}.tar.gz \
>> -           file://init-relay file://default-relay \
>> -           file://init-server file://default-server \
>> -           file://dhclient.conf file://dhcpd.conf \
>> -           file://dhclient-systemd-wrapper \
>> -           file://dhclient.service \
>> -           file://dhcpd.service file://dhcrelay.service \
>> -           file://dhcpd6.service \
>> -           "
>> -UPSTREAM_CHECK_URI = "http://ftp.isc.org/isc/dhcp/"
>> -UPSTREAM_CHECK_REGEX = "(?P<pver>\d+\.\d+\.(\d+?))/"
>> -
>> -inherit autotools-brokensep systemd useradd update-rc.d
>> -
>> -USERADD_PACKAGES = "${PN}-server"
>> -USERADD_PARAM_${PN}-server = "--system --no-create-home --home-dir
>/var/run/${BPN} --shell /bin/false --user-group ${BPN}"
>> -
>> -SYSTEMD_PACKAGES = "${PN}-server ${PN}-relay ${PN}-client"
>> -SYSTEMD_SERVICE_${PN}-server = "dhcpd.service dhcpd6.service"
>> -SYSTEMD_AUTO_ENABLE_${PN}-server = "disable"
>> -
>> -SYSTEMD_SERVICE_${PN}-relay = "dhcrelay.service"
>> -SYSTEMD_AUTO_ENABLE_${PN}-relay = "disable"
>> -
>> -SYSTEMD_SERVICE_${PN}-client = "dhclient.service"
>> -SYSTEMD_AUTO_ENABLE_${PN}-client = "disable"
>> -
>> -INITSCRIPT_PACKAGES = "dhcp-server"
>> -INITSCRIPT_NAME_dhcp-server = "dhcp-server"
>> -INITSCRIPT_PARAMS_dhcp-server = "defaults"
>> -
>> -CFLAGS += "-D_GNU_SOURCE"
>> -EXTRA_OECONF = "--with-srv-lease-
>file=${localstatedir}/lib/dhcp/dhcpd.leases \
>> -                --with-srv6-lease-file=${localstatedir}/lib/dhcp/dhcpd6.leases \
>> -                --with-cli-lease-file=${localstatedir}/lib/dhcp/dhclient.leases \
>> -                --with-cli6-lease-file=${localstatedir}/lib/dhcp/dhclient6.leases \
>> -                --enable-paranoia --disable-static \
>> -                --with-randomdev=/dev/random \
>> -                --with-libbind=${STAGING_DIR_HOST} \
>> -               --enable-libtool \
>> -               "
>> -
>> -#Enable shared libs per dhcp README
>> -do_configure_prepend () {
>> -       cp configure.ac+lt configure.ac
>> -}
>> -
>> -do_install_append () {
>> -       install -d ${D}${sysconfdir}/init.d
>> -       install -d ${D}${sysconfdir}/default
>> -       install -d ${D}${sysconfdir}/dhcp
>> -       install -m 0755 ${WORKDIR}/init-relay ${D}${sysconfdir}/init.d/dhcp-
>relay
>> -       install -m 0644 ${WORKDIR}/default-relay
>${D}${sysconfdir}/default/dhcp-relay
>> -       install -m 0755 ${WORKDIR}/init-server ${D}${sysconfdir}/init.d/dhcp-
>server
>> -       install -m 0644 ${WORKDIR}/default-server
>${D}${sysconfdir}/default/dhcp-server
>> -
>> -       rm -f ${D}${sysconfdir}/dhclient.conf*
>> -       rm -f ${D}${sysconfdir}/dhcpd.conf*
>> -       install -m 0644 ${WORKDIR}/dhclient.conf
>${D}${sysconfdir}/dhcp/dhclient.conf
>> -       install -m 0644 ${WORKDIR}/dhcpd.conf
>${D}${sysconfdir}/dhcp/dhcpd.conf
>> -
>> -       install -d ${D}${base_sbindir}/
>> -       if [ "${sbindir}" != "${base_sbindir}" ]; then
>> -               mv ${D}${sbindir}/dhclient ${D}${base_sbindir}/
>> -       fi
>> -       install -m 0755 ${S}/client/scripts/linux ${D}${base_sbindir}/dhclient-
>script
>> -
>> -       # Install systemd unit files
>> -       install -d ${D}${systemd_unitdir}/system
>> -       install -m 0644 ${WORKDIR}/dhcpd.service
>${D}${systemd_unitdir}/system
>> -       install -m 0644 ${WORKDIR}/dhcpd6.service
>${D}${systemd_unitdir}/system
>> -       install -m 0644 ${WORKDIR}/dhcrelay.service
>${D}${systemd_unitdir}/system
>> -       sed -i -e 's,@SBINDIR@,${sbindir},g'
>${D}${systemd_unitdir}/system/dhcpd*.service
>${D}${systemd_unitdir}/system/dhcrelay.service
>> -       sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g'
>${D}${systemd_unitdir}/system/dhcpd*.service
>> -       sed -i -e 's,@base_bindir@,${base_bindir},g'
>${D}${systemd_unitdir}/system/dhcpd*.service
>> -       sed -i -e 's,@localstatedir@,${localstatedir},g'
>${D}${systemd_unitdir}/system/dhcpd*.service
>> -       sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g'
>${D}${systemd_unitdir}/system/dhcrelay.service
>> -
>> -       install -d ${D}${base_sbindir}
>> -       install -m 0755 ${WORKDIR}/dhclient-systemd-wrapper
>${D}${base_sbindir}/dhclient-systemd-wrapper
>> -       install -m 0644 ${WORKDIR}/dhclient.service
>${D}${systemd_unitdir}/system
>> -       sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g'
>${D}${systemd_unitdir}/system/dhclient.service
>> -       sed -i -e 's,@BASE_SBINDIR@,${base_sbindir},g'
>${D}${systemd_unitdir}/system/dhclient.service
>> -}
>> -
>> -PACKAGES += "dhcp-libs dhcp-server dhcp-server-config dhcp-client dhcp-
>relay dhcp-omshell"
>> -
>> -PACKAGES_remove = "${PN}"
>> -RDEPENDS_${PN}-client += "${@bb.utils.contains('DISTRO_FEATURES',
>'systemd', 'iproute2', '', d)}"
>> -RDEPENDS_${PN}-dev = ""
>> -RDEPENDS_${PN}-staticdev = ""
>> -FILES_${PN}-libs = "${libdir}/libdhcpctl.so.0* ${libdir}/libomapi.so.0*
>${libdir}/libdhcp.so.0*"
>> -
>> -FILES_${PN}-server = "${sbindir}/dhcpd ${sysconfdir}/init.d/dhcp-server"
>> -RRECOMMENDS_${PN}-server = "dhcp-server-config"
>> -
>> -FILES_${PN}-server-config = "${sysconfdir}/default/dhcp-server
>${sysconfdir}/dhcp/dhcpd.conf"
>> -
>> -FILES_${PN}-relay = "${sbindir}/dhcrelay ${sysconfdir}/init.d/dhcp-relay
>${sysconfdir}/default/dhcp-relay"
>> -
>> -FILES_${PN}-client = "${base_sbindir}/dhclient \
>> -                      ${base_sbindir}/dhclient-script \
>> -                      ${sysconfdir}/dhcp/dhclient.conf \
>> -                      ${base_sbindir}/dhclient-systemd-wrapper \
>> -                     "
>> -
>> -FILES_${PN}-omshell = "${bindir}/omshell"
>> -
>> -pkg_postinst_dhcp-server() {
>> -    mkdir -p $D/${localstatedir}/lib/dhcp
>> -    touch $D/${localstatedir}/lib/dhcp/dhcpd.leases
>> -    touch $D/${localstatedir}/lib/dhcp/dhcpd6.leases
>> -}
>> -
>> -pkg_postinst_dhcp-client() {
>> -    mkdir -p $D/${localstatedir}/lib/dhcp
>> -}
>> -
>> -pkg_postrm_dhcp-server() {
>> -    rm -f $D/${localstatedir}/lib/dhcp/dhcpd.leases
>> -    rm -f $D/${localstatedir}/lib/dhcp/dhcpd6.leases
>> -
>> -    if ! rmdir $D/${localstatedir}/lib/dhcp 2>/dev/null; then
>> -        echo "Not removing ${localstatedir}/lib/dhcp as it is non-empty."
>> -    fi
>> -}
>> -
>> -pkg_postrm_dhcp-client() {
>> -    rm -f $D/${localstatedir}/lib/dhcp/dhclient.leases
>> -    rm -f $D/${localstatedir}/lib/dhcp/dhclient6.leases
>> -
>> -    if ! rmdir $D/${localstatedir}/lib/dhcp 2>/dev/null; then
>> -        echo "Not removing ${localstatedir}/lib/dhcp as it is non-empty."
>> -    fi
>> -}
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-
>_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch b/meta/recipes-
>connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-
>_PATH_DHCLIENT_CON.patch
>> deleted file mode 100644
>> index d1b57f0bb41..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-
>_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch
>> +++ /dev/null
>> @@ -1,27 +0,0 @@
>> -From 7cc29144535a622fc671dc86eb1da65b0473a7c4 Mon Sep 17 00:00:00
>2001
>> -From: Hongxu Jia <hongxu.jia@windriver.com>
>> -Date: Tue, 15 Aug 2017 16:14:22 +0800
>> -Subject: [PATCH 01/11] define macro _PATH_DHCPD_CONF and
>_PATH_DHCLIENT_CONF
>> -
>> -Upstream-Status: Inappropriate [OE specific]
>> -
>> -Rebase to 4.3.6
>> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ----
>> - includes/site.h | 3 ++-
>> - 1 file changed, 2 insertions(+), 1 deletion(-)
>> -
>> -Index: dhcp-4.4.1/includes/site.h
>> -
>================================================================
>===
>> ---- dhcp-4.4.1.orig/includes/site.h
>> -+++ dhcp-4.4.1/includes/site.h
>> -@@ -148,7 +148,8 @@
>> - /* Define this if you want the dhcpd.conf file to go somewhere other than
>> -    the default location.   By default, it goes in /etc/dhcpd.conf. */
>> -
>> --/* #define _PATH_DHCPD_CONF   "/etc/dhcpd.conf" */
>> -+#define _PATH_DHCPD_CONF      "/etc/dhcp/dhcpd.conf"
>> -+#define _PATH_DHCLIENT_CONF   "/etc/dhcp/dhclient.conf"
>> -
>> - /* Network API definitions.   You do not need to choose one of these - if
>> -    you don't choose, one will be chosen for you in your system's config
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0001-workaround-
>busybox-limitation-in-linux-dhclient-script.patch b/meta/recipes-
>connectivity/dhcp/dhcp/0001-workaround-busybox-limitation-in-linux-
>dhclient-script.patch
>> deleted file mode 100644
>> index 2359381b938..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0001-workaround-busybox-
>limitation-in-linux-dhclient-script.patch
>> +++ /dev/null
>> @@ -1,65 +0,0 @@
>> -From eec0503cfc36f63d777f5cb3f2719cecedcb8468 Mon Sep 17 00:00:00
>2001
>> -From: Haris Okanovic <haris.okanovic@ni.com>
>> -Date: Mon, 7 Jan 2019 13:22:09 -0600
>> -Subject: [PATCH] Workaround busybox limitation in Linux dhclient-script
>> -
>> -Busybox is a lightweight implementation of coreutils commonly used on
>> -space-constrained embedded Linux distributions. It's implementation of
>> -chown and chmod doesn't provide a "--reference" option added to
>> -client/scripts/linux as of commit 9261cb14. This change works around
>> -that limitation by using stat to read ownership and permissions flags
>> -and simple chown/chmod calls supported in both coreutils and busybox.
>> -
>> -    modified:   client/scripts/linux
>> -
>> -Signed-off-by: Haris Okanovic <haris.okanovic@ni.com>
>> -Upstream-Status: Pending [ISC-Bugs #48771]
>> ----
>> - client/scripts/linux | 17 +++++++++++++----
>> - 1 file changed, 13 insertions(+), 4 deletions(-)
>> -
>> -diff --git a/client/scripts/linux b/client/scripts/linux
>> -index 0c429697..2435a44b 100755
>> ---- a/client/scripts/linux
>> -+++ b/client/scripts/linux
>> -@@ -32,6 +32,17 @@
>> - # if your system holds ip tool in a non-standard location.
>> - ip=/sbin/ip
>> -
>> -+chown_chmod_by_reference() {
>> -+    local reference_file="$1"
>> -+    local target_file="$2"
>> -+
>> -+    local owner=$(stat -c "%u:%g" "$reference_file")
>> -+    local perm=$(stat -c "%a" "$reference_file")
>> -+
>> -+    chown "$owner" "$target_file"
>> -+    chmod "$perm" "$target_file"
>> -+}
>> -+
>> - # update /etc/resolv.conf based on received values
>> - # This updated version mostly follows Debian script by Andrew Pollock et al.
>> - make_resolv_conf() {
>> -@@ -74,8 +85,7 @@ make_resolv_conf() {
>> -         fi
>> -
>> -       if [ -f /etc/resolv.conf ]; then
>> --          chown --reference=/etc/resolv.conf $new_resolv_conf
>> --          chmod --reference=/etc/resolv.conf $new_resolv_conf
>> -+          chown_chmod_by_reference /etc/resolv.conf $new_resolv_conf
>> -       fi
>> -         mv -f $new_resolv_conf /etc/resolv.conf
>> -     # DHCPv6
>> -@@ -101,8 +111,7 @@ make_resolv_conf() {
>> -         fi
>> -
>> -       if [ -f /etc/resolv.conf ]; then
>> --            chown --reference=/etc/resolv.conf $new_resolv_conf
>> --            chmod --reference=/etc/resolv.conf $new_resolv_conf
>> -+          chown_chmod_by_reference /etc/resolv.conf $new_resolv_conf
>> -       fi
>> -         mv -f $new_resolv_conf /etc/resolv.conf
>> -     fi
>> ---
>> -2.20.0
>> -
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch
>b/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch
>> deleted file mode 100644
>> index 101c33f677a..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch
>> +++ /dev/null
>> @@ -1,117 +0,0 @@
>> -From be7540d31c356e80ee02e90e8bf162b7ac6e5ba5 Mon Sep 17 00:00:00
>2001
>> -From: Hongxu Jia <hongxu.jia@windriver.com>
>> -Date: Tue, 15 Aug 2017 14:56:56 +0800
>> -Subject: [PATCH 02/11] dhclient dbus
>> -
>> -Upstream-Status: Inappropriate [distribution]
>> -
>> -Rebase to 4.3.6
>> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ----
>> - client/scripts/bsdos   | 5 +++++
>> - client/scripts/freebsd | 5 +++++
>> - client/scripts/linux   | 5 +++++
>> - client/scripts/netbsd  | 5 +++++
>> - client/scripts/openbsd | 5 +++++
>> - client/scripts/solaris | 5 +++++
>> - 6 files changed, 30 insertions(+)
>> -
>> -diff --git a/client/scripts/bsdos b/client/scripts/bsdos
>> -index d69d0d8..095b143 100755
>> ---- a/client/scripts/bsdos
>> -+++ b/client/scripts/bsdos
>> -@@ -45,6 +45,11 @@ exit_with_hooks() {
>> -     . /etc/dhclient-exit-hooks
>> -   fi
>> - # probably should do something with exit status of the local script
>> -+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
>> -+    dbus-send --system --dest=com.redhat.dhcp \
>> -+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set
>\
>> -+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
>> -+  fi
>> -   exit $exit_status
>> - }
>> -
>> -diff --git a/client/scripts/freebsd b/client/scripts/freebsd
>> -index 8f3e2a2..ad7fb44 100755
>> ---- a/client/scripts/freebsd
>> -+++ b/client/scripts/freebsd
>> -@@ -89,6 +89,11 @@ exit_with_hooks() {
>> -     . /etc/dhclient-exit-hooks
>> -   fi
>> - # probably should do something with exit status of the local script
>> -+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
>> -+    dbus-send --system --dest=com.redhat.dhcp \
>> -+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set
>\
>> -+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
>> -+  fi
>> -   exit $exit_status
>> - }
>> -
>> -diff --git a/client/scripts/linux b/client/scripts/linux
>> -index 5fb1612..3d447b6 100755
>> ---- a/client/scripts/linux
>> -+++ b/client/scripts/linux
>> -@@ -174,6 +174,11 @@ exit_with_hooks() {
>> -         exit_status=$?
>> -     fi
>> -
>> -+    if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
>> -+        dbus-send --system --dest=com.redhat.dhcp \
>> -+           --type=method_call /com/redhat/dhcp/$interface
>com.redhat.dhcp.set \
>> -+           'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
>> -+    fi
>> -     exit $exit_status
>> - }
>> -
>> -diff --git a/client/scripts/netbsd b/client/scripts/netbsd
>> -index 07383b7..aaba8e8 100755
>> ---- a/client/scripts/netbsd
>> -+++ b/client/scripts/netbsd
>> -@@ -45,6 +45,11 @@ exit_with_hooks() {
>> -     . /etc/dhclient-exit-hooks
>> -   fi
>> - # probably should do something with exit status of the local script
>> -+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
>> -+    dbus-send --system --dest=com.redhat.dhcp \
>> -+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set
>\
>> -+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
>> -+  fi
>> -   exit $exit_status
>> - }
>> -
>> -diff --git a/client/scripts/openbsd b/client/scripts/openbsd
>> -index e7f4746..56b980c 100644
>> ---- a/client/scripts/openbsd
>> -+++ b/client/scripts/openbsd
>> -@@ -45,6 +45,11 @@ exit_with_hooks() {
>> -     . /etc/dhclient-exit-hooks
>> -   fi
>> - # probably should do something with exit status of the local script
>> -+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
>> -+    dbus-send --system --dest=com.redhat.dhcp \
>> -+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set
>\
>> -+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
>> -+  fi
>> -   exit $exit_status
>> - }
>> -
>> -diff --git a/client/scripts/solaris b/client/scripts/solaris
>> -index af553b9..4a2aa69 100755
>> ---- a/client/scripts/solaris
>> -+++ b/client/scripts/solaris
>> -@@ -26,6 +26,11 @@ exit_with_hooks() {
>> -     . /etc/dhclient-exit-hooks
>> -   fi
>> - # probably should do something with exit status of the local script
>> -+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
>> -+    dbus-send --system --dest=com.redhat.dhcp \
>> -+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set
>\
>> -+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
>> -+  fi
>> -   exit $exit_status
>> - }
>> -
>> ---
>> -1.8.3.1
>> -
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-
>lcrypto.patch b/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-
>lcrypto.patch
>> deleted file mode 100644
>> index 5b35933a54a..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch
>> +++ /dev/null
>> @@ -1,35 +0,0 @@
>> -From d80bd792323dbd56269309f85b4506eb6b1b60e9 Mon Sep 17
>00:00:00 2001
>> -From: Andrei Gherzan <andrei@gherzan.ro>
>> -Date: Tue, 15 Aug 2017 15:05:47 +0800
>> -Subject: [PATCH 03/11] link with lcrypto
>> -
>> -From 4.2.0 final release, -lcrypto check was removed and we compile
>> -static libraries
>> -from bind that are linked to libcrypto. This is why i added a patch in
>> -order to add
>> --lcrypto to LIBS.
>> -
>> -Upstream-Status: Pending
>> -Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
>> -
>> -Rebase to 4.3.6
>> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ----
>> - configure.ac | 4 ++++
>> - 1 file changed, 4 insertions(+)
>> -
>> -Index: dhcp-4.4.1/configure.ac
>> -
>================================================================
>===
>> ---- dhcp-4.4.1.orig/configure.ac
>> -+++ dhcp-4.4.1/configure.ac
>> -@@ -612,6 +612,10 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]],
>> - # Look for optional headers.
>> - AC_CHECK_HEADERS(sys/socket.h net/if_dl.h net/if6.h regex.h)
>> -
>> -+# find an MD5 library
>> -+AC_SEARCH_LIBS(MD5_Init, [crypto])
>> -+AC_SEARCH_LIBS(MD5Init, [crypto])
>> -+
>> - # Solaris needs some libraries for functions
>> - AC_SEARCH_LIBS(socket, [socket])
>> - AC_SEARCH_LIBS(inet_ntoa, [nsl])
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-
>builds.patch b/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-
>builds.patch
>> deleted file mode 100644
>> index 7b57730ffb7..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch
>> +++ /dev/null
>> @@ -1,95 +0,0 @@
>> -From cccec0344d68dac4100b6f260ee24e7c2da9dfda Mon Sep 17 00:00:00
>2001
>> -From: Hongxu Jia <hongxu.jia@windriver.com>
>> -Date: Tue, 15 Aug 2017 15:08:22 +0800
>> -Subject: [PATCH 04/11] Fix out of tree builds
>> -
>> -Upstream-Status: Pending
>> -
>> -RP 2013/03/21
>> -
>> -Rebase to 4.3.6
>> -
>> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ----
>> - client/Makefile.am  | 4 ++--
>> - common/Makefile.am  | 3 ++-
>> - dhcpctl/Makefile.am | 2 ++
>> - omapip/Makefile.am  | 1 +
>> - relay/Makefile.am   | 2 +-
>> - server/Makefile.am  | 2 +-
>> - 6 files changed, 9 insertions(+), 5 deletions(-)
>> -
>> -Index: dhcp-4.4.1/common/Makefile.am
>> -
>================================================================
>===
>> ---- dhcp-4.4.1.orig/common/Makefile.am
>> -+++ dhcp-4.4.1/common/Makefile.am
>> -@@ -1,4 +1,5 @@
>> --AM_CPPFLAGS = -I$(top_srcdir) -DLOCALSTATEDIR='"@localstatedir@"'
>> -+AM_CPPFLAGS = -I$(top_srcdir)/includes -I$(top_srcdir) -
>DLOCALSTATEDIR='"@localstatedir@"'
>> -+
>> - AM_CFLAGS = $(LDAP_CFLAGS)
>> -
>> - lib_LIBRARIES = libdhcp.a
>> -Index: dhcp-4.4.1/dhcpctl/Makefile.am
>> -
>================================================================
>===
>> ---- dhcp-4.4.1.orig/dhcpctl/Makefile.am
>> -+++ dhcp-4.4.1/dhcpctl/Makefile.am
>> -@@ -3,6 +3,8 @@ BINDLIBDNSDIR=@BINDLIBDNSDIR@
>> - BINDLIBISCCFGDIR=@BINDLIBISCCFGDIR@
>> - BINDLIBISCDIR=@BINDLIBISCDIR@
>> -
>> -+AM_CPPFLAGS = -I$(top_srcdir)/includes -I$(top_srcdir)
>> -+
>> - bin_PROGRAMS = omshell
>> - lib_LIBRARIES = libdhcpctl.a
>> - noinst_PROGRAMS = cltest
>> -Index: dhcp-4.4.1/server/Makefile.am
>> -
>================================================================
>===
>> ---- dhcp-4.4.1.orig/server/Makefile.am
>> -+++ dhcp-4.4.1/server/Makefile.am
>> -@@ -4,7 +4,7 @@
>> - # production code. Sadly, we are not there yet.
>> - SUBDIRS = . tests
>> -
>> --AM_CPPFLAGS = -I.. -DLOCALSTATEDIR='"@localstatedir@"'
>> -+AM_CPPFLAGS = -I$(top_srcdir) -DLOCALSTATEDIR='"@localstatedir@"' -
>I$(top_srcdir)/includes
>> -
>> - dist_sysconf_DATA = dhcpd.conf.example
>> - sbin_PROGRAMS = dhcpd
>> -Index: dhcp-4.4.1/client/Makefile.am
>> -
>================================================================
>===
>> ---- dhcp-4.4.1.orig/client/Makefile.am
>> -+++ dhcp-4.4.1/client/Makefile.am
>> -@@ -5,7 +5,7 @@
>> - SUBDIRS = . tests
>> -
>> - AM_CPPFLAGS = -
>DCLIENT_PATH='"PATH=$(sbindir):/sbin:/bin:/usr/sbin:/usr/bin"'
>> --AM_CPPFLAGS += -DLOCALSTATEDIR='"$(localstatedir)"'
>> -+AM_CPPFLAGS += -DLOCALSTATEDIR='"$(localstatedir)"' -
>I$(top_srcdir)/includes
>> -
>> - dist_sysconf_DATA = dhclient.conf.example
>> - sbin_PROGRAMS = dhclient
>> -Index: dhcp-4.4.1/omapip/Makefile.am
>> -
>================================================================
>===
>> ---- dhcp-4.4.1.orig/omapip/Makefile.am
>> -+++ dhcp-4.4.1/omapip/Makefile.am
>> -@@ -2,6 +2,7 @@ BINDLIBIRSDIR=@BINDLIBIRSDIR@
>> - BINDLIBDNSDIR=@BINDLIBDNSDIR@
>> - BINDLIBISCCFGDIR=@BINDLIBISCCFGDIR@
>> - BINDLIBISCDIR=@BINDLIBISCDIR@
>> -+AM_CPPFLAGS = -I$(top_srcdir)/includes
>> -
>> - lib_LIBRARIES = libomapi.a
>> - noinst_PROGRAMS = svtest
>> -Index: dhcp-4.4.1/relay/Makefile.am
>> -
>================================================================
>===
>> ---- dhcp-4.4.1.orig/relay/Makefile.am
>> -+++ dhcp-4.4.1/relay/Makefile.am
>> -@@ -1,6 +1,6 @@
>> - SUBDIRS = . tests
>> -
>> --AM_CPPFLAGS = -DLOCALSTATEDIR='"@localstatedir@"'
>> -+AM_CPPFLAGS = -DLOCALSTATEDIR='"@localstatedir@"' -
>I$(top_srcdir)/includes
>> -
>> - sbin_PROGRAMS = dhcrelay
>> - dhcrelay_SOURCES = dhcrelay.c
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0005-dhcp-client-fix-
>invoke-dhclient-script-failed-on-Rea.patch b/meta/recipes-
>connectivity/dhcp/dhcp/0005-dhcp-client-fix-invoke-dhclient-script-failed-on-
>Rea.patch
>> deleted file mode 100644
>> index dd56381b1dc..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0005-dhcp-client-fix-invoke-
>dhclient-script-failed-on-Rea.patch
>> +++ /dev/null
>> @@ -1,36 +0,0 @@
>> -From 2e8ff0e4f6d39e346ea86b8c514ab4ccc78fa359 Mon Sep 17 00:00:00
>2001
>> -From: Hongxu Jia <hongxu.jia@windriver.com>
>> -Date: Tue, 15 Aug 2017 15:24:14 +0800
>> -Subject: [PATCH 05/11] dhcp-client: fix invoke dhclient-script failed on
>> - Read-only file system
>> -
>> -In read-only file system, '/etc' is on the readonly partition,
>> -and '/etc/resolv.conf' is symlinked to a separate writable
>> -partition.
>> -
>> -In this situation, we create temp files 'resolv.conf.dhclient-new'
>> -in /tmp dir.
>> -
>> -Upstream-Status: Pending
>> -
>> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ----
>> - client/scripts/linux | 2 +-
>> - 1 file changed, 1 insertion(+), 1 deletion(-)
>> -
>> -diff --git a/client/scripts/linux b/client/scripts/linux
>> -index 3d447b6..3122a75 100755
>> ---- a/client/scripts/linux
>> -+++ b/client/scripts/linux
>> -@@ -40,7 +40,7 @@ make_resolv_conf() {
>> -     # DHCPv4
>> -     if [ -n "$new_domain_search" ] || [ -n "$new_domain_name" ] ||
>> -        [ -n "$new_domain_name_servers" ]; then
>> --        new_resolv_conf=/etc/resolv.conf.dhclient-new
>> -+        new_resolv_conf=/tmp/resolv.conf.dhclient-new
>> -         rm -f $new_resolv_conf
>> -
>> -         if [ -n "$new_domain_name" ]; then
>> ---
>> -1.8.3.1
>> -
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-
>argument-to-make-the-libxml2-dependenc.patch b/meta/recipes-
>connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-
>dependenc.patch
>> deleted file mode 100644
>> index feb0754fff4..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-
>to-make-the-libxml2-dependenc.patch
>> +++ /dev/null
>> @@ -1,62 +0,0 @@
>> -From 7107511fd209f08f9a96f8938041ae48f3295895 Mon Sep 17 00:00:00
>2001
>> -From: Christopher Larson <chris_larson@mentor.com>
>> -Date: Tue, 15 Aug 2017 16:17:49 +0800
>> -Subject: [PATCH 07/11] Add configure argument to make the libxml2
>dependency
>> - explicit and determinisitic.
>> -
>> -Upstream-Status: Pending
>> -
>> -Signed-off-by: Christopher Larson <chris_larson@mentor.com>
>> -
>> -Rebase to 4.3.6
>> -
>> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ----
>> - configure.ac | 11 +++++++++++
>> - 1 file changed, 11 insertions(+)
>> -
>> -Index: dhcp-4.4.1/configure.ac
>> -
>================================================================
>===
>> ---- dhcp-4.4.1.orig/configure.ac
>> -+++ dhcp-4.4.1/configure.ac
>> -@@ -642,6 +642,17 @@ if test "$have_nanosleep" = "rt"; then
>> -       LIBS="-lrt $LIBS"
>> - fi
>> -
>> -+AC_ARG_WITH(libxml2,
>> -+      AS_HELP_STRING([--with-libxml2], [link against libxml2. this is needed if
>bind was built with xml2 support enabled]),
>> -+      with_libxml2="$withval", with_libxml2="no")
>> -+
>> -+if test x$with_libxml2 != xno; then
>> -+      AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],
>> -+              [if test x$with_libxml2 != xauto; then
>> -+                      AC_MSG_FAILURE([*** Cannot find xmlTextWriterStartElement
>with -lxml2 and libxml2 was requested])
>> -+              fi])
>> -+fi
>> -+
>> - # check for /dev/random (declares HAVE_DEV_RANDOM)
>> - AC_MSG_CHECKING(for random device)
>> - AC_ARG_WITH(randomdev,
>> -Index: dhcp-4.4.1/configure.ac+lt
>> -
>================================================================
>===
>> ---- dhcp-4.4.1.orig/configure.ac+lt
>> -+++ dhcp-4.4.1/configure.ac+lt
>> -@@ -909,6 +909,18 @@ elif test "$want_libtool" = "yes" -a "$u
>> - fi
>> - AM_CONDITIONAL(INSTALL_BIND, test "$want_install_bind" = "yes")
>> -
>> -+AC_ARG_WITH(libxml2,
>> -+      AS_HELP_STRING([--with-libxml2], [link against libxml2. this is needed if
>bind was built with xml2 support enabled]),
>> -+      with_libxml2="$withval", with_libxml2="no")
>> -+
>> -+if test x$with_libxml2 != xno; then
>> -+      AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],,
>> -+              [if test x$with_libxml2 != xauto; then
>> -+                      AC_MSG_FAILURE([*** Cannot find xmlTextWriterStartElement
>with -lxml2 and libxml2 was requested])
>> -+              fi])
>> -+fi
>> -+
>> -+
>> - # OpenLDAP support.
>> - AC_ARG_WITH(ldap,
>> -     AS_HELP_STRING([--with-ldap],[enable OpenLDAP support in dhcpd
>(default is no)]),
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0009-remove-dhclient-
>script-bash-dependency.patch b/meta/recipes-connectivity/dhcp/dhcp/0009-
>remove-dhclient-script-bash-dependency.patch
>> deleted file mode 100644
>> index 912b6d6312c..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0009-remove-dhclient-script-
>bash-dependency.patch
>> +++ /dev/null
>> @@ -1,28 +0,0 @@
>> -From f3f8b7726e50e24ef3edf5fa5a17e31d39118d7e Mon Sep 17 00:00:00
>2001
>> -From: Andre McCurdy <armccurdy@gmail.com>
>> -Date: Tue, 15 Aug 2017 15:49:31 +0800
>> -Subject: [PATCH 09/11] remove dhclient-script bash dependency
>> -
>> -Upstream-Status: Inappropriate [OE specific]
>> -
>> -Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
>> -
>> -Rebase to 4.3.6
>> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ----
>> - client/scripts/linux | 2 +-
>> - 1 file changed, 1 insertion(+), 1 deletion(-)
>> -
>> -diff --git a/client/scripts/linux b/client/scripts/linux
>> -index 3122a75..1712d7d 100755
>> ---- a/client/scripts/linux
>> -+++ b/client/scripts/linux
>> -@@ -1,4 +1,4 @@
>> --#!/bin/bash
>> -+#!/bin/sh
>> - # dhclient-script for Linux. Dan Halbert, March, 1997.
>> - # Updated for Linux 2.[12] by Brian J. Murrell, January 1999.
>> - # No guarantees about this. I'm a novice at the details of Linux
>> ---
>> -1.8.3.1
>> -
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-
>intention-for-xml2-lib-search.patch b/meta/recipes-
>connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-
>search.patch
>> deleted file mode 100644
>> index 39ba65fbc46..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-
>for-xml2-lib-search.patch
>> +++ /dev/null
>> @@ -1,34 +0,0 @@
>> -From 501543b3ef715488a142e3d301ff2733aa33eec7 Mon Sep 17 00:00:00
>2001
>> -From: Awais Belal <awais_belal@mentor.com>
>> -Date: Wed, 25 Oct 2017 21:00:05 +0500
>> -Subject: [PATCH] dhcp: correct the intention for xml2 lib search
>> -
>> -A missing case breaks the build when libxml2 is
>> -required and found appropriately. The third argument
>> -to the function AC_SEARCH_LIB is action-if-found which
>> -was mistakenly been used for the case where the library
>> -is not found and hence breaks the configure phase
>> -where it shoud actually pass.
>> -We now pass on silently when action-if-found is
>> -executed.
>> -
>> -Upstream-Status: Pending
>> -
>> -Signed-off-by: Awais Belal <awais_belal@mentor.com>
>> ----
>> - configure.ac | 2 +-
>> - 1 file changed, 1 insertion(+), 1 deletion(-)
>> -
>> -Index: dhcp-4.4.1/configure.ac
>> -
>================================================================
>===
>> ---- dhcp-4.4.1.orig/configure.ac
>> -+++ dhcp-4.4.1/configure.ac
>> -@@ -647,7 +647,7 @@ AC_ARG_WITH(libxml2,
>> -       with_libxml2="$withval", with_libxml2="no")
>> -
>> - if test x$with_libxml2 != xno; then
>> --      AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],
>> -+      AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],,
>> -               [if test x$with_libxml2 != xauto; then
>> -                       AC_MSG_FAILURE([*** Cannot find xmlTextWriterStartElement
>with -lxml2 and libxml2 was requested])
>> -               fi])
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0013-
>fixup_use_libbind.patch b/meta/recipes-connectivity/dhcp/dhcp/0013-
>fixup_use_libbind.patch
>> deleted file mode 100644
>> index fcec010bd01..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch
>> +++ /dev/null
>> @@ -1,64 +0,0 @@
>> -lib and include path is hardcoded for use_libbind
>> -
>> -use libdir and includedir vars
>> -
>> -Upstream-Status: Pending
>> -Signed-off-by: Armin Kuster <akuster808@gmail.com>
>> -
>> -Index: dhcp-4.4.1/configure.ac+lt
>> -
>================================================================
>===
>> ---- dhcp-4.4.1.orig/configure.ac+lt
>> -+++ dhcp-4.4.1/configure.ac+lt
>> -@@ -801,22 +801,22 @@ no)
>> -       if test ! -d "$use_libbind"; then
>> -               AC_MSG_ERROR([Cannot find bind directory at $use_libbind])
>> -       fi
>> --      if test ! -d "$use_libbind/include" -o \
>> --              ! -f "$use_libbind/include/isc/buffer.h"
>> -+      if test ! -d "$use_libbind/$includedir" -o \
>> -+              ! -f "$use_libbind/$includedir/isc/buffer.h"
>> -       then
>> --              AC_MSG_ERROR([Cannot find bind includes at
>$use_libbind/include])
>> -+              AC_MSG_ERROR([Cannot find bind includes at
>$use_libbind/$includedir])
>> -       fi
>> --      if test ! -d "$use_libbind/lib" -o \
>> --              \( ! -f "$use_libbind/lib/libisc.a" -a \
>> --                 ! -f "$use_libbind/lib/libisc.la" \)
>> -+      if test ! -d "$use_libbind/$libdir" -o \
>> -+              \( ! -f "$use_libbind/$libdir/libisc.a" -a \
>> -+                 ! -f "$use_libbind/$libdir/libisc.la" \)
>> -       then
>> --              AC_MSG_ERROR([Cannot find bind libraries at $use_libbind/lib])
>> -+              AC_MSG_ERROR([Cannot find bind libraries at $use_libbind/$libdir])
>> -       fi
>> -       BINDDIR="$use_libbind"
>> --      BINDLIBIRSDIR="$BINDDIR/lib"
>> --      BINDLIBDNSDIR="$BINDDIR/lib"
>> --      BINDLIBISCCFGDIR="$BINDDIR/lib"
>> --      BINDLIBISCDIR="$BINDDIR/lib"
>> -+      BINDLIBIRSDIR="$BINDDIR/$libdir"
>> -+      BINDLIBDNSDIR="$BINDDIR/$libdir"
>> -+      BINDLIBISCCFGDIR="$BINDDIR/$libdir"
>> -+      BINDLIBISCDIR="$BINDDIR/$libdir"
>> -       DISTCHECK_LIBBIND_CONFIGURE_FLAG="--with-libbind=$use_libbind"
>> -       ;;
>> - esac
>> -@@ -856,14 +856,14 @@ AC_ARG_ENABLE(libtool,
>> -
>> - if test "$use_libbind" != "no"; then
>> -       if test "$want_libtool" = "yes" -a \
>> --              ! -f "$use_libbind/lib/libisc.la"
>> -+              ! -f "$use_libbind/$libdir/libisc.la"
>> -       then
>> --              AC_MSG_ERROR([Cannot find dynamic libraries at $use_libbind/lib])
>> -+              AC_MSG_ERROR([Cannot find dynamic libraries at
>$use_libbind/$libdir])
>> -       fi
>> -       if test "$want_libtool" = "no" -a \
>> --              ! -f "$use_libbind/lib/libisc.a"
>> -+              ! -f "$use_libbind/$libdir/libisc.a"
>> -       then
>> --              AC_MSG_ERROR([Cannot find static libraries at $use_libbind/lib])
>> -+              AC_MSG_ERROR([Cannot find static libraries at
>$use_libbind/$libdir])
>> -       fi
>> - fi
>> -
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb b/meta/recipes-
>connectivity/dhcp/dhcp_4.4.2.bb
>> deleted file mode 100644
>> index cf4af826099..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb
>> +++ /dev/null
>> @@ -1,23 +0,0 @@
>> -require dhcp.inc
>> -
>> -SRC_URI += "file://0001-define-macro-_PATH_DHCPD_CONF-and-
>_PATH_DHCLIENT_CON.patch \
>> -            file://0002-dhclient-dbus.patch \
>> -            file://0003-link-with-lcrypto.patch \
>> -            file://0004-Fix-out-of-tree-builds.patch \
>> -            file://0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch \
>> -            file://0007-Add-configure-argument-to-make-the-libxml2-
>dependenc.patch \
>> -            file://0009-remove-dhclient-script-bash-dependency.patch \
>> -            file://0012-dhcp-correct-the-intention-for-xml2-lib-search.patch \
>> -            file://0013-fixup_use_libbind.patch \
>> -            file://0001-workaround-busybox-limitation-in-linux-dhclient-
>script.patch \
>> -"
>> -
>> -SRC_URI[md5sum] = "2afdaf8498dc1edaf3012efdd589b3e1"
>> -SRC_URI[sha256sum] =
>"1a7ccd64a16e5e68f7b5e0f527fd07240a2892ea53fe245620f4f5f607004521"
>> -
>> -LDFLAGS_append = " -pthread"
>> -
>> -PACKAGECONFIG ?= ""
>> -PACKAGECONFIG[bind-httpstats] = "--with-libxml2,--without-
>libxml2,libxml2"
>> -
>> -CFLAGS += "-fcommon"
>> diff --git a/meta/recipes-connectivity/dhcp/files/default-relay
>b/meta/recipes-connectivity/dhcp/files/default-relay
>> deleted file mode 100644
>> index 7961f014bef..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/default-relay
>> +++ /dev/null
>> @@ -1,12 +0,0 @@
>> -# Defaults for dhcp-relay initscript
>> -# sourced by /etc/init.d/dhcp-relay
>> -
>> -# What servers should the DHCP relay forward requests to?
>> -# e.g: SERVERS="192.168.0.1"
>> -SERVERS=""
>> -
>> -# On what interfaces should the DHCP relay (dhrelay) serve DHCP requests?
>> -INTERFACES=""
>> -
>> -# Additional options that are passed to the DHCP relay daemon?
>> -OPTIONS=""
>> diff --git a/meta/recipes-connectivity/dhcp/files/default-server
>b/meta/recipes-connectivity/dhcp/files/default-server
>> deleted file mode 100644
>> index 0385d169922..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/default-server
>> +++ /dev/null
>> @@ -1,7 +0,0 @@
>> -# Defaults for dhcp initscript
>> -# sourced by /etc/init.d/dhcp-server
>> -# installed at /etc/default/dhcp-server by the maintainer scripts
>> -
>> -# On what interfaces should the DHCP server (dhcpd) serve DHCP requests?
>> -#       Separate multiple interfaces with spaces, e.g. "eth0 eth1".
>> -INTERFACES=""
>> diff --git a/meta/recipes-connectivity/dhcp/files/dhclient-systemd-wrapper
>b/meta/recipes-connectivity/dhcp/files/dhclient-systemd-wrapper
>> deleted file mode 100644
>> index 7d0e224a1df..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/dhclient-systemd-wrapper
>> +++ /dev/null
>> @@ -1,39 +0,0 @@
>> -#!/bin/sh
>> -
>> -# In case the interface is used for nfs, skip it.
>> -nfsroot=0
>> -interfaces=""
>> -exec 9<&0 < /proc/mounts
>> -while read dev mtpt fstype rest; do
>> -    if test $mtpt = "/" ; then
>> -        case $fstype in
>> -            nfs | nfs4)
>> -                nfsroot=1
>> -                nfs_addr=`echo $rest | sed -e 's/^.*addr=\([0-9.]*\).*$/\1/'`
>> -                break
>> -                ;;
>> -            *)
>> -                ;;
>> -        esac
>> -    fi
>> -done
>> -exec 0<&9 9<&-
>> -
>> -if [ $nfsroot -eq 0 ]; then
>> -    interfaces="$INTERFACES"
>> -else
>> -    if [ -x /bin/ip -o -x /sbin/ip ] ; then
>> -       nfs_iface=`ip route get $nfs_addr | grep dev | sed -e 's/^.*dev \([-a-z0-
>9.]*\).*$/\1/'`
>> -    fi
>> -    for i in $INTERFACES; do
>> -       if test "x$i" = "x$nfs_iface"; then
>> -            echo "dhclient skipping nfsroot interface $i"
>> -       else
>> -           interfaces="$interfaces $i"
>> -       fi
>> -    done
>> -fi
>> -
>> -if test "x$interfaces" != "x"; then
>> -    /sbin/dhclient -d -cf /etc/dhcp/dhclient.conf -q -lf
>/var/lib/dhcp/dhclient.leases $interfaces
>> -fi
>> diff --git a/meta/recipes-connectivity/dhcp/files/dhclient.conf
>b/meta/recipes-connectivity/dhcp/files/dhclient.conf
>> deleted file mode 100644
>> index 0e6dcf96c21..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/dhclient.conf
>> +++ /dev/null
>> @@ -1,50 +0,0 @@
>> -# Configuration file for /sbin/dhclient, which is included in Debian's
>> -#      dhcp3-client package.
>> -#
>> -# This is a sample configuration file for dhclient. See dhclient.conf's
>> -#      man page for more information about the syntax of this file
>> -#      and a more comprehensive list of the parameters understood by
>> -#      dhclient.
>> -#
>> -# Normally, if the DHCP server provides reasonable information and does
>> -#      not leave anything out (like the domain name, for example), then
>> -#      few changes must be made to this file, if any.
>> -#
>> -
>> -#send host-name "andare.fugue.com";
>> -#send dhcp-client-identifier 1:0:a0:24:ab:fb:9c;
>> -#send dhcp-lease-time 3600;
>> -#supersede domain-name "fugue.com home.vix.com";
>> -#prepend domain-name-servers 127.0.0.1;
>> -request subnet-mask, broadcast-address, time-offset, routers,
>> -       domain-name, domain-name-servers, host-name,
>> -       netbios-name-servers, netbios-scope;
>> -#require subnet-mask, domain-name-servers;
>> -#timeout 60;
>> -#retry 60;
>> -#reboot 10;
>> -#select-timeout 5;
>> -#initial-interval 2;
>> -#script "/etc/dhcp3/dhclient-script";
>> -#media "-link0 -link1 -link2", "link0 link1";
>> -#reject 192.33.137.209;
>> -
>> -#alias {
>> -#  interface "eth0";
>> -#  fixed-address 192.5.5.213;
>> -#  option subnet-mask 255.255.255.255;
>> -#}
>> -
>> -#lease {
>> -#  interface "eth0";
>> -#  fixed-address 192.33.137.200;
>> -#  medium "link0 link1";
>> -#  option host-name "andare.swiftmedia.com";
>> -#  option subnet-mask 255.255.255.0;
>> -#  option broadcast-address 192.33.137.255;
>> -#  option routers 192.33.137.250;
>> -#  option domain-name-servers 127.0.0.1;
>> -#  renew 2 2000/1/12 00:00:01;
>> -#  rebind 2 2000/1/12 00:00:01;
>> -#  expire 2 2000/1/12 00:00:01;
>> -#}
>> diff --git a/meta/recipes-connectivity/dhcp/files/dhclient.service
>b/meta/recipes-connectivity/dhcp/files/dhclient.service
>> deleted file mode 100644
>> index 9ddb4d1dfe9..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/dhclient.service
>> +++ /dev/null
>> @@ -1,13 +0,0 @@
>> -[Unit]
>> -Description=Dynamic Host Configuration Protocol (DHCP)
>> -Wants=network.target
>> -Before=network.target
>> -After=systemd-udevd.service
>> -
>> -[Service]
>> -EnvironmentFile=-@SYSCONFDIR@/default/dhcp-client
>> -ExecStart=@BASE_SBINDIR@/dhclient-systemd-wrapper
>> -RemainAfterExit=yes
>> -
>> -[Install]
>> -WantedBy=multi-user.target
>> diff --git a/meta/recipes-connectivity/dhcp/files/dhcpd.conf b/meta/recipes-
>connectivity/dhcp/files/dhcpd.conf
>> deleted file mode 100644
>> index 0001c0f00e2..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/dhcpd.conf
>> +++ /dev/null
>> @@ -1,108 +0,0 @@
>> -#
>> -# Sample configuration file for ISC dhcpd for Debian
>> -#
>> -# $Id: dhcpd.conf,v 1.1.1.1 2002/05/21 00:07:44 peloy Exp $
>> -#
>> -
>> -# The ddns-updates-style parameter controls whether or not the server will
>> -# attempt to do a DNS update when a lease is confirmed. We default to the
>> -# behavior of the version 2 packages ('none', since DHCP v2 didn't
>> -# have support for DDNS.)
>> -ddns-update-style none;
>> -
>> -# option definitions common to all supported networks...
>> -option domain-name "example.org";
>> -option domain-name-servers ns1.example.org, ns2.example.org;
>> -
>> -default-lease-time 600;
>> -max-lease-time 7200;
>> -
>> -# If this DHCP server is the official DHCP server for the local
>> -# network, the authoritative directive should be uncommented.
>> -#authoritative;
>> -
>> -# Use this to send dhcp log messages to a different log file (you also
>> -# have to hack syslog.conf to complete the redirection).
>> -log-facility local7;
>> -
>> -# No service will be given on this subnet, but declaring it helps the
>> -# DHCP server to understand the network topology.
>> -
>> -#subnet 10.152.187.0 netmask 255.255.255.0 {
>> -#}
>> -
>> -# This is a very basic subnet declaration.
>> -
>> -#subnet 10.254.239.0 netmask 255.255.255.224 {
>> -#  range 10.254.239.10 10.254.239.20;
>> -#  option routers rtr-239-0-1.example.org, rtr-239-0-2.example.org;
>> -#}
>> -
>> -# This declaration allows BOOTP clients to get dynamic addresses,
>> -# which we don't really recommend.
>> -
>> -#subnet 10.254.239.32 netmask 255.255.255.224 {
>> -#  range dynamic-bootp 10.254.239.40 10.254.239.60;
>> -#  option broadcast-address 10.254.239.31;
>> -#  option routers rtr-239-32-1.example.org;
>> -#}
>> -
>> -# A slightly different configuration for an internal subnet.
>> -#subnet 10.5.5.0 netmask 255.255.255.224 {
>> -#  range 10.5.5.26 10.5.5.30;
>> -#  option domain-name-servers ns1.internal.example.org;
>> -#  option domain-name "internal.example.org";
>> -#  option routers 10.5.5.1;
>> -#  option broadcast-address 10.5.5.31;
>> -#  default-lease-time 600;
>> -#  max-lease-time 7200;
>> -#}
>> -
>> -# Hosts which require special configuration options can be listed in
>> -# host statements.   If no address is specified, the address will be
>> -# allocated dynamically (if possible), but the host-specific information
>> -# will still come from the host declaration.
>> -
>> -#host passacaglia {
>> -#  hardware ethernet 0:0:c0:5d:bd:95;
>> -#  filename "vmunix.passacaglia";
>> -#  server-name "toccata.fugue.com";
>> -#}
>> -
>> -# Fixed IP addresses can also be specified for hosts.   These addresses
>> -# should not also be listed as being available for dynamic assignment.
>> -# Hosts for which fixed IP addresses have been specified can boot using
>> -# BOOTP or DHCP.   Hosts for which no fixed address is specified can only
>> -# be booted with DHCP, unless there is an address range on the subnet
>> -# to which a BOOTP client is connected which has the dynamic-bootp flag
>> -# set.
>> -#host fantasia {
>> -#  hardware ethernet 08:00:07:26:c0:a5;
>> -#  fixed-address fantasia.fugue.com;
>> -#}
>> -
>> -# You can declare a class of clients and then do address allocation
>> -# based on that.   The example below shows a case where all clients
>> -# in a certain class get addresses on the 10.17.224/24 subnet, and all
>> -# other clients get addresses on the 10.0.29/24 subnet.
>> -
>> -#class "foo" {
>> -#  match if substring (option vendor-class-identifier, 0, 4) = "SUNW";
>> -#}
>> -
>> -#shared-network 224-29 {
>> -#  subnet 10.17.224.0 netmask 255.255.255.0 {
>> -#    option routers rtr-224.example.org;
>> -#  }
>> -#  subnet 10.0.29.0 netmask 255.255.255.0 {
>> -#    option routers rtr-29.example.org;
>> -#  }
>> -#  pool {
>> -#    allow members of "foo";
>> -#    range 10.17.224.10 10.17.224.250;
>> -#  }
>> -#  pool {
>> -#    deny members of "foo";
>> -#    range 10.0.29.10 10.0.29.230;
>> -#  }
>> -#}
>> diff --git a/meta/recipes-connectivity/dhcp/files/dhcpd.service
>b/meta/recipes-connectivity/dhcp/files/dhcpd.service
>> deleted file mode 100644
>> index ae4f93eca5b..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/dhcpd.service
>> +++ /dev/null
>> @@ -1,15 +0,0 @@
>> -[Unit]
>> -Description=DHCPv4 Server Daemon
>> -Documentation=man:dhcpd(8) man:dhcpd.conf(5)
>> -After=network.target
>> -After=time-sync.target
>> -
>> -[Service]
>> -PIDFile=@localstatedir@/run/dhcpd.pid
>> -EnvironmentFile=@SYSCONFDIR@/default/dhcp-server
>> -EnvironmentFile=-@SYSCONFDIR@/sysconfig/dhcp-server
>> -ExecStartPre=@base_bindir@/touch
>@localstatedir@/lib/dhcp/dhcpd.leases
>> -ExecStart=@SBINDIR@/dhcpd -f -cf @SYSCONFDIR@/dhcp/dhcpd.conf -pf
>@localstatedir@/run/dhcpd.pid $DHCPDARGS -q $INTERFACES
>> -
>> -[Install]
>> -WantedBy=multi-user.target
>> diff --git a/meta/recipes-connectivity/dhcp/files/dhcpd6.service
>b/meta/recipes-connectivity/dhcp/files/dhcpd6.service
>> deleted file mode 100644
>> index 52a6224dc2c..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/dhcpd6.service
>> +++ /dev/null
>> @@ -1,15 +0,0 @@
>> -[Unit]
>> -Description=DHCPv6 Server Daemon
>> -Documentation=man:dhcpd(8) man:dhcpd.conf(5)
>> -After=network.target
>> -After=time-sync.target
>> -
>> -[Service]
>> -PIDFile=@localstatedir@/run/dhcpd6.pid
>> -EnvironmentFile=@SYSCONFDIR@/default/dhcp-server
>> -EnvironmentFile=-@SYSCONFDIR@/sysconfig/dhcpd6
>> -ExecStartPre=@base_bindir@/touch
>@localstatedir@/lib/dhcp/dhcpd6.leases
>> -ExecStart=@SBINDIR@/dhcpd -f -6 -cf @SYSCONFDIR@/dhcp/dhcpd6.conf -
>pf @localstatedir@/run/dhcpd6.pid $DHCPDARGS -q $INTERFACES
>> -
>> -[Install]
>> -WantedBy=multi-user.target
>> diff --git a/meta/recipes-connectivity/dhcp/files/dhcrelay.service
>b/meta/recipes-connectivity/dhcp/files/dhcrelay.service
>> deleted file mode 100644
>> index 15ff927d346..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/dhcrelay.service
>> +++ /dev/null
>> @@ -1,10 +0,0 @@
>> -[Unit]
>> -Description=DHCP Relay Agent Daemon
>> -After=network.target
>> -
>> -[Service]
>> -EnvironmentFile=@SYSCONFDIR@/default/dhcp-relay
>> -ExecStart=@SBINDIR@/dhcrelay -d --no-pid -q $SERVERS
>> -
>> -[Install]
>> -WantedBy=multi-user.target
>> diff --git a/meta/recipes-connectivity/dhcp/files/init-relay b/meta/recipes-
>connectivity/dhcp/files/init-relay
>> deleted file mode 100644
>> index 019a7e84cf4..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/init-relay
>> +++ /dev/null
>> @@ -1,44 +0,0 @@
>> -#!/bin/sh
>> -#
>> -# $Id: dhcp3-relay,v 1.1 2004/04/16 15:41:08 ml Exp $
>> -#
>> -
>> -# It is not safe to start if we don't have a default configuration...
>> -if [ ! -f /etc/default/dhcp-relay ]; then
>> -       echo "/etc/default/dhcp-relay does not exist! - Aborting..."
>> -       echo "create this file to fix the problem."
>> -       exit 1
>> -fi
>> -
>> -# Read init script configuration (interfaces the daemon should listen on
>> -# and the DHCP server we should forward requests to.)
>> -. /etc/default/dhcp-relay
>> -
>> -# Build command line for interfaces (will be passed to dhrelay below.)
>> -IFCMD=""
>> -if test "$INTERFACES" != ""; then
>> -       for I in $INTERFACES; do
>> -               IFCMD=${IFCMD}"-i "${I}" "
>> -       done
>> -fi
>> -
>> -DHCRELAYPID=/var/run/dhcrelay.pid
>> -
>> -case "$1" in
>> -       start)
>> -               start-stop-daemon -S -x /usr/sbin/dhcrelay -- -q $OPTIONS $IFCMD
>$SERVERS
>> -               ;;
>> -       stop)
>> -               start-stop-daemon -K -x /usr/sbin/dhcrelay
>> -               ;;
>> -       restart | force-reload)
>> -               $0 stop
>> -               sleep 2
>> -               $0 start
>> -               ;;
>> -       *)
>> -               echo "Usage: /etc/init.d/dhcp-relay {start|stop|restart|force-
>reload}"
>> -               exit 1
>> -esac
>> -
>> -exit 0
>> diff --git a/meta/recipes-connectivity/dhcp/files/init-server b/meta/recipes-
>connectivity/dhcp/files/init-server
>> deleted file mode 100644
>> index 5e693adf785..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/init-server
>> +++ /dev/null
>> @@ -1,44 +0,0 @@
>> -#!/bin/sh
>> -#
>> -# $Id: dhcp3-server.init.d,v 1.4 2003/07/13 19:12:41 mdz Exp $
>> -#
>> -
>> -test -f /usr/sbin/dhcpd || exit 0
>> -
>> -# It is not safe to start if we don't have a default configuration...
>> -if [ ! -f /etc/default/dhcp-server ]; then
>> -       echo "/etc/default/dhcp-server does not exist! - Aborting..."
>> -       exit 0
>> -fi
>> -
>> -# Read init script configuration (so far only interfaces the daemon
>> -# should listen on.)
>> -. /etc/default/dhcp-server
>> -
>> -case "$1" in
>> -       start)
>> -               echo -n "Starting DHCP server: "
>> -               test -d /var/lib/dhcp/ || mkdir -p /var/lib/dhcp/
>> -               test -f /var/lib/dhcp/dhcpd.leases || touch
>/var/lib/dhcp/dhcpd.leases
>> -               start-stop-daemon -S -x /usr/sbin/dhcpd -- -q $INTERFACES -user
>dhcp -group dhcp
>> -               echo "."
>> -               ;;
>> -       stop)
>> -               echo -n "Stopping DHCP server: dhcpd3"
>> -               start-stop-daemon -K -x /usr/sbin/dhcpd
>> -               echo "."
>> -               ;;
>> -       restart | force-reload)
>> -               $0 stop
>> -               sleep 2
>> -               $0 start
>> -               if [ "$?" != "0" ]; then
>> -                       exit 1
>> -               fi
>> -               ;;
>> -       *)
>> -               echo "Usage: /etc/init.d/dhcp-server {start|stop|restart|force-
>reload}"
>> -               exit 1
>> -esac
>> -
>> -exit 0
>> --
>> 2.17.1
>>
>>

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [OE-core] [PATCH 6/8] dhcp: remove from core
  2020-09-01 18:10   ` [OE-core] " Khem Raj
  2020-09-01 19:15     ` Diego Sueiro
@ 2020-09-01 20:39     ` akuster
  1 sibling, 0 replies; 24+ messages in thread
From: akuster @ 2020-09-01 20:39 UTC (permalink / raw)
  To: Khem Raj; +Cc: Patches and discussions about the oe-core layer



On 9/1/20 11:10 AM, Khem Raj wrote:
> it seems its used by
> build-appliance-image and packagegroup-core-base-utils so you need to
> take care of that as well.

Richard caught that just after I sent he patch series.

He added a change for that.

http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?h=master-next&id=a5a4fa3d7cf7a88a7788e64306b8797e60999005

-armin
>  in meta-networking networkmanager recipe
> depends on it too which I think I can take care.
>
> On Tue, Sep 1, 2020 at 8:23 AM akuster <akuster808@gmail.com> wrote:
>> update maintainers.inc too
>>
>> Signed-off-by: Armin Kuster <akuster808@gmail.com>
>> ---
>>  meta/conf/distro/include/maintainers.inc      |   1 -
>>  meta/recipes-connectivity/dhcp/dhcp.inc       | 149 ------------------
>>  ...TH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch |  27 ----
>>  ...-limitation-in-linux-dhclient-script.patch |  65 --------
>>  .../dhcp/dhcp/0002-dhclient-dbus.patch        | 117 --------------
>>  .../dhcp/dhcp/0003-link-with-lcrypto.patch    |  35 ----
>>  .../dhcp/0004-Fix-out-of-tree-builds.patch    |  95 -----------
>>  ...invoke-dhclient-script-failed-on-Rea.patch |  36 -----
>>  ...gument-to-make-the-libxml2-dependenc.patch |  62 --------
>>  ...move-dhclient-script-bash-dependency.patch |  28 ----
>>  ...ct-the-intention-for-xml2-lib-search.patch |  34 ----
>>  .../dhcp/dhcp/0013-fixup_use_libbind.patch    |  64 --------
>>  meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb  |  23 ---
>>  .../dhcp/files/default-relay                  |  12 --
>>  .../dhcp/files/default-server                 |   7 -
>>  .../dhcp/files/dhclient-systemd-wrapper       |  39 -----
>>  .../dhcp/files/dhclient.conf                  |  50 ------
>>  .../dhcp/files/dhclient.service               |  13 --
>>  .../dhcp/files/dhcpd.conf                     | 108 -------------
>>  .../dhcp/files/dhcpd.service                  |  15 --
>>  .../dhcp/files/dhcpd6.service                 |  15 --
>>  .../dhcp/files/dhcrelay.service               |  10 --
>>  .../dhcp/files/init-relay                     |  44 ------
>>  .../dhcp/files/init-server                    |  44 ------
>>  24 files changed, 1093 deletions(-)
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp.inc
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0001-workaround-busybox-limitation-in-linux-dhclient-script.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0009-remove-dhclient-script-bash-dependency.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch
>>  delete mode 100644 meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/default-relay
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/default-server
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhclient-systemd-wrapper
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhclient.conf
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhclient.service
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcpd.conf
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcpd.service
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcpd6.service
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/dhcrelay.service
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/init-relay
>>  delete mode 100644 meta/recipes-connectivity/dhcp/files/init-server
>>
>> diff --git a/meta/conf/distro/include/maintainers.inc b/meta/conf/distro/include/maintainers.inc
>> index 27e3474da8b..a55dbfa13c9 100644
>> --- a/meta/conf/distro/include/maintainers.inc
>> +++ b/meta/conf/distro/include/maintainers.inc
>> @@ -143,7 +143,6 @@ RECIPE_MAINTAINER_pn-debianutils = "Yi Zhao <yi.zhao@windriver.com>"
>>  RECIPE_MAINTAINER_pn-dejagnu = "Nathan Rossi <nathan@nathanrossi.com>"
>>  RECIPE_MAINTAINER_pn-depmodwrapper-cross = "Unassigned <unassigned@yoctoproject.org>"
>>  RECIPE_MAINTAINER_pn-desktop-file-utils = "Alexander Kanavin <alex.kanavin@gmail.com>"
>> -RECIPE_MAINTAINER_pn-dhcp = "Hongxu Jia <hongxu.jia@windriver.com>"
>>  RECIPE_MAINTAINER_pn-dhcpd = "Armin Kuster <akuster808@gmail.com>"
>>  RECIPE_MAINTAINER_pn-diffoscope = "Joshua Watt <JPEWhacker@gmail.com>"
>>  RECIPE_MAINTAINER_pn-diffstat = "Chen Qi <Qi.Chen@windriver.com>"
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp.inc b/meta/recipes-connectivity/dhcp/dhcp.inc
>> deleted file mode 100644
>> index d46130d49b9..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp.inc
>> +++ /dev/null
>> @@ -1,149 +0,0 @@
>> -SECTION = "console/network"
>> -SUMMARY = "Internet Software Consortium DHCP package"
>> -DESCRIPTION = "DHCP (Dynamic Host Configuration Protocol) is a protocol \
>> -which allows individual devices on an IP network to get their own \
>> -network configuration information from a server.  DHCP helps make it \
>> -easier to administer devices."
>> -
>> -HOMEPAGE = "http://www.isc.org/"
>> -
>> -LICENSE = "ISC"
>> -LIC_FILES_CHKSUM = "file://LICENSE;beginline=4;md5=004a4db50a1e20972e924a8618747c01"
>> -
>> -DEPENDS = "openssl bind"
>> -
>> -SRC_URI = "http://ftp.isc.org/isc/dhcp/${PV}/dhcp-${PV}.tar.gz \
>> -           file://init-relay file://default-relay \
>> -           file://init-server file://default-server \
>> -           file://dhclient.conf file://dhcpd.conf \
>> -           file://dhclient-systemd-wrapper \
>> -           file://dhclient.service \
>> -           file://dhcpd.service file://dhcrelay.service \
>> -           file://dhcpd6.service \
>> -           "
>> -UPSTREAM_CHECK_URI = "http://ftp.isc.org/isc/dhcp/"
>> -UPSTREAM_CHECK_REGEX = "(?P<pver>\d+\.\d+\.(\d+?))/"
>> -
>> -inherit autotools-brokensep systemd useradd update-rc.d
>> -
>> -USERADD_PACKAGES = "${PN}-server"
>> -USERADD_PARAM_${PN}-server = "--system --no-create-home --home-dir /var/run/${BPN} --shell /bin/false --user-group ${BPN}"
>> -
>> -SYSTEMD_PACKAGES = "${PN}-server ${PN}-relay ${PN}-client"
>> -SYSTEMD_SERVICE_${PN}-server = "dhcpd.service dhcpd6.service"
>> -SYSTEMD_AUTO_ENABLE_${PN}-server = "disable"
>> -
>> -SYSTEMD_SERVICE_${PN}-relay = "dhcrelay.service"
>> -SYSTEMD_AUTO_ENABLE_${PN}-relay = "disable"
>> -
>> -SYSTEMD_SERVICE_${PN}-client = "dhclient.service"
>> -SYSTEMD_AUTO_ENABLE_${PN}-client = "disable"
>> -
>> -INITSCRIPT_PACKAGES = "dhcp-server"
>> -INITSCRIPT_NAME_dhcp-server = "dhcp-server"
>> -INITSCRIPT_PARAMS_dhcp-server = "defaults"
>> -
>> -CFLAGS += "-D_GNU_SOURCE"
>> -EXTRA_OECONF = "--with-srv-lease-file=${localstatedir}/lib/dhcp/dhcpd.leases \
>> -                --with-srv6-lease-file=${localstatedir}/lib/dhcp/dhcpd6.leases \
>> -                --with-cli-lease-file=${localstatedir}/lib/dhcp/dhclient.leases \
>> -                --with-cli6-lease-file=${localstatedir}/lib/dhcp/dhclient6.leases \
>> -                --enable-paranoia --disable-static \
>> -                --with-randomdev=/dev/random \
>> -                --with-libbind=${STAGING_DIR_HOST} \
>> -               --enable-libtool \
>> -               "
>> -
>> -#Enable shared libs per dhcp README
>> -do_configure_prepend () {
>> -       cp configure.ac+lt configure.ac
>> -}
>> -
>> -do_install_append () {
>> -       install -d ${D}${sysconfdir}/init.d
>> -       install -d ${D}${sysconfdir}/default
>> -       install -d ${D}${sysconfdir}/dhcp
>> -       install -m 0755 ${WORKDIR}/init-relay ${D}${sysconfdir}/init.d/dhcp-relay
>> -       install -m 0644 ${WORKDIR}/default-relay ${D}${sysconfdir}/default/dhcp-relay
>> -       install -m 0755 ${WORKDIR}/init-server ${D}${sysconfdir}/init.d/dhcp-server
>> -       install -m 0644 ${WORKDIR}/default-server ${D}${sysconfdir}/default/dhcp-server
>> -
>> -       rm -f ${D}${sysconfdir}/dhclient.conf*
>> -       rm -f ${D}${sysconfdir}/dhcpd.conf*
>> -       install -m 0644 ${WORKDIR}/dhclient.conf ${D}${sysconfdir}/dhcp/dhclient.conf
>> -       install -m 0644 ${WORKDIR}/dhcpd.conf ${D}${sysconfdir}/dhcp/dhcpd.conf
>> -
>> -       install -d ${D}${base_sbindir}/
>> -       if [ "${sbindir}" != "${base_sbindir}" ]; then
>> -               mv ${D}${sbindir}/dhclient ${D}${base_sbindir}/
>> -       fi
>> -       install -m 0755 ${S}/client/scripts/linux ${D}${base_sbindir}/dhclient-script
>> -
>> -       # Install systemd unit files
>> -       install -d ${D}${systemd_unitdir}/system
>> -       install -m 0644 ${WORKDIR}/dhcpd.service ${D}${systemd_unitdir}/system
>> -       install -m 0644 ${WORKDIR}/dhcpd6.service ${D}${systemd_unitdir}/system
>> -       install -m 0644 ${WORKDIR}/dhcrelay.service ${D}${systemd_unitdir}/system
>> -       sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/dhcpd*.service ${D}${systemd_unitdir}/system/dhcrelay.service
>> -       sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' ${D}${systemd_unitdir}/system/dhcpd*.service
>> -       sed -i -e 's,@base_bindir@,${base_bindir},g' ${D}${systemd_unitdir}/system/dhcpd*.service
>> -       sed -i -e 's,@localstatedir@,${localstatedir},g' ${D}${systemd_unitdir}/system/dhcpd*.service
>> -       sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' ${D}${systemd_unitdir}/system/dhcrelay.service
>> -
>> -       install -d ${D}${base_sbindir}
>> -       install -m 0755 ${WORKDIR}/dhclient-systemd-wrapper ${D}${base_sbindir}/dhclient-systemd-wrapper
>> -       install -m 0644 ${WORKDIR}/dhclient.service ${D}${systemd_unitdir}/system
>> -       sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' ${D}${systemd_unitdir}/system/dhclient.service
>> -       sed -i -e 's,@BASE_SBINDIR@,${base_sbindir},g' ${D}${systemd_unitdir}/system/dhclient.service
>> -}
>> -
>> -PACKAGES += "dhcp-libs dhcp-server dhcp-server-config dhcp-client dhcp-relay dhcp-omshell"
>> -
>> -PACKAGES_remove = "${PN}"
>> -RDEPENDS_${PN}-client += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'iproute2', '', d)}"
>> -RDEPENDS_${PN}-dev = ""
>> -RDEPENDS_${PN}-staticdev = ""
>> -FILES_${PN}-libs = "${libdir}/libdhcpctl.so.0* ${libdir}/libomapi.so.0* ${libdir}/libdhcp.so.0*"
>> -
>> -FILES_${PN}-server = "${sbindir}/dhcpd ${sysconfdir}/init.d/dhcp-server"
>> -RRECOMMENDS_${PN}-server = "dhcp-server-config"
>> -
>> -FILES_${PN}-server-config = "${sysconfdir}/default/dhcp-server ${sysconfdir}/dhcp/dhcpd.conf"
>> -
>> -FILES_${PN}-relay = "${sbindir}/dhcrelay ${sysconfdir}/init.d/dhcp-relay ${sysconfdir}/default/dhcp-relay"
>> -
>> -FILES_${PN}-client = "${base_sbindir}/dhclient \
>> -                      ${base_sbindir}/dhclient-script \
>> -                      ${sysconfdir}/dhcp/dhclient.conf \
>> -                      ${base_sbindir}/dhclient-systemd-wrapper \
>> -                     "
>> -
>> -FILES_${PN}-omshell = "${bindir}/omshell"
>> -
>> -pkg_postinst_dhcp-server() {
>> -    mkdir -p $D/${localstatedir}/lib/dhcp
>> -    touch $D/${localstatedir}/lib/dhcp/dhcpd.leases
>> -    touch $D/${localstatedir}/lib/dhcp/dhcpd6.leases
>> -}
>> -
>> -pkg_postinst_dhcp-client() {
>> -    mkdir -p $D/${localstatedir}/lib/dhcp
>> -}
>> -
>> -pkg_postrm_dhcp-server() {
>> -    rm -f $D/${localstatedir}/lib/dhcp/dhcpd.leases
>> -    rm -f $D/${localstatedir}/lib/dhcp/dhcpd6.leases
>> -
>> -    if ! rmdir $D/${localstatedir}/lib/dhcp 2>/dev/null; then
>> -        echo "Not removing ${localstatedir}/lib/dhcp as it is non-empty."
>> -    fi
>> -}
>> -
>> -pkg_postrm_dhcp-client() {
>> -    rm -f $D/${localstatedir}/lib/dhcp/dhclient.leases
>> -    rm -f $D/${localstatedir}/lib/dhcp/dhclient6.leases
>> -
>> -    if ! rmdir $D/${localstatedir}/lib/dhcp 2>/dev/null; then
>> -        echo "Not removing ${localstatedir}/lib/dhcp as it is non-empty."
>> -    fi
>> -}
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch b/meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch
>> deleted file mode 100644
>> index d1b57f0bb41..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch
>> +++ /dev/null
>> @@ -1,27 +0,0 @@
>> -From 7cc29144535a622fc671dc86eb1da65b0473a7c4 Mon Sep 17 00:00:00 2001
>> -From: Hongxu Jia <hongxu.jia@windriver.com>
>> -Date: Tue, 15 Aug 2017 16:14:22 +0800
>> -Subject: [PATCH 01/11] define macro _PATH_DHCPD_CONF and _PATH_DHCLIENT_CONF
>> -
>> -Upstream-Status: Inappropriate [OE specific]
>> -
>> -Rebase to 4.3.6
>> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ----
>> - includes/site.h | 3 ++-
>> - 1 file changed, 2 insertions(+), 1 deletion(-)
>> -
>> -Index: dhcp-4.4.1/includes/site.h
>> -===================================================================
>> ---- dhcp-4.4.1.orig/includes/site.h
>> -+++ dhcp-4.4.1/includes/site.h
>> -@@ -148,7 +148,8 @@
>> - /* Define this if you want the dhcpd.conf file to go somewhere other than
>> -    the default location.   By default, it goes in /etc/dhcpd.conf. */
>> -
>> --/* #define _PATH_DHCPD_CONF   "/etc/dhcpd.conf" */
>> -+#define _PATH_DHCPD_CONF      "/etc/dhcp/dhcpd.conf"
>> -+#define _PATH_DHCLIENT_CONF   "/etc/dhcp/dhclient.conf"
>> -
>> - /* Network API definitions.   You do not need to choose one of these - if
>> -    you don't choose, one will be chosen for you in your system's config
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0001-workaround-busybox-limitation-in-linux-dhclient-script.patch b/meta/recipes-connectivity/dhcp/dhcp/0001-workaround-busybox-limitation-in-linux-dhclient-script.patch
>> deleted file mode 100644
>> index 2359381b938..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0001-workaround-busybox-limitation-in-linux-dhclient-script.patch
>> +++ /dev/null
>> @@ -1,65 +0,0 @@
>> -From eec0503cfc36f63d777f5cb3f2719cecedcb8468 Mon Sep 17 00:00:00 2001
>> -From: Haris Okanovic <haris.okanovic@ni.com>
>> -Date: Mon, 7 Jan 2019 13:22:09 -0600
>> -Subject: [PATCH] Workaround busybox limitation in Linux dhclient-script
>> -
>> -Busybox is a lightweight implementation of coreutils commonly used on
>> -space-constrained embedded Linux distributions. It's implementation of
>> -chown and chmod doesn't provide a "--reference" option added to
>> -client/scripts/linux as of commit 9261cb14. This change works around
>> -that limitation by using stat to read ownership and permissions flags
>> -and simple chown/chmod calls supported in both coreutils and busybox.
>> -
>> -    modified:   client/scripts/linux
>> -
>> -Signed-off-by: Haris Okanovic <haris.okanovic@ni.com>
>> -Upstream-Status: Pending [ISC-Bugs #48771]
>> ----
>> - client/scripts/linux | 17 +++++++++++++----
>> - 1 file changed, 13 insertions(+), 4 deletions(-)
>> -
>> -diff --git a/client/scripts/linux b/client/scripts/linux
>> -index 0c429697..2435a44b 100755
>> ---- a/client/scripts/linux
>> -+++ b/client/scripts/linux
>> -@@ -32,6 +32,17 @@
>> - # if your system holds ip tool in a non-standard location.
>> - ip=/sbin/ip
>> -
>> -+chown_chmod_by_reference() {
>> -+    local reference_file="$1"
>> -+    local target_file="$2"
>> -+
>> -+    local owner=$(stat -c "%u:%g" "$reference_file")
>> -+    local perm=$(stat -c "%a" "$reference_file")
>> -+
>> -+    chown "$owner" "$target_file"
>> -+    chmod "$perm" "$target_file"
>> -+}
>> -+
>> - # update /etc/resolv.conf based on received values
>> - # This updated version mostly follows Debian script by Andrew Pollock et al.
>> - make_resolv_conf() {
>> -@@ -74,8 +85,7 @@ make_resolv_conf() {
>> -         fi
>> -
>> -       if [ -f /etc/resolv.conf ]; then
>> --          chown --reference=/etc/resolv.conf $new_resolv_conf
>> --          chmod --reference=/etc/resolv.conf $new_resolv_conf
>> -+          chown_chmod_by_reference /etc/resolv.conf $new_resolv_conf
>> -       fi
>> -         mv -f $new_resolv_conf /etc/resolv.conf
>> -     # DHCPv6
>> -@@ -101,8 +111,7 @@ make_resolv_conf() {
>> -         fi
>> -
>> -       if [ -f /etc/resolv.conf ]; then
>> --            chown --reference=/etc/resolv.conf $new_resolv_conf
>> --            chmod --reference=/etc/resolv.conf $new_resolv_conf
>> -+          chown_chmod_by_reference /etc/resolv.conf $new_resolv_conf
>> -       fi
>> -         mv -f $new_resolv_conf /etc/resolv.conf
>> -     fi
>> ---
>> -2.20.0
>> -
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch b/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch
>> deleted file mode 100644
>> index 101c33f677a..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0002-dhclient-dbus.patch
>> +++ /dev/null
>> @@ -1,117 +0,0 @@
>> -From be7540d31c356e80ee02e90e8bf162b7ac6e5ba5 Mon Sep 17 00:00:00 2001
>> -From: Hongxu Jia <hongxu.jia@windriver.com>
>> -Date: Tue, 15 Aug 2017 14:56:56 +0800
>> -Subject: [PATCH 02/11] dhclient dbus
>> -
>> -Upstream-Status: Inappropriate [distribution]
>> -
>> -Rebase to 4.3.6
>> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ----
>> - client/scripts/bsdos   | 5 +++++
>> - client/scripts/freebsd | 5 +++++
>> - client/scripts/linux   | 5 +++++
>> - client/scripts/netbsd  | 5 +++++
>> - client/scripts/openbsd | 5 +++++
>> - client/scripts/solaris | 5 +++++
>> - 6 files changed, 30 insertions(+)
>> -
>> -diff --git a/client/scripts/bsdos b/client/scripts/bsdos
>> -index d69d0d8..095b143 100755
>> ---- a/client/scripts/bsdos
>> -+++ b/client/scripts/bsdos
>> -@@ -45,6 +45,11 @@ exit_with_hooks() {
>> -     . /etc/dhclient-exit-hooks
>> -   fi
>> - # probably should do something with exit status of the local script
>> -+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
>> -+    dbus-send --system --dest=com.redhat.dhcp \
>> -+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
>> -+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
>> -+  fi
>> -   exit $exit_status
>> - }
>> -
>> -diff --git a/client/scripts/freebsd b/client/scripts/freebsd
>> -index 8f3e2a2..ad7fb44 100755
>> ---- a/client/scripts/freebsd
>> -+++ b/client/scripts/freebsd
>> -@@ -89,6 +89,11 @@ exit_with_hooks() {
>> -     . /etc/dhclient-exit-hooks
>> -   fi
>> - # probably should do something with exit status of the local script
>> -+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
>> -+    dbus-send --system --dest=com.redhat.dhcp \
>> -+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
>> -+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
>> -+  fi
>> -   exit $exit_status
>> - }
>> -
>> -diff --git a/client/scripts/linux b/client/scripts/linux
>> -index 5fb1612..3d447b6 100755
>> ---- a/client/scripts/linux
>> -+++ b/client/scripts/linux
>> -@@ -174,6 +174,11 @@ exit_with_hooks() {
>> -         exit_status=$?
>> -     fi
>> -
>> -+    if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
>> -+        dbus-send --system --dest=com.redhat.dhcp \
>> -+           --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
>> -+           'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
>> -+    fi
>> -     exit $exit_status
>> - }
>> -
>> -diff --git a/client/scripts/netbsd b/client/scripts/netbsd
>> -index 07383b7..aaba8e8 100755
>> ---- a/client/scripts/netbsd
>> -+++ b/client/scripts/netbsd
>> -@@ -45,6 +45,11 @@ exit_with_hooks() {
>> -     . /etc/dhclient-exit-hooks
>> -   fi
>> - # probably should do something with exit status of the local script
>> -+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
>> -+    dbus-send --system --dest=com.redhat.dhcp \
>> -+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
>> -+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
>> -+  fi
>> -   exit $exit_status
>> - }
>> -
>> -diff --git a/client/scripts/openbsd b/client/scripts/openbsd
>> -index e7f4746..56b980c 100644
>> ---- a/client/scripts/openbsd
>> -+++ b/client/scripts/openbsd
>> -@@ -45,6 +45,11 @@ exit_with_hooks() {
>> -     . /etc/dhclient-exit-hooks
>> -   fi
>> - # probably should do something with exit status of the local script
>> -+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
>> -+    dbus-send --system --dest=com.redhat.dhcp \
>> -+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
>> -+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
>> -+  fi
>> -   exit $exit_status
>> - }
>> -
>> -diff --git a/client/scripts/solaris b/client/scripts/solaris
>> -index af553b9..4a2aa69 100755
>> ---- a/client/scripts/solaris
>> -+++ b/client/scripts/solaris
>> -@@ -26,6 +26,11 @@ exit_with_hooks() {
>> -     . /etc/dhclient-exit-hooks
>> -   fi
>> - # probably should do something with exit status of the local script
>> -+  if [ x$dhc_dbus != x -a $exit_status -eq 0 ]; then
>> -+    dbus-send --system --dest=com.redhat.dhcp \
>> -+      --type=method_call /com/redhat/dhcp/$interface com.redhat.dhcp.set \
>> -+      'string:'"`env | grep -Ev '^(PATH|SHLVL|_|PWD|dhc_dbus)\='`"
>> -+  fi
>> -   exit $exit_status
>> - }
>> -
>> ---
>> -1.8.3.1
>> -
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch b/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch
>> deleted file mode 100644
>> index 5b35933a54a..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0003-link-with-lcrypto.patch
>> +++ /dev/null
>> @@ -1,35 +0,0 @@
>> -From d80bd792323dbd56269309f85b4506eb6b1b60e9 Mon Sep 17 00:00:00 2001
>> -From: Andrei Gherzan <andrei@gherzan.ro>
>> -Date: Tue, 15 Aug 2017 15:05:47 +0800
>> -Subject: [PATCH 03/11] link with lcrypto
>> -
>> -From 4.2.0 final release, -lcrypto check was removed and we compile
>> -static libraries
>> -from bind that are linked to libcrypto. This is why i added a patch in
>> -order to add
>> --lcrypto to LIBS.
>> -
>> -Upstream-Status: Pending
>> -Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
>> -
>> -Rebase to 4.3.6
>> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ----
>> - configure.ac | 4 ++++
>> - 1 file changed, 4 insertions(+)
>> -
>> -Index: dhcp-4.4.1/configure.ac
>> -===================================================================
>> ---- dhcp-4.4.1.orig/configure.ac
>> -+++ dhcp-4.4.1/configure.ac
>> -@@ -612,6 +612,10 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]],
>> - # Look for optional headers.
>> - AC_CHECK_HEADERS(sys/socket.h net/if_dl.h net/if6.h regex.h)
>> -
>> -+# find an MD5 library
>> -+AC_SEARCH_LIBS(MD5_Init, [crypto])
>> -+AC_SEARCH_LIBS(MD5Init, [crypto])
>> -+
>> - # Solaris needs some libraries for functions
>> - AC_SEARCH_LIBS(socket, [socket])
>> - AC_SEARCH_LIBS(inet_ntoa, [nsl])
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch b/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch
>> deleted file mode 100644
>> index 7b57730ffb7..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0004-Fix-out-of-tree-builds.patch
>> +++ /dev/null
>> @@ -1,95 +0,0 @@
>> -From cccec0344d68dac4100b6f260ee24e7c2da9dfda Mon Sep 17 00:00:00 2001
>> -From: Hongxu Jia <hongxu.jia@windriver.com>
>> -Date: Tue, 15 Aug 2017 15:08:22 +0800
>> -Subject: [PATCH 04/11] Fix out of tree builds
>> -
>> -Upstream-Status: Pending
>> -
>> -RP 2013/03/21
>> -
>> -Rebase to 4.3.6
>> -
>> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ----
>> - client/Makefile.am  | 4 ++--
>> - common/Makefile.am  | 3 ++-
>> - dhcpctl/Makefile.am | 2 ++
>> - omapip/Makefile.am  | 1 +
>> - relay/Makefile.am   | 2 +-
>> - server/Makefile.am  | 2 +-
>> - 6 files changed, 9 insertions(+), 5 deletions(-)
>> -
>> -Index: dhcp-4.4.1/common/Makefile.am
>> -===================================================================
>> ---- dhcp-4.4.1.orig/common/Makefile.am
>> -+++ dhcp-4.4.1/common/Makefile.am
>> -@@ -1,4 +1,5 @@
>> --AM_CPPFLAGS = -I$(top_srcdir) -DLOCALSTATEDIR='"@localstatedir@"'
>> -+AM_CPPFLAGS = -I$(top_srcdir)/includes -I$(top_srcdir) -DLOCALSTATEDIR='"@localstatedir@"'
>> -+
>> - AM_CFLAGS = $(LDAP_CFLAGS)
>> -
>> - lib_LIBRARIES = libdhcp.a
>> -Index: dhcp-4.4.1/dhcpctl/Makefile.am
>> -===================================================================
>> ---- dhcp-4.4.1.orig/dhcpctl/Makefile.am
>> -+++ dhcp-4.4.1/dhcpctl/Makefile.am
>> -@@ -3,6 +3,8 @@ BINDLIBDNSDIR=@BINDLIBDNSDIR@
>> - BINDLIBISCCFGDIR=@BINDLIBISCCFGDIR@
>> - BINDLIBISCDIR=@BINDLIBISCDIR@
>> -
>> -+AM_CPPFLAGS = -I$(top_srcdir)/includes -I$(top_srcdir)
>> -+
>> - bin_PROGRAMS = omshell
>> - lib_LIBRARIES = libdhcpctl.a
>> - noinst_PROGRAMS = cltest
>> -Index: dhcp-4.4.1/server/Makefile.am
>> -===================================================================
>> ---- dhcp-4.4.1.orig/server/Makefile.am
>> -+++ dhcp-4.4.1/server/Makefile.am
>> -@@ -4,7 +4,7 @@
>> - # production code. Sadly, we are not there yet.
>> - SUBDIRS = . tests
>> -
>> --AM_CPPFLAGS = -I.. -DLOCALSTATEDIR='"@localstatedir@"'
>> -+AM_CPPFLAGS = -I$(top_srcdir) -DLOCALSTATEDIR='"@localstatedir@"' -I$(top_srcdir)/includes
>> -
>> - dist_sysconf_DATA = dhcpd.conf.example
>> - sbin_PROGRAMS = dhcpd
>> -Index: dhcp-4.4.1/client/Makefile.am
>> -===================================================================
>> ---- dhcp-4.4.1.orig/client/Makefile.am
>> -+++ dhcp-4.4.1/client/Makefile.am
>> -@@ -5,7 +5,7 @@
>> - SUBDIRS = . tests
>> -
>> - AM_CPPFLAGS = -DCLIENT_PATH='"PATH=$(sbindir):/sbin:/bin:/usr/sbin:/usr/bin"'
>> --AM_CPPFLAGS += -DLOCALSTATEDIR='"$(localstatedir)"'
>> -+AM_CPPFLAGS += -DLOCALSTATEDIR='"$(localstatedir)"' -I$(top_srcdir)/includes
>> -
>> - dist_sysconf_DATA = dhclient.conf.example
>> - sbin_PROGRAMS = dhclient
>> -Index: dhcp-4.4.1/omapip/Makefile.am
>> -===================================================================
>> ---- dhcp-4.4.1.orig/omapip/Makefile.am
>> -+++ dhcp-4.4.1/omapip/Makefile.am
>> -@@ -2,6 +2,7 @@ BINDLIBIRSDIR=@BINDLIBIRSDIR@
>> - BINDLIBDNSDIR=@BINDLIBDNSDIR@
>> - BINDLIBISCCFGDIR=@BINDLIBISCCFGDIR@
>> - BINDLIBISCDIR=@BINDLIBISCDIR@
>> -+AM_CPPFLAGS = -I$(top_srcdir)/includes
>> -
>> - lib_LIBRARIES = libomapi.a
>> - noinst_PROGRAMS = svtest
>> -Index: dhcp-4.4.1/relay/Makefile.am
>> -===================================================================
>> ---- dhcp-4.4.1.orig/relay/Makefile.am
>> -+++ dhcp-4.4.1/relay/Makefile.am
>> -@@ -1,6 +1,6 @@
>> - SUBDIRS = . tests
>> -
>> --AM_CPPFLAGS = -DLOCALSTATEDIR='"@localstatedir@"'
>> -+AM_CPPFLAGS = -DLOCALSTATEDIR='"@localstatedir@"' -I$(top_srcdir)/includes
>> -
>> - sbin_PROGRAMS = dhcrelay
>> - dhcrelay_SOURCES = dhcrelay.c
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch b/meta/recipes-connectivity/dhcp/dhcp/0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch
>> deleted file mode 100644
>> index dd56381b1dc..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch
>> +++ /dev/null
>> @@ -1,36 +0,0 @@
>> -From 2e8ff0e4f6d39e346ea86b8c514ab4ccc78fa359 Mon Sep 17 00:00:00 2001
>> -From: Hongxu Jia <hongxu.jia@windriver.com>
>> -Date: Tue, 15 Aug 2017 15:24:14 +0800
>> -Subject: [PATCH 05/11] dhcp-client: fix invoke dhclient-script failed on
>> - Read-only file system
>> -
>> -In read-only file system, '/etc' is on the readonly partition,
>> -and '/etc/resolv.conf' is symlinked to a separate writable
>> -partition.
>> -
>> -In this situation, we create temp files 'resolv.conf.dhclient-new'
>> -in /tmp dir.
>> -
>> -Upstream-Status: Pending
>> -
>> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ----
>> - client/scripts/linux | 2 +-
>> - 1 file changed, 1 insertion(+), 1 deletion(-)
>> -
>> -diff --git a/client/scripts/linux b/client/scripts/linux
>> -index 3d447b6..3122a75 100755
>> ---- a/client/scripts/linux
>> -+++ b/client/scripts/linux
>> -@@ -40,7 +40,7 @@ make_resolv_conf() {
>> -     # DHCPv4
>> -     if [ -n "$new_domain_search" ] || [ -n "$new_domain_name" ] ||
>> -        [ -n "$new_domain_name_servers" ]; then
>> --        new_resolv_conf=/etc/resolv.conf.dhclient-new
>> -+        new_resolv_conf=/tmp/resolv.conf.dhclient-new
>> -         rm -f $new_resolv_conf
>> -
>> -         if [ -n "$new_domain_name" ]; then
>> ---
>> -1.8.3.1
>> -
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch b/meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch
>> deleted file mode 100644
>> index feb0754fff4..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch
>> +++ /dev/null
>> @@ -1,62 +0,0 @@
>> -From 7107511fd209f08f9a96f8938041ae48f3295895 Mon Sep 17 00:00:00 2001
>> -From: Christopher Larson <chris_larson@mentor.com>
>> -Date: Tue, 15 Aug 2017 16:17:49 +0800
>> -Subject: [PATCH 07/11] Add configure argument to make the libxml2 dependency
>> - explicit and determinisitic.
>> -
>> -Upstream-Status: Pending
>> -
>> -Signed-off-by: Christopher Larson <chris_larson@mentor.com>
>> -
>> -Rebase to 4.3.6
>> -
>> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ----
>> - configure.ac | 11 +++++++++++
>> - 1 file changed, 11 insertions(+)
>> -
>> -Index: dhcp-4.4.1/configure.ac
>> -===================================================================
>> ---- dhcp-4.4.1.orig/configure.ac
>> -+++ dhcp-4.4.1/configure.ac
>> -@@ -642,6 +642,17 @@ if test "$have_nanosleep" = "rt"; then
>> -       LIBS="-lrt $LIBS"
>> - fi
>> -
>> -+AC_ARG_WITH(libxml2,
>> -+      AS_HELP_STRING([--with-libxml2], [link against libxml2. this is needed if bind was built with xml2 support enabled]),
>> -+      with_libxml2="$withval", with_libxml2="no")
>> -+
>> -+if test x$with_libxml2 != xno; then
>> -+      AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],
>> -+              [if test x$with_libxml2 != xauto; then
>> -+                      AC_MSG_FAILURE([*** Cannot find xmlTextWriterStartElement with -lxml2 and libxml2 was requested])
>> -+              fi])
>> -+fi
>> -+
>> - # check for /dev/random (declares HAVE_DEV_RANDOM)
>> - AC_MSG_CHECKING(for random device)
>> - AC_ARG_WITH(randomdev,
>> -Index: dhcp-4.4.1/configure.ac+lt
>> -===================================================================
>> ---- dhcp-4.4.1.orig/configure.ac+lt
>> -+++ dhcp-4.4.1/configure.ac+lt
>> -@@ -909,6 +909,18 @@ elif test "$want_libtool" = "yes" -a "$u
>> - fi
>> - AM_CONDITIONAL(INSTALL_BIND, test "$want_install_bind" = "yes")
>> -
>> -+AC_ARG_WITH(libxml2,
>> -+      AS_HELP_STRING([--with-libxml2], [link against libxml2. this is needed if bind was built with xml2 support enabled]),
>> -+      with_libxml2="$withval", with_libxml2="no")
>> -+
>> -+if test x$with_libxml2 != xno; then
>> -+      AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],,
>> -+              [if test x$with_libxml2 != xauto; then
>> -+                      AC_MSG_FAILURE([*** Cannot find xmlTextWriterStartElement with -lxml2 and libxml2 was requested])
>> -+              fi])
>> -+fi
>> -+
>> -+
>> - # OpenLDAP support.
>> - AC_ARG_WITH(ldap,
>> -     AS_HELP_STRING([--with-ldap],[enable OpenLDAP support in dhcpd (default is no)]),
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0009-remove-dhclient-script-bash-dependency.patch b/meta/recipes-connectivity/dhcp/dhcp/0009-remove-dhclient-script-bash-dependency.patch
>> deleted file mode 100644
>> index 912b6d6312c..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0009-remove-dhclient-script-bash-dependency.patch
>> +++ /dev/null
>> @@ -1,28 +0,0 @@
>> -From f3f8b7726e50e24ef3edf5fa5a17e31d39118d7e Mon Sep 17 00:00:00 2001
>> -From: Andre McCurdy <armccurdy@gmail.com>
>> -Date: Tue, 15 Aug 2017 15:49:31 +0800
>> -Subject: [PATCH 09/11] remove dhclient-script bash dependency
>> -
>> -Upstream-Status: Inappropriate [OE specific]
>> -
>> -Signed-off-by: Andre McCurdy <armccurdy@gmail.com>
>> -
>> -Rebase to 4.3.6
>> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> ----
>> - client/scripts/linux | 2 +-
>> - 1 file changed, 1 insertion(+), 1 deletion(-)
>> -
>> -diff --git a/client/scripts/linux b/client/scripts/linux
>> -index 3122a75..1712d7d 100755
>> ---- a/client/scripts/linux
>> -+++ b/client/scripts/linux
>> -@@ -1,4 +1,4 @@
>> --#!/bin/bash
>> -+#!/bin/sh
>> - # dhclient-script for Linux. Dan Halbert, March, 1997.
>> - # Updated for Linux 2.[12] by Brian J. Murrell, January 1999.
>> - # No guarantees about this. I'm a novice at the details of Linux
>> ---
>> -1.8.3.1
>> -
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch b/meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch
>> deleted file mode 100644
>> index 39ba65fbc46..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0012-dhcp-correct-the-intention-for-xml2-lib-search.patch
>> +++ /dev/null
>> @@ -1,34 +0,0 @@
>> -From 501543b3ef715488a142e3d301ff2733aa33eec7 Mon Sep 17 00:00:00 2001
>> -From: Awais Belal <awais_belal@mentor.com>
>> -Date: Wed, 25 Oct 2017 21:00:05 +0500
>> -Subject: [PATCH] dhcp: correct the intention for xml2 lib search
>> -
>> -A missing case breaks the build when libxml2 is
>> -required and found appropriately. The third argument
>> -to the function AC_SEARCH_LIB is action-if-found which
>> -was mistakenly been used for the case where the library
>> -is not found and hence breaks the configure phase
>> -where it shoud actually pass.
>> -We now pass on silently when action-if-found is
>> -executed.
>> -
>> -Upstream-Status: Pending
>> -
>> -Signed-off-by: Awais Belal <awais_belal@mentor.com>
>> ----
>> - configure.ac | 2 +-
>> - 1 file changed, 1 insertion(+), 1 deletion(-)
>> -
>> -Index: dhcp-4.4.1/configure.ac
>> -===================================================================
>> ---- dhcp-4.4.1.orig/configure.ac
>> -+++ dhcp-4.4.1/configure.ac
>> -@@ -647,7 +647,7 @@ AC_ARG_WITH(libxml2,
>> -       with_libxml2="$withval", with_libxml2="no")
>> -
>> - if test x$with_libxml2 != xno; then
>> --      AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],
>> -+      AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],,
>> -               [if test x$with_libxml2 != xauto; then
>> -                       AC_MSG_FAILURE([*** Cannot find xmlTextWriterStartElement with -lxml2 and libxml2 was requested])
>> -               fi])
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch b/meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch
>> deleted file mode 100644
>> index fcec010bd01..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp/0013-fixup_use_libbind.patch
>> +++ /dev/null
>> @@ -1,64 +0,0 @@
>> -lib and include path is hardcoded for use_libbind
>> -
>> -use libdir and includedir vars
>> -
>> -Upstream-Status: Pending
>> -Signed-off-by: Armin Kuster <akuster808@gmail.com>
>> -
>> -Index: dhcp-4.4.1/configure.ac+lt
>> -===================================================================
>> ---- dhcp-4.4.1.orig/configure.ac+lt
>> -+++ dhcp-4.4.1/configure.ac+lt
>> -@@ -801,22 +801,22 @@ no)
>> -       if test ! -d "$use_libbind"; then
>> -               AC_MSG_ERROR([Cannot find bind directory at $use_libbind])
>> -       fi
>> --      if test ! -d "$use_libbind/include" -o \
>> --              ! -f "$use_libbind/include/isc/buffer.h"
>> -+      if test ! -d "$use_libbind/$includedir" -o \
>> -+              ! -f "$use_libbind/$includedir/isc/buffer.h"
>> -       then
>> --              AC_MSG_ERROR([Cannot find bind includes at $use_libbind/include])
>> -+              AC_MSG_ERROR([Cannot find bind includes at $use_libbind/$includedir])
>> -       fi
>> --      if test ! -d "$use_libbind/lib" -o \
>> --              \( ! -f "$use_libbind/lib/libisc.a" -a \
>> --                 ! -f "$use_libbind/lib/libisc.la" \)
>> -+      if test ! -d "$use_libbind/$libdir" -o \
>> -+              \( ! -f "$use_libbind/$libdir/libisc.a" -a \
>> -+                 ! -f "$use_libbind/$libdir/libisc.la" \)
>> -       then
>> --              AC_MSG_ERROR([Cannot find bind libraries at $use_libbind/lib])
>> -+              AC_MSG_ERROR([Cannot find bind libraries at $use_libbind/$libdir])
>> -       fi
>> -       BINDDIR="$use_libbind"
>> --      BINDLIBIRSDIR="$BINDDIR/lib"
>> --      BINDLIBDNSDIR="$BINDDIR/lib"
>> --      BINDLIBISCCFGDIR="$BINDDIR/lib"
>> --      BINDLIBISCDIR="$BINDDIR/lib"
>> -+      BINDLIBIRSDIR="$BINDDIR/$libdir"
>> -+      BINDLIBDNSDIR="$BINDDIR/$libdir"
>> -+      BINDLIBISCCFGDIR="$BINDDIR/$libdir"
>> -+      BINDLIBISCDIR="$BINDDIR/$libdir"
>> -       DISTCHECK_LIBBIND_CONFIGURE_FLAG="--with-libbind=$use_libbind"
>> -       ;;
>> - esac
>> -@@ -856,14 +856,14 @@ AC_ARG_ENABLE(libtool,
>> -
>> - if test "$use_libbind" != "no"; then
>> -       if test "$want_libtool" = "yes" -a \
>> --              ! -f "$use_libbind/lib/libisc.la"
>> -+              ! -f "$use_libbind/$libdir/libisc.la"
>> -       then
>> --              AC_MSG_ERROR([Cannot find dynamic libraries at $use_libbind/lib])
>> -+              AC_MSG_ERROR([Cannot find dynamic libraries at $use_libbind/$libdir])
>> -       fi
>> -       if test "$want_libtool" = "no" -a \
>> --              ! -f "$use_libbind/lib/libisc.a"
>> -+              ! -f "$use_libbind/$libdir/libisc.a"
>> -       then
>> --              AC_MSG_ERROR([Cannot find static libraries at $use_libbind/lib])
>> -+              AC_MSG_ERROR([Cannot find static libraries at $use_libbind/$libdir])
>> -       fi
>> - fi
>> -
>> diff --git a/meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb b/meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb
>> deleted file mode 100644
>> index cf4af826099..00000000000
>> --- a/meta/recipes-connectivity/dhcp/dhcp_4.4.2.bb
>> +++ /dev/null
>> @@ -1,23 +0,0 @@
>> -require dhcp.inc
>> -
>> -SRC_URI += "file://0001-define-macro-_PATH_DHCPD_CONF-and-_PATH_DHCLIENT_CON.patch \
>> -            file://0002-dhclient-dbus.patch \
>> -            file://0003-link-with-lcrypto.patch \
>> -            file://0004-Fix-out-of-tree-builds.patch \
>> -            file://0005-dhcp-client-fix-invoke-dhclient-script-failed-on-Rea.patch \
>> -            file://0007-Add-configure-argument-to-make-the-libxml2-dependenc.patch \
>> -            file://0009-remove-dhclient-script-bash-dependency.patch \
>> -            file://0012-dhcp-correct-the-intention-for-xml2-lib-search.patch \
>> -            file://0013-fixup_use_libbind.patch \
>> -            file://0001-workaround-busybox-limitation-in-linux-dhclient-script.patch \
>> -"
>> -
>> -SRC_URI[md5sum] = "2afdaf8498dc1edaf3012efdd589b3e1"
>> -SRC_URI[sha256sum] = "1a7ccd64a16e5e68f7b5e0f527fd07240a2892ea53fe245620f4f5f607004521"
>> -
>> -LDFLAGS_append = " -pthread"
>> -
>> -PACKAGECONFIG ?= ""
>> -PACKAGECONFIG[bind-httpstats] = "--with-libxml2,--without-libxml2,libxml2"
>> -
>> -CFLAGS += "-fcommon"
>> diff --git a/meta/recipes-connectivity/dhcp/files/default-relay b/meta/recipes-connectivity/dhcp/files/default-relay
>> deleted file mode 100644
>> index 7961f014bef..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/default-relay
>> +++ /dev/null
>> @@ -1,12 +0,0 @@
>> -# Defaults for dhcp-relay initscript
>> -# sourced by /etc/init.d/dhcp-relay
>> -
>> -# What servers should the DHCP relay forward requests to?
>> -# e.g: SERVERS="192.168.0.1"
>> -SERVERS=""
>> -
>> -# On what interfaces should the DHCP relay (dhrelay) serve DHCP requests?
>> -INTERFACES=""
>> -
>> -# Additional options that are passed to the DHCP relay daemon?
>> -OPTIONS=""
>> diff --git a/meta/recipes-connectivity/dhcp/files/default-server b/meta/recipes-connectivity/dhcp/files/default-server
>> deleted file mode 100644
>> index 0385d169922..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/default-server
>> +++ /dev/null
>> @@ -1,7 +0,0 @@
>> -# Defaults for dhcp initscript
>> -# sourced by /etc/init.d/dhcp-server
>> -# installed at /etc/default/dhcp-server by the maintainer scripts
>> -
>> -# On what interfaces should the DHCP server (dhcpd) serve DHCP requests?
>> -#       Separate multiple interfaces with spaces, e.g. "eth0 eth1".
>> -INTERFACES=""
>> diff --git a/meta/recipes-connectivity/dhcp/files/dhclient-systemd-wrapper b/meta/recipes-connectivity/dhcp/files/dhclient-systemd-wrapper
>> deleted file mode 100644
>> index 7d0e224a1df..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/dhclient-systemd-wrapper
>> +++ /dev/null
>> @@ -1,39 +0,0 @@
>> -#!/bin/sh
>> -
>> -# In case the interface is used for nfs, skip it.
>> -nfsroot=0
>> -interfaces=""
>> -exec 9<&0 < /proc/mounts
>> -while read dev mtpt fstype rest; do
>> -    if test $mtpt = "/" ; then
>> -        case $fstype in
>> -            nfs | nfs4)
>> -                nfsroot=1
>> -                nfs_addr=`echo $rest | sed -e 's/^.*addr=\([0-9.]*\).*$/\1/'`
>> -                break
>> -                ;;
>> -            *)
>> -                ;;
>> -        esac
>> -    fi
>> -done
>> -exec 0<&9 9<&-
>> -
>> -if [ $nfsroot -eq 0 ]; then
>> -    interfaces="$INTERFACES"
>> -else
>> -    if [ -x /bin/ip -o -x /sbin/ip ] ; then
>> -       nfs_iface=`ip route get $nfs_addr | grep dev | sed -e 's/^.*dev \([-a-z0-9.]*\).*$/\1/'`
>> -    fi
>> -    for i in $INTERFACES; do
>> -       if test "x$i" = "x$nfs_iface"; then
>> -            echo "dhclient skipping nfsroot interface $i"
>> -       else
>> -           interfaces="$interfaces $i"
>> -       fi
>> -    done
>> -fi
>> -
>> -if test "x$interfaces" != "x"; then
>> -    /sbin/dhclient -d -cf /etc/dhcp/dhclient.conf -q -lf /var/lib/dhcp/dhclient.leases $interfaces
>> -fi
>> diff --git a/meta/recipes-connectivity/dhcp/files/dhclient.conf b/meta/recipes-connectivity/dhcp/files/dhclient.conf
>> deleted file mode 100644
>> index 0e6dcf96c21..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/dhclient.conf
>> +++ /dev/null
>> @@ -1,50 +0,0 @@
>> -# Configuration file for /sbin/dhclient, which is included in Debian's
>> -#      dhcp3-client package.
>> -#
>> -# This is a sample configuration file for dhclient. See dhclient.conf's
>> -#      man page for more information about the syntax of this file
>> -#      and a more comprehensive list of the parameters understood by
>> -#      dhclient.
>> -#
>> -# Normally, if the DHCP server provides reasonable information and does
>> -#      not leave anything out (like the domain name, for example), then
>> -#      few changes must be made to this file, if any.
>> -#
>> -
>> -#send host-name "andare.fugue.com";
>> -#send dhcp-client-identifier 1:0:a0:24:ab:fb:9c;
>> -#send dhcp-lease-time 3600;
>> -#supersede domain-name "fugue.com home.vix.com";
>> -#prepend domain-name-servers 127.0.0.1;
>> -request subnet-mask, broadcast-address, time-offset, routers,
>> -       domain-name, domain-name-servers, host-name,
>> -       netbios-name-servers, netbios-scope;
>> -#require subnet-mask, domain-name-servers;
>> -#timeout 60;
>> -#retry 60;
>> -#reboot 10;
>> -#select-timeout 5;
>> -#initial-interval 2;
>> -#script "/etc/dhcp3/dhclient-script";
>> -#media "-link0 -link1 -link2", "link0 link1";
>> -#reject 192.33.137.209;
>> -
>> -#alias {
>> -#  interface "eth0";
>> -#  fixed-address 192.5.5.213;
>> -#  option subnet-mask 255.255.255.255;
>> -#}
>> -
>> -#lease {
>> -#  interface "eth0";
>> -#  fixed-address 192.33.137.200;
>> -#  medium "link0 link1";
>> -#  option host-name "andare.swiftmedia.com";
>> -#  option subnet-mask 255.255.255.0;
>> -#  option broadcast-address 192.33.137.255;
>> -#  option routers 192.33.137.250;
>> -#  option domain-name-servers 127.0.0.1;
>> -#  renew 2 2000/1/12 00:00:01;
>> -#  rebind 2 2000/1/12 00:00:01;
>> -#  expire 2 2000/1/12 00:00:01;
>> -#}
>> diff --git a/meta/recipes-connectivity/dhcp/files/dhclient.service b/meta/recipes-connectivity/dhcp/files/dhclient.service
>> deleted file mode 100644
>> index 9ddb4d1dfe9..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/dhclient.service
>> +++ /dev/null
>> @@ -1,13 +0,0 @@
>> -[Unit]
>> -Description=Dynamic Host Configuration Protocol (DHCP)
>> -Wants=network.target
>> -Before=network.target
>> -After=systemd-udevd.service
>> -
>> -[Service]
>> -EnvironmentFile=-@SYSCONFDIR@/default/dhcp-client
>> -ExecStart=@BASE_SBINDIR@/dhclient-systemd-wrapper
>> -RemainAfterExit=yes
>> -
>> -[Install]
>> -WantedBy=multi-user.target
>> diff --git a/meta/recipes-connectivity/dhcp/files/dhcpd.conf b/meta/recipes-connectivity/dhcp/files/dhcpd.conf
>> deleted file mode 100644
>> index 0001c0f00e2..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/dhcpd.conf
>> +++ /dev/null
>> @@ -1,108 +0,0 @@
>> -#
>> -# Sample configuration file for ISC dhcpd for Debian
>> -#
>> -# $Id: dhcpd.conf,v 1.1.1.1 2002/05/21 00:07:44 peloy Exp $
>> -#
>> -
>> -# The ddns-updates-style parameter controls whether or not the server will
>> -# attempt to do a DNS update when a lease is confirmed. We default to the
>> -# behavior of the version 2 packages ('none', since DHCP v2 didn't
>> -# have support for DDNS.)
>> -ddns-update-style none;
>> -
>> -# option definitions common to all supported networks...
>> -option domain-name "example.org";
>> -option domain-name-servers ns1.example.org, ns2.example.org;
>> -
>> -default-lease-time 600;
>> -max-lease-time 7200;
>> -
>> -# If this DHCP server is the official DHCP server for the local
>> -# network, the authoritative directive should be uncommented.
>> -#authoritative;
>> -
>> -# Use this to send dhcp log messages to a different log file (you also
>> -# have to hack syslog.conf to complete the redirection).
>> -log-facility local7;
>> -
>> -# No service will be given on this subnet, but declaring it helps the
>> -# DHCP server to understand the network topology.
>> -
>> -#subnet 10.152.187.0 netmask 255.255.255.0 {
>> -#}
>> -
>> -# This is a very basic subnet declaration.
>> -
>> -#subnet 10.254.239.0 netmask 255.255.255.224 {
>> -#  range 10.254.239.10 10.254.239.20;
>> -#  option routers rtr-239-0-1.example.org, rtr-239-0-2.example.org;
>> -#}
>> -
>> -# This declaration allows BOOTP clients to get dynamic addresses,
>> -# which we don't really recommend.
>> -
>> -#subnet 10.254.239.32 netmask 255.255.255.224 {
>> -#  range dynamic-bootp 10.254.239.40 10.254.239.60;
>> -#  option broadcast-address 10.254.239.31;
>> -#  option routers rtr-239-32-1.example.org;
>> -#}
>> -
>> -# A slightly different configuration for an internal subnet.
>> -#subnet 10.5.5.0 netmask 255.255.255.224 {
>> -#  range 10.5.5.26 10.5.5.30;
>> -#  option domain-name-servers ns1.internal.example.org;
>> -#  option domain-name "internal.example.org";
>> -#  option routers 10.5.5.1;
>> -#  option broadcast-address 10.5.5.31;
>> -#  default-lease-time 600;
>> -#  max-lease-time 7200;
>> -#}
>> -
>> -# Hosts which require special configuration options can be listed in
>> -# host statements.   If no address is specified, the address will be
>> -# allocated dynamically (if possible), but the host-specific information
>> -# will still come from the host declaration.
>> -
>> -#host passacaglia {
>> -#  hardware ethernet 0:0:c0:5d:bd:95;
>> -#  filename "vmunix.passacaglia";
>> -#  server-name "toccata.fugue.com";
>> -#}
>> -
>> -# Fixed IP addresses can also be specified for hosts.   These addresses
>> -# should not also be listed as being available for dynamic assignment.
>> -# Hosts for which fixed IP addresses have been specified can boot using
>> -# BOOTP or DHCP.   Hosts for which no fixed address is specified can only
>> -# be booted with DHCP, unless there is an address range on the subnet
>> -# to which a BOOTP client is connected which has the dynamic-bootp flag
>> -# set.
>> -#host fantasia {
>> -#  hardware ethernet 08:00:07:26:c0:a5;
>> -#  fixed-address fantasia.fugue.com;
>> -#}
>> -
>> -# You can declare a class of clients and then do address allocation
>> -# based on that.   The example below shows a case where all clients
>> -# in a certain class get addresses on the 10.17.224/24 subnet, and all
>> -# other clients get addresses on the 10.0.29/24 subnet.
>> -
>> -#class "foo" {
>> -#  match if substring (option vendor-class-identifier, 0, 4) = "SUNW";
>> -#}
>> -
>> -#shared-network 224-29 {
>> -#  subnet 10.17.224.0 netmask 255.255.255.0 {
>> -#    option routers rtr-224.example.org;
>> -#  }
>> -#  subnet 10.0.29.0 netmask 255.255.255.0 {
>> -#    option routers rtr-29.example.org;
>> -#  }
>> -#  pool {
>> -#    allow members of "foo";
>> -#    range 10.17.224.10 10.17.224.250;
>> -#  }
>> -#  pool {
>> -#    deny members of "foo";
>> -#    range 10.0.29.10 10.0.29.230;
>> -#  }
>> -#}
>> diff --git a/meta/recipes-connectivity/dhcp/files/dhcpd.service b/meta/recipes-connectivity/dhcp/files/dhcpd.service
>> deleted file mode 100644
>> index ae4f93eca5b..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/dhcpd.service
>> +++ /dev/null
>> @@ -1,15 +0,0 @@
>> -[Unit]
>> -Description=DHCPv4 Server Daemon
>> -Documentation=man:dhcpd(8) man:dhcpd.conf(5)
>> -After=network.target
>> -After=time-sync.target
>> -
>> -[Service]
>> -PIDFile=@localstatedir@/run/dhcpd.pid
>> -EnvironmentFile=@SYSCONFDIR@/default/dhcp-server
>> -EnvironmentFile=-@SYSCONFDIR@/sysconfig/dhcp-server
>> -ExecStartPre=@base_bindir@/touch @localstatedir@/lib/dhcp/dhcpd.leases
>> -ExecStart=@SBINDIR@/dhcpd -f -cf @SYSCONFDIR@/dhcp/dhcpd.conf -pf @localstatedir@/run/dhcpd.pid $DHCPDARGS -q $INTERFACES
>> -
>> -[Install]
>> -WantedBy=multi-user.target
>> diff --git a/meta/recipes-connectivity/dhcp/files/dhcpd6.service b/meta/recipes-connectivity/dhcp/files/dhcpd6.service
>> deleted file mode 100644
>> index 52a6224dc2c..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/dhcpd6.service
>> +++ /dev/null
>> @@ -1,15 +0,0 @@
>> -[Unit]
>> -Description=DHCPv6 Server Daemon
>> -Documentation=man:dhcpd(8) man:dhcpd.conf(5)
>> -After=network.target
>> -After=time-sync.target
>> -
>> -[Service]
>> -PIDFile=@localstatedir@/run/dhcpd6.pid
>> -EnvironmentFile=@SYSCONFDIR@/default/dhcp-server
>> -EnvironmentFile=-@SYSCONFDIR@/sysconfig/dhcpd6
>> -ExecStartPre=@base_bindir@/touch @localstatedir@/lib/dhcp/dhcpd6.leases
>> -ExecStart=@SBINDIR@/dhcpd -f -6 -cf @SYSCONFDIR@/dhcp/dhcpd6.conf -pf @localstatedir@/run/dhcpd6.pid $DHCPDARGS -q $INTERFACES
>> -
>> -[Install]
>> -WantedBy=multi-user.target
>> diff --git a/meta/recipes-connectivity/dhcp/files/dhcrelay.service b/meta/recipes-connectivity/dhcp/files/dhcrelay.service
>> deleted file mode 100644
>> index 15ff927d346..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/dhcrelay.service
>> +++ /dev/null
>> @@ -1,10 +0,0 @@
>> -[Unit]
>> -Description=DHCP Relay Agent Daemon
>> -After=network.target
>> -
>> -[Service]
>> -EnvironmentFile=@SYSCONFDIR@/default/dhcp-relay
>> -ExecStart=@SBINDIR@/dhcrelay -d --no-pid -q $SERVERS
>> -
>> -[Install]
>> -WantedBy=multi-user.target
>> diff --git a/meta/recipes-connectivity/dhcp/files/init-relay b/meta/recipes-connectivity/dhcp/files/init-relay
>> deleted file mode 100644
>> index 019a7e84cf4..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/init-relay
>> +++ /dev/null
>> @@ -1,44 +0,0 @@
>> -#!/bin/sh
>> -#
>> -# $Id: dhcp3-relay,v 1.1 2004/04/16 15:41:08 ml Exp $
>> -#
>> -
>> -# It is not safe to start if we don't have a default configuration...
>> -if [ ! -f /etc/default/dhcp-relay ]; then
>> -       echo "/etc/default/dhcp-relay does not exist! - Aborting..."
>> -       echo "create this file to fix the problem."
>> -       exit 1
>> -fi
>> -
>> -# Read init script configuration (interfaces the daemon should listen on
>> -# and the DHCP server we should forward requests to.)
>> -. /etc/default/dhcp-relay
>> -
>> -# Build command line for interfaces (will be passed to dhrelay below.)
>> -IFCMD=""
>> -if test "$INTERFACES" != ""; then
>> -       for I in $INTERFACES; do
>> -               IFCMD=${IFCMD}"-i "${I}" "
>> -       done
>> -fi
>> -
>> -DHCRELAYPID=/var/run/dhcrelay.pid
>> -
>> -case "$1" in
>> -       start)
>> -               start-stop-daemon -S -x /usr/sbin/dhcrelay -- -q $OPTIONS $IFCMD $SERVERS
>> -               ;;
>> -       stop)
>> -               start-stop-daemon -K -x /usr/sbin/dhcrelay
>> -               ;;
>> -       restart | force-reload)
>> -               $0 stop
>> -               sleep 2
>> -               $0 start
>> -               ;;
>> -       *)
>> -               echo "Usage: /etc/init.d/dhcp-relay {start|stop|restart|force-reload}"
>> -               exit 1
>> -esac
>> -
>> -exit 0
>> diff --git a/meta/recipes-connectivity/dhcp/files/init-server b/meta/recipes-connectivity/dhcp/files/init-server
>> deleted file mode 100644
>> index 5e693adf785..00000000000
>> --- a/meta/recipes-connectivity/dhcp/files/init-server
>> +++ /dev/null
>> @@ -1,44 +0,0 @@
>> -#!/bin/sh
>> -#
>> -# $Id: dhcp3-server.init.d,v 1.4 2003/07/13 19:12:41 mdz Exp $
>> -#
>> -
>> -test -f /usr/sbin/dhcpd || exit 0
>> -
>> -# It is not safe to start if we don't have a default configuration...
>> -if [ ! -f /etc/default/dhcp-server ]; then
>> -       echo "/etc/default/dhcp-server does not exist! - Aborting..."
>> -       exit 0
>> -fi
>> -
>> -# Read init script configuration (so far only interfaces the daemon
>> -# should listen on.)
>> -. /etc/default/dhcp-server
>> -
>> -case "$1" in
>> -       start)
>> -               echo -n "Starting DHCP server: "
>> -               test -d /var/lib/dhcp/ || mkdir -p /var/lib/dhcp/
>> -               test -f /var/lib/dhcp/dhcpd.leases || touch /var/lib/dhcp/dhcpd.leases
>> -               start-stop-daemon -S -x /usr/sbin/dhcpd -- -q $INTERFACES -user dhcp -group dhcp
>> -               echo "."
>> -               ;;
>> -       stop)
>> -               echo -n "Stopping DHCP server: dhcpd3"
>> -               start-stop-daemon -K -x /usr/sbin/dhcpd
>> -               echo "."
>> -               ;;
>> -       restart | force-reload)
>> -               $0 stop
>> -               sleep 2
>> -               $0 start
>> -               if [ "$?" != "0" ]; then
>> -                       exit 1
>> -               fi
>> -               ;;
>> -       *)
>> -               echo "Usage: /etc/init.d/dhcp-server {start|stop|restart|force-reload}"
>> -               exit 1
>> -esac
>> -
>> -exit 0
>> --
>> 2.17.1
>>
>> 


^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [OE-core] [PATCH 4/8] dhcpd: move from meta-network need a client
  2020-09-01 15:22 ` [PATCH 4/8] dhcpd: move from meta-network need a client akuster
@ 2020-09-02  1:38   ` Chen Qi
  2020-09-02 15:06     ` Richard Purdie
  0 siblings, 1 reply; 24+ messages in thread
From: Chen Qi @ 2020-09-02  1:38 UTC (permalink / raw)
  To: akuster, openembedded-core

[-- Attachment #1: Type: text/plain, Size: 3823 bytes --]

The title uses 'dhcpd' but the recipe's name is 'dhcpcd'. [Patch 5/8] 
also uses 'dhcpd'.

One more thing to confirm. We are using dhcpcd to replace dhcp, right?

Best Regards,
Chen Qi


On 09/01/2020 11:22 PM, akuster wrote:
> Signed-off-by: Armin Kuster <akuster808@gmail.com>
> ---
>   .../dhcpcd/dhcpcd_9.1.4.bb                    | 28 ++++++++++++
>   ...e-INCLUDEDIR-to-prevent-build-issues.patch | 45 +++++++++++++++++++
>   2 files changed, 73 insertions(+)
>   create mode 100644 meta/recipes-connectivity/dhcpcd/dhcpcd_9.1.4.bb
>   create mode 100644 meta/recipes-connectivity/dhcpcd/files/0001-remove-INCLUDEDIR-to-prevent-build-issues.patch
>
> diff --git a/meta/recipes-connectivity/dhcpcd/dhcpcd_9.1.4.bb b/meta/recipes-connectivity/dhcpcd/dhcpcd_9.1.4.bb
> new file mode 100644
> index 00000000000..defd3420f02
> --- /dev/null
> +++ b/meta/recipes-connectivity/dhcpcd/dhcpcd_9.1.4.bb
> @@ -0,0 +1,28 @@
> +SECTION = "console/network"
> +SUMMARY = "dhcpcd - a DHCP client"
> +DESCRIPTION = "dhcpcd runs on your machine and silently configures your \
> +               computer to work on the attached networks without trouble \
> +               and mostly without configuration."
> +
> +HOMEPAGE = "http://roy.marples.name/projects/dhcpcd/"
> +
> +LICENSE = "BSD-2-Clause"
> +LIC_FILES_CHKSUM = "file://LICENSE;md5=9674cc803c5d71306941e6e8b5c002f2"
> +
> +UPSTREAM_CHECK_URI = "https://roy.marples.name/downloads/dhcpcd/"
> +
> +SRC_URI = "http://roy.marples.name/downloads/${BPN}/${BPN}-${PV}.tar.xz \
> +           file://0001-remove-INCLUDEDIR-to-prevent-build-issues.patch"
> +
> +SRC_URI[sha256sum] = "5fe133e5497d8af6d26bd6e6b8dd48ab12d124d6cc4cefe6de6536ff97f76820"
> +
> +inherit pkgconfig autotools-brokensep
> +
> +PACKAGECONFIG ?= "udev ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)}"
> +
> +PACKAGECONFIG[udev] = "--with-udev,--without-udev,udev,udev"
> +PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6"
> +
> +EXTRA_OECONF = "--enable-ipv4"
> +
> +FILES_${PN}-dbg += "${libdir}/dhcpcd/dev/.debug"
> diff --git a/meta/recipes-connectivity/dhcpcd/files/0001-remove-INCLUDEDIR-to-prevent-build-issues.patch b/meta/recipes-connectivity/dhcpcd/files/0001-remove-INCLUDEDIR-to-prevent-build-issues.patch
> new file mode 100644
> index 00000000000..37d2344438a
> --- /dev/null
> +++ b/meta/recipes-connectivity/dhcpcd/files/0001-remove-INCLUDEDIR-to-prevent-build-issues.patch
> @@ -0,0 +1,45 @@
> +From aa9e3982c1e75ad49945a62f5e262279c7a905a4 Mon Sep 17 00:00:00 2001
> +From: Stefano Cappa <stefano.cappa.ks89@gmail.com>
> +Date: Sun, 13 Jan 2019 01:50:52 +0100
> +Subject: [PATCH] remove INCLUDEDIR to prevent build issues
> +
> +Upstream-Status: Pending
> +
> +Signed-off-by: Stefano Cappa <stefano.cappa.ks89@gmail.com>
> +---
> + configure | 5 -----
> + 1 file changed, 5 deletions(-)
> +
> +diff --git a/configure b/configure
> +index 6c81e0db..32dea2b4 100755
> +--- a/configure
> ++++ b/configure
> +@@ -20,7 +20,6 @@ BUILD=
> + HOST=
> + HOSTCC=
> + TARGET=
> +-INCLUDEDIR=
> + DEBUG=
> + FORK=
> + STATIC=
> +@@ -72,7 +71,6 @@ for x do
> + 	--mandir) MANDIR=$var;;
> + 	--datadir) DATADIR=$var;;
> + 	--with-ccopts|CFLAGS) CFLAGS=$var;;
> +-	-I|--includedir) INCLUDEDIR="$INCLUDEDIR${INCLUDEDIR:+ }-I$var";;
> + 	CC) CC=$var;;
> + 	CPPFLAGS) CPPFLAGS=$var;;
> + 	PKG_CONFIG) PKG_CONFIG=$var;;
> +@@ -309,9 +307,6 @@ if [ -n "$CPPFLAGS" ]; then
> + 	echo "CPPFLAGS=" >>$CONFIG_MK
> + 	echo "CPPFLAGS+=	$CPPFLAGS" >>$CONFIG_MK
> + fi
> +-if [ -n "$INCLUDEDIR" ]; then
> +-	echo "CPPFLAGS+=	$INCLUDEDIR" >>$CONFIG_MK
> +-fi
> + if [ -n "$LDFLAGS" ]; then
> + 	echo "LDFLAGS=" >>$CONFIG_MK
> + 	echo "LDFLAGS+=	$LDFLAGS" >>$CONFIG_MK
> +--
> +2.17.2 (Apple Git-113)
> +
>
>
> 



[-- Attachment #2: Type: text/html, Size: 5126 bytes --]

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [OE-core] [PATCH 6/8] dhcp: remove from core
  2020-09-01 19:15     ` Diego Sueiro
@ 2020-09-02 15:05       ` Richard Purdie
  0 siblings, 0 replies; 24+ messages in thread
From: Richard Purdie @ 2020-09-02 15:05 UTC (permalink / raw)
  To: Diego Sueiro, raj.khem, akuster
  Cc: Patches and discussions about the oe-core layer, nd

On Tue, 2020-09-01 at 19:15 +0000, Diego Sueiro wrote:
> > -----Original Message-----
> > From: openembedded-core@lists.openembedded.org <openembedded-
> > core@lists.openembedded.org> On Behalf Of Khem Raj via
> > lists.openembedded.org
> > Sent: 01 September 2020 19:11
> > To: akuster <akuster808@gmail.com>
> > Cc: Patches and discussions about the oe-core layer <openembedded-
> > core@lists.openembedded.org>
> > Subject: Re: [OE-core] [PATCH 6/8] dhcp: remove from core
> > 
> > it seems its used by
> > build-appliance-image and packagegroup-core-base-utils so you need
> > to
> > take care of that as well. in meta-networking networkmanager recipe
> > depends on it too which I think I can take care.
> > 
> 
> Armin,
> You added a new recipe for a dhcp client but what is the alternative
> for the dhcp server in oe-core?

Its kea.

Cheers,

Richard


^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [OE-core] [PATCH 4/8] dhcpd: move from meta-network need a client
  2020-09-02  1:38   ` [OE-core] " Chen Qi
@ 2020-09-02 15:06     ` Richard Purdie
  0 siblings, 0 replies; 24+ messages in thread
From: Richard Purdie @ 2020-09-02 15:06 UTC (permalink / raw)
  To: Chen Qi, akuster, openembedded-core

On Wed, 2020-09-02 at 09:38 +0800, Chen Qi wrote:
> The title uses 'dhcpd' but the recipe's name is 'dhcpcd'. [Patch 5/8]
> also uses 'dhcpd'.
> 
> One more thing to confirm. We are using dhcpcd to replace dhcp,
> right?

kea replaces dhcp-server, dhcpcd replaces dhcp-client.

I tried to fix the naming in the patches that merged.

Cheers,

Richard


^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [OE-core] [PATCH 7/8] bind: Add 9.16.x
  2020-09-01 15:22 ` [PATCH 7/8] bind: Add 9.16.x akuster
@ 2020-09-04  8:39   ` Andrey Zhizhikin
  2020-09-07 15:28     ` akuster
  0 siblings, 1 reply; 24+ messages in thread
From: Andrey Zhizhikin @ 2020-09-04  8:39 UTC (permalink / raw)
  To: akuster; +Cc: OE Core mailing list

Hello Armin,

On Tue, Sep 1, 2020 at 5:23 PM akuster <akuster808@gmail.com> wrote:
>
> Removed obsolete packageconfig options
>
> License change to MPL-2.0
> https://gitlab.isc.org/isc-projects/bind9/blob/master/LICENSE
>
> Refreshed:
> bind-ensure-searching-for-json-headers-searches-sysr.patch
> 0001-named-lwresd-V-and-start-log-hide-build-options.patch
> bind-ensure-searching-for-json-headers-searches-sysr.patch
>
> Drop obsolete patch: 0001-configure.in-remove-useless-L-use_openssl-lib.patch
>
> Signed-off-by: Armin Kuster <akuster808@gmail.com>
> ---
>  ...1-avoid-start-failure-with-bind-user.patch |  27 ++
>  ...d-V-and-start-log-hide-build-options.patch |  35 ++
>  ...ching-for-json-headers-searches-sysr.patch |  47 +++
>  .../bind/bind-9.16.5/bind9                    |   2 +
>  .../bind/bind-9.16.5/conf.patch               | 330 ++++++++++++++++++
>  .../bind/bind-9.16.5/generate-rndc-key.sh     |   8 +
>  ...t.d-add-support-for-read-only-rootfs.patch |  65 ++++
>  .../make-etc-initd-bind-stop-work.patch       |  42 +++
>  .../bind/bind-9.16.5/named.service            |  22 ++
>  meta/recipes-connectivity/bind/bind_9.16.5.bb | 125 +++++++
>  10 files changed, 703 insertions(+)
>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind9
>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/named.service
>  create mode 100644 meta/recipes-connectivity/bind/bind_9.16.5.bb
>
> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
> new file mode 100644
> index 00000000000..8db96ec049c
> --- /dev/null
> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
> @@ -0,0 +1,27 @@
> +From 31dde3562f287429eea94b77250d184818b49063 Mon Sep 17 00:00:00 2001
> +From: Chen Qi <Qi.Chen@windriver.com>
> +Date: Mon, 15 Oct 2018 16:55:09 +0800
> +Subject: [PATCH] avoid start failure with bind user
> +
> +Upstream-Status: Pending
> +
> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
> +---
> + init.d | 1 +
> + 1 file changed, 1 insertion(+)
> +
> +diff --git a/init.d b/init.d
> +index b2eec60..6e03936 100644
> +--- a/init.d
> ++++ b/init.d
> +@@ -57,6 +57,7 @@ case "$1" in
> +       modprobe capability >/dev/null 2>&1 || true
> +       if [ ! -f /etc/bind/rndc.key ]; then
> +           /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
> ++          chown root:bind /etc/bind/rndc.key >/dev/null 2>&1 || true
> +           chmod 0640 /etc/bind/rndc.key
> +       fi
> +       if [ -f /var/run/named/named.pid ]; then
> +--
> +2.7.4
> +
> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
> new file mode 100644
> index 00000000000..5bcc16c9b2b
> --- /dev/null
> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
> @@ -0,0 +1,35 @@
> +From a3af4a405baf5ff582e82aaba392dd9667d94bdc Mon Sep 17 00:00:00 2001
> +From: Hongxu Jia <hongxu.jia@windriver.com>
> +Date: Mon, 27 Aug 2018 21:24:20 +0800
> +Subject: [PATCH] `named/lwresd -V' and start log hide build options
> +
> +The build options expose build path directories, so hide them.
> +[snip]
> +$ named -V
> +|built by make with *** (options are hidden)
> +[snip]
> +
> +Upstream-Status: Inappropriate [oe-core specific]
> +
> +Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
> +
> +Refreshed for 9.16.0
> +Signed-off-by: Armin Kuster <akuster@mvista.com>
> +
> +---
> + bin/named/include/named/globals.h | 2 +-
> + 1 file changed, 1 insertion(+), 1 deletion(-)
> +
> +Index: bind-9.16.0/bin/named/include/named/globals.h
> +===================================================================
> +--- bind-9.16.0.orig/bin/named/include/named/globals.h
> ++++ bind-9.16.0/bin/named/include/named/globals.h
> +@@ -69,7 +69,7 @@ EXTERN const char *named_g_version     I
> + EXTERN const char *named_g_product     INIT(PRODUCT);
> + EXTERN const char *named_g_description INIT(DESCRIPTION);
> + EXTERN const char *named_g_srcid       INIT(SRCID);
> +-EXTERN const char *named_g_configargs  INIT(CONFIGARGS);
> ++EXTERN const char *named_g_configargs  INIT("*** (options are hidden)");
> + EXTERN const char *named_g_builder     INIT(BUILDER);
> + EXTERN in_port_t named_g_port        INIT(0);
> + EXTERN isc_dscp_t named_g_dscp               INIT(-1);
> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
> new file mode 100644
> index 00000000000..f9cdc7ca4df
> --- /dev/null
> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
> @@ -0,0 +1,47 @@
> +From edda20fb5a6e88548f85e39d34d6c074306e15bc Mon Sep 17 00:00:00 2001
> +From: Paul Gortmaker <paul.gortmaker@windriver.com>
> +Date: Tue, 9 Jun 2015 11:22:00 -0400
> +Subject: [PATCH] bind: ensure searching for json headers searches sysroot
> +
> +Bind can fail configure by detecting headers w/o libs[1], or
> +it can fail the host contamination check as per below:
> +
> +ERROR: This autoconf log indicates errors, it looked at host include and/or library paths while determining system capabilities.
> +Rerun configure task after fixing this. The path was 'build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/build'
> +ERROR: Function failed: do_qa_configure
> +ERROR: Logfile of failure stored in: build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/temp/log.do_configure.5242
> +ERROR: Task 5 (meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure) failed with exit code '1'
> +NOTE: Tasks Summary: Attempted 773 tasks of which 768 didn't need to be rerun and 1 failed.
> +No currently running tasks (773 of 781)
> +
> +Summary: 1 task failed:
> +  /meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure
> +
> +One way to fix it would be to unconditionally disable json in bind
> +configure[2] but here we fix it by using the path to where we would
> +put the header if we had json in the sysroot, in case someone wants
> +to make use of the combination some day.
> +
> +[1] https://trac.macports.org/ticket/45305
> +[2] https://trac.macports.org/changeset/126406
> +
> +Upstream-Status: Inappropriate [OE Specific]
> +Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
> +
> +---
> + configure.ac | 2 +-
> + 1 file changed, 1 insertion(+), 1 deletion(-)
> +
> +Index: bind-9.16.4/configure.ac
> +===================================================================
> +--- bind-9.16.4.orig/configure.ac
> ++++ bind-9.16.4/configure.ac
> +@@ -1232,7 +1232,7 @@ case "$use_lmdb" in
> +               LMDB_LIBS=""
> +               ;;
> +       auto|yes)
> +-              for d in /usr /usr/local /opt/local
> ++              for d in "${STAGING_INCDIR}"
> +               do
> +                       if test -f "${d}/include/lmdb.h"
> +                       then
> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind9 b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
> new file mode 100644
> index 00000000000..968679ff7f7
> --- /dev/null
> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
> @@ -0,0 +1,2 @@
> +# startup options for the server
> +OPTIONS="-u bind"
> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
> new file mode 100644
> index 00000000000..aad345f9fcf
> --- /dev/null
> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
> @@ -0,0 +1,330 @@
> +Upstream-Status: Inappropriate [configuration]
> +
> +the patch is imported from openembedded project
> +
> +11/30/2010 - Qing He <qing.he@intel.com>
> +
> +diff -urN bind-9.3.1.orig/conf/db.0 bind-9.3.1/conf/db.0
> +--- bind-9.3.1.orig/conf/db.0  1970-01-01 01:00:00.000000000 +0100
> ++++ bind-9.3.1/conf/db.0       2005-07-10 22:14:00.000000000 +0200
> +@@ -0,0 +1,12 @@
> ++;
> ++; BIND reverse data file for broadcast zone
> ++;
> ++$TTL  604800
> ++@     IN      SOA     localhost. root.localhost. (
> ++                            1         ; Serial
> ++                       604800         ; Refresh
> ++                        86400         ; Retry
> ++                      2419200         ; Expire
> ++                       604800 )       ; Negative Cache TTL
> ++;
> ++@     IN      NS      localhost.
> +diff -urN bind-9.3.1.orig/conf/db.127 bind-9.3.1/conf/db.127
> +--- bind-9.3.1.orig/conf/db.127        1970-01-01 01:00:00.000000000 +0100
> ++++ bind-9.3.1/conf/db.127     2005-07-10 22:14:00.000000000 +0200
> +@@ -0,0 +1,13 @@
> ++;
> ++; BIND reverse data file for local loopback interface
> ++;
> ++$TTL  604800
> ++@     IN      SOA     localhost. root.localhost. (
> ++                            1         ; Serial
> ++                       604800         ; Refresh
> ++                        86400         ; Retry
> ++                      2419200         ; Expire
> ++                       604800 )       ; Negative Cache TTL
> ++;
> ++@     IN      NS      localhost.
> ++1.0.0 IN      PTR     localhost.
> +diff -urN bind-9.3.1.orig/conf/db.empty bind-9.3.1/conf/db.empty
> +--- bind-9.3.1.orig/conf/db.empty      1970-01-01 01:00:00.000000000 +0100
> ++++ bind-9.3.1/conf/db.empty   2005-07-10 22:14:00.000000000 +0200
> +@@ -0,0 +1,14 @@
> ++; BIND reverse data file for empty rfc1918 zone
> ++;
> ++; DO NOT EDIT THIS FILE - it is used for multiple zones.
> ++; Instead, copy it, edit named.conf, and use that copy.
> ++;
> ++$TTL  86400
> ++@     IN      SOA     localhost. root.localhost. (
> ++                            1         ; Serial
> ++                       604800         ; Refresh
> ++                        86400         ; Retry
> ++                      2419200         ; Expire
> ++                        86400 )       ; Negative Cache TTL
> ++;
> ++@     IN      NS      localhost.
> +diff -urN bind-9.3.1.orig/conf/db.255 bind-9.3.1/conf/db.255
> +--- bind-9.3.1.orig/conf/db.255        1970-01-01 01:00:00.000000000 +0100
> ++++ bind-9.3.1/conf/db.255     2005-07-10 22:14:00.000000000 +0200
> +@@ -0,0 +1,12 @@
> ++;
> ++; BIND reserve data file for broadcast zone
> ++;
> ++$TTL  604800
> ++@     IN      SOA     localhost. root.localhost. (
> ++                            1         ; Serial
> ++                       604800         ; Refresh
> ++                        86400         ; Retry
> ++                      2419200         ; Expire
> ++                       604800 )       ; Negative Cache TTL
> ++;
> ++@     IN      NS      localhost.
> +diff -urN bind-9.3.1.orig/conf/db.local bind-9.3.1/conf/db.local
> +--- bind-9.3.1.orig/conf/db.local      1970-01-01 01:00:00.000000000 +0100
> ++++ bind-9.3.1/conf/db.local   2005-07-10 22:14:00.000000000 +0200
> +@@ -0,0 +1,13 @@
> ++;
> ++; BIND data file for local loopback interface
> ++;
> ++$TTL  604800
> ++@     IN      SOA     localhost. root.localhost. (
> ++                            1         ; Serial
> ++                       604800         ; Refresh
> ++                        86400         ; Retry
> ++                      2419200         ; Expire
> ++                       604800 )       ; Negative Cache TTL
> ++;
> ++@     IN      NS      localhost.
> ++@     IN      A       127.0.0.1
> +diff -urN bind-9.3.1.orig/conf/db.root bind-9.3.1/conf/db.root
> +--- bind-9.3.1.orig/conf/db.root       1970-01-01 01:00:00.000000000 +0100
> ++++ bind-9.3.1/conf/db.root    2005-07-10 22:14:00.000000000 +0200
> +@@ -0,0 +1,45 @@
> ++
> ++; <<>> DiG 9.2.3 <<>> ns . @a.root-servers.net.
> ++;; global options:  printcmd
> ++;; Got answer:
> ++;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 18944
> ++;; flags: qr aa rd; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 13
> ++
> ++;; QUESTION SECTION:
> ++;.                            IN      NS
> ++
> ++;; ANSWER SECTION:
> ++.                     518400  IN      NS      A.ROOT-SERVERS.NET.
> ++.                     518400  IN      NS      B.ROOT-SERVERS.NET.
> ++.                     518400  IN      NS      C.ROOT-SERVERS.NET.
> ++.                     518400  IN      NS      D.ROOT-SERVERS.NET.
> ++.                     518400  IN      NS      E.ROOT-SERVERS.NET.
> ++.                     518400  IN      NS      F.ROOT-SERVERS.NET.
> ++.                     518400  IN      NS      G.ROOT-SERVERS.NET.
> ++.                     518400  IN      NS      H.ROOT-SERVERS.NET.
> ++.                     518400  IN      NS      I.ROOT-SERVERS.NET.
> ++.                     518400  IN      NS      J.ROOT-SERVERS.NET.
> ++.                     518400  IN      NS      K.ROOT-SERVERS.NET.
> ++.                     518400  IN      NS      L.ROOT-SERVERS.NET.
> ++.                     518400  IN      NS      M.ROOT-SERVERS.NET.
> ++
> ++;; ADDITIONAL SECTION:
> ++A.ROOT-SERVERS.NET.   3600000 IN      A       198.41.0.4
> ++B.ROOT-SERVERS.NET.   3600000 IN      A       192.228.79.201
> ++C.ROOT-SERVERS.NET.   3600000 IN      A       192.33.4.12
> ++D.ROOT-SERVERS.NET.   3600000 IN      A       128.8.10.90
> ++E.ROOT-SERVERS.NET.   3600000 IN      A       192.203.230.10
> ++F.ROOT-SERVERS.NET.   3600000 IN      A       192.5.5.241
> ++G.ROOT-SERVERS.NET.   3600000 IN      A       192.112.36.4
> ++H.ROOT-SERVERS.NET.   3600000 IN      A       128.63.2.53
> ++I.ROOT-SERVERS.NET.   3600000 IN      A       192.36.148.17
> ++J.ROOT-SERVERS.NET.   3600000 IN      A       192.58.128.30
> ++K.ROOT-SERVERS.NET.   3600000 IN      A       193.0.14.129
> ++L.ROOT-SERVERS.NET.   3600000 IN      A       198.32.64.12
> ++M.ROOT-SERVERS.NET.   3600000 IN      A       202.12.27.33
> ++
> ++;; Query time: 81 msec
> ++;; SERVER: 198.41.0.4#53(a.root-servers.net.)
> ++;; WHEN: Sun Feb  1 11:27:14 2004
> ++;; MSG SIZE  rcvd: 436
> ++
> +diff -urN bind-9.3.1.orig/conf/named.conf bind-9.3.1/conf/named.conf
> +--- bind-9.3.1.orig/conf/named.conf    1970-01-01 01:00:00.000000000 +0100
> ++++ bind-9.3.1/conf/named.conf 2005-07-10 22:33:46.000000000 +0200
> +@@ -0,0 +1,49 @@
> ++// This is the primary configuration file for the BIND DNS server named.
> ++//
> ++// If you are just adding zones, please do that in /etc/bind/named.conf.local
> ++
> ++include "/etc/bind/named.conf.options";
> ++
> ++// prime the server with knowledge of the root servers
> ++zone "." {
> ++      type hint;
> ++      file "/etc/bind/db.root";
> ++};
> ++
> ++// be authoritative for the localhost forward and reverse zones, and for
> ++// broadcast zones as per RFC 1912
> ++
> ++zone "localhost" {
> ++      type master;
> ++      file "/etc/bind/db.local";
> ++};
> ++
> ++zone "127.in-addr.arpa" {
> ++      type master;
> ++      file "/etc/bind/db.127";
> ++};
> ++
> ++zone "0.in-addr.arpa" {
> ++      type master;
> ++      file "/etc/bind/db.0";
> ++};
> ++
> ++zone "255.in-addr.arpa" {
> ++      type master;
> ++      file "/etc/bind/db.255";
> ++};
> ++
> ++// zone "com" { type delegation-only; };
> ++// zone "net" { type delegation-only; };
> ++
> ++// From the release notes:
> ++//  Because many of our users are uncomfortable receiving undelegated answers
> ++//  from root or top level domains, other than a few for whom that behaviour
> ++//  has been trusted and expected for quite some length of time, we have now
> ++//  introduced the "root-delegations-only" feature which applies delegation-only
> ++//  logic to all top level domains, and to the root domain.  An exception list
> ++//  should be specified, including "MUSEUM" and "DE", and any other top level
> ++//  domains from whom undelegated responses are expected and trusted.
> ++// root-delegation-only exclude { "DE"; "MUSEUM"; };
> ++
> ++include "/etc/bind/named.conf.local";
> +diff -urN bind-9.3.1.orig/conf/named.conf.local bind-9.3.1/conf/named.conf.local
> +--- bind-9.3.1.orig/conf/named.conf.local      1970-01-01 01:00:00.000000000 +0100
> ++++ bind-9.3.1/conf/named.conf.local   2005-07-10 22:14:06.000000000 +0200
> +@@ -0,0 +1,8 @@
> ++//
> ++// Do any local configuration here
> ++//
> ++
> ++// Consider adding the 1918 zones here, if they are not used in your
> ++// organization
> ++//include "/etc/bind/zones.rfc1918";
> ++
> +diff -urN bind-9.3.1.orig/conf/named.conf.options bind-9.3.1/conf/named.conf.options
> +--- bind-9.3.1.orig/conf/named.conf.options    1970-01-01 01:00:00.000000000 +0100
> ++++ bind-9.3.1/conf/named.conf.options 2005-07-10 22:14:06.000000000 +0200
> +@@ -0,0 +1,24 @@
> ++options {
> ++      directory "/var/cache/bind";
> ++
> ++      // If there is a firewall between you and nameservers you want
> ++      // to talk to, you might need to uncomment the query-source
> ++      // directive below.  Previous versions of BIND always asked
> ++      // questions using port 53, but BIND 8.1 and later use an unprivileged
> ++      // port by default.
> ++
> ++      // query-source address * port 53;
> ++
> ++      // If your ISP provided one or more IP addresses for stable
> ++      // nameservers, you probably want to use them as forwarders.
> ++      // Uncomment the following block, and insert the addresses replacing
> ++      // the all-0's placeholder.
> ++
> ++      // forwarders {
> ++      //      0.0.0.0;
> ++      // };
> ++
> ++      auth-nxdomain no;    # conform to RFC1035
> ++
> ++};
> ++
> +diff -urN bind-9.3.1.orig/conf/zones.rfc1918 bind-9.3.1/conf/zones.rfc1918
> +--- bind-9.3.1.orig/conf/zones.rfc1918 1970-01-01 01:00:00.000000000 +0100
> ++++ bind-9.3.1/conf/zones.rfc1918      2005-07-10 22:14:10.000000000 +0200
> +@@ -0,0 +1,20 @@
> ++zone "10.in-addr.arpa"      { type master; file "/etc/bind/db.empty"; };
> ++
> ++zone "16.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++zone "17.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++zone "18.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++zone "19.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++zone "20.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++zone "21.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++zone "22.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++zone "23.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++zone "24.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++zone "25.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++zone "26.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++zone "27.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++zone "28.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++zone "29.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++zone "30.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++zone "31.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> ++
> ++zone "168.192.in-addr.arpa" { type master; file "/etc/bind/db.empty"; };
> +diff -urN bind-9.3.1.orig/init.d bind-9.3.1/init.d
> +--- bind-9.3.1.orig/init.d     1970-01-01 01:00:00.000000000 +0100
> ++++ bind-9.3.1/init.d  2005-07-10 23:09:58.000000000 +0200
> +@@ -0,0 +1,70 @@
> ++#!/bin/sh
> ++
> ++PATH=/sbin:/bin:/usr/sbin:/usr/bin
> ++
> ++# for a chrooted server: "-u bind -t /var/lib/named"
> ++# Don't modify this line, change or create /etc/default/bind9.
> ++OPTIONS=""
> ++
> ++test -f /etc/default/bind9 && . /etc/default/bind9
> ++
> ++test -x /usr/sbin/rndc || exit 0
> ++
> ++case "$1" in
> ++    start)
> ++      echo -n "Starting domain name service: named"
> ++
> ++      modprobe capability >/dev/null 2>&1 || true
> ++      if [ ! -f /etc/bind/rndc.key ]; then
> ++          /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
> ++          chmod 0640 /etc/bind/rndc.key
> ++      fi
> ++      if [ -f /var/run/named/named.pid ]; then
> ++          ps `cat /var/run/named/named.pid` > /dev/null && exit 1
> ++      fi
> ++
> ++      # dirs under /var/run can go away on reboots.
> ++      mkdir -p /var/run/named
> ++      mkdir -p /var/cache/bind
> ++      chmod 775 /var/run/named
> ++      chown root:bind /var/run/named >/dev/null 2>&1 || true
> ++
> ++      if [ ! -x /usr/sbin/named ]; then
> ++          echo "named binary missing - not starting"
> ++          exit 1
> ++      fi
> ++      if start-stop-daemon --start --quiet --exec /usr/sbin/named \
> ++              --pidfile /var/run/named/named.pid -- $OPTIONS; then
> ++          if [ -x /sbin/resolvconf ] ; then
> ++              echo "nameserver 127.0.0.1" | /sbin/resolvconf -a lo
> ++          fi
> ++      fi
> ++      echo "."
> ++    ;;
> ++
> ++    stop)
> ++      echo -n "Stopping domain name service: named"
> ++      if [ -x /sbin/resolvconf ]; then
> ++          /sbin/resolvconf -d lo
> ++      fi
> ++      /usr/sbin/rndc stop >/dev/null 2>&1
> ++      echo "."
> ++    ;;
> ++
> ++    reload)
> ++      /usr/sbin/rndc reload
> ++    ;;
> ++
> ++    restart|force-reload)
> ++      $0 stop
> ++      sleep 2
> ++      $0 start
> ++    ;;
> ++
> ++    *)
> ++      echo "Usage: /etc/init.d/bind {start|stop|reload|restart|force-reload}" >&2
> ++      exit 1
> ++    ;;
> ++esac
> ++
> ++exit 0
> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
> new file mode 100644
> index 00000000000..ef915c0ae5a
> --- /dev/null
> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
> @@ -0,0 +1,8 @@
> +#!/bin/sh
> +
> +if [ ! -s /etc/bind/rndc.key ]; then
> +    echo -n "Generating /etc/bind/rndc.key:"
> +    /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
> +    chown root:bind /etc/bind/rndc.key
> +    chmod 0640 /etc/bind/rndc.key
> +fi
> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
> new file mode 100644
> index 00000000000..11db95ede12
> --- /dev/null
> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
> @@ -0,0 +1,65 @@
> +Subject: init.d: add support for read-only rootfs
> +
> +Upstream-Status: Inappropriate [oe specific]
> +
> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
> +---
> + init.d |   40 ++++++++++++++++++++++++++++++++++++++++
> + 1 file changed, 40 insertions(+)
> +
> +diff --git a/init.d b/init.d
> +index 0111ed4..24677c8 100644
> +--- a/init.d
> ++++ b/init.d
> +@@ -6,8 +6,48 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin
> + # Don't modify this line, change or create /etc/default/bind9.
> + OPTIONS=""
> +
> ++test -f /etc/default/rcS && . /etc/default/rcS
> + test -f /etc/default/bind9 && . /etc/default/bind9
> +
> ++# This function is here because it's possible that /var and / are on different partitions.
> ++is_on_read_only_partition () {
> ++    DIRECTORY=$1
> ++    dir=`readlink -f $DIRECTORY`
> ++    while true; do
> ++      if [ ! -d "$dir" ]; then
> ++          echo "ERROR: $dir is not a directory"
> ++          exit 1
> ++      else
> ++          for flag in `awk -v dir=$dir '{ if ($2 == dir) { print "FOUND"; split($4,FLAGS,",") } }; \
> ++              END { for (f in FLAGS) print FLAGS[f] }' < /proc/mounts`; do
> ++              [ "$flag" = "FOUND" ] && partition="read-write"
> ++              [ "$flag" = "ro" ] && { partition="read-only"; break; }
> ++          done
> ++          if [ "$dir" = "/" -o -n "$partition" ]; then
> ++              break
> ++          else
> ++              dir=`dirname $dir`
> ++          fi
> ++      fi
> ++    done
> ++    [ "$partition" = "read-only" ] && echo "yes" || echo "no"
> ++}
> ++
> ++bind_mount () {
> ++    olddir=$1
> ++    newdir=$2
> ++    mkdir -p $olddir
> ++    cp -a $newdir/* $olddir
> ++    mount --bind $olddir $newdir
> ++}
> ++
> ++# Deal with read-only rootfs
> ++if [ "$ROOTFS_READ_ONLY" = "yes" ]; then
> ++    [ "$VERBOSE" != "no" ] && echo "WARN: start bind service in read-only rootfs"
> ++    [ `is_on_read_only_partition /etc/bind` = "yes" ] && bind_mount /var/volatile/bind/etc /etc/bind
> ++    [ `is_on_read_only_partition /var/named` = "yes" ] && bind_mount /var/volatile/bind/named /var/named
> ++fi
> ++
> + test -x /usr/sbin/rndc || exit 0
> +
> + case "$1" in
> +--
> +1.7.9.5
> +
> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
> new file mode 100644
> index 00000000000..146f3e35db6
> --- /dev/null
> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
> @@ -0,0 +1,42 @@
> +bind: make "/etc/init.d/bind stop" work
> +
> +Upstream-Status: Inappropriate [configuration]
> +
> +Add some configurations, make rndc command be able to controls
> +the named daemon.
> +
> +Signed-off-by: Roy Li <rongqing.li@windriver.com>
> +---
> + conf/named.conf |    5 +++++
> + conf/rndc.conf  |    5 +++++
> + 2 files changed, 10 insertions(+), 0 deletions(-)
> + create mode 100644 conf/rndc.conf
> +
> +diff --git a/conf/named.conf b/conf/named.conf
> +index 95829cf..c8899e7 100644
> +--- a/conf/named.conf
> ++++ b/conf/named.conf
> +@@ -47,3 +47,8 @@ zone "255.in-addr.arpa" {
> + // root-delegation-only exclude { "DE"; "MUSEUM"; };
> +
> + include "/etc/bind/named.conf.local";
> ++include "/etc/bind/rndc.key" ;
> ++controls {
> ++      inet 127.0.0.1 allow { localhost; }
> ++      keys { rndc-key; };
> ++};
> +diff --git a/conf/rndc.conf b/conf/rndc.conf
> +new file mode 100644
> +index 0000000..a0b481d
> +--- /dev/null
> ++++ b/conf/rndc.conf
> +@@ -0,0 +1,5 @@
> ++include "/etc/bind/rndc.key";
> ++options {
> ++      default-server  localhost;
> ++      default-key     rndc-key;
> ++};
> +
> +--
> +1.7.5.4
> +
> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/named.service b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
> new file mode 100644
> index 00000000000..cda56ef0150
> --- /dev/null
> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
> @@ -0,0 +1,22 @@
> +[Unit]
> +Description=Berkeley Internet Name Domain (DNS)
> +Wants=nss-lookup.target
> +Before=nss-lookup.target
> +After=network.target
> +
> +[Service]
> +Type=forking
> +EnvironmentFile=-/etc/default/bind9
> +PIDFile=/run/named/named.pid
> +
> +ExecStartPre=@SBINDIR@/generate-rndc-key.sh
> +ExecStart=@SBINDIR@/named $OPTIONS
> +
> +ExecReload=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc reload > /dev/null 2>&1 || @BASE_BINDIR@/kill -HUP $MAINPID'
> +
> +ExecStop=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc stop > /dev/null 2>&1 || @BASE_BINDIR@/kill -TERM $MAINPID'
> +
> +PrivateTmp=true
> +
> +[Install]
> +WantedBy=multi-user.target
> diff --git a/meta/recipes-connectivity/bind/bind_9.16.5.bb b/meta/recipes-connectivity/bind/bind_9.16.5.bb
> new file mode 100644
> index 00000000000..9c20ccc6fa2
> --- /dev/null
> +++ b/meta/recipes-connectivity/bind/bind_9.16.5.bb
> @@ -0,0 +1,125 @@
> +SUMMARY = "ISC Internet Domain Name Server"
> +HOMEPAGE = "http://www.isc.org/sw/bind/"
> +SECTION = "console/network"
> +
> +LICENSE = "MPL-2.0"
> +LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=188b8d0644bd6835df43b84e3f180be1"
> +
> +DEPENDS = "openssl libcap zlib libuv"
> +
> +SRC_URI = "https://ftp.isc.org/isc/bind9/${PV}/${BPN}-${PV}.tar.xz \
> +           file://conf.patch \
> +           file://named.service \
> +           file://bind9 \
> +           file://generate-rndc-key.sh \
> +           file://make-etc-initd-bind-stop-work.patch \
> +           file://init.d-add-support-for-read-only-rootfs.patch \
> +           file://bind-ensure-searching-for-json-headers-searches-sysr.patch \
> +           file://0001-named-lwresd-V-and-start-log-hide-build-options.patch \
> +           file://0001-avoid-start-failure-with-bind-user.patch \
> +           "
> +
> +SRC_URI[sha256sum] = "6378b3e51fef11a8be4794dc48e8111ba92d211c0dfd129a0c296ed06a3dc075"
> +
> +UPSTREAM_CHECK_URI = "https://ftp.isc.org/isc/bind9/"
> +# stay at 9.16 follow the ESV versions divisible by 4
> +UPSTREAM_CHECK_REGEX = "(?P<pver>9.(16|20|24|28)(\.\d+)+(-P\d+)*)/"
> +
> +inherit autotools update-rc.d systemd useradd pkgconfig multilib_script multilib_header
> +
> +MULTILIB_SCRIPTS = "${PN}:${bindir}/bind9-config ${PN}:${bindir}/isc-config.sh"
> +
> +# PACKAGECONFIGs readline and libedit should NOT be set at same time
> +PACKAGECONFIG ?= "readline"
> +PACKAGECONFIG[httpstats] = "--with-libxml2=${STAGING_DIR_HOST}${prefix},--without-libxml2,libxml2"
> +PACKAGECONFIG[readline] = "--with-readline=-lreadline,,readline"
> +PACKAGECONFIG[libedit] = "--with-readline=-ledit,,libedit"
> +PACKAGECONFIG[python3] = "--with-python=yes --with-python-install-dir=${PYTHON_SITEPACKAGES_DIR} , --without-python, python3-ply-native,"
> +
> +EXTRA_OECONF = " --with-libtool --disable-devpoll --enable-epoll \
> +                 --with-gssapi=no --with-lmdb=no --with-zlib \
> +                 --sysconfdir=${sysconfdir}/bind \
> +                 --with-openssl=${STAGING_DIR_HOST}${prefix} \
> +               "
> +LDFLAGS_append = " -lz"
> +
> +inherit ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3native distutils3-base', '', d)}
> +
> +# dhcp needs .la so keep them
> +REMOVE_LIBTOOL_LA = "0"
> +
> +USERADD_PACKAGES = "${PN}"
> +USERADD_PARAM_${PN} = "--system --home ${localstatedir}/cache/bind --no-create-home \
> +                       --user-group bind"
> +
> +INITSCRIPT_NAME = "bind"
> +INITSCRIPT_PARAMS = "defaults"
> +
> +SYSTEMD_SERVICE_${PN} = "named.service"
> +
> +do_install_append() {
> +
> +       rmdir "${D}${localstatedir}/run"
> +       rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
> +       install -d -o bind "${D}${localstatedir}/cache/bind"
> +       install -d "${D}${sysconfdir}/bind"
> +       install -d "${D}${sysconfdir}/init.d"
> +       install -m 644 ${S}/conf/* "${D}${sysconfdir}/bind/"
> +       install -m 755 "${S}/init.d" "${D}${sysconfdir}/init.d/bind"
> +        if ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'true', 'false', d)}; then
> +               sed -i -e '1s,#!.*python3,#! /usr/bin/python3,' \
> +               ${D}${sbindir}/dnssec-coverage \
> +               ${D}${sbindir}/dnssec-checkds \
> +               ${D}${sbindir}/dnssec-keymgr
> +       fi
> +
> +       # Install systemd related files
> +       install -d ${D}${sbindir}
> +       install -m 755 ${WORKDIR}/generate-rndc-key.sh ${D}${sbindir}
> +       install -d ${D}${systemd_unitdir}/system
> +       install -m 0644 ${WORKDIR}/named.service ${D}${systemd_unitdir}/system
> +       sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
> +              -e 's,@SBINDIR@,${sbindir},g' \
> +              ${D}${systemd_unitdir}/system/named.service
> +
> +       install -d ${D}${sysconfdir}/default
> +       install -m 0644 ${WORKDIR}/bind9 ${D}${sysconfdir}/default
> +
> +       if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
> +               install -d ${D}${sysconfdir}/tmpfiles.d
> +               echo "d /run/named 0755 bind bind - -" > ${D}${sysconfdir}/tmpfiles.d/bind.conf
> +       fi
> +
> +    oe_multilib_header isc/platform.h
> +}
> +
> +CONFFILES_${PN} = " \
> +       ${sysconfdir}/bind/named.conf \
> +       ${sysconfdir}/bind/named.conf.local \
> +       ${sysconfdir}/bind/named.conf.options \
> +       ${sysconfdir}/bind/db.0 \
> +       ${sysconfdir}/bind/db.127 \
> +       ${sysconfdir}/bind/db.empty \
> +       ${sysconfdir}/bind/db.local \
> +       ${sysconfdir}/bind/db.root \
> +       "
> +
> +ALTERNATIVE_${PN}-utils = "nslookup"
> +ALTERNATIVE_LINK_NAME[nslookup] = "${bindir}/nslookup"
> +ALTERNATIVE_PRIORITY = "100"

I'm seeing this failing with busybox:
update-alternatives: Error: not linking
/development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
to /bin/busybox.nosuid since
/development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
exists and is not a link

busybox sets ALTERNATIVE_PRIORITY = "50". Can this be the issue?

Going back to bind 9.11.22 seems to solve it...

> +
> +PACKAGE_BEFORE_PN += "${PN}-utils"
> +FILES_${PN}-utils = "${bindir}/host ${bindir}/dig ${bindir}/mdig ${bindir}/nslookup ${bindir}/nsupdate"
> +FILES_${PN}-dev += "${bindir}/isc-config.h"
> +FILES_${PN} += "${sbindir}/generate-rndc-key.sh"
> +
> +PACKAGE_BEFORE_PN += "${PN}-libs"
> +FILES_${PN}-libs = "${libdir}/*.so* ${libdir}/named/*.so*"
> +FILES_${PN}-staticdev += "${libdir}/*.la"
> +
> +PACKAGE_BEFORE_PN += "${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3-bind', '', d)}"
> +FILES_python3-bind = "${sbindir}/dnssec-coverage ${sbindir}/dnssec-checkds \
> +                ${sbindir}/dnssec-keymgr ${PYTHON_SITEPACKAGES_DIR}"
> +
> +RDEPENDS_${PN}-dev = ""
> +RDEPENDS_python3-bind = "python3-core python3-ply"
> --
> 2.17.1
>
> 



-- 
Regards,
Andrey.

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [OE-core] [PATCH 7/8] bind: Add 9.16.x
  2020-09-04  8:39   ` [OE-core] " Andrey Zhizhikin
@ 2020-09-07 15:28     ` akuster
  2020-09-07 21:17       ` Andrey Zhizhikin
  0 siblings, 1 reply; 24+ messages in thread
From: akuster @ 2020-09-07 15:28 UTC (permalink / raw)
  To: Andrey Zhizhikin; +Cc: OE Core mailing list



On 9/4/20 1:39 AM, Andrey Zhizhikin wrote:
> Hello Armin,
>
> On Tue, Sep 1, 2020 at 5:23 PM akuster <akuster808@gmail.com> wrote:
>> Removed obsolete packageconfig options
>>
>> License change to MPL-2.0
>> https://gitlab.isc.org/isc-projects/bind9/blob/master/LICENSE
>>
>> Refreshed:
>> bind-ensure-searching-for-json-headers-searches-sysr.patch
>> 0001-named-lwresd-V-and-start-log-hide-build-options.patch
>> bind-ensure-searching-for-json-headers-searches-sysr.patch
>>
>> Drop obsolete patch: 0001-configure.in-remove-useless-L-use_openssl-lib.patch
>>
>> Signed-off-by: Armin Kuster <akuster808@gmail.com>
>> ---
>>  ...1-avoid-start-failure-with-bind-user.patch |  27 ++
>>  ...d-V-and-start-log-hide-build-options.patch |  35 ++
>>  ...ching-for-json-headers-searches-sysr.patch |  47 +++
>>  .../bind/bind-9.16.5/bind9                    |   2 +
>>  .../bind/bind-9.16.5/conf.patch               | 330 ++++++++++++++++++
>>  .../bind/bind-9.16.5/generate-rndc-key.sh     |   8 +
>>  ...t.d-add-support-for-read-only-rootfs.patch |  65 ++++
>>  .../make-etc-initd-bind-stop-work.patch       |  42 +++
>>  .../bind/bind-9.16.5/named.service            |  22 ++
>>  meta/recipes-connectivity/bind/bind_9.16.5.bb | 125 +++++++
>>  10 files changed, 703 insertions(+)
>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind9
>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/named.service
>>  create mode 100644 meta/recipes-connectivity/bind/bind_9.16.5.bb
>>
>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
>> new file mode 100644
>> index 00000000000..8db96ec049c
>> --- /dev/null
>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
>> @@ -0,0 +1,27 @@
>> +From 31dde3562f287429eea94b77250d184818b49063 Mon Sep 17 00:00:00 2001
>> +From: Chen Qi <Qi.Chen@windriver.com>
>> +Date: Mon, 15 Oct 2018 16:55:09 +0800
>> +Subject: [PATCH] avoid start failure with bind user
>> +
>> +Upstream-Status: Pending
>> +
>> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
>> +---
>> + init.d | 1 +
>> + 1 file changed, 1 insertion(+)
>> +
>> +diff --git a/init.d b/init.d
>> +index b2eec60..6e03936 100644
>> +--- a/init.d
>> ++++ b/init.d
>> +@@ -57,6 +57,7 @@ case "$1" in
>> +       modprobe capability >/dev/null 2>&1 || true
>> +       if [ ! -f /etc/bind/rndc.key ]; then
>> +           /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
>> ++          chown root:bind /etc/bind/rndc.key >/dev/null 2>&1 || true
>> +           chmod 0640 /etc/bind/rndc.key
>> +       fi
>> +       if [ -f /var/run/named/named.pid ]; then
>> +--
>> +2.7.4
>> +
>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
>> new file mode 100644
>> index 00000000000..5bcc16c9b2b
>> --- /dev/null
>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
>> @@ -0,0 +1,35 @@
>> +From a3af4a405baf5ff582e82aaba392dd9667d94bdc Mon Sep 17 00:00:00 2001
>> +From: Hongxu Jia <hongxu.jia@windriver.com>
>> +Date: Mon, 27 Aug 2018 21:24:20 +0800
>> +Subject: [PATCH] `named/lwresd -V' and start log hide build options
>> +
>> +The build options expose build path directories, so hide them.
>> +[snip]
>> +$ named -V
>> +|built by make with *** (options are hidden)
>> +[snip]
>> +
>> +Upstream-Status: Inappropriate [oe-core specific]
>> +
>> +Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>> +
>> +Refreshed for 9.16.0
>> +Signed-off-by: Armin Kuster <akuster@mvista.com>
>> +
>> +---
>> + bin/named/include/named/globals.h | 2 +-
>> + 1 file changed, 1 insertion(+), 1 deletion(-)
>> +
>> +Index: bind-9.16.0/bin/named/include/named/globals.h
>> +===================================================================
>> +--- bind-9.16.0.orig/bin/named/include/named/globals.h
>> ++++ bind-9.16.0/bin/named/include/named/globals.h
>> +@@ -69,7 +69,7 @@ EXTERN const char *named_g_version     I
>> + EXTERN const char *named_g_product     INIT(PRODUCT);
>> + EXTERN const char *named_g_description INIT(DESCRIPTION);
>> + EXTERN const char *named_g_srcid       INIT(SRCID);
>> +-EXTERN const char *named_g_configargs  INIT(CONFIGARGS);
>> ++EXTERN const char *named_g_configargs  INIT("*** (options are hidden)");
>> + EXTERN const char *named_g_builder     INIT(BUILDER);
>> + EXTERN in_port_t named_g_port        INIT(0);
>> + EXTERN isc_dscp_t named_g_dscp               INIT(-1);
>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
>> new file mode 100644
>> index 00000000000..f9cdc7ca4df
>> --- /dev/null
>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
>> @@ -0,0 +1,47 @@
>> +From edda20fb5a6e88548f85e39d34d6c074306e15bc Mon Sep 17 00:00:00 2001
>> +From: Paul Gortmaker <paul.gortmaker@windriver.com>
>> +Date: Tue, 9 Jun 2015 11:22:00 -0400
>> +Subject: [PATCH] bind: ensure searching for json headers searches sysroot
>> +
>> +Bind can fail configure by detecting headers w/o libs[1], or
>> +it can fail the host contamination check as per below:
>> +
>> +ERROR: This autoconf log indicates errors, it looked at host include and/or library paths while determining system capabilities.
>> +Rerun configure task after fixing this. The path was 'build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/build'
>> +ERROR: Function failed: do_qa_configure
>> +ERROR: Logfile of failure stored in: build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/temp/log.do_configure.5242
>> +ERROR: Task 5 (meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure) failed with exit code '1'
>> +NOTE: Tasks Summary: Attempted 773 tasks of which 768 didn't need to be rerun and 1 failed.
>> +No currently running tasks (773 of 781)
>> +
>> +Summary: 1 task failed:
>> +  /meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure
>> +
>> +One way to fix it would be to unconditionally disable json in bind
>> +configure[2] but here we fix it by using the path to where we would
>> +put the header if we had json in the sysroot, in case someone wants
>> +to make use of the combination some day.
>> +
>> +[1] https://trac.macports.org/ticket/45305
>> +[2] https://trac.macports.org/changeset/126406
>> +
>> +Upstream-Status: Inappropriate [OE Specific]
>> +Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
>> +
>> +---
>> + configure.ac | 2 +-
>> + 1 file changed, 1 insertion(+), 1 deletion(-)
>> +
>> +Index: bind-9.16.4/configure.ac
>> +===================================================================
>> +--- bind-9.16.4.orig/configure.ac
>> ++++ bind-9.16.4/configure.ac
>> +@@ -1232,7 +1232,7 @@ case "$use_lmdb" in
>> +               LMDB_LIBS=""
>> +               ;;
>> +       auto|yes)
>> +-              for d in /usr /usr/local /opt/local
>> ++              for d in "${STAGING_INCDIR}"
>> +               do
>> +                       if test -f "${d}/include/lmdb.h"
>> +                       then
>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind9 b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
>> new file mode 100644
>> index 00000000000..968679ff7f7
>> --- /dev/null
>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
>> @@ -0,0 +1,2 @@
>> +# startup options for the server
>> +OPTIONS="-u bind"
>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
>> new file mode 100644
>> index 00000000000..aad345f9fcf
>> --- /dev/null
>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
>> @@ -0,0 +1,330 @@
>> +Upstream-Status: Inappropriate [configuration]
>> +
>> +the patch is imported from openembedded project
>> +
>> +11/30/2010 - Qing He <qing.he@intel.com>
>> +
>> +diff -urN bind-9.3.1.orig/conf/db.0 bind-9.3.1/conf/db.0
>> +--- bind-9.3.1.orig/conf/db.0  1970-01-01 01:00:00.000000000 +0100
>> ++++ bind-9.3.1/conf/db.0       2005-07-10 22:14:00.000000000 +0200
>> +@@ -0,0 +1,12 @@
>> ++;
>> ++; BIND reverse data file for broadcast zone
>> ++;
>> ++$TTL  604800
>> ++@     IN      SOA     localhost. root.localhost. (
>> ++                            1         ; Serial
>> ++                       604800         ; Refresh
>> ++                        86400         ; Retry
>> ++                      2419200         ; Expire
>> ++                       604800 )       ; Negative Cache TTL
>> ++;
>> ++@     IN      NS      localhost.
>> +diff -urN bind-9.3.1.orig/conf/db.127 bind-9.3.1/conf/db.127
>> +--- bind-9.3.1.orig/conf/db.127        1970-01-01 01:00:00.000000000 +0100
>> ++++ bind-9.3.1/conf/db.127     2005-07-10 22:14:00.000000000 +0200
>> +@@ -0,0 +1,13 @@
>> ++;
>> ++; BIND reverse data file for local loopback interface
>> ++;
>> ++$TTL  604800
>> ++@     IN      SOA     localhost. root.localhost. (
>> ++                            1         ; Serial
>> ++                       604800         ; Refresh
>> ++                        86400         ; Retry
>> ++                      2419200         ; Expire
>> ++                       604800 )       ; Negative Cache TTL
>> ++;
>> ++@     IN      NS      localhost.
>> ++1.0.0 IN      PTR     localhost.
>> +diff -urN bind-9.3.1.orig/conf/db.empty bind-9.3.1/conf/db.empty
>> +--- bind-9.3.1.orig/conf/db.empty      1970-01-01 01:00:00.000000000 +0100
>> ++++ bind-9.3.1/conf/db.empty   2005-07-10 22:14:00.000000000 +0200
>> +@@ -0,0 +1,14 @@
>> ++; BIND reverse data file for empty rfc1918 zone
>> ++;
>> ++; DO NOT EDIT THIS FILE - it is used for multiple zones.
>> ++; Instead, copy it, edit named.conf, and use that copy.
>> ++;
>> ++$TTL  86400
>> ++@     IN      SOA     localhost. root.localhost. (
>> ++                            1         ; Serial
>> ++                       604800         ; Refresh
>> ++                        86400         ; Retry
>> ++                      2419200         ; Expire
>> ++                        86400 )       ; Negative Cache TTL
>> ++;
>> ++@     IN      NS      localhost.
>> +diff -urN bind-9.3.1.orig/conf/db.255 bind-9.3.1/conf/db.255
>> +--- bind-9.3.1.orig/conf/db.255        1970-01-01 01:00:00.000000000 +0100
>> ++++ bind-9.3.1/conf/db.255     2005-07-10 22:14:00.000000000 +0200
>> +@@ -0,0 +1,12 @@
>> ++;
>> ++; BIND reserve data file for broadcast zone
>> ++;
>> ++$TTL  604800
>> ++@     IN      SOA     localhost. root.localhost. (
>> ++                            1         ; Serial
>> ++                       604800         ; Refresh
>> ++                        86400         ; Retry
>> ++                      2419200         ; Expire
>> ++                       604800 )       ; Negative Cache TTL
>> ++;
>> ++@     IN      NS      localhost.
>> +diff -urN bind-9.3.1.orig/conf/db.local bind-9.3.1/conf/db.local
>> +--- bind-9.3.1.orig/conf/db.local      1970-01-01 01:00:00.000000000 +0100
>> ++++ bind-9.3.1/conf/db.local   2005-07-10 22:14:00.000000000 +0200
>> +@@ -0,0 +1,13 @@
>> ++;
>> ++; BIND data file for local loopback interface
>> ++;
>> ++$TTL  604800
>> ++@     IN      SOA     localhost. root.localhost. (
>> ++                            1         ; Serial
>> ++                       604800         ; Refresh
>> ++                        86400         ; Retry
>> ++                      2419200         ; Expire
>> ++                       604800 )       ; Negative Cache TTL
>> ++;
>> ++@     IN      NS      localhost.
>> ++@     IN      A       127.0.0.1
>> +diff -urN bind-9.3.1.orig/conf/db.root bind-9.3.1/conf/db.root
>> +--- bind-9.3.1.orig/conf/db.root       1970-01-01 01:00:00.000000000 +0100
>> ++++ bind-9.3.1/conf/db.root    2005-07-10 22:14:00.000000000 +0200
>> +@@ -0,0 +1,45 @@
>> ++
>> ++; <<>> DiG 9.2.3 <<>> ns . @a.root-servers.net.
>> ++;; global options:  printcmd
>> ++;; Got answer:
>> ++;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 18944
>> ++;; flags: qr aa rd; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 13
>> ++
>> ++;; QUESTION SECTION:
>> ++;.                            IN      NS
>> ++
>> ++;; ANSWER SECTION:
>> ++.                     518400  IN      NS      A.ROOT-SERVERS.NET.
>> ++.                     518400  IN      NS      B.ROOT-SERVERS.NET.
>> ++.                     518400  IN      NS      C.ROOT-SERVERS.NET.
>> ++.                     518400  IN      NS      D.ROOT-SERVERS.NET.
>> ++.                     518400  IN      NS      E.ROOT-SERVERS.NET.
>> ++.                     518400  IN      NS      F.ROOT-SERVERS.NET.
>> ++.                     518400  IN      NS      G.ROOT-SERVERS.NET.
>> ++.                     518400  IN      NS      H.ROOT-SERVERS.NET.
>> ++.                     518400  IN      NS      I.ROOT-SERVERS.NET.
>> ++.                     518400  IN      NS      J.ROOT-SERVERS.NET.
>> ++.                     518400  IN      NS      K.ROOT-SERVERS.NET.
>> ++.                     518400  IN      NS      L.ROOT-SERVERS.NET.
>> ++.                     518400  IN      NS      M.ROOT-SERVERS.NET.
>> ++
>> ++;; ADDITIONAL SECTION:
>> ++A.ROOT-SERVERS.NET.   3600000 IN      A       198.41.0.4
>> ++B.ROOT-SERVERS.NET.   3600000 IN      A       192.228.79.201
>> ++C.ROOT-SERVERS.NET.   3600000 IN      A       192.33.4.12
>> ++D.ROOT-SERVERS.NET.   3600000 IN      A       128.8.10.90
>> ++E.ROOT-SERVERS.NET.   3600000 IN      A       192.203.230.10
>> ++F.ROOT-SERVERS.NET.   3600000 IN      A       192.5.5.241
>> ++G.ROOT-SERVERS.NET.   3600000 IN      A       192.112.36.4
>> ++H.ROOT-SERVERS.NET.   3600000 IN      A       128.63.2.53
>> ++I.ROOT-SERVERS.NET.   3600000 IN      A       192.36.148.17
>> ++J.ROOT-SERVERS.NET.   3600000 IN      A       192.58.128.30
>> ++K.ROOT-SERVERS.NET.   3600000 IN      A       193.0.14.129
>> ++L.ROOT-SERVERS.NET.   3600000 IN      A       198.32.64.12
>> ++M.ROOT-SERVERS.NET.   3600000 IN      A       202.12.27.33
>> ++
>> ++;; Query time: 81 msec
>> ++;; SERVER: 198.41.0.4#53(a.root-servers.net.)
>> ++;; WHEN: Sun Feb  1 11:27:14 2004
>> ++;; MSG SIZE  rcvd: 436
>> ++
>> +diff -urN bind-9.3.1.orig/conf/named.conf bind-9.3.1/conf/named.conf
>> +--- bind-9.3.1.orig/conf/named.conf    1970-01-01 01:00:00.000000000 +0100
>> ++++ bind-9.3.1/conf/named.conf 2005-07-10 22:33:46.000000000 +0200
>> +@@ -0,0 +1,49 @@
>> ++// This is the primary configuration file for the BIND DNS server named.
>> ++//
>> ++// If you are just adding zones, please do that in /etc/bind/named.conf.local
>> ++
>> ++include "/etc/bind/named.conf.options";
>> ++
>> ++// prime the server with knowledge of the root servers
>> ++zone "." {
>> ++      type hint;
>> ++      file "/etc/bind/db.root";
>> ++};
>> ++
>> ++// be authoritative for the localhost forward and reverse zones, and for
>> ++// broadcast zones as per RFC 1912
>> ++
>> ++zone "localhost" {
>> ++      type master;
>> ++      file "/etc/bind/db.local";
>> ++};
>> ++
>> ++zone "127.in-addr.arpa" {
>> ++      type master;
>> ++      file "/etc/bind/db.127";
>> ++};
>> ++
>> ++zone "0.in-addr.arpa" {
>> ++      type master;
>> ++      file "/etc/bind/db.0";
>> ++};
>> ++
>> ++zone "255.in-addr.arpa" {
>> ++      type master;
>> ++      file "/etc/bind/db.255";
>> ++};
>> ++
>> ++// zone "com" { type delegation-only; };
>> ++// zone "net" { type delegation-only; };
>> ++
>> ++// From the release notes:
>> ++//  Because many of our users are uncomfortable receiving undelegated answers
>> ++//  from root or top level domains, other than a few for whom that behaviour
>> ++//  has been trusted and expected for quite some length of time, we have now
>> ++//  introduced the "root-delegations-only" feature which applies delegation-only
>> ++//  logic to all top level domains, and to the root domain.  An exception list
>> ++//  should be specified, including "MUSEUM" and "DE", and any other top level
>> ++//  domains from whom undelegated responses are expected and trusted.
>> ++// root-delegation-only exclude { "DE"; "MUSEUM"; };
>> ++
>> ++include "/etc/bind/named.conf.local";
>> +diff -urN bind-9.3.1.orig/conf/named.conf.local bind-9.3.1/conf/named.conf.local
>> +--- bind-9.3.1.orig/conf/named.conf.local      1970-01-01 01:00:00.000000000 +0100
>> ++++ bind-9.3.1/conf/named.conf.local   2005-07-10 22:14:06.000000000 +0200
>> +@@ -0,0 +1,8 @@
>> ++//
>> ++// Do any local configuration here
>> ++//
>> ++
>> ++// Consider adding the 1918 zones here, if they are not used in your
>> ++// organization
>> ++//include "/etc/bind/zones.rfc1918";
>> ++
>> +diff -urN bind-9.3.1.orig/conf/named.conf.options bind-9.3.1/conf/named.conf.options
>> +--- bind-9.3.1.orig/conf/named.conf.options    1970-01-01 01:00:00.000000000 +0100
>> ++++ bind-9.3.1/conf/named.conf.options 2005-07-10 22:14:06.000000000 +0200
>> +@@ -0,0 +1,24 @@
>> ++options {
>> ++      directory "/var/cache/bind";
>> ++
>> ++      // If there is a firewall between you and nameservers you want
>> ++      // to talk to, you might need to uncomment the query-source
>> ++      // directive below.  Previous versions of BIND always asked
>> ++      // questions using port 53, but BIND 8.1 and later use an unprivileged
>> ++      // port by default.
>> ++
>> ++      // query-source address * port 53;
>> ++
>> ++      // If your ISP provided one or more IP addresses for stable
>> ++      // nameservers, you probably want to use them as forwarders.
>> ++      // Uncomment the following block, and insert the addresses replacing
>> ++      // the all-0's placeholder.
>> ++
>> ++      // forwarders {
>> ++      //      0.0.0.0;
>> ++      // };
>> ++
>> ++      auth-nxdomain no;    # conform to RFC1035
>> ++
>> ++};
>> ++
>> +diff -urN bind-9.3.1.orig/conf/zones.rfc1918 bind-9.3.1/conf/zones.rfc1918
>> +--- bind-9.3.1.orig/conf/zones.rfc1918 1970-01-01 01:00:00.000000000 +0100
>> ++++ bind-9.3.1/conf/zones.rfc1918      2005-07-10 22:14:10.000000000 +0200
>> +@@ -0,0 +1,20 @@
>> ++zone "10.in-addr.arpa"      { type master; file "/etc/bind/db.empty"; };
>> ++
>> ++zone "16.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++zone "17.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++zone "18.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++zone "19.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++zone "20.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++zone "21.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++zone "22.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++zone "23.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++zone "24.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++zone "25.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++zone "26.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++zone "27.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++zone "28.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++zone "29.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++zone "30.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++zone "31.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>> ++
>> ++zone "168.192.in-addr.arpa" { type master; file "/etc/bind/db.empty"; };
>> +diff -urN bind-9.3.1.orig/init.d bind-9.3.1/init.d
>> +--- bind-9.3.1.orig/init.d     1970-01-01 01:00:00.000000000 +0100
>> ++++ bind-9.3.1/init.d  2005-07-10 23:09:58.000000000 +0200
>> +@@ -0,0 +1,70 @@
>> ++#!/bin/sh
>> ++
>> ++PATH=/sbin:/bin:/usr/sbin:/usr/bin
>> ++
>> ++# for a chrooted server: "-u bind -t /var/lib/named"
>> ++# Don't modify this line, change or create /etc/default/bind9.
>> ++OPTIONS=""
>> ++
>> ++test -f /etc/default/bind9 && . /etc/default/bind9
>> ++
>> ++test -x /usr/sbin/rndc || exit 0
>> ++
>> ++case "$1" in
>> ++    start)
>> ++      echo -n "Starting domain name service: named"
>> ++
>> ++      modprobe capability >/dev/null 2>&1 || true
>> ++      if [ ! -f /etc/bind/rndc.key ]; then
>> ++          /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
>> ++          chmod 0640 /etc/bind/rndc.key
>> ++      fi
>> ++      if [ -f /var/run/named/named.pid ]; then
>> ++          ps `cat /var/run/named/named.pid` > /dev/null && exit 1
>> ++      fi
>> ++
>> ++      # dirs under /var/run can go away on reboots.
>> ++      mkdir -p /var/run/named
>> ++      mkdir -p /var/cache/bind
>> ++      chmod 775 /var/run/named
>> ++      chown root:bind /var/run/named >/dev/null 2>&1 || true
>> ++
>> ++      if [ ! -x /usr/sbin/named ]; then
>> ++          echo "named binary missing - not starting"
>> ++          exit 1
>> ++      fi
>> ++      if start-stop-daemon --start --quiet --exec /usr/sbin/named \
>> ++              --pidfile /var/run/named/named.pid -- $OPTIONS; then
>> ++          if [ -x /sbin/resolvconf ] ; then
>> ++              echo "nameserver 127.0.0.1" | /sbin/resolvconf -a lo
>> ++          fi
>> ++      fi
>> ++      echo "."
>> ++    ;;
>> ++
>> ++    stop)
>> ++      echo -n "Stopping domain name service: named"
>> ++      if [ -x /sbin/resolvconf ]; then
>> ++          /sbin/resolvconf -d lo
>> ++      fi
>> ++      /usr/sbin/rndc stop >/dev/null 2>&1
>> ++      echo "."
>> ++    ;;
>> ++
>> ++    reload)
>> ++      /usr/sbin/rndc reload
>> ++    ;;
>> ++
>> ++    restart|force-reload)
>> ++      $0 stop
>> ++      sleep 2
>> ++      $0 start
>> ++    ;;
>> ++
>> ++    *)
>> ++      echo "Usage: /etc/init.d/bind {start|stop|reload|restart|force-reload}" >&2
>> ++      exit 1
>> ++    ;;
>> ++esac
>> ++
>> ++exit 0
>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
>> new file mode 100644
>> index 00000000000..ef915c0ae5a
>> --- /dev/null
>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
>> @@ -0,0 +1,8 @@
>> +#!/bin/sh
>> +
>> +if [ ! -s /etc/bind/rndc.key ]; then
>> +    echo -n "Generating /etc/bind/rndc.key:"
>> +    /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
>> +    chown root:bind /etc/bind/rndc.key
>> +    chmod 0640 /etc/bind/rndc.key
>> +fi
>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
>> new file mode 100644
>> index 00000000000..11db95ede12
>> --- /dev/null
>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
>> @@ -0,0 +1,65 @@
>> +Subject: init.d: add support for read-only rootfs
>> +
>> +Upstream-Status: Inappropriate [oe specific]
>> +
>> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
>> +---
>> + init.d |   40 ++++++++++++++++++++++++++++++++++++++++
>> + 1 file changed, 40 insertions(+)
>> +
>> +diff --git a/init.d b/init.d
>> +index 0111ed4..24677c8 100644
>> +--- a/init.d
>> ++++ b/init.d
>> +@@ -6,8 +6,48 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin
>> + # Don't modify this line, change or create /etc/default/bind9.
>> + OPTIONS=""
>> +
>> ++test -f /etc/default/rcS && . /etc/default/rcS
>> + test -f /etc/default/bind9 && . /etc/default/bind9
>> +
>> ++# This function is here because it's possible that /var and / are on different partitions.
>> ++is_on_read_only_partition () {
>> ++    DIRECTORY=$1
>> ++    dir=`readlink -f $DIRECTORY`
>> ++    while true; do
>> ++      if [ ! -d "$dir" ]; then
>> ++          echo "ERROR: $dir is not a directory"
>> ++          exit 1
>> ++      else
>> ++          for flag in `awk -v dir=$dir '{ if ($2 == dir) { print "FOUND"; split($4,FLAGS,",") } }; \
>> ++              END { for (f in FLAGS) print FLAGS[f] }' < /proc/mounts`; do
>> ++              [ "$flag" = "FOUND" ] && partition="read-write"
>> ++              [ "$flag" = "ro" ] && { partition="read-only"; break; }
>> ++          done
>> ++          if [ "$dir" = "/" -o -n "$partition" ]; then
>> ++              break
>> ++          else
>> ++              dir=`dirname $dir`
>> ++          fi
>> ++      fi
>> ++    done
>> ++    [ "$partition" = "read-only" ] && echo "yes" || echo "no"
>> ++}
>> ++
>> ++bind_mount () {
>> ++    olddir=$1
>> ++    newdir=$2
>> ++    mkdir -p $olddir
>> ++    cp -a $newdir/* $olddir
>> ++    mount --bind $olddir $newdir
>> ++}
>> ++
>> ++# Deal with read-only rootfs
>> ++if [ "$ROOTFS_READ_ONLY" = "yes" ]; then
>> ++    [ "$VERBOSE" != "no" ] && echo "WARN: start bind service in read-only rootfs"
>> ++    [ `is_on_read_only_partition /etc/bind` = "yes" ] && bind_mount /var/volatile/bind/etc /etc/bind
>> ++    [ `is_on_read_only_partition /var/named` = "yes" ] && bind_mount /var/volatile/bind/named /var/named
>> ++fi
>> ++
>> + test -x /usr/sbin/rndc || exit 0
>> +
>> + case "$1" in
>> +--
>> +1.7.9.5
>> +
>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
>> new file mode 100644
>> index 00000000000..146f3e35db6
>> --- /dev/null
>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
>> @@ -0,0 +1,42 @@
>> +bind: make "/etc/init.d/bind stop" work
>> +
>> +Upstream-Status: Inappropriate [configuration]
>> +
>> +Add some configurations, make rndc command be able to controls
>> +the named daemon.
>> +
>> +Signed-off-by: Roy Li <rongqing.li@windriver.com>
>> +---
>> + conf/named.conf |    5 +++++
>> + conf/rndc.conf  |    5 +++++
>> + 2 files changed, 10 insertions(+), 0 deletions(-)
>> + create mode 100644 conf/rndc.conf
>> +
>> +diff --git a/conf/named.conf b/conf/named.conf
>> +index 95829cf..c8899e7 100644
>> +--- a/conf/named.conf
>> ++++ b/conf/named.conf
>> +@@ -47,3 +47,8 @@ zone "255.in-addr.arpa" {
>> + // root-delegation-only exclude { "DE"; "MUSEUM"; };
>> +
>> + include "/etc/bind/named.conf.local";
>> ++include "/etc/bind/rndc.key" ;
>> ++controls {
>> ++      inet 127.0.0.1 allow { localhost; }
>> ++      keys { rndc-key; };
>> ++};
>> +diff --git a/conf/rndc.conf b/conf/rndc.conf
>> +new file mode 100644
>> +index 0000000..a0b481d
>> +--- /dev/null
>> ++++ b/conf/rndc.conf
>> +@@ -0,0 +1,5 @@
>> ++include "/etc/bind/rndc.key";
>> ++options {
>> ++      default-server  localhost;
>> ++      default-key     rndc-key;
>> ++};
>> +
>> +--
>> +1.7.5.4
>> +
>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/named.service b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
>> new file mode 100644
>> index 00000000000..cda56ef0150
>> --- /dev/null
>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
>> @@ -0,0 +1,22 @@
>> +[Unit]
>> +Description=Berkeley Internet Name Domain (DNS)
>> +Wants=nss-lookup.target
>> +Before=nss-lookup.target
>> +After=network.target
>> +
>> +[Service]
>> +Type=forking
>> +EnvironmentFile=-/etc/default/bind9
>> +PIDFile=/run/named/named.pid
>> +
>> +ExecStartPre=@SBINDIR@/generate-rndc-key.sh
>> +ExecStart=@SBINDIR@/named $OPTIONS
>> +
>> +ExecReload=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc reload > /dev/null 2>&1 || @BASE_BINDIR@/kill -HUP $MAINPID'
>> +
>> +ExecStop=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc stop > /dev/null 2>&1 || @BASE_BINDIR@/kill -TERM $MAINPID'
>> +
>> +PrivateTmp=true
>> +
>> +[Install]
>> +WantedBy=multi-user.target
>> diff --git a/meta/recipes-connectivity/bind/bind_9.16.5.bb b/meta/recipes-connectivity/bind/bind_9.16.5.bb
>> new file mode 100644
>> index 00000000000..9c20ccc6fa2
>> --- /dev/null
>> +++ b/meta/recipes-connectivity/bind/bind_9.16.5.bb
>> @@ -0,0 +1,125 @@
>> +SUMMARY = "ISC Internet Domain Name Server"
>> +HOMEPAGE = "http://www.isc.org/sw/bind/"
>> +SECTION = "console/network"
>> +
>> +LICENSE = "MPL-2.0"
>> +LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=188b8d0644bd6835df43b84e3f180be1"
>> +
>> +DEPENDS = "openssl libcap zlib libuv"
>> +
>> +SRC_URI = "https://ftp.isc.org/isc/bind9/${PV}/${BPN}-${PV}.tar.xz \
>> +           file://conf.patch \
>> +           file://named.service \
>> +           file://bind9 \
>> +           file://generate-rndc-key.sh \
>> +           file://make-etc-initd-bind-stop-work.patch \
>> +           file://init.d-add-support-for-read-only-rootfs.patch \
>> +           file://bind-ensure-searching-for-json-headers-searches-sysr.patch \
>> +           file://0001-named-lwresd-V-and-start-log-hide-build-options.patch \
>> +           file://0001-avoid-start-failure-with-bind-user.patch \
>> +           "
>> +
>> +SRC_URI[sha256sum] = "6378b3e51fef11a8be4794dc48e8111ba92d211c0dfd129a0c296ed06a3dc075"
>> +
>> +UPSTREAM_CHECK_URI = "https://ftp.isc.org/isc/bind9/"
>> +# stay at 9.16 follow the ESV versions divisible by 4
>> +UPSTREAM_CHECK_REGEX = "(?P<pver>9.(16|20|24|28)(\.\d+)+(-P\d+)*)/"
>> +
>> +inherit autotools update-rc.d systemd useradd pkgconfig multilib_script multilib_header
>> +
>> +MULTILIB_SCRIPTS = "${PN}:${bindir}/bind9-config ${PN}:${bindir}/isc-config.sh"
>> +
>> +# PACKAGECONFIGs readline and libedit should NOT be set at same time
>> +PACKAGECONFIG ?= "readline"
>> +PACKAGECONFIG[httpstats] = "--with-libxml2=${STAGING_DIR_HOST}${prefix},--without-libxml2,libxml2"
>> +PACKAGECONFIG[readline] = "--with-readline=-lreadline,,readline"
>> +PACKAGECONFIG[libedit] = "--with-readline=-ledit,,libedit"
>> +PACKAGECONFIG[python3] = "--with-python=yes --with-python-install-dir=${PYTHON_SITEPACKAGES_DIR} , --without-python, python3-ply-native,"
>> +
>> +EXTRA_OECONF = " --with-libtool --disable-devpoll --enable-epoll \
>> +                 --with-gssapi=no --with-lmdb=no --with-zlib \
>> +                 --sysconfdir=${sysconfdir}/bind \
>> +                 --with-openssl=${STAGING_DIR_HOST}${prefix} \
>> +               "
>> +LDFLAGS_append = " -lz"
>> +
>> +inherit ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3native distutils3-base', '', d)}
>> +
>> +# dhcp needs .la so keep them
>> +REMOVE_LIBTOOL_LA = "0"
>> +
>> +USERADD_PACKAGES = "${PN}"
>> +USERADD_PARAM_${PN} = "--system --home ${localstatedir}/cache/bind --no-create-home \
>> +                       --user-group bind"
>> +
>> +INITSCRIPT_NAME = "bind"
>> +INITSCRIPT_PARAMS = "defaults"
>> +
>> +SYSTEMD_SERVICE_${PN} = "named.service"
>> +
>> +do_install_append() {
>> +
>> +       rmdir "${D}${localstatedir}/run"
>> +       rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
>> +       install -d -o bind "${D}${localstatedir}/cache/bind"
>> +       install -d "${D}${sysconfdir}/bind"
>> +       install -d "${D}${sysconfdir}/init.d"
>> +       install -m 644 ${S}/conf/* "${D}${sysconfdir}/bind/"
>> +       install -m 755 "${S}/init.d" "${D}${sysconfdir}/init.d/bind"
>> +        if ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'true', 'false', d)}; then
>> +               sed -i -e '1s,#!.*python3,#! /usr/bin/python3,' \
>> +               ${D}${sbindir}/dnssec-coverage \
>> +               ${D}${sbindir}/dnssec-checkds \
>> +               ${D}${sbindir}/dnssec-keymgr
>> +       fi
>> +
>> +       # Install systemd related files
>> +       install -d ${D}${sbindir}
>> +       install -m 755 ${WORKDIR}/generate-rndc-key.sh ${D}${sbindir}
>> +       install -d ${D}${systemd_unitdir}/system
>> +       install -m 0644 ${WORKDIR}/named.service ${D}${systemd_unitdir}/system
>> +       sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
>> +              -e 's,@SBINDIR@,${sbindir},g' \
>> +              ${D}${systemd_unitdir}/system/named.service
>> +
>> +       install -d ${D}${sysconfdir}/default
>> +       install -m 0644 ${WORKDIR}/bind9 ${D}${sysconfdir}/default
>> +
>> +       if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
>> +               install -d ${D}${sysconfdir}/tmpfiles.d
>> +               echo "d /run/named 0755 bind bind - -" > ${D}${sysconfdir}/tmpfiles.d/bind.conf
>> +       fi
>> +
>> +    oe_multilib_header isc/platform.h
>> +}
>> +
>> +CONFFILES_${PN} = " \
>> +       ${sysconfdir}/bind/named.conf \
>> +       ${sysconfdir}/bind/named.conf.local \
>> +       ${sysconfdir}/bind/named.conf.options \
>> +       ${sysconfdir}/bind/db.0 \
>> +       ${sysconfdir}/bind/db.127 \
>> +       ${sysconfdir}/bind/db.empty \
>> +       ${sysconfdir}/bind/db.local \
>> +       ${sysconfdir}/bind/db.root \
>> +       "
>> +
>> +ALTERNATIVE_${PN}-utils = "nslookup"
>> +ALTERNATIVE_LINK_NAME[nslookup] = "${bindir}/nslookup"
>> +ALTERNATIVE_PRIORITY = "100"
> I'm seeing this failing with busybox:
> update-alternatives: Error: not linking
> /development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
> to /bin/busybox.nosuid since
> /development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
> exists and is not a link
>
> busybox sets ALTERNATIVE_PRIORITY = "50". Can this be the issue?

That is weird. I would have expected that to be an issue with the old
version too.

Got any steps to reproduce this?

-armin
>
> Going back to bind 9.11.22 seems to solve it...
>
>> +
>> +PACKAGE_BEFORE_PN += "${PN}-utils"
>> +FILES_${PN}-utils = "${bindir}/host ${bindir}/dig ${bindir}/mdig ${bindir}/nslookup ${bindir}/nsupdate"
>> +FILES_${PN}-dev += "${bindir}/isc-config.h"
>> +FILES_${PN} += "${sbindir}/generate-rndc-key.sh"
>> +
>> +PACKAGE_BEFORE_PN += "${PN}-libs"
>> +FILES_${PN}-libs = "${libdir}/*.so* ${libdir}/named/*.so*"
>> +FILES_${PN}-staticdev += "${libdir}/*.la"
>> +
>> +PACKAGE_BEFORE_PN += "${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3-bind', '', d)}"
>> +FILES_python3-bind = "${sbindir}/dnssec-coverage ${sbindir}/dnssec-checkds \
>> +                ${sbindir}/dnssec-keymgr ${PYTHON_SITEPACKAGES_DIR}"
>> +
>> +RDEPENDS_${PN}-dev = ""
>> +RDEPENDS_python3-bind = "python3-core python3-ply"
>> --
>> 2.17.1
>>
>> 
>
>


^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [OE-core] [PATCH 7/8] bind: Add 9.16.x
  2020-09-07 15:28     ` akuster
@ 2020-09-07 21:17       ` Andrey Zhizhikin
  2020-09-09 23:53         ` Khem Raj
  0 siblings, 1 reply; 24+ messages in thread
From: Andrey Zhizhikin @ 2020-09-07 21:17 UTC (permalink / raw)
  To: akuster808; +Cc: OE Core mailing list

On Mon, Sep 7, 2020 at 5:28 PM akuster808 <akuster808@gmail.com> wrote:
>
>
>
> On 9/4/20 1:39 AM, Andrey Zhizhikin wrote:
> > Hello Armin,
> >
> > On Tue, Sep 1, 2020 at 5:23 PM akuster <akuster808@gmail.com> wrote:
> >> Removed obsolete packageconfig options
> >>
> >> License change to MPL-2.0
> >> https://gitlab.isc.org/isc-projects/bind9/blob/master/LICENSE
> >>
> >> Refreshed:
> >> bind-ensure-searching-for-json-headers-searches-sysr.patch
> >> 0001-named-lwresd-V-and-start-log-hide-build-options.patch
> >> bind-ensure-searching-for-json-headers-searches-sysr.patch
> >>
> >> Drop obsolete patch: 0001-configure.in-remove-useless-L-use_openssl-lib.patch
> >>
> >> Signed-off-by: Armin Kuster <akuster808@gmail.com>
> >> ---
> >>  ...1-avoid-start-failure-with-bind-user.patch |  27 ++
> >>  ...d-V-and-start-log-hide-build-options.patch |  35 ++
> >>  ...ching-for-json-headers-searches-sysr.patch |  47 +++
> >>  .../bind/bind-9.16.5/bind9                    |   2 +
> >>  .../bind/bind-9.16.5/conf.patch               | 330 ++++++++++++++++++
> >>  .../bind/bind-9.16.5/generate-rndc-key.sh     |   8 +
> >>  ...t.d-add-support-for-read-only-rootfs.patch |  65 ++++
> >>  .../make-etc-initd-bind-stop-work.patch       |  42 +++
> >>  .../bind/bind-9.16.5/named.service            |  22 ++
> >>  meta/recipes-connectivity/bind/bind_9.16.5.bb | 125 +++++++
> >>  10 files changed, 703 insertions(+)
> >>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
> >>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
> >>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
> >>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind9
> >>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
> >>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
> >>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
> >>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
> >>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/named.service
> >>  create mode 100644 meta/recipes-connectivity/bind/bind_9.16.5.bb
> >>
> >> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
> >> new file mode 100644
> >> index 00000000000..8db96ec049c
> >> --- /dev/null
> >> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
> >> @@ -0,0 +1,27 @@
> >> +From 31dde3562f287429eea94b77250d184818b49063 Mon Sep 17 00:00:00 2001
> >> +From: Chen Qi <Qi.Chen@windriver.com>
> >> +Date: Mon, 15 Oct 2018 16:55:09 +0800
> >> +Subject: [PATCH] avoid start failure with bind user
> >> +
> >> +Upstream-Status: Pending
> >> +
> >> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
> >> +---
> >> + init.d | 1 +
> >> + 1 file changed, 1 insertion(+)
> >> +
> >> +diff --git a/init.d b/init.d
> >> +index b2eec60..6e03936 100644
> >> +--- a/init.d
> >> ++++ b/init.d
> >> +@@ -57,6 +57,7 @@ case "$1" in
> >> +       modprobe capability >/dev/null 2>&1 || true
> >> +       if [ ! -f /etc/bind/rndc.key ]; then
> >> +           /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
> >> ++          chown root:bind /etc/bind/rndc.key >/dev/null 2>&1 || true
> >> +           chmod 0640 /etc/bind/rndc.key
> >> +       fi
> >> +       if [ -f /var/run/named/named.pid ]; then
> >> +--
> >> +2.7.4
> >> +
> >> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
> >> new file mode 100644
> >> index 00000000000..5bcc16c9b2b
> >> --- /dev/null
> >> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
> >> @@ -0,0 +1,35 @@
> >> +From a3af4a405baf5ff582e82aaba392dd9667d94bdc Mon Sep 17 00:00:00 2001
> >> +From: Hongxu Jia <hongxu.jia@windriver.com>
> >> +Date: Mon, 27 Aug 2018 21:24:20 +0800
> >> +Subject: [PATCH] `named/lwresd -V' and start log hide build options
> >> +
> >> +The build options expose build path directories, so hide them.
> >> +[snip]
> >> +$ named -V
> >> +|built by make with *** (options are hidden)
> >> +[snip]
> >> +
> >> +Upstream-Status: Inappropriate [oe-core specific]
> >> +
> >> +Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
> >> +
> >> +Refreshed for 9.16.0
> >> +Signed-off-by: Armin Kuster <akuster@mvista.com>
> >> +
> >> +---
> >> + bin/named/include/named/globals.h | 2 +-
> >> + 1 file changed, 1 insertion(+), 1 deletion(-)
> >> +
> >> +Index: bind-9.16.0/bin/named/include/named/globals.h
> >> +===================================================================
> >> +--- bind-9.16.0.orig/bin/named/include/named/globals.h
> >> ++++ bind-9.16.0/bin/named/include/named/globals.h
> >> +@@ -69,7 +69,7 @@ EXTERN const char *named_g_version     I
> >> + EXTERN const char *named_g_product     INIT(PRODUCT);
> >> + EXTERN const char *named_g_description INIT(DESCRIPTION);
> >> + EXTERN const char *named_g_srcid       INIT(SRCID);
> >> +-EXTERN const char *named_g_configargs  INIT(CONFIGARGS);
> >> ++EXTERN const char *named_g_configargs  INIT("*** (options are hidden)");
> >> + EXTERN const char *named_g_builder     INIT(BUILDER);
> >> + EXTERN in_port_t named_g_port        INIT(0);
> >> + EXTERN isc_dscp_t named_g_dscp               INIT(-1);
> >> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
> >> new file mode 100644
> >> index 00000000000..f9cdc7ca4df
> >> --- /dev/null
> >> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
> >> @@ -0,0 +1,47 @@
> >> +From edda20fb5a6e88548f85e39d34d6c074306e15bc Mon Sep 17 00:00:00 2001
> >> +From: Paul Gortmaker <paul.gortmaker@windriver.com>
> >> +Date: Tue, 9 Jun 2015 11:22:00 -0400
> >> +Subject: [PATCH] bind: ensure searching for json headers searches sysroot
> >> +
> >> +Bind can fail configure by detecting headers w/o libs[1], or
> >> +it can fail the host contamination check as per below:
> >> +
> >> +ERROR: This autoconf log indicates errors, it looked at host include and/or library paths while determining system capabilities.
> >> +Rerun configure task after fixing this. The path was 'build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/build'
> >> +ERROR: Function failed: do_qa_configure
> >> +ERROR: Logfile of failure stored in: build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/temp/log.do_configure.5242
> >> +ERROR: Task 5 (meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure) failed with exit code '1'
> >> +NOTE: Tasks Summary: Attempted 773 tasks of which 768 didn't need to be rerun and 1 failed.
> >> +No currently running tasks (773 of 781)
> >> +
> >> +Summary: 1 task failed:
> >> +  /meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure
> >> +
> >> +One way to fix it would be to unconditionally disable json in bind
> >> +configure[2] but here we fix it by using the path to where we would
> >> +put the header if we had json in the sysroot, in case someone wants
> >> +to make use of the combination some day.
> >> +
> >> +[1] https://trac.macports.org/ticket/45305
> >> +[2] https://trac.macports.org/changeset/126406
> >> +
> >> +Upstream-Status: Inappropriate [OE Specific]
> >> +Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
> >> +
> >> +---
> >> + configure.ac | 2 +-
> >> + 1 file changed, 1 insertion(+), 1 deletion(-)
> >> +
> >> +Index: bind-9.16.4/configure.ac
> >> +===================================================================
> >> +--- bind-9.16.4.orig/configure.ac
> >> ++++ bind-9.16.4/configure.ac
> >> +@@ -1232,7 +1232,7 @@ case "$use_lmdb" in
> >> +               LMDB_LIBS=""
> >> +               ;;
> >> +       auto|yes)
> >> +-              for d in /usr /usr/local /opt/local
> >> ++              for d in "${STAGING_INCDIR}"
> >> +               do
> >> +                       if test -f "${d}/include/lmdb.h"
> >> +                       then
> >> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind9 b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
> >> new file mode 100644
> >> index 00000000000..968679ff7f7
> >> --- /dev/null
> >> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
> >> @@ -0,0 +1,2 @@
> >> +# startup options for the server
> >> +OPTIONS="-u bind"
> >> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
> >> new file mode 100644
> >> index 00000000000..aad345f9fcf
> >> --- /dev/null
> >> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
> >> @@ -0,0 +1,330 @@
> >> +Upstream-Status: Inappropriate [configuration]
> >> +
> >> +the patch is imported from openembedded project
> >> +
> >> +11/30/2010 - Qing He <qing.he@intel.com>
> >> +
> >> +diff -urN bind-9.3.1.orig/conf/db.0 bind-9.3.1/conf/db.0
> >> +--- bind-9.3.1.orig/conf/db.0  1970-01-01 01:00:00.000000000 +0100
> >> ++++ bind-9.3.1/conf/db.0       2005-07-10 22:14:00.000000000 +0200
> >> +@@ -0,0 +1,12 @@
> >> ++;
> >> ++; BIND reverse data file for broadcast zone
> >> ++;
> >> ++$TTL  604800
> >> ++@     IN      SOA     localhost. root.localhost. (
> >> ++                            1         ; Serial
> >> ++                       604800         ; Refresh
> >> ++                        86400         ; Retry
> >> ++                      2419200         ; Expire
> >> ++                       604800 )       ; Negative Cache TTL
> >> ++;
> >> ++@     IN      NS      localhost.
> >> +diff -urN bind-9.3.1.orig/conf/db.127 bind-9.3.1/conf/db.127
> >> +--- bind-9.3.1.orig/conf/db.127        1970-01-01 01:00:00.000000000 +0100
> >> ++++ bind-9.3.1/conf/db.127     2005-07-10 22:14:00.000000000 +0200
> >> +@@ -0,0 +1,13 @@
> >> ++;
> >> ++; BIND reverse data file for local loopback interface
> >> ++;
> >> ++$TTL  604800
> >> ++@     IN      SOA     localhost. root.localhost. (
> >> ++                            1         ; Serial
> >> ++                       604800         ; Refresh
> >> ++                        86400         ; Retry
> >> ++                      2419200         ; Expire
> >> ++                       604800 )       ; Negative Cache TTL
> >> ++;
> >> ++@     IN      NS      localhost.
> >> ++1.0.0 IN      PTR     localhost.
> >> +diff -urN bind-9.3.1.orig/conf/db.empty bind-9.3.1/conf/db.empty
> >> +--- bind-9.3.1.orig/conf/db.empty      1970-01-01 01:00:00.000000000 +0100
> >> ++++ bind-9.3.1/conf/db.empty   2005-07-10 22:14:00.000000000 +0200
> >> +@@ -0,0 +1,14 @@
> >> ++; BIND reverse data file for empty rfc1918 zone
> >> ++;
> >> ++; DO NOT EDIT THIS FILE - it is used for multiple zones.
> >> ++; Instead, copy it, edit named.conf, and use that copy.
> >> ++;
> >> ++$TTL  86400
> >> ++@     IN      SOA     localhost. root.localhost. (
> >> ++                            1         ; Serial
> >> ++                       604800         ; Refresh
> >> ++                        86400         ; Retry
> >> ++                      2419200         ; Expire
> >> ++                        86400 )       ; Negative Cache TTL
> >> ++;
> >> ++@     IN      NS      localhost.
> >> +diff -urN bind-9.3.1.orig/conf/db.255 bind-9.3.1/conf/db.255
> >> +--- bind-9.3.1.orig/conf/db.255        1970-01-01 01:00:00.000000000 +0100
> >> ++++ bind-9.3.1/conf/db.255     2005-07-10 22:14:00.000000000 +0200
> >> +@@ -0,0 +1,12 @@
> >> ++;
> >> ++; BIND reserve data file for broadcast zone
> >> ++;
> >> ++$TTL  604800
> >> ++@     IN      SOA     localhost. root.localhost. (
> >> ++                            1         ; Serial
> >> ++                       604800         ; Refresh
> >> ++                        86400         ; Retry
> >> ++                      2419200         ; Expire
> >> ++                       604800 )       ; Negative Cache TTL
> >> ++;
> >> ++@     IN      NS      localhost.
> >> +diff -urN bind-9.3.1.orig/conf/db.local bind-9.3.1/conf/db.local
> >> +--- bind-9.3.1.orig/conf/db.local      1970-01-01 01:00:00.000000000 +0100
> >> ++++ bind-9.3.1/conf/db.local   2005-07-10 22:14:00.000000000 +0200
> >> +@@ -0,0 +1,13 @@
> >> ++;
> >> ++; BIND data file for local loopback interface
> >> ++;
> >> ++$TTL  604800
> >> ++@     IN      SOA     localhost. root.localhost. (
> >> ++                            1         ; Serial
> >> ++                       604800         ; Refresh
> >> ++                        86400         ; Retry
> >> ++                      2419200         ; Expire
> >> ++                       604800 )       ; Negative Cache TTL
> >> ++;
> >> ++@     IN      NS      localhost.
> >> ++@     IN      A       127.0.0.1
> >> +diff -urN bind-9.3.1.orig/conf/db.root bind-9.3.1/conf/db.root
> >> +--- bind-9.3.1.orig/conf/db.root       1970-01-01 01:00:00.000000000 +0100
> >> ++++ bind-9.3.1/conf/db.root    2005-07-10 22:14:00.000000000 +0200
> >> +@@ -0,0 +1,45 @@
> >> ++
> >> ++; <<>> DiG 9.2.3 <<>> ns . @a.root-servers.net.
> >> ++;; global options:  printcmd
> >> ++;; Got answer:
> >> ++;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 18944
> >> ++;; flags: qr aa rd; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 13
> >> ++
> >> ++;; QUESTION SECTION:
> >> ++;.                            IN      NS
> >> ++
> >> ++;; ANSWER SECTION:
> >> ++.                     518400  IN      NS      A.ROOT-SERVERS.NET.
> >> ++.                     518400  IN      NS      B.ROOT-SERVERS.NET.
> >> ++.                     518400  IN      NS      C.ROOT-SERVERS.NET.
> >> ++.                     518400  IN      NS      D.ROOT-SERVERS.NET.
> >> ++.                     518400  IN      NS      E.ROOT-SERVERS.NET.
> >> ++.                     518400  IN      NS      F.ROOT-SERVERS.NET.
> >> ++.                     518400  IN      NS      G.ROOT-SERVERS.NET.
> >> ++.                     518400  IN      NS      H.ROOT-SERVERS.NET.
> >> ++.                     518400  IN      NS      I.ROOT-SERVERS.NET.
> >> ++.                     518400  IN      NS      J.ROOT-SERVERS.NET.
> >> ++.                     518400  IN      NS      K.ROOT-SERVERS.NET.
> >> ++.                     518400  IN      NS      L.ROOT-SERVERS.NET.
> >> ++.                     518400  IN      NS      M.ROOT-SERVERS.NET.
> >> ++
> >> ++;; ADDITIONAL SECTION:
> >> ++A.ROOT-SERVERS.NET.   3600000 IN      A       198.41.0.4
> >> ++B.ROOT-SERVERS.NET.   3600000 IN      A       192.228.79.201
> >> ++C.ROOT-SERVERS.NET.   3600000 IN      A       192.33.4.12
> >> ++D.ROOT-SERVERS.NET.   3600000 IN      A       128.8.10.90
> >> ++E.ROOT-SERVERS.NET.   3600000 IN      A       192.203.230.10
> >> ++F.ROOT-SERVERS.NET.   3600000 IN      A       192.5.5.241
> >> ++G.ROOT-SERVERS.NET.   3600000 IN      A       192.112.36.4
> >> ++H.ROOT-SERVERS.NET.   3600000 IN      A       128.63.2.53
> >> ++I.ROOT-SERVERS.NET.   3600000 IN      A       192.36.148.17
> >> ++J.ROOT-SERVERS.NET.   3600000 IN      A       192.58.128.30
> >> ++K.ROOT-SERVERS.NET.   3600000 IN      A       193.0.14.129
> >> ++L.ROOT-SERVERS.NET.   3600000 IN      A       198.32.64.12
> >> ++M.ROOT-SERVERS.NET.   3600000 IN      A       202.12.27.33
> >> ++
> >> ++;; Query time: 81 msec
> >> ++;; SERVER: 198.41.0.4#53(a.root-servers.net.)
> >> ++;; WHEN: Sun Feb  1 11:27:14 2004
> >> ++;; MSG SIZE  rcvd: 436
> >> ++
> >> +diff -urN bind-9.3.1.orig/conf/named.conf bind-9.3.1/conf/named.conf
> >> +--- bind-9.3.1.orig/conf/named.conf    1970-01-01 01:00:00.000000000 +0100
> >> ++++ bind-9.3.1/conf/named.conf 2005-07-10 22:33:46.000000000 +0200
> >> +@@ -0,0 +1,49 @@
> >> ++// This is the primary configuration file for the BIND DNS server named.
> >> ++//
> >> ++// If you are just adding zones, please do that in /etc/bind/named.conf.local
> >> ++
> >> ++include "/etc/bind/named.conf.options";
> >> ++
> >> ++// prime the server with knowledge of the root servers
> >> ++zone "." {
> >> ++      type hint;
> >> ++      file "/etc/bind/db.root";
> >> ++};
> >> ++
> >> ++// be authoritative for the localhost forward and reverse zones, and for
> >> ++// broadcast zones as per RFC 1912
> >> ++
> >> ++zone "localhost" {
> >> ++      type master;
> >> ++      file "/etc/bind/db.local";
> >> ++};
> >> ++
> >> ++zone "127.in-addr.arpa" {
> >> ++      type master;
> >> ++      file "/etc/bind/db.127";
> >> ++};
> >> ++
> >> ++zone "0.in-addr.arpa" {
> >> ++      type master;
> >> ++      file "/etc/bind/db.0";
> >> ++};
> >> ++
> >> ++zone "255.in-addr.arpa" {
> >> ++      type master;
> >> ++      file "/etc/bind/db.255";
> >> ++};
> >> ++
> >> ++// zone "com" { type delegation-only; };
> >> ++// zone "net" { type delegation-only; };
> >> ++
> >> ++// From the release notes:
> >> ++//  Because many of our users are uncomfortable receiving undelegated answers
> >> ++//  from root or top level domains, other than a few for whom that behaviour
> >> ++//  has been trusted and expected for quite some length of time, we have now
> >> ++//  introduced the "root-delegations-only" feature which applies delegation-only
> >> ++//  logic to all top level domains, and to the root domain.  An exception list
> >> ++//  should be specified, including "MUSEUM" and "DE", and any other top level
> >> ++//  domains from whom undelegated responses are expected and trusted.
> >> ++// root-delegation-only exclude { "DE"; "MUSEUM"; };
> >> ++
> >> ++include "/etc/bind/named.conf.local";
> >> +diff -urN bind-9.3.1.orig/conf/named.conf.local bind-9.3.1/conf/named.conf.local
> >> +--- bind-9.3.1.orig/conf/named.conf.local      1970-01-01 01:00:00.000000000 +0100
> >> ++++ bind-9.3.1/conf/named.conf.local   2005-07-10 22:14:06.000000000 +0200
> >> +@@ -0,0 +1,8 @@
> >> ++//
> >> ++// Do any local configuration here
> >> ++//
> >> ++
> >> ++// Consider adding the 1918 zones here, if they are not used in your
> >> ++// organization
> >> ++//include "/etc/bind/zones.rfc1918";
> >> ++
> >> +diff -urN bind-9.3.1.orig/conf/named.conf.options bind-9.3.1/conf/named.conf.options
> >> +--- bind-9.3.1.orig/conf/named.conf.options    1970-01-01 01:00:00.000000000 +0100
> >> ++++ bind-9.3.1/conf/named.conf.options 2005-07-10 22:14:06.000000000 +0200
> >> +@@ -0,0 +1,24 @@
> >> ++options {
> >> ++      directory "/var/cache/bind";
> >> ++
> >> ++      // If there is a firewall between you and nameservers you want
> >> ++      // to talk to, you might need to uncomment the query-source
> >> ++      // directive below.  Previous versions of BIND always asked
> >> ++      // questions using port 53, but BIND 8.1 and later use an unprivileged
> >> ++      // port by default.
> >> ++
> >> ++      // query-source address * port 53;
> >> ++
> >> ++      // If your ISP provided one or more IP addresses for stable
> >> ++      // nameservers, you probably want to use them as forwarders.
> >> ++      // Uncomment the following block, and insert the addresses replacing
> >> ++      // the all-0's placeholder.
> >> ++
> >> ++      // forwarders {
> >> ++      //      0.0.0.0;
> >> ++      // };
> >> ++
> >> ++      auth-nxdomain no;    # conform to RFC1035
> >> ++
> >> ++};
> >> ++
> >> +diff -urN bind-9.3.1.orig/conf/zones.rfc1918 bind-9.3.1/conf/zones.rfc1918
> >> +--- bind-9.3.1.orig/conf/zones.rfc1918 1970-01-01 01:00:00.000000000 +0100
> >> ++++ bind-9.3.1/conf/zones.rfc1918      2005-07-10 22:14:10.000000000 +0200
> >> +@@ -0,0 +1,20 @@
> >> ++zone "10.in-addr.arpa"      { type master; file "/etc/bind/db.empty"; };
> >> ++
> >> ++zone "16.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++zone "17.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++zone "18.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++zone "19.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++zone "20.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++zone "21.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++zone "22.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++zone "23.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++zone "24.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++zone "25.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++zone "26.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++zone "27.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++zone "28.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++zone "29.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++zone "30.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++zone "31.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >> ++
> >> ++zone "168.192.in-addr.arpa" { type master; file "/etc/bind/db.empty"; };
> >> +diff -urN bind-9.3.1.orig/init.d bind-9.3.1/init.d
> >> +--- bind-9.3.1.orig/init.d     1970-01-01 01:00:00.000000000 +0100
> >> ++++ bind-9.3.1/init.d  2005-07-10 23:09:58.000000000 +0200
> >> +@@ -0,0 +1,70 @@
> >> ++#!/bin/sh
> >> ++
> >> ++PATH=/sbin:/bin:/usr/sbin:/usr/bin
> >> ++
> >> ++# for a chrooted server: "-u bind -t /var/lib/named"
> >> ++# Don't modify this line, change or create /etc/default/bind9.
> >> ++OPTIONS=""
> >> ++
> >> ++test -f /etc/default/bind9 && . /etc/default/bind9
> >> ++
> >> ++test -x /usr/sbin/rndc || exit 0
> >> ++
> >> ++case "$1" in
> >> ++    start)
> >> ++      echo -n "Starting domain name service: named"
> >> ++
> >> ++      modprobe capability >/dev/null 2>&1 || true
> >> ++      if [ ! -f /etc/bind/rndc.key ]; then
> >> ++          /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
> >> ++          chmod 0640 /etc/bind/rndc.key
> >> ++      fi
> >> ++      if [ -f /var/run/named/named.pid ]; then
> >> ++          ps `cat /var/run/named/named.pid` > /dev/null && exit 1
> >> ++      fi
> >> ++
> >> ++      # dirs under /var/run can go away on reboots.
> >> ++      mkdir -p /var/run/named
> >> ++      mkdir -p /var/cache/bind
> >> ++      chmod 775 /var/run/named
> >> ++      chown root:bind /var/run/named >/dev/null 2>&1 || true
> >> ++
> >> ++      if [ ! -x /usr/sbin/named ]; then
> >> ++          echo "named binary missing - not starting"
> >> ++          exit 1
> >> ++      fi
> >> ++      if start-stop-daemon --start --quiet --exec /usr/sbin/named \
> >> ++              --pidfile /var/run/named/named.pid -- $OPTIONS; then
> >> ++          if [ -x /sbin/resolvconf ] ; then
> >> ++              echo "nameserver 127.0.0.1" | /sbin/resolvconf -a lo
> >> ++          fi
> >> ++      fi
> >> ++      echo "."
> >> ++    ;;
> >> ++
> >> ++    stop)
> >> ++      echo -n "Stopping domain name service: named"
> >> ++      if [ -x /sbin/resolvconf ]; then
> >> ++          /sbin/resolvconf -d lo
> >> ++      fi
> >> ++      /usr/sbin/rndc stop >/dev/null 2>&1
> >> ++      echo "."
> >> ++    ;;
> >> ++
> >> ++    reload)
> >> ++      /usr/sbin/rndc reload
> >> ++    ;;
> >> ++
> >> ++    restart|force-reload)
> >> ++      $0 stop
> >> ++      sleep 2
> >> ++      $0 start
> >> ++    ;;
> >> ++
> >> ++    *)
> >> ++      echo "Usage: /etc/init.d/bind {start|stop|reload|restart|force-reload}" >&2
> >> ++      exit 1
> >> ++    ;;
> >> ++esac
> >> ++
> >> ++exit 0
> >> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
> >> new file mode 100644
> >> index 00000000000..ef915c0ae5a
> >> --- /dev/null
> >> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
> >> @@ -0,0 +1,8 @@
> >> +#!/bin/sh
> >> +
> >> +if [ ! -s /etc/bind/rndc.key ]; then
> >> +    echo -n "Generating /etc/bind/rndc.key:"
> >> +    /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
> >> +    chown root:bind /etc/bind/rndc.key
> >> +    chmod 0640 /etc/bind/rndc.key
> >> +fi
> >> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
> >> new file mode 100644
> >> index 00000000000..11db95ede12
> >> --- /dev/null
> >> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
> >> @@ -0,0 +1,65 @@
> >> +Subject: init.d: add support for read-only rootfs
> >> +
> >> +Upstream-Status: Inappropriate [oe specific]
> >> +
> >> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
> >> +---
> >> + init.d |   40 ++++++++++++++++++++++++++++++++++++++++
> >> + 1 file changed, 40 insertions(+)
> >> +
> >> +diff --git a/init.d b/init.d
> >> +index 0111ed4..24677c8 100644
> >> +--- a/init.d
> >> ++++ b/init.d
> >> +@@ -6,8 +6,48 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin
> >> + # Don't modify this line, change or create /etc/default/bind9.
> >> + OPTIONS=""
> >> +
> >> ++test -f /etc/default/rcS && . /etc/default/rcS
> >> + test -f /etc/default/bind9 && . /etc/default/bind9
> >> +
> >> ++# This function is here because it's possible that /var and / are on different partitions.
> >> ++is_on_read_only_partition () {
> >> ++    DIRECTORY=$1
> >> ++    dir=`readlink -f $DIRECTORY`
> >> ++    while true; do
> >> ++      if [ ! -d "$dir" ]; then
> >> ++          echo "ERROR: $dir is not a directory"
> >> ++          exit 1
> >> ++      else
> >> ++          for flag in `awk -v dir=$dir '{ if ($2 == dir) { print "FOUND"; split($4,FLAGS,",") } }; \
> >> ++              END { for (f in FLAGS) print FLAGS[f] }' < /proc/mounts`; do
> >> ++              [ "$flag" = "FOUND" ] && partition="read-write"
> >> ++              [ "$flag" = "ro" ] && { partition="read-only"; break; }
> >> ++          done
> >> ++          if [ "$dir" = "/" -o -n "$partition" ]; then
> >> ++              break
> >> ++          else
> >> ++              dir=`dirname $dir`
> >> ++          fi
> >> ++      fi
> >> ++    done
> >> ++    [ "$partition" = "read-only" ] && echo "yes" || echo "no"
> >> ++}
> >> ++
> >> ++bind_mount () {
> >> ++    olddir=$1
> >> ++    newdir=$2
> >> ++    mkdir -p $olddir
> >> ++    cp -a $newdir/* $olddir
> >> ++    mount --bind $olddir $newdir
> >> ++}
> >> ++
> >> ++# Deal with read-only rootfs
> >> ++if [ "$ROOTFS_READ_ONLY" = "yes" ]; then
> >> ++    [ "$VERBOSE" != "no" ] && echo "WARN: start bind service in read-only rootfs"
> >> ++    [ `is_on_read_only_partition /etc/bind` = "yes" ] && bind_mount /var/volatile/bind/etc /etc/bind
> >> ++    [ `is_on_read_only_partition /var/named` = "yes" ] && bind_mount /var/volatile/bind/named /var/named
> >> ++fi
> >> ++
> >> + test -x /usr/sbin/rndc || exit 0
> >> +
> >> + case "$1" in
> >> +--
> >> +1.7.9.5
> >> +
> >> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
> >> new file mode 100644
> >> index 00000000000..146f3e35db6
> >> --- /dev/null
> >> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
> >> @@ -0,0 +1,42 @@
> >> +bind: make "/etc/init.d/bind stop" work
> >> +
> >> +Upstream-Status: Inappropriate [configuration]
> >> +
> >> +Add some configurations, make rndc command be able to controls
> >> +the named daemon.
> >> +
> >> +Signed-off-by: Roy Li <rongqing.li@windriver.com>
> >> +---
> >> + conf/named.conf |    5 +++++
> >> + conf/rndc.conf  |    5 +++++
> >> + 2 files changed, 10 insertions(+), 0 deletions(-)
> >> + create mode 100644 conf/rndc.conf
> >> +
> >> +diff --git a/conf/named.conf b/conf/named.conf
> >> +index 95829cf..c8899e7 100644
> >> +--- a/conf/named.conf
> >> ++++ b/conf/named.conf
> >> +@@ -47,3 +47,8 @@ zone "255.in-addr.arpa" {
> >> + // root-delegation-only exclude { "DE"; "MUSEUM"; };
> >> +
> >> + include "/etc/bind/named.conf.local";
> >> ++include "/etc/bind/rndc.key" ;
> >> ++controls {
> >> ++      inet 127.0.0.1 allow { localhost; }
> >> ++      keys { rndc-key; };
> >> ++};
> >> +diff --git a/conf/rndc.conf b/conf/rndc.conf
> >> +new file mode 100644
> >> +index 0000000..a0b481d
> >> +--- /dev/null
> >> ++++ b/conf/rndc.conf
> >> +@@ -0,0 +1,5 @@
> >> ++include "/etc/bind/rndc.key";
> >> ++options {
> >> ++      default-server  localhost;
> >> ++      default-key     rndc-key;
> >> ++};
> >> +
> >> +--
> >> +1.7.5.4
> >> +
> >> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/named.service b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
> >> new file mode 100644
> >> index 00000000000..cda56ef0150
> >> --- /dev/null
> >> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
> >> @@ -0,0 +1,22 @@
> >> +[Unit]
> >> +Description=Berkeley Internet Name Domain (DNS)
> >> +Wants=nss-lookup.target
> >> +Before=nss-lookup.target
> >> +After=network.target
> >> +
> >> +[Service]
> >> +Type=forking
> >> +EnvironmentFile=-/etc/default/bind9
> >> +PIDFile=/run/named/named.pid
> >> +
> >> +ExecStartPre=@SBINDIR@/generate-rndc-key.sh
> >> +ExecStart=@SBINDIR@/named $OPTIONS
> >> +
> >> +ExecReload=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc reload > /dev/null 2>&1 || @BASE_BINDIR@/kill -HUP $MAINPID'
> >> +
> >> +ExecStop=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc stop > /dev/null 2>&1 || @BASE_BINDIR@/kill -TERM $MAINPID'
> >> +
> >> +PrivateTmp=true
> >> +
> >> +[Install]
> >> +WantedBy=multi-user.target
> >> diff --git a/meta/recipes-connectivity/bind/bind_9.16.5.bb b/meta/recipes-connectivity/bind/bind_9.16.5.bb
> >> new file mode 100644
> >> index 00000000000..9c20ccc6fa2
> >> --- /dev/null
> >> +++ b/meta/recipes-connectivity/bind/bind_9.16.5.bb
> >> @@ -0,0 +1,125 @@
> >> +SUMMARY = "ISC Internet Domain Name Server"
> >> +HOMEPAGE = "http://www.isc.org/sw/bind/"
> >> +SECTION = "console/network"
> >> +
> >> +LICENSE = "MPL-2.0"
> >> +LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=188b8d0644bd6835df43b84e3f180be1"
> >> +
> >> +DEPENDS = "openssl libcap zlib libuv"
> >> +
> >> +SRC_URI = "https://ftp.isc.org/isc/bind9/${PV}/${BPN}-${PV}.tar.xz \
> >> +           file://conf.patch \
> >> +           file://named.service \
> >> +           file://bind9 \
> >> +           file://generate-rndc-key.sh \
> >> +           file://make-etc-initd-bind-stop-work.patch \
> >> +           file://init.d-add-support-for-read-only-rootfs.patch \
> >> +           file://bind-ensure-searching-for-json-headers-searches-sysr.patch \
> >> +           file://0001-named-lwresd-V-and-start-log-hide-build-options.patch \
> >> +           file://0001-avoid-start-failure-with-bind-user.patch \
> >> +           "
> >> +
> >> +SRC_URI[sha256sum] = "6378b3e51fef11a8be4794dc48e8111ba92d211c0dfd129a0c296ed06a3dc075"
> >> +
> >> +UPSTREAM_CHECK_URI = "https://ftp.isc.org/isc/bind9/"
> >> +# stay at 9.16 follow the ESV versions divisible by 4
> >> +UPSTREAM_CHECK_REGEX = "(?P<pver>9.(16|20|24|28)(\.\d+)+(-P\d+)*)/"
> >> +
> >> +inherit autotools update-rc.d systemd useradd pkgconfig multilib_script multilib_header
> >> +
> >> +MULTILIB_SCRIPTS = "${PN}:${bindir}/bind9-config ${PN}:${bindir}/isc-config.sh"
> >> +
> >> +# PACKAGECONFIGs readline and libedit should NOT be set at same time
> >> +PACKAGECONFIG ?= "readline"
> >> +PACKAGECONFIG[httpstats] = "--with-libxml2=${STAGING_DIR_HOST}${prefix},--without-libxml2,libxml2"
> >> +PACKAGECONFIG[readline] = "--with-readline=-lreadline,,readline"
> >> +PACKAGECONFIG[libedit] = "--with-readline=-ledit,,libedit"
> >> +PACKAGECONFIG[python3] = "--with-python=yes --with-python-install-dir=${PYTHON_SITEPACKAGES_DIR} , --without-python, python3-ply-native,"
> >> +
> >> +EXTRA_OECONF = " --with-libtool --disable-devpoll --enable-epoll \
> >> +                 --with-gssapi=no --with-lmdb=no --with-zlib \
> >> +                 --sysconfdir=${sysconfdir}/bind \
> >> +                 --with-openssl=${STAGING_DIR_HOST}${prefix} \
> >> +               "
> >> +LDFLAGS_append = " -lz"
> >> +
> >> +inherit ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3native distutils3-base', '', d)}
> >> +
> >> +# dhcp needs .la so keep them
> >> +REMOVE_LIBTOOL_LA = "0"
> >> +
> >> +USERADD_PACKAGES = "${PN}"
> >> +USERADD_PARAM_${PN} = "--system --home ${localstatedir}/cache/bind --no-create-home \
> >> +                       --user-group bind"
> >> +
> >> +INITSCRIPT_NAME = "bind"
> >> +INITSCRIPT_PARAMS = "defaults"
> >> +
> >> +SYSTEMD_SERVICE_${PN} = "named.service"
> >> +
> >> +do_install_append() {
> >> +
> >> +       rmdir "${D}${localstatedir}/run"
> >> +       rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
> >> +       install -d -o bind "${D}${localstatedir}/cache/bind"
> >> +       install -d "${D}${sysconfdir}/bind"
> >> +       install -d "${D}${sysconfdir}/init.d"
> >> +       install -m 644 ${S}/conf/* "${D}${sysconfdir}/bind/"
> >> +       install -m 755 "${S}/init.d" "${D}${sysconfdir}/init.d/bind"
> >> +        if ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'true', 'false', d)}; then
> >> +               sed -i -e '1s,#!.*python3,#! /usr/bin/python3,' \
> >> +               ${D}${sbindir}/dnssec-coverage \
> >> +               ${D}${sbindir}/dnssec-checkds \
> >> +               ${D}${sbindir}/dnssec-keymgr
> >> +       fi
> >> +
> >> +       # Install systemd related files
> >> +       install -d ${D}${sbindir}
> >> +       install -m 755 ${WORKDIR}/generate-rndc-key.sh ${D}${sbindir}
> >> +       install -d ${D}${systemd_unitdir}/system
> >> +       install -m 0644 ${WORKDIR}/named.service ${D}${systemd_unitdir}/system
> >> +       sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
> >> +              -e 's,@SBINDIR@,${sbindir},g' \
> >> +              ${D}${systemd_unitdir}/system/named.service
> >> +
> >> +       install -d ${D}${sysconfdir}/default
> >> +       install -m 0644 ${WORKDIR}/bind9 ${D}${sysconfdir}/default
> >> +
> >> +       if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
> >> +               install -d ${D}${sysconfdir}/tmpfiles.d
> >> +               echo "d /run/named 0755 bind bind - -" > ${D}${sysconfdir}/tmpfiles.d/bind.conf
> >> +       fi
> >> +
> >> +    oe_multilib_header isc/platform.h
> >> +}
> >> +
> >> +CONFFILES_${PN} = " \
> >> +       ${sysconfdir}/bind/named.conf \
> >> +       ${sysconfdir}/bind/named.conf.local \
> >> +       ${sysconfdir}/bind/named.conf.options \
> >> +       ${sysconfdir}/bind/db.0 \
> >> +       ${sysconfdir}/bind/db.127 \
> >> +       ${sysconfdir}/bind/db.empty \
> >> +       ${sysconfdir}/bind/db.local \
> >> +       ${sysconfdir}/bind/db.root \
> >> +       "
> >> +
> >> +ALTERNATIVE_${PN}-utils = "nslookup"
> >> +ALTERNATIVE_LINK_NAME[nslookup] = "${bindir}/nslookup"
> >> +ALTERNATIVE_PRIORITY = "100"
> > I'm seeing this failing with busybox:
> > update-alternatives: Error: not linking
> > /development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
> > to /bin/busybox.nosuid since
> > /development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
> > exists and is not a link
> >
> > busybox sets ALTERNATIVE_PRIORITY = "50". Can this be the issue?
>
> That is weird. I would have expected that to be an issue with the old
> version too.
>
> Got any steps to reproduce this?

Sorry for delayed response here, it took me some time but I've finally
figured the setup to reproduce the issue.

I've used the "vanilla" Poky from master, added IMAGE_INSTALL +=
"bind-utils" to core-image-minimal and switched from RPM to IPK
format. The last thing turned out to be the trigger for the issue, as
with RPM package format I was not able to reproduce the issue, and
this was cause of the delay here.

After the above is done - following error is produced:
WARNING: core-image-minimal-1.0-r0 do_rootfs: busybox.postinst
returned 1, marking as unpacked only, configuration required on
target.
ERROR: core-image-minimal-1.0-r0 do_rootfs: Postinstall scriptlets of
['busybox'] have failed. If the intention is to defer them to first
boot,
then please place them into pkg_postinst_ontarget_${PN} ().
Deferring to first boot via 'exit 1' is no longer supported.
Details of the failure are in
/development/projects/poky-vanilla/poky/build/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/temp/log.do_rootfs.
ERROR: Logfile of failure stored in:
/development/projects/poky-vanilla/poky/build/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/temp/log.do_rootfs.6423
ERROR: Task (/development/projects/poky-vanilla/poky/meta/recipes-core/images/core-image-minimal.bb:do_rootfs)
failed with exit code '1'
NOTE: Tasks Summary: Attempted 3554 tasks of which 3552 didn't need to
be rerun and 1 failed.

Summary: 1 task failed:
  /development/projects/poky-vanilla/poky/meta/recipes-core/images/core-image-minimal.bb:do_rootfs
ed:

'nslookup' is definitely comming from the bind-utils package, and the
only thing I've noted so far it that in bind-9.11.22 result binary
name in ${D} is [nslookup.bind], which is different from the one
provided in bind-9.16.5 - [nslookup].

In case of previous bind version - both versions seems to be
installed, and the symlink is fixed onto the nslookup.bind. In the
current version though - I guess that the real binary is installed
instead, making symlink operation to fail during update-alternative.



>
> -armin
> >
> > Going back to bind 9.11.22 seems to solve it...
> >
> >> +
> >> +PACKAGE_BEFORE_PN += "${PN}-utils"
> >> +FILES_${PN}-utils = "${bindir}/host ${bindir}/dig ${bindir}/mdig ${bindir}/nslookup ${bindir}/nsupdate"
> >> +FILES_${PN}-dev += "${bindir}/isc-config.h"
> >> +FILES_${PN} += "${sbindir}/generate-rndc-key.sh"
> >> +
> >> +PACKAGE_BEFORE_PN += "${PN}-libs"
> >> +FILES_${PN}-libs = "${libdir}/*.so* ${libdir}/named/*.so*"
> >> +FILES_${PN}-staticdev += "${libdir}/*.la"
> >> +
> >> +PACKAGE_BEFORE_PN += "${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3-bind', '', d)}"
> >> +FILES_python3-bind = "${sbindir}/dnssec-coverage ${sbindir}/dnssec-checkds \
> >> +                ${sbindir}/dnssec-keymgr ${PYTHON_SITEPACKAGES_DIR}"
> >> +
> >> +RDEPENDS_${PN}-dev = ""
> >> +RDEPENDS_python3-bind = "python3-core python3-ply"
> >> --
> >> 2.17.1
> >>
> >> 
> >
> >
>


--
Regards,
Andrey.

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [OE-core] [PATCH 7/8] bind: Add 9.16.x
  2020-09-07 21:17       ` Andrey Zhizhikin
@ 2020-09-09 23:53         ` Khem Raj
  2020-09-10  7:12           ` Andrey Zhizhikin
  0 siblings, 1 reply; 24+ messages in thread
From: Khem Raj @ 2020-09-09 23:53 UTC (permalink / raw)
  To: Andrey Zhizhikin, akuster808; +Cc: OE Core mailing list


[-- Attachment #1.1: Type: text/plain, Size: 39837 bytes --]



On 9/7/20 2:17 PM, Andrey Zhizhikin wrote:
> On Mon, Sep 7, 2020 at 5:28 PM akuster808 <akuster808@gmail.com> wrote:
>>
>>
>>
>> On 9/4/20 1:39 AM, Andrey Zhizhikin wrote:
>>> Hello Armin,
>>>
>>> On Tue, Sep 1, 2020 at 5:23 PM akuster <akuster808@gmail.com> wrote:
>>>> Removed obsolete packageconfig options
>>>>
>>>> License change to MPL-2.0
>>>> https://gitlab.isc.org/isc-projects/bind9/blob/master/LICENSE
>>>>
>>>> Refreshed:
>>>> bind-ensure-searching-for-json-headers-searches-sysr.patch
>>>> 0001-named-lwresd-V-and-start-log-hide-build-options.patch
>>>> bind-ensure-searching-for-json-headers-searches-sysr.patch
>>>>
>>>> Drop obsolete patch: 0001-configure.in-remove-useless-L-use_openssl-lib.patch
>>>>
>>>> Signed-off-by: Armin Kuster <akuster808@gmail.com>
>>>> ---
>>>>  ...1-avoid-start-failure-with-bind-user.patch |  27 ++
>>>>  ...d-V-and-start-log-hide-build-options.patch |  35 ++
>>>>  ...ching-for-json-headers-searches-sysr.patch |  47 +++
>>>>  .../bind/bind-9.16.5/bind9                    |   2 +
>>>>  .../bind/bind-9.16.5/conf.patch               | 330 ++++++++++++++++++
>>>>  .../bind/bind-9.16.5/generate-rndc-key.sh     |   8 +
>>>>  ...t.d-add-support-for-read-only-rootfs.patch |  65 ++++
>>>>  .../make-etc-initd-bind-stop-work.patch       |  42 +++
>>>>  .../bind/bind-9.16.5/named.service            |  22 ++
>>>>  meta/recipes-connectivity/bind/bind_9.16.5.bb | 125 +++++++
>>>>  10 files changed, 703 insertions(+)
>>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
>>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
>>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
>>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind9
>>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
>>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
>>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
>>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
>>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/named.service
>>>>  create mode 100644 meta/recipes-connectivity/bind/bind_9.16.5.bb
>>>>
>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
>>>> new file mode 100644
>>>> index 00000000000..8db96ec049c
>>>> --- /dev/null
>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
>>>> @@ -0,0 +1,27 @@
>>>> +From 31dde3562f287429eea94b77250d184818b49063 Mon Sep 17 00:00:00 2001
>>>> +From: Chen Qi <Qi.Chen@windriver.com>
>>>> +Date: Mon, 15 Oct 2018 16:55:09 +0800
>>>> +Subject: [PATCH] avoid start failure with bind user
>>>> +
>>>> +Upstream-Status: Pending
>>>> +
>>>> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
>>>> +---
>>>> + init.d | 1 +
>>>> + 1 file changed, 1 insertion(+)
>>>> +
>>>> +diff --git a/init.d b/init.d
>>>> +index b2eec60..6e03936 100644
>>>> +--- a/init.d
>>>> ++++ b/init.d
>>>> +@@ -57,6 +57,7 @@ case "$1" in
>>>> +       modprobe capability >/dev/null 2>&1 || true
>>>> +       if [ ! -f /etc/bind/rndc.key ]; then
>>>> +           /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
>>>> ++          chown root:bind /etc/bind/rndc.key >/dev/null 2>&1 || true
>>>> +           chmod 0640 /etc/bind/rndc.key
>>>> +       fi
>>>> +       if [ -f /var/run/named/named.pid ]; then
>>>> +--
>>>> +2.7.4
>>>> +
>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
>>>> new file mode 100644
>>>> index 00000000000..5bcc16c9b2b
>>>> --- /dev/null
>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
>>>> @@ -0,0 +1,35 @@
>>>> +From a3af4a405baf5ff582e82aaba392dd9667d94bdc Mon Sep 17 00:00:00 2001
>>>> +From: Hongxu Jia <hongxu.jia@windriver.com>
>>>> +Date: Mon, 27 Aug 2018 21:24:20 +0800
>>>> +Subject: [PATCH] `named/lwresd -V' and start log hide build options
>>>> +
>>>> +The build options expose build path directories, so hide them.
>>>> +[snip]
>>>> +$ named -V
>>>> +|built by make with *** (options are hidden)
>>>> +[snip]
>>>> +
>>>> +Upstream-Status: Inappropriate [oe-core specific]
>>>> +
>>>> +Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>>>> +
>>>> +Refreshed for 9.16.0
>>>> +Signed-off-by: Armin Kuster <akuster@mvista.com>
>>>> +
>>>> +---
>>>> + bin/named/include/named/globals.h | 2 +-
>>>> + 1 file changed, 1 insertion(+), 1 deletion(-)
>>>> +
>>>> +Index: bind-9.16.0/bin/named/include/named/globals.h
>>>> +===================================================================
>>>> +--- bind-9.16.0.orig/bin/named/include/named/globals.h
>>>> ++++ bind-9.16.0/bin/named/include/named/globals.h
>>>> +@@ -69,7 +69,7 @@ EXTERN const char *named_g_version     I
>>>> + EXTERN const char *named_g_product     INIT(PRODUCT);
>>>> + EXTERN const char *named_g_description INIT(DESCRIPTION);
>>>> + EXTERN const char *named_g_srcid       INIT(SRCID);
>>>> +-EXTERN const char *named_g_configargs  INIT(CONFIGARGS);
>>>> ++EXTERN const char *named_g_configargs  INIT("*** (options are hidden)");
>>>> + EXTERN const char *named_g_builder     INIT(BUILDER);
>>>> + EXTERN in_port_t named_g_port        INIT(0);
>>>> + EXTERN isc_dscp_t named_g_dscp               INIT(-1);
>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
>>>> new file mode 100644
>>>> index 00000000000..f9cdc7ca4df
>>>> --- /dev/null
>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
>>>> @@ -0,0 +1,47 @@
>>>> +From edda20fb5a6e88548f85e39d34d6c074306e15bc Mon Sep 17 00:00:00 2001
>>>> +From: Paul Gortmaker <paul.gortmaker@windriver.com>
>>>> +Date: Tue, 9 Jun 2015 11:22:00 -0400
>>>> +Subject: [PATCH] bind: ensure searching for json headers searches sysroot
>>>> +
>>>> +Bind can fail configure by detecting headers w/o libs[1], or
>>>> +it can fail the host contamination check as per below:
>>>> +
>>>> +ERROR: This autoconf log indicates errors, it looked at host include and/or library paths while determining system capabilities.
>>>> +Rerun configure task after fixing this. The path was 'build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/build'
>>>> +ERROR: Function failed: do_qa_configure
>>>> +ERROR: Logfile of failure stored in: build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/temp/log.do_configure.5242
>>>> +ERROR: Task 5 (meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure) failed with exit code '1'
>>>> +NOTE: Tasks Summary: Attempted 773 tasks of which 768 didn't need to be rerun and 1 failed.
>>>> +No currently running tasks (773 of 781)
>>>> +
>>>> +Summary: 1 task failed:
>>>> +  /meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure
>>>> +
>>>> +One way to fix it would be to unconditionally disable json in bind
>>>> +configure[2] but here we fix it by using the path to where we would
>>>> +put the header if we had json in the sysroot, in case someone wants
>>>> +to make use of the combination some day.
>>>> +
>>>> +[1] https://trac.macports.org/ticket/45305
>>>> +[2] https://trac.macports.org/changeset/126406
>>>> +
>>>> +Upstream-Status: Inappropriate [OE Specific]
>>>> +Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
>>>> +
>>>> +---
>>>> + configure.ac | 2 +-
>>>> + 1 file changed, 1 insertion(+), 1 deletion(-)
>>>> +
>>>> +Index: bind-9.16.4/configure.ac
>>>> +===================================================================
>>>> +--- bind-9.16.4.orig/configure.ac
>>>> ++++ bind-9.16.4/configure.ac
>>>> +@@ -1232,7 +1232,7 @@ case "$use_lmdb" in
>>>> +               LMDB_LIBS=""
>>>> +               ;;
>>>> +       auto|yes)
>>>> +-              for d in /usr /usr/local /opt/local
>>>> ++              for d in "${STAGING_INCDIR}"
>>>> +               do
>>>> +                       if test -f "${d}/include/lmdb.h"
>>>> +                       then
>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind9 b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
>>>> new file mode 100644
>>>> index 00000000000..968679ff7f7
>>>> --- /dev/null
>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
>>>> @@ -0,0 +1,2 @@
>>>> +# startup options for the server
>>>> +OPTIONS="-u bind"
>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
>>>> new file mode 100644
>>>> index 00000000000..aad345f9fcf
>>>> --- /dev/null
>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
>>>> @@ -0,0 +1,330 @@
>>>> +Upstream-Status: Inappropriate [configuration]
>>>> +
>>>> +the patch is imported from openembedded project
>>>> +
>>>> +11/30/2010 - Qing He <qing.he@intel.com>
>>>> +
>>>> +diff -urN bind-9.3.1.orig/conf/db.0 bind-9.3.1/conf/db.0
>>>> +--- bind-9.3.1.orig/conf/db.0  1970-01-01 01:00:00.000000000 +0100
>>>> ++++ bind-9.3.1/conf/db.0       2005-07-10 22:14:00.000000000 +0200
>>>> +@@ -0,0 +1,12 @@
>>>> ++;
>>>> ++; BIND reverse data file for broadcast zone
>>>> ++;
>>>> ++$TTL  604800
>>>> ++@     IN      SOA     localhost. root.localhost. (
>>>> ++                            1         ; Serial
>>>> ++                       604800         ; Refresh
>>>> ++                        86400         ; Retry
>>>> ++                      2419200         ; Expire
>>>> ++                       604800 )       ; Negative Cache TTL
>>>> ++;
>>>> ++@     IN      NS      localhost.
>>>> +diff -urN bind-9.3.1.orig/conf/db.127 bind-9.3.1/conf/db.127
>>>> +--- bind-9.3.1.orig/conf/db.127        1970-01-01 01:00:00.000000000 +0100
>>>> ++++ bind-9.3.1/conf/db.127     2005-07-10 22:14:00.000000000 +0200
>>>> +@@ -0,0 +1,13 @@
>>>> ++;
>>>> ++; BIND reverse data file for local loopback interface
>>>> ++;
>>>> ++$TTL  604800
>>>> ++@     IN      SOA     localhost. root.localhost. (
>>>> ++                            1         ; Serial
>>>> ++                       604800         ; Refresh
>>>> ++                        86400         ; Retry
>>>> ++                      2419200         ; Expire
>>>> ++                       604800 )       ; Negative Cache TTL
>>>> ++;
>>>> ++@     IN      NS      localhost.
>>>> ++1.0.0 IN      PTR     localhost.
>>>> +diff -urN bind-9.3.1.orig/conf/db.empty bind-9.3.1/conf/db.empty
>>>> +--- bind-9.3.1.orig/conf/db.empty      1970-01-01 01:00:00.000000000 +0100
>>>> ++++ bind-9.3.1/conf/db.empty   2005-07-10 22:14:00.000000000 +0200
>>>> +@@ -0,0 +1,14 @@
>>>> ++; BIND reverse data file for empty rfc1918 zone
>>>> ++;
>>>> ++; DO NOT EDIT THIS FILE - it is used for multiple zones.
>>>> ++; Instead, copy it, edit named.conf, and use that copy.
>>>> ++;
>>>> ++$TTL  86400
>>>> ++@     IN      SOA     localhost. root.localhost. (
>>>> ++                            1         ; Serial
>>>> ++                       604800         ; Refresh
>>>> ++                        86400         ; Retry
>>>> ++                      2419200         ; Expire
>>>> ++                        86400 )       ; Negative Cache TTL
>>>> ++;
>>>> ++@     IN      NS      localhost.
>>>> +diff -urN bind-9.3.1.orig/conf/db.255 bind-9.3.1/conf/db.255
>>>> +--- bind-9.3.1.orig/conf/db.255        1970-01-01 01:00:00.000000000 +0100
>>>> ++++ bind-9.3.1/conf/db.255     2005-07-10 22:14:00.000000000 +0200
>>>> +@@ -0,0 +1,12 @@
>>>> ++;
>>>> ++; BIND reserve data file for broadcast zone
>>>> ++;
>>>> ++$TTL  604800
>>>> ++@     IN      SOA     localhost. root.localhost. (
>>>> ++                            1         ; Serial
>>>> ++                       604800         ; Refresh
>>>> ++                        86400         ; Retry
>>>> ++                      2419200         ; Expire
>>>> ++                       604800 )       ; Negative Cache TTL
>>>> ++;
>>>> ++@     IN      NS      localhost.
>>>> +diff -urN bind-9.3.1.orig/conf/db.local bind-9.3.1/conf/db.local
>>>> +--- bind-9.3.1.orig/conf/db.local      1970-01-01 01:00:00.000000000 +0100
>>>> ++++ bind-9.3.1/conf/db.local   2005-07-10 22:14:00.000000000 +0200
>>>> +@@ -0,0 +1,13 @@
>>>> ++;
>>>> ++; BIND data file for local loopback interface
>>>> ++;
>>>> ++$TTL  604800
>>>> ++@     IN      SOA     localhost. root.localhost. (
>>>> ++                            1         ; Serial
>>>> ++                       604800         ; Refresh
>>>> ++                        86400         ; Retry
>>>> ++                      2419200         ; Expire
>>>> ++                       604800 )       ; Negative Cache TTL
>>>> ++;
>>>> ++@     IN      NS      localhost.
>>>> ++@     IN      A       127.0.0.1
>>>> +diff -urN bind-9.3.1.orig/conf/db.root bind-9.3.1/conf/db.root
>>>> +--- bind-9.3.1.orig/conf/db.root       1970-01-01 01:00:00.000000000 +0100
>>>> ++++ bind-9.3.1/conf/db.root    2005-07-10 22:14:00.000000000 +0200
>>>> +@@ -0,0 +1,45 @@
>>>> ++
>>>> ++; <<>> DiG 9.2.3 <<>> ns . @a.root-servers.net.
>>>> ++;; global options:  printcmd
>>>> ++;; Got answer:
>>>> ++;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 18944
>>>> ++;; flags: qr aa rd; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 13
>>>> ++
>>>> ++;; QUESTION SECTION:
>>>> ++;.                            IN      NS
>>>> ++
>>>> ++;; ANSWER SECTION:
>>>> ++.                     518400  IN      NS      A.ROOT-SERVERS.NET.
>>>> ++.                     518400  IN      NS      B.ROOT-SERVERS.NET.
>>>> ++.                     518400  IN      NS      C.ROOT-SERVERS.NET.
>>>> ++.                     518400  IN      NS      D.ROOT-SERVERS.NET.
>>>> ++.                     518400  IN      NS      E.ROOT-SERVERS.NET.
>>>> ++.                     518400  IN      NS      F.ROOT-SERVERS.NET.
>>>> ++.                     518400  IN      NS      G.ROOT-SERVERS.NET.
>>>> ++.                     518400  IN      NS      H.ROOT-SERVERS.NET.
>>>> ++.                     518400  IN      NS      I.ROOT-SERVERS.NET.
>>>> ++.                     518400  IN      NS      J.ROOT-SERVERS.NET.
>>>> ++.                     518400  IN      NS      K.ROOT-SERVERS.NET.
>>>> ++.                     518400  IN      NS      L.ROOT-SERVERS.NET.
>>>> ++.                     518400  IN      NS      M.ROOT-SERVERS.NET.
>>>> ++
>>>> ++;; ADDITIONAL SECTION:
>>>> ++A.ROOT-SERVERS.NET.   3600000 IN      A       198.41.0.4
>>>> ++B.ROOT-SERVERS.NET.   3600000 IN      A       192.228.79.201
>>>> ++C.ROOT-SERVERS.NET.   3600000 IN      A       192.33.4.12
>>>> ++D.ROOT-SERVERS.NET.   3600000 IN      A       128.8.10.90
>>>> ++E.ROOT-SERVERS.NET.   3600000 IN      A       192.203.230.10
>>>> ++F.ROOT-SERVERS.NET.   3600000 IN      A       192.5.5.241
>>>> ++G.ROOT-SERVERS.NET.   3600000 IN      A       192.112.36.4
>>>> ++H.ROOT-SERVERS.NET.   3600000 IN      A       128.63.2.53
>>>> ++I.ROOT-SERVERS.NET.   3600000 IN      A       192.36.148.17
>>>> ++J.ROOT-SERVERS.NET.   3600000 IN      A       192.58.128.30
>>>> ++K.ROOT-SERVERS.NET.   3600000 IN      A       193.0.14.129
>>>> ++L.ROOT-SERVERS.NET.   3600000 IN      A       198.32.64.12
>>>> ++M.ROOT-SERVERS.NET.   3600000 IN      A       202.12.27.33
>>>> ++
>>>> ++;; Query time: 81 msec
>>>> ++;; SERVER: 198.41.0.4#53(a.root-servers.net.)
>>>> ++;; WHEN: Sun Feb  1 11:27:14 2004
>>>> ++;; MSG SIZE  rcvd: 436
>>>> ++
>>>> +diff -urN bind-9.3.1.orig/conf/named.conf bind-9.3.1/conf/named.conf
>>>> +--- bind-9.3.1.orig/conf/named.conf    1970-01-01 01:00:00.000000000 +0100
>>>> ++++ bind-9.3.1/conf/named.conf 2005-07-10 22:33:46.000000000 +0200
>>>> +@@ -0,0 +1,49 @@
>>>> ++// This is the primary configuration file for the BIND DNS server named.
>>>> ++//
>>>> ++// If you are just adding zones, please do that in /etc/bind/named.conf.local
>>>> ++
>>>> ++include "/etc/bind/named.conf.options";
>>>> ++
>>>> ++// prime the server with knowledge of the root servers
>>>> ++zone "." {
>>>> ++      type hint;
>>>> ++      file "/etc/bind/db.root";
>>>> ++};
>>>> ++
>>>> ++// be authoritative for the localhost forward and reverse zones, and for
>>>> ++// broadcast zones as per RFC 1912
>>>> ++
>>>> ++zone "localhost" {
>>>> ++      type master;
>>>> ++      file "/etc/bind/db.local";
>>>> ++};
>>>> ++
>>>> ++zone "127.in-addr.arpa" {
>>>> ++      type master;
>>>> ++      file "/etc/bind/db.127";
>>>> ++};
>>>> ++
>>>> ++zone "0.in-addr.arpa" {
>>>> ++      type master;
>>>> ++      file "/etc/bind/db.0";
>>>> ++};
>>>> ++
>>>> ++zone "255.in-addr.arpa" {
>>>> ++      type master;
>>>> ++      file "/etc/bind/db.255";
>>>> ++};
>>>> ++
>>>> ++// zone "com" { type delegation-only; };
>>>> ++// zone "net" { type delegation-only; };
>>>> ++
>>>> ++// From the release notes:
>>>> ++//  Because many of our users are uncomfortable receiving undelegated answers
>>>> ++//  from root or top level domains, other than a few for whom that behaviour
>>>> ++//  has been trusted and expected for quite some length of time, we have now
>>>> ++//  introduced the "root-delegations-only" feature which applies delegation-only
>>>> ++//  logic to all top level domains, and to the root domain.  An exception list
>>>> ++//  should be specified, including "MUSEUM" and "DE", and any other top level
>>>> ++//  domains from whom undelegated responses are expected and trusted.
>>>> ++// root-delegation-only exclude { "DE"; "MUSEUM"; };
>>>> ++
>>>> ++include "/etc/bind/named.conf.local";
>>>> +diff -urN bind-9.3.1.orig/conf/named.conf.local bind-9.3.1/conf/named.conf.local
>>>> +--- bind-9.3.1.orig/conf/named.conf.local      1970-01-01 01:00:00.000000000 +0100
>>>> ++++ bind-9.3.1/conf/named.conf.local   2005-07-10 22:14:06.000000000 +0200
>>>> +@@ -0,0 +1,8 @@
>>>> ++//
>>>> ++// Do any local configuration here
>>>> ++//
>>>> ++
>>>> ++// Consider adding the 1918 zones here, if they are not used in your
>>>> ++// organization
>>>> ++//include "/etc/bind/zones.rfc1918";
>>>> ++
>>>> +diff -urN bind-9.3.1.orig/conf/named.conf.options bind-9.3.1/conf/named.conf.options
>>>> +--- bind-9.3.1.orig/conf/named.conf.options    1970-01-01 01:00:00.000000000 +0100
>>>> ++++ bind-9.3.1/conf/named.conf.options 2005-07-10 22:14:06.000000000 +0200
>>>> +@@ -0,0 +1,24 @@
>>>> ++options {
>>>> ++      directory "/var/cache/bind";
>>>> ++
>>>> ++      // If there is a firewall between you and nameservers you want
>>>> ++      // to talk to, you might need to uncomment the query-source
>>>> ++      // directive below.  Previous versions of BIND always asked
>>>> ++      // questions using port 53, but BIND 8.1 and later use an unprivileged
>>>> ++      // port by default.
>>>> ++
>>>> ++      // query-source address * port 53;
>>>> ++
>>>> ++      // If your ISP provided one or more IP addresses for stable
>>>> ++      // nameservers, you probably want to use them as forwarders.
>>>> ++      // Uncomment the following block, and insert the addresses replacing
>>>> ++      // the all-0's placeholder.
>>>> ++
>>>> ++      // forwarders {
>>>> ++      //      0.0.0.0;
>>>> ++      // };
>>>> ++
>>>> ++      auth-nxdomain no;    # conform to RFC1035
>>>> ++
>>>> ++};
>>>> ++
>>>> +diff -urN bind-9.3.1.orig/conf/zones.rfc1918 bind-9.3.1/conf/zones.rfc1918
>>>> +--- bind-9.3.1.orig/conf/zones.rfc1918 1970-01-01 01:00:00.000000000 +0100
>>>> ++++ bind-9.3.1/conf/zones.rfc1918      2005-07-10 22:14:10.000000000 +0200
>>>> +@@ -0,0 +1,20 @@
>>>> ++zone "10.in-addr.arpa"      { type master; file "/etc/bind/db.empty"; };
>>>> ++
>>>> ++zone "16.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++zone "17.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++zone "18.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++zone "19.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++zone "20.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++zone "21.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++zone "22.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++zone "23.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++zone "24.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++zone "25.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++zone "26.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++zone "27.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++zone "28.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++zone "29.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++zone "30.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++zone "31.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>> ++
>>>> ++zone "168.192.in-addr.arpa" { type master; file "/etc/bind/db.empty"; };
>>>> +diff -urN bind-9.3.1.orig/init.d bind-9.3.1/init.d
>>>> +--- bind-9.3.1.orig/init.d     1970-01-01 01:00:00.000000000 +0100
>>>> ++++ bind-9.3.1/init.d  2005-07-10 23:09:58.000000000 +0200
>>>> +@@ -0,0 +1,70 @@
>>>> ++#!/bin/sh
>>>> ++
>>>> ++PATH=/sbin:/bin:/usr/sbin:/usr/bin
>>>> ++
>>>> ++# for a chrooted server: "-u bind -t /var/lib/named"
>>>> ++# Don't modify this line, change or create /etc/default/bind9.
>>>> ++OPTIONS=""
>>>> ++
>>>> ++test -f /etc/default/bind9 && . /etc/default/bind9
>>>> ++
>>>> ++test -x /usr/sbin/rndc || exit 0
>>>> ++
>>>> ++case "$1" in
>>>> ++    start)
>>>> ++      echo -n "Starting domain name service: named"
>>>> ++
>>>> ++      modprobe capability >/dev/null 2>&1 || true
>>>> ++      if [ ! -f /etc/bind/rndc.key ]; then
>>>> ++          /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
>>>> ++          chmod 0640 /etc/bind/rndc.key
>>>> ++      fi
>>>> ++      if [ -f /var/run/named/named.pid ]; then
>>>> ++          ps `cat /var/run/named/named.pid` > /dev/null && exit 1
>>>> ++      fi
>>>> ++
>>>> ++      # dirs under /var/run can go away on reboots.
>>>> ++      mkdir -p /var/run/named
>>>> ++      mkdir -p /var/cache/bind
>>>> ++      chmod 775 /var/run/named
>>>> ++      chown root:bind /var/run/named >/dev/null 2>&1 || true
>>>> ++
>>>> ++      if [ ! -x /usr/sbin/named ]; then
>>>> ++          echo "named binary missing - not starting"
>>>> ++          exit 1
>>>> ++      fi
>>>> ++      if start-stop-daemon --start --quiet --exec /usr/sbin/named \
>>>> ++              --pidfile /var/run/named/named.pid -- $OPTIONS; then
>>>> ++          if [ -x /sbin/resolvconf ] ; then
>>>> ++              echo "nameserver 127.0.0.1" | /sbin/resolvconf -a lo
>>>> ++          fi
>>>> ++      fi
>>>> ++      echo "."
>>>> ++    ;;
>>>> ++
>>>> ++    stop)
>>>> ++      echo -n "Stopping domain name service: named"
>>>> ++      if [ -x /sbin/resolvconf ]; then
>>>> ++          /sbin/resolvconf -d lo
>>>> ++      fi
>>>> ++      /usr/sbin/rndc stop >/dev/null 2>&1
>>>> ++      echo "."
>>>> ++    ;;
>>>> ++
>>>> ++    reload)
>>>> ++      /usr/sbin/rndc reload
>>>> ++    ;;
>>>> ++
>>>> ++    restart|force-reload)
>>>> ++      $0 stop
>>>> ++      sleep 2
>>>> ++      $0 start
>>>> ++    ;;
>>>> ++
>>>> ++    *)
>>>> ++      echo "Usage: /etc/init.d/bind {start|stop|reload|restart|force-reload}" >&2
>>>> ++      exit 1
>>>> ++    ;;
>>>> ++esac
>>>> ++
>>>> ++exit 0
>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
>>>> new file mode 100644
>>>> index 00000000000..ef915c0ae5a
>>>> --- /dev/null
>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
>>>> @@ -0,0 +1,8 @@
>>>> +#!/bin/sh
>>>> +
>>>> +if [ ! -s /etc/bind/rndc.key ]; then
>>>> +    echo -n "Generating /etc/bind/rndc.key:"
>>>> +    /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
>>>> +    chown root:bind /etc/bind/rndc.key
>>>> +    chmod 0640 /etc/bind/rndc.key
>>>> +fi
>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
>>>> new file mode 100644
>>>> index 00000000000..11db95ede12
>>>> --- /dev/null
>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
>>>> @@ -0,0 +1,65 @@
>>>> +Subject: init.d: add support for read-only rootfs
>>>> +
>>>> +Upstream-Status: Inappropriate [oe specific]
>>>> +
>>>> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
>>>> +---
>>>> + init.d |   40 ++++++++++++++++++++++++++++++++++++++++
>>>> + 1 file changed, 40 insertions(+)
>>>> +
>>>> +diff --git a/init.d b/init.d
>>>> +index 0111ed4..24677c8 100644
>>>> +--- a/init.d
>>>> ++++ b/init.d
>>>> +@@ -6,8 +6,48 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin
>>>> + # Don't modify this line, change or create /etc/default/bind9.
>>>> + OPTIONS=""
>>>> +
>>>> ++test -f /etc/default/rcS && . /etc/default/rcS
>>>> + test -f /etc/default/bind9 && . /etc/default/bind9
>>>> +
>>>> ++# This function is here because it's possible that /var and / are on different partitions.
>>>> ++is_on_read_only_partition () {
>>>> ++    DIRECTORY=$1
>>>> ++    dir=`readlink -f $DIRECTORY`
>>>> ++    while true; do
>>>> ++      if [ ! -d "$dir" ]; then
>>>> ++          echo "ERROR: $dir is not a directory"
>>>> ++          exit 1
>>>> ++      else
>>>> ++          for flag in `awk -v dir=$dir '{ if ($2 == dir) { print "FOUND"; split($4,FLAGS,",") } }; \
>>>> ++              END { for (f in FLAGS) print FLAGS[f] }' < /proc/mounts`; do
>>>> ++              [ "$flag" = "FOUND" ] && partition="read-write"
>>>> ++              [ "$flag" = "ro" ] && { partition="read-only"; break; }
>>>> ++          done
>>>> ++          if [ "$dir" = "/" -o -n "$partition" ]; then
>>>> ++              break
>>>> ++          else
>>>> ++              dir=`dirname $dir`
>>>> ++          fi
>>>> ++      fi
>>>> ++    done
>>>> ++    [ "$partition" = "read-only" ] && echo "yes" || echo "no"
>>>> ++}
>>>> ++
>>>> ++bind_mount () {
>>>> ++    olddir=$1
>>>> ++    newdir=$2
>>>> ++    mkdir -p $olddir
>>>> ++    cp -a $newdir/* $olddir
>>>> ++    mount --bind $olddir $newdir
>>>> ++}
>>>> ++
>>>> ++# Deal with read-only rootfs
>>>> ++if [ "$ROOTFS_READ_ONLY" = "yes" ]; then
>>>> ++    [ "$VERBOSE" != "no" ] && echo "WARN: start bind service in read-only rootfs"
>>>> ++    [ `is_on_read_only_partition /etc/bind` = "yes" ] && bind_mount /var/volatile/bind/etc /etc/bind
>>>> ++    [ `is_on_read_only_partition /var/named` = "yes" ] && bind_mount /var/volatile/bind/named /var/named
>>>> ++fi
>>>> ++
>>>> + test -x /usr/sbin/rndc || exit 0
>>>> +
>>>> + case "$1" in
>>>> +--
>>>> +1.7.9.5
>>>> +
>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
>>>> new file mode 100644
>>>> index 00000000000..146f3e35db6
>>>> --- /dev/null
>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
>>>> @@ -0,0 +1,42 @@
>>>> +bind: make "/etc/init.d/bind stop" work
>>>> +
>>>> +Upstream-Status: Inappropriate [configuration]
>>>> +
>>>> +Add some configurations, make rndc command be able to controls
>>>> +the named daemon.
>>>> +
>>>> +Signed-off-by: Roy Li <rongqing.li@windriver.com>
>>>> +---
>>>> + conf/named.conf |    5 +++++
>>>> + conf/rndc.conf  |    5 +++++
>>>> + 2 files changed, 10 insertions(+), 0 deletions(-)
>>>> + create mode 100644 conf/rndc.conf
>>>> +
>>>> +diff --git a/conf/named.conf b/conf/named.conf
>>>> +index 95829cf..c8899e7 100644
>>>> +--- a/conf/named.conf
>>>> ++++ b/conf/named.conf
>>>> +@@ -47,3 +47,8 @@ zone "255.in-addr.arpa" {
>>>> + // root-delegation-only exclude { "DE"; "MUSEUM"; };
>>>> +
>>>> + include "/etc/bind/named.conf.local";
>>>> ++include "/etc/bind/rndc.key" ;
>>>> ++controls {
>>>> ++      inet 127.0.0.1 allow { localhost; }
>>>> ++      keys { rndc-key; };
>>>> ++};
>>>> +diff --git a/conf/rndc.conf b/conf/rndc.conf
>>>> +new file mode 100644
>>>> +index 0000000..a0b481d
>>>> +--- /dev/null
>>>> ++++ b/conf/rndc.conf
>>>> +@@ -0,0 +1,5 @@
>>>> ++include "/etc/bind/rndc.key";
>>>> ++options {
>>>> ++      default-server  localhost;
>>>> ++      default-key     rndc-key;
>>>> ++};
>>>> +
>>>> +--
>>>> +1.7.5.4
>>>> +
>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/named.service b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
>>>> new file mode 100644
>>>> index 00000000000..cda56ef0150
>>>> --- /dev/null
>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
>>>> @@ -0,0 +1,22 @@
>>>> +[Unit]
>>>> +Description=Berkeley Internet Name Domain (DNS)
>>>> +Wants=nss-lookup.target
>>>> +Before=nss-lookup.target
>>>> +After=network.target
>>>> +
>>>> +[Service]
>>>> +Type=forking
>>>> +EnvironmentFile=-/etc/default/bind9
>>>> +PIDFile=/run/named/named.pid
>>>> +
>>>> +ExecStartPre=@SBINDIR@/generate-rndc-key.sh
>>>> +ExecStart=@SBINDIR@/named $OPTIONS
>>>> +
>>>> +ExecReload=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc reload > /dev/null 2>&1 || @BASE_BINDIR@/kill -HUP $MAINPID'
>>>> +
>>>> +ExecStop=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc stop > /dev/null 2>&1 || @BASE_BINDIR@/kill -TERM $MAINPID'
>>>> +
>>>> +PrivateTmp=true
>>>> +
>>>> +[Install]
>>>> +WantedBy=multi-user.target
>>>> diff --git a/meta/recipes-connectivity/bind/bind_9.16.5.bb b/meta/recipes-connectivity/bind/bind_9.16.5.bb
>>>> new file mode 100644
>>>> index 00000000000..9c20ccc6fa2
>>>> --- /dev/null
>>>> +++ b/meta/recipes-connectivity/bind/bind_9.16.5.bb
>>>> @@ -0,0 +1,125 @@
>>>> +SUMMARY = "ISC Internet Domain Name Server"
>>>> +HOMEPAGE = "http://www.isc.org/sw/bind/"
>>>> +SECTION = "console/network"
>>>> +
>>>> +LICENSE = "MPL-2.0"
>>>> +LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=188b8d0644bd6835df43b84e3f180be1"
>>>> +
>>>> +DEPENDS = "openssl libcap zlib libuv"
>>>> +
>>>> +SRC_URI = "https://ftp.isc.org/isc/bind9/${PV}/${BPN}-${PV}.tar.xz \
>>>> +           file://conf.patch \
>>>> +           file://named.service \
>>>> +           file://bind9 \
>>>> +           file://generate-rndc-key.sh \
>>>> +           file://make-etc-initd-bind-stop-work.patch \
>>>> +           file://init.d-add-support-for-read-only-rootfs.patch \
>>>> +           file://bind-ensure-searching-for-json-headers-searches-sysr.patch \
>>>> +           file://0001-named-lwresd-V-and-start-log-hide-build-options.patch \
>>>> +           file://0001-avoid-start-failure-with-bind-user.patch \
>>>> +           "
>>>> +
>>>> +SRC_URI[sha256sum] = "6378b3e51fef11a8be4794dc48e8111ba92d211c0dfd129a0c296ed06a3dc075"
>>>> +
>>>> +UPSTREAM_CHECK_URI = "https://ftp.isc.org/isc/bind9/"
>>>> +# stay at 9.16 follow the ESV versions divisible by 4
>>>> +UPSTREAM_CHECK_REGEX = "(?P<pver>9.(16|20|24|28)(\.\d+)+(-P\d+)*)/"
>>>> +
>>>> +inherit autotools update-rc.d systemd useradd pkgconfig multilib_script multilib_header
>>>> +
>>>> +MULTILIB_SCRIPTS = "${PN}:${bindir}/bind9-config ${PN}:${bindir}/isc-config.sh"
>>>> +
>>>> +# PACKAGECONFIGs readline and libedit should NOT be set at same time
>>>> +PACKAGECONFIG ?= "readline"
>>>> +PACKAGECONFIG[httpstats] = "--with-libxml2=${STAGING_DIR_HOST}${prefix},--without-libxml2,libxml2"
>>>> +PACKAGECONFIG[readline] = "--with-readline=-lreadline,,readline"
>>>> +PACKAGECONFIG[libedit] = "--with-readline=-ledit,,libedit"
>>>> +PACKAGECONFIG[python3] = "--with-python=yes --with-python-install-dir=${PYTHON_SITEPACKAGES_DIR} , --without-python, python3-ply-native,"
>>>> +
>>>> +EXTRA_OECONF = " --with-libtool --disable-devpoll --enable-epoll \
>>>> +                 --with-gssapi=no --with-lmdb=no --with-zlib \
>>>> +                 --sysconfdir=${sysconfdir}/bind \
>>>> +                 --with-openssl=${STAGING_DIR_HOST}${prefix} \
>>>> +               "
>>>> +LDFLAGS_append = " -lz"
>>>> +
>>>> +inherit ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3native distutils3-base', '', d)}
>>>> +
>>>> +# dhcp needs .la so keep them
>>>> +REMOVE_LIBTOOL_LA = "0"
>>>> +
>>>> +USERADD_PACKAGES = "${PN}"
>>>> +USERADD_PARAM_${PN} = "--system --home ${localstatedir}/cache/bind --no-create-home \
>>>> +                       --user-group bind"
>>>> +
>>>> +INITSCRIPT_NAME = "bind"
>>>> +INITSCRIPT_PARAMS = "defaults"
>>>> +
>>>> +SYSTEMD_SERVICE_${PN} = "named.service"
>>>> +
>>>> +do_install_append() {
>>>> +
>>>> +       rmdir "${D}${localstatedir}/run"
>>>> +       rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
>>>> +       install -d -o bind "${D}${localstatedir}/cache/bind"
>>>> +       install -d "${D}${sysconfdir}/bind"
>>>> +       install -d "${D}${sysconfdir}/init.d"
>>>> +       install -m 644 ${S}/conf/* "${D}${sysconfdir}/bind/"
>>>> +       install -m 755 "${S}/init.d" "${D}${sysconfdir}/init.d/bind"
>>>> +        if ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'true', 'false', d)}; then
>>>> +               sed -i -e '1s,#!.*python3,#! /usr/bin/python3,' \
>>>> +               ${D}${sbindir}/dnssec-coverage \
>>>> +               ${D}${sbindir}/dnssec-checkds \
>>>> +               ${D}${sbindir}/dnssec-keymgr
>>>> +       fi
>>>> +
>>>> +       # Install systemd related files
>>>> +       install -d ${D}${sbindir}
>>>> +       install -m 755 ${WORKDIR}/generate-rndc-key.sh ${D}${sbindir}
>>>> +       install -d ${D}${systemd_unitdir}/system
>>>> +       install -m 0644 ${WORKDIR}/named.service ${D}${systemd_unitdir}/system
>>>> +       sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
>>>> +              -e 's,@SBINDIR@,${sbindir},g' \
>>>> +              ${D}${systemd_unitdir}/system/named.service
>>>> +
>>>> +       install -d ${D}${sysconfdir}/default
>>>> +       install -m 0644 ${WORKDIR}/bind9 ${D}${sysconfdir}/default
>>>> +
>>>> +       if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
>>>> +               install -d ${D}${sysconfdir}/tmpfiles.d
>>>> +               echo "d /run/named 0755 bind bind - -" > ${D}${sysconfdir}/tmpfiles.d/bind.conf
>>>> +       fi
>>>> +
>>>> +    oe_multilib_header isc/platform.h
>>>> +}
>>>> +
>>>> +CONFFILES_${PN} = " \
>>>> +       ${sysconfdir}/bind/named.conf \
>>>> +       ${sysconfdir}/bind/named.conf.local \
>>>> +       ${sysconfdir}/bind/named.conf.options \
>>>> +       ${sysconfdir}/bind/db.0 \
>>>> +       ${sysconfdir}/bind/db.127 \
>>>> +       ${sysconfdir}/bind/db.empty \
>>>> +       ${sysconfdir}/bind/db.local \
>>>> +       ${sysconfdir}/bind/db.root \
>>>> +       "
>>>> +
>>>> +ALTERNATIVE_${PN}-utils = "nslookup"
>>>> +ALTERNATIVE_LINK_NAME[nslookup] = "${bindir}/nslookup"
>>>> +ALTERNATIVE_PRIORITY = "100"
>>> I'm seeing this failing with busybox:
>>> update-alternatives: Error: not linking
>>> /development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
>>> to /bin/busybox.nosuid since
>>> /development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
>>> exists and is not a link
>>>
>>> busybox sets ALTERNATIVE_PRIORITY = "50". Can this be the issue?
>>
>> That is weird. I would have expected that to be an issue with the old
>> version too.
>>
>> Got any steps to reproduce this?
> 
> Sorry for delayed response here, it took me some time but I've finally
> figured the setup to reproduce the issue.
> 
> I've used the "vanilla" Poky from master, added IMAGE_INSTALL +=
> "bind-utils" to core-image-minimal and switched from RPM to IPK
> format. The last thing turned out to be the trigger for the issue, as
> with RPM package format I was not able to reproduce the issue, and
> this was cause of the delay here.
> 
> After the above is done - following error is produced:
> WARNING: core-image-minimal-1.0-r0 do_rootfs: busybox.postinst
> returned 1, marking as unpacked only, configuration required on
> target.
> ERROR: core-image-minimal-1.0-r0 do_rootfs: Postinstall scriptlets of
> ['busybox'] have failed. If the intention is to defer them to first
> boot,
> then please place them into pkg_postinst_ontarget_${PN} ().
> Deferring to first boot via 'exit 1' is no longer supported.
> Details of the failure are in
> /development/projects/poky-vanilla/poky/build/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/temp/log.do_rootfs.
> ERROR: Logfile of failure stored in:
> /development/projects/poky-vanilla/poky/build/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/temp/log.do_rootfs.6423
> ERROR: Task (/development/projects/poky-vanilla/poky/meta/recipes-core/images/core-image-minimal.bb:do_rootfs)
> failed with exit code '1'
> NOTE: Tasks Summary: Attempted 3554 tasks of which 3552 didn't need to
> be rerun and 1 failed.
> 
> Summary: 1 task failed:
>   /development/projects/poky-vanilla/poky/meta/recipes-core/images/core-image-minimal.bb:do_rootfs
> ed:
> 
> 'nslookup' is definitely comming from the bind-utils package, and the
> only thing I've noted so far it that in bind-9.11.22 result binary
> name in ${D} is [nslookup.bind], which is different from the one
> provided in bind-9.16.5 - [nslookup].
> 
> In case of previous bind version - both versions seems to be
> installed, and the symlink is fixed onto the nslookup.bind. In the
> current version though - I guess that the real binary is installed
> instead, making symlink operation to fail during update-alternative.

If it is competing with busybox then perhaps priority for bind to
provide nslookup should be higher than busybox. Can you try that ?

> 
> 
> 
>>
>> -armin
>>>
>>> Going back to bind 9.11.22 seems to solve it...
>>>
>>>> +
>>>> +PACKAGE_BEFORE_PN += "${PN}-utils"
>>>> +FILES_${PN}-utils = "${bindir}/host ${bindir}/dig ${bindir}/mdig ${bindir}/nslookup ${bindir}/nsupdate"
>>>> +FILES_${PN}-dev += "${bindir}/isc-config.h"
>>>> +FILES_${PN} += "${sbindir}/generate-rndc-key.sh"
>>>> +
>>>> +PACKAGE_BEFORE_PN += "${PN}-libs"
>>>> +FILES_${PN}-libs = "${libdir}/*.so* ${libdir}/named/*.so*"
>>>> +FILES_${PN}-staticdev += "${libdir}/*.la"
>>>> +
>>>> +PACKAGE_BEFORE_PN += "${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3-bind', '', d)}"
>>>> +FILES_python3-bind = "${sbindir}/dnssec-coverage ${sbindir}/dnssec-checkds \
>>>> +                ${sbindir}/dnssec-keymgr ${PYTHON_SITEPACKAGES_DIR}"
>>>> +
>>>> +RDEPENDS_${PN}-dev = ""
>>>> +RDEPENDS_python3-bind = "python3-core python3-ply"
>>>> --
>>>> 2.17.1
>>>>
>>>>
>>>
>>>
>>
> 
> 
> --
> Regards,
> Andrey.
> 
> 
> 
> 


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 201 bytes --]

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [OE-core] [PATCH 7/8] bind: Add 9.16.x
  2020-09-09 23:53         ` Khem Raj
@ 2020-09-10  7:12           ` Andrey Zhizhikin
  2020-09-14 17:55             ` Andrey Zhizhikin
  0 siblings, 1 reply; 24+ messages in thread
From: Andrey Zhizhikin @ 2020-09-10  7:12 UTC (permalink / raw)
  To: Khem Raj; +Cc: akuster808, OE Core mailing list

On Thu, Sep 10, 2020 at 1:53 AM Khem Raj <raj.khem@gmail.com> wrote:
>
>
>
> On 9/7/20 2:17 PM, Andrey Zhizhikin wrote:
> > On Mon, Sep 7, 2020 at 5:28 PM akuster808 <akuster808@gmail.com> wrote:
> >>
> >>
> >>
> >> On 9/4/20 1:39 AM, Andrey Zhizhikin wrote:
> >>> Hello Armin,
> >>>
> >>> On Tue, Sep 1, 2020 at 5:23 PM akuster <akuster808@gmail.com> wrote:
> >>>> Removed obsolete packageconfig options
> >>>>
> >>>> License change to MPL-2.0
> >>>> https://gitlab.isc.org/isc-projects/bind9/blob/master/LICENSE
> >>>>
> >>>> Refreshed:
> >>>> bind-ensure-searching-for-json-headers-searches-sysr.patch
> >>>> 0001-named-lwresd-V-and-start-log-hide-build-options.patch
> >>>> bind-ensure-searching-for-json-headers-searches-sysr.patch
> >>>>
> >>>> Drop obsolete patch: 0001-configure.in-remove-useless-L-use_openssl-lib.patch
> >>>>
> >>>> Signed-off-by: Armin Kuster <akuster808@gmail.com>
> >>>> ---
> >>>>  ...1-avoid-start-failure-with-bind-user.patch |  27 ++
> >>>>  ...d-V-and-start-log-hide-build-options.patch |  35 ++
> >>>>  ...ching-for-json-headers-searches-sysr.patch |  47 +++
> >>>>  .../bind/bind-9.16.5/bind9                    |   2 +
> >>>>  .../bind/bind-9.16.5/conf.patch               | 330 ++++++++++++++++++
> >>>>  .../bind/bind-9.16.5/generate-rndc-key.sh     |   8 +
> >>>>  ...t.d-add-support-for-read-only-rootfs.patch |  65 ++++
> >>>>  .../make-etc-initd-bind-stop-work.patch       |  42 +++
> >>>>  .../bind/bind-9.16.5/named.service            |  22 ++
> >>>>  meta/recipes-connectivity/bind/bind_9.16.5.bb | 125 +++++++
> >>>>  10 files changed, 703 insertions(+)
> >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
> >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
> >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
> >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind9
> >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
> >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
> >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
> >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
> >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/named.service
> >>>>  create mode 100644 meta/recipes-connectivity/bind/bind_9.16.5.bb
> >>>>
> >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
> >>>> new file mode 100644
> >>>> index 00000000000..8db96ec049c
> >>>> --- /dev/null
> >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
> >>>> @@ -0,0 +1,27 @@
> >>>> +From 31dde3562f287429eea94b77250d184818b49063 Mon Sep 17 00:00:00 2001
> >>>> +From: Chen Qi <Qi.Chen@windriver.com>
> >>>> +Date: Mon, 15 Oct 2018 16:55:09 +0800
> >>>> +Subject: [PATCH] avoid start failure with bind user
> >>>> +
> >>>> +Upstream-Status: Pending
> >>>> +
> >>>> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
> >>>> +---
> >>>> + init.d | 1 +
> >>>> + 1 file changed, 1 insertion(+)
> >>>> +
> >>>> +diff --git a/init.d b/init.d
> >>>> +index b2eec60..6e03936 100644
> >>>> +--- a/init.d
> >>>> ++++ b/init.d
> >>>> +@@ -57,6 +57,7 @@ case "$1" in
> >>>> +       modprobe capability >/dev/null 2>&1 || true
> >>>> +       if [ ! -f /etc/bind/rndc.key ]; then
> >>>> +           /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
> >>>> ++          chown root:bind /etc/bind/rndc.key >/dev/null 2>&1 || true
> >>>> +           chmod 0640 /etc/bind/rndc.key
> >>>> +       fi
> >>>> +       if [ -f /var/run/named/named.pid ]; then
> >>>> +--
> >>>> +2.7.4
> >>>> +
> >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
> >>>> new file mode 100644
> >>>> index 00000000000..5bcc16c9b2b
> >>>> --- /dev/null
> >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
> >>>> @@ -0,0 +1,35 @@
> >>>> +From a3af4a405baf5ff582e82aaba392dd9667d94bdc Mon Sep 17 00:00:00 2001
> >>>> +From: Hongxu Jia <hongxu.jia@windriver.com>
> >>>> +Date: Mon, 27 Aug 2018 21:24:20 +0800
> >>>> +Subject: [PATCH] `named/lwresd -V' and start log hide build options
> >>>> +
> >>>> +The build options expose build path directories, so hide them.
> >>>> +[snip]
> >>>> +$ named -V
> >>>> +|built by make with *** (options are hidden)
> >>>> +[snip]
> >>>> +
> >>>> +Upstream-Status: Inappropriate [oe-core specific]
> >>>> +
> >>>> +Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
> >>>> +
> >>>> +Refreshed for 9.16.0
> >>>> +Signed-off-by: Armin Kuster <akuster@mvista.com>
> >>>> +
> >>>> +---
> >>>> + bin/named/include/named/globals.h | 2 +-
> >>>> + 1 file changed, 1 insertion(+), 1 deletion(-)
> >>>> +
> >>>> +Index: bind-9.16.0/bin/named/include/named/globals.h
> >>>> +===================================================================
> >>>> +--- bind-9.16.0.orig/bin/named/include/named/globals.h
> >>>> ++++ bind-9.16.0/bin/named/include/named/globals.h
> >>>> +@@ -69,7 +69,7 @@ EXTERN const char *named_g_version     I
> >>>> + EXTERN const char *named_g_product     INIT(PRODUCT);
> >>>> + EXTERN const char *named_g_description INIT(DESCRIPTION);
> >>>> + EXTERN const char *named_g_srcid       INIT(SRCID);
> >>>> +-EXTERN const char *named_g_configargs  INIT(CONFIGARGS);
> >>>> ++EXTERN const char *named_g_configargs  INIT("*** (options are hidden)");
> >>>> + EXTERN const char *named_g_builder     INIT(BUILDER);
> >>>> + EXTERN in_port_t named_g_port        INIT(0);
> >>>> + EXTERN isc_dscp_t named_g_dscp               INIT(-1);
> >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
> >>>> new file mode 100644
> >>>> index 00000000000..f9cdc7ca4df
> >>>> --- /dev/null
> >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
> >>>> @@ -0,0 +1,47 @@
> >>>> +From edda20fb5a6e88548f85e39d34d6c074306e15bc Mon Sep 17 00:00:00 2001
> >>>> +From: Paul Gortmaker <paul.gortmaker@windriver.com>
> >>>> +Date: Tue, 9 Jun 2015 11:22:00 -0400
> >>>> +Subject: [PATCH] bind: ensure searching for json headers searches sysroot
> >>>> +
> >>>> +Bind can fail configure by detecting headers w/o libs[1], or
> >>>> +it can fail the host contamination check as per below:
> >>>> +
> >>>> +ERROR: This autoconf log indicates errors, it looked at host include and/or library paths while determining system capabilities.
> >>>> +Rerun configure task after fixing this. The path was 'build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/build'
> >>>> +ERROR: Function failed: do_qa_configure
> >>>> +ERROR: Logfile of failure stored in: build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/temp/log.do_configure.5242
> >>>> +ERROR: Task 5 (meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure) failed with exit code '1'
> >>>> +NOTE: Tasks Summary: Attempted 773 tasks of which 768 didn't need to be rerun and 1 failed.
> >>>> +No currently running tasks (773 of 781)
> >>>> +
> >>>> +Summary: 1 task failed:
> >>>> +  /meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure
> >>>> +
> >>>> +One way to fix it would be to unconditionally disable json in bind
> >>>> +configure[2] but here we fix it by using the path to where we would
> >>>> +put the header if we had json in the sysroot, in case someone wants
> >>>> +to make use of the combination some day.
> >>>> +
> >>>> +[1] https://trac.macports.org/ticket/45305
> >>>> +[2] https://trac.macports.org/changeset/126406
> >>>> +
> >>>> +Upstream-Status: Inappropriate [OE Specific]
> >>>> +Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
> >>>> +
> >>>> +---
> >>>> + configure.ac | 2 +-
> >>>> + 1 file changed, 1 insertion(+), 1 deletion(-)
> >>>> +
> >>>> +Index: bind-9.16.4/configure.ac
> >>>> +===================================================================
> >>>> +--- bind-9.16.4.orig/configure.ac
> >>>> ++++ bind-9.16.4/configure.ac
> >>>> +@@ -1232,7 +1232,7 @@ case "$use_lmdb" in
> >>>> +               LMDB_LIBS=""
> >>>> +               ;;
> >>>> +       auto|yes)
> >>>> +-              for d in /usr /usr/local /opt/local
> >>>> ++              for d in "${STAGING_INCDIR}"
> >>>> +               do
> >>>> +                       if test -f "${d}/include/lmdb.h"
> >>>> +                       then
> >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind9 b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
> >>>> new file mode 100644
> >>>> index 00000000000..968679ff7f7
> >>>> --- /dev/null
> >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
> >>>> @@ -0,0 +1,2 @@
> >>>> +# startup options for the server
> >>>> +OPTIONS="-u bind"
> >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
> >>>> new file mode 100644
> >>>> index 00000000000..aad345f9fcf
> >>>> --- /dev/null
> >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
> >>>> @@ -0,0 +1,330 @@
> >>>> +Upstream-Status: Inappropriate [configuration]
> >>>> +
> >>>> +the patch is imported from openembedded project
> >>>> +
> >>>> +11/30/2010 - Qing He <qing.he@intel.com>
> >>>> +
> >>>> +diff -urN bind-9.3.1.orig/conf/db.0 bind-9.3.1/conf/db.0
> >>>> +--- bind-9.3.1.orig/conf/db.0  1970-01-01 01:00:00.000000000 +0100
> >>>> ++++ bind-9.3.1/conf/db.0       2005-07-10 22:14:00.000000000 +0200
> >>>> +@@ -0,0 +1,12 @@
> >>>> ++;
> >>>> ++; BIND reverse data file for broadcast zone
> >>>> ++;
> >>>> ++$TTL  604800
> >>>> ++@     IN      SOA     localhost. root.localhost. (
> >>>> ++                            1         ; Serial
> >>>> ++                       604800         ; Refresh
> >>>> ++                        86400         ; Retry
> >>>> ++                      2419200         ; Expire
> >>>> ++                       604800 )       ; Negative Cache TTL
> >>>> ++;
> >>>> ++@     IN      NS      localhost.
> >>>> +diff -urN bind-9.3.1.orig/conf/db.127 bind-9.3.1/conf/db.127
> >>>> +--- bind-9.3.1.orig/conf/db.127        1970-01-01 01:00:00.000000000 +0100
> >>>> ++++ bind-9.3.1/conf/db.127     2005-07-10 22:14:00.000000000 +0200
> >>>> +@@ -0,0 +1,13 @@
> >>>> ++;
> >>>> ++; BIND reverse data file for local loopback interface
> >>>> ++;
> >>>> ++$TTL  604800
> >>>> ++@     IN      SOA     localhost. root.localhost. (
> >>>> ++                            1         ; Serial
> >>>> ++                       604800         ; Refresh
> >>>> ++                        86400         ; Retry
> >>>> ++                      2419200         ; Expire
> >>>> ++                       604800 )       ; Negative Cache TTL
> >>>> ++;
> >>>> ++@     IN      NS      localhost.
> >>>> ++1.0.0 IN      PTR     localhost.
> >>>> +diff -urN bind-9.3.1.orig/conf/db.empty bind-9.3.1/conf/db.empty
> >>>> +--- bind-9.3.1.orig/conf/db.empty      1970-01-01 01:00:00.000000000 +0100
> >>>> ++++ bind-9.3.1/conf/db.empty   2005-07-10 22:14:00.000000000 +0200
> >>>> +@@ -0,0 +1,14 @@
> >>>> ++; BIND reverse data file for empty rfc1918 zone
> >>>> ++;
> >>>> ++; DO NOT EDIT THIS FILE - it is used for multiple zones.
> >>>> ++; Instead, copy it, edit named.conf, and use that copy.
> >>>> ++;
> >>>> ++$TTL  86400
> >>>> ++@     IN      SOA     localhost. root.localhost. (
> >>>> ++                            1         ; Serial
> >>>> ++                       604800         ; Refresh
> >>>> ++                        86400         ; Retry
> >>>> ++                      2419200         ; Expire
> >>>> ++                        86400 )       ; Negative Cache TTL
> >>>> ++;
> >>>> ++@     IN      NS      localhost.
> >>>> +diff -urN bind-9.3.1.orig/conf/db.255 bind-9.3.1/conf/db.255
> >>>> +--- bind-9.3.1.orig/conf/db.255        1970-01-01 01:00:00.000000000 +0100
> >>>> ++++ bind-9.3.1/conf/db.255     2005-07-10 22:14:00.000000000 +0200
> >>>> +@@ -0,0 +1,12 @@
> >>>> ++;
> >>>> ++; BIND reserve data file for broadcast zone
> >>>> ++;
> >>>> ++$TTL  604800
> >>>> ++@     IN      SOA     localhost. root.localhost. (
> >>>> ++                            1         ; Serial
> >>>> ++                       604800         ; Refresh
> >>>> ++                        86400         ; Retry
> >>>> ++                      2419200         ; Expire
> >>>> ++                       604800 )       ; Negative Cache TTL
> >>>> ++;
> >>>> ++@     IN      NS      localhost.
> >>>> +diff -urN bind-9.3.1.orig/conf/db.local bind-9.3.1/conf/db.local
> >>>> +--- bind-9.3.1.orig/conf/db.local      1970-01-01 01:00:00.000000000 +0100
> >>>> ++++ bind-9.3.1/conf/db.local   2005-07-10 22:14:00.000000000 +0200
> >>>> +@@ -0,0 +1,13 @@
> >>>> ++;
> >>>> ++; BIND data file for local loopback interface
> >>>> ++;
> >>>> ++$TTL  604800
> >>>> ++@     IN      SOA     localhost. root.localhost. (
> >>>> ++                            1         ; Serial
> >>>> ++                       604800         ; Refresh
> >>>> ++                        86400         ; Retry
> >>>> ++                      2419200         ; Expire
> >>>> ++                       604800 )       ; Negative Cache TTL
> >>>> ++;
> >>>> ++@     IN      NS      localhost.
> >>>> ++@     IN      A       127.0.0.1
> >>>> +diff -urN bind-9.3.1.orig/conf/db.root bind-9.3.1/conf/db.root
> >>>> +--- bind-9.3.1.orig/conf/db.root       1970-01-01 01:00:00.000000000 +0100
> >>>> ++++ bind-9.3.1/conf/db.root    2005-07-10 22:14:00.000000000 +0200
> >>>> +@@ -0,0 +1,45 @@
> >>>> ++
> >>>> ++; <<>> DiG 9.2.3 <<>> ns . @a.root-servers.net.
> >>>> ++;; global options:  printcmd
> >>>> ++;; Got answer:
> >>>> ++;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 18944
> >>>> ++;; flags: qr aa rd; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 13
> >>>> ++
> >>>> ++;; QUESTION SECTION:
> >>>> ++;.                            IN      NS
> >>>> ++
> >>>> ++;; ANSWER SECTION:
> >>>> ++.                     518400  IN      NS      A.ROOT-SERVERS.NET.
> >>>> ++.                     518400  IN      NS      B.ROOT-SERVERS.NET.
> >>>> ++.                     518400  IN      NS      C.ROOT-SERVERS.NET.
> >>>> ++.                     518400  IN      NS      D.ROOT-SERVERS.NET.
> >>>> ++.                     518400  IN      NS      E.ROOT-SERVERS.NET.
> >>>> ++.                     518400  IN      NS      F.ROOT-SERVERS.NET.
> >>>> ++.                     518400  IN      NS      G.ROOT-SERVERS.NET.
> >>>> ++.                     518400  IN      NS      H.ROOT-SERVERS.NET.
> >>>> ++.                     518400  IN      NS      I.ROOT-SERVERS.NET.
> >>>> ++.                     518400  IN      NS      J.ROOT-SERVERS.NET.
> >>>> ++.                     518400  IN      NS      K.ROOT-SERVERS.NET.
> >>>> ++.                     518400  IN      NS      L.ROOT-SERVERS.NET.
> >>>> ++.                     518400  IN      NS      M.ROOT-SERVERS.NET.
> >>>> ++
> >>>> ++;; ADDITIONAL SECTION:
> >>>> ++A.ROOT-SERVERS.NET.   3600000 IN      A       198.41.0.4
> >>>> ++B.ROOT-SERVERS.NET.   3600000 IN      A       192.228.79.201
> >>>> ++C.ROOT-SERVERS.NET.   3600000 IN      A       192.33.4.12
> >>>> ++D.ROOT-SERVERS.NET.   3600000 IN      A       128.8.10.90
> >>>> ++E.ROOT-SERVERS.NET.   3600000 IN      A       192.203.230.10
> >>>> ++F.ROOT-SERVERS.NET.   3600000 IN      A       192.5.5.241
> >>>> ++G.ROOT-SERVERS.NET.   3600000 IN      A       192.112.36.4
> >>>> ++H.ROOT-SERVERS.NET.   3600000 IN      A       128.63.2.53
> >>>> ++I.ROOT-SERVERS.NET.   3600000 IN      A       192.36.148.17
> >>>> ++J.ROOT-SERVERS.NET.   3600000 IN      A       192.58.128.30
> >>>> ++K.ROOT-SERVERS.NET.   3600000 IN      A       193.0.14.129
> >>>> ++L.ROOT-SERVERS.NET.   3600000 IN      A       198.32.64.12
> >>>> ++M.ROOT-SERVERS.NET.   3600000 IN      A       202.12.27.33
> >>>> ++
> >>>> ++;; Query time: 81 msec
> >>>> ++;; SERVER: 198.41.0.4#53(a.root-servers.net.)
> >>>> ++;; WHEN: Sun Feb  1 11:27:14 2004
> >>>> ++;; MSG SIZE  rcvd: 436
> >>>> ++
> >>>> +diff -urN bind-9.3.1.orig/conf/named.conf bind-9.3.1/conf/named.conf
> >>>> +--- bind-9.3.1.orig/conf/named.conf    1970-01-01 01:00:00.000000000 +0100
> >>>> ++++ bind-9.3.1/conf/named.conf 2005-07-10 22:33:46.000000000 +0200
> >>>> +@@ -0,0 +1,49 @@
> >>>> ++// This is the primary configuration file for the BIND DNS server named.
> >>>> ++//
> >>>> ++// If you are just adding zones, please do that in /etc/bind/named.conf.local
> >>>> ++
> >>>> ++include "/etc/bind/named.conf.options";
> >>>> ++
> >>>> ++// prime the server with knowledge of the root servers
> >>>> ++zone "." {
> >>>> ++      type hint;
> >>>> ++      file "/etc/bind/db.root";
> >>>> ++};
> >>>> ++
> >>>> ++// be authoritative for the localhost forward and reverse zones, and for
> >>>> ++// broadcast zones as per RFC 1912
> >>>> ++
> >>>> ++zone "localhost" {
> >>>> ++      type master;
> >>>> ++      file "/etc/bind/db.local";
> >>>> ++};
> >>>> ++
> >>>> ++zone "127.in-addr.arpa" {
> >>>> ++      type master;
> >>>> ++      file "/etc/bind/db.127";
> >>>> ++};
> >>>> ++
> >>>> ++zone "0.in-addr.arpa" {
> >>>> ++      type master;
> >>>> ++      file "/etc/bind/db.0";
> >>>> ++};
> >>>> ++
> >>>> ++zone "255.in-addr.arpa" {
> >>>> ++      type master;
> >>>> ++      file "/etc/bind/db.255";
> >>>> ++};
> >>>> ++
> >>>> ++// zone "com" { type delegation-only; };
> >>>> ++// zone "net" { type delegation-only; };
> >>>> ++
> >>>> ++// From the release notes:
> >>>> ++//  Because many of our users are uncomfortable receiving undelegated answers
> >>>> ++//  from root or top level domains, other than a few for whom that behaviour
> >>>> ++//  has been trusted and expected for quite some length of time, we have now
> >>>> ++//  introduced the "root-delegations-only" feature which applies delegation-only
> >>>> ++//  logic to all top level domains, and to the root domain.  An exception list
> >>>> ++//  should be specified, including "MUSEUM" and "DE", and any other top level
> >>>> ++//  domains from whom undelegated responses are expected and trusted.
> >>>> ++// root-delegation-only exclude { "DE"; "MUSEUM"; };
> >>>> ++
> >>>> ++include "/etc/bind/named.conf.local";
> >>>> +diff -urN bind-9.3.1.orig/conf/named.conf.local bind-9.3.1/conf/named.conf.local
> >>>> +--- bind-9.3.1.orig/conf/named.conf.local      1970-01-01 01:00:00.000000000 +0100
> >>>> ++++ bind-9.3.1/conf/named.conf.local   2005-07-10 22:14:06.000000000 +0200
> >>>> +@@ -0,0 +1,8 @@
> >>>> ++//
> >>>> ++// Do any local configuration here
> >>>> ++//
> >>>> ++
> >>>> ++// Consider adding the 1918 zones here, if they are not used in your
> >>>> ++// organization
> >>>> ++//include "/etc/bind/zones.rfc1918";
> >>>> ++
> >>>> +diff -urN bind-9.3.1.orig/conf/named.conf.options bind-9.3.1/conf/named.conf.options
> >>>> +--- bind-9.3.1.orig/conf/named.conf.options    1970-01-01 01:00:00.000000000 +0100
> >>>> ++++ bind-9.3.1/conf/named.conf.options 2005-07-10 22:14:06.000000000 +0200
> >>>> +@@ -0,0 +1,24 @@
> >>>> ++options {
> >>>> ++      directory "/var/cache/bind";
> >>>> ++
> >>>> ++      // If there is a firewall between you and nameservers you want
> >>>> ++      // to talk to, you might need to uncomment the query-source
> >>>> ++      // directive below.  Previous versions of BIND always asked
> >>>> ++      // questions using port 53, but BIND 8.1 and later use an unprivileged
> >>>> ++      // port by default.
> >>>> ++
> >>>> ++      // query-source address * port 53;
> >>>> ++
> >>>> ++      // If your ISP provided one or more IP addresses for stable
> >>>> ++      // nameservers, you probably want to use them as forwarders.
> >>>> ++      // Uncomment the following block, and insert the addresses replacing
> >>>> ++      // the all-0's placeholder.
> >>>> ++
> >>>> ++      // forwarders {
> >>>> ++      //      0.0.0.0;
> >>>> ++      // };
> >>>> ++
> >>>> ++      auth-nxdomain no;    # conform to RFC1035
> >>>> ++
> >>>> ++};
> >>>> ++
> >>>> +diff -urN bind-9.3.1.orig/conf/zones.rfc1918 bind-9.3.1/conf/zones.rfc1918
> >>>> +--- bind-9.3.1.orig/conf/zones.rfc1918 1970-01-01 01:00:00.000000000 +0100
> >>>> ++++ bind-9.3.1/conf/zones.rfc1918      2005-07-10 22:14:10.000000000 +0200
> >>>> +@@ -0,0 +1,20 @@
> >>>> ++zone "10.in-addr.arpa"      { type master; file "/etc/bind/db.empty"; };
> >>>> ++
> >>>> ++zone "16.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++zone "17.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++zone "18.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++zone "19.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++zone "20.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++zone "21.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++zone "22.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++zone "23.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++zone "24.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++zone "25.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++zone "26.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++zone "27.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++zone "28.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++zone "29.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++zone "30.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++zone "31.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>> ++
> >>>> ++zone "168.192.in-addr.arpa" { type master; file "/etc/bind/db.empty"; };
> >>>> +diff -urN bind-9.3.1.orig/init.d bind-9.3.1/init.d
> >>>> +--- bind-9.3.1.orig/init.d     1970-01-01 01:00:00.000000000 +0100
> >>>> ++++ bind-9.3.1/init.d  2005-07-10 23:09:58.000000000 +0200
> >>>> +@@ -0,0 +1,70 @@
> >>>> ++#!/bin/sh
> >>>> ++
> >>>> ++PATH=/sbin:/bin:/usr/sbin:/usr/bin
> >>>> ++
> >>>> ++# for a chrooted server: "-u bind -t /var/lib/named"
> >>>> ++# Don't modify this line, change or create /etc/default/bind9.
> >>>> ++OPTIONS=""
> >>>> ++
> >>>> ++test -f /etc/default/bind9 && . /etc/default/bind9
> >>>> ++
> >>>> ++test -x /usr/sbin/rndc || exit 0
> >>>> ++
> >>>> ++case "$1" in
> >>>> ++    start)
> >>>> ++      echo -n "Starting domain name service: named"
> >>>> ++
> >>>> ++      modprobe capability >/dev/null 2>&1 || true
> >>>> ++      if [ ! -f /etc/bind/rndc.key ]; then
> >>>> ++          /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
> >>>> ++          chmod 0640 /etc/bind/rndc.key
> >>>> ++      fi
> >>>> ++      if [ -f /var/run/named/named.pid ]; then
> >>>> ++          ps `cat /var/run/named/named.pid` > /dev/null && exit 1
> >>>> ++      fi
> >>>> ++
> >>>> ++      # dirs under /var/run can go away on reboots.
> >>>> ++      mkdir -p /var/run/named
> >>>> ++      mkdir -p /var/cache/bind
> >>>> ++      chmod 775 /var/run/named
> >>>> ++      chown root:bind /var/run/named >/dev/null 2>&1 || true
> >>>> ++
> >>>> ++      if [ ! -x /usr/sbin/named ]; then
> >>>> ++          echo "named binary missing - not starting"
> >>>> ++          exit 1
> >>>> ++      fi
> >>>> ++      if start-stop-daemon --start --quiet --exec /usr/sbin/named \
> >>>> ++              --pidfile /var/run/named/named.pid -- $OPTIONS; then
> >>>> ++          if [ -x /sbin/resolvconf ] ; then
> >>>> ++              echo "nameserver 127.0.0.1" | /sbin/resolvconf -a lo
> >>>> ++          fi
> >>>> ++      fi
> >>>> ++      echo "."
> >>>> ++    ;;
> >>>> ++
> >>>> ++    stop)
> >>>> ++      echo -n "Stopping domain name service: named"
> >>>> ++      if [ -x /sbin/resolvconf ]; then
> >>>> ++          /sbin/resolvconf -d lo
> >>>> ++      fi
> >>>> ++      /usr/sbin/rndc stop >/dev/null 2>&1
> >>>> ++      echo "."
> >>>> ++    ;;
> >>>> ++
> >>>> ++    reload)
> >>>> ++      /usr/sbin/rndc reload
> >>>> ++    ;;
> >>>> ++
> >>>> ++    restart|force-reload)
> >>>> ++      $0 stop
> >>>> ++      sleep 2
> >>>> ++      $0 start
> >>>> ++    ;;
> >>>> ++
> >>>> ++    *)
> >>>> ++      echo "Usage: /etc/init.d/bind {start|stop|reload|restart|force-reload}" >&2
> >>>> ++      exit 1
> >>>> ++    ;;
> >>>> ++esac
> >>>> ++
> >>>> ++exit 0
> >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
> >>>> new file mode 100644
> >>>> index 00000000000..ef915c0ae5a
> >>>> --- /dev/null
> >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
> >>>> @@ -0,0 +1,8 @@
> >>>> +#!/bin/sh
> >>>> +
> >>>> +if [ ! -s /etc/bind/rndc.key ]; then
> >>>> +    echo -n "Generating /etc/bind/rndc.key:"
> >>>> +    /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
> >>>> +    chown root:bind /etc/bind/rndc.key
> >>>> +    chmod 0640 /etc/bind/rndc.key
> >>>> +fi
> >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
> >>>> new file mode 100644
> >>>> index 00000000000..11db95ede12
> >>>> --- /dev/null
> >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
> >>>> @@ -0,0 +1,65 @@
> >>>> +Subject: init.d: add support for read-only rootfs
> >>>> +
> >>>> +Upstream-Status: Inappropriate [oe specific]
> >>>> +
> >>>> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
> >>>> +---
> >>>> + init.d |   40 ++++++++++++++++++++++++++++++++++++++++
> >>>> + 1 file changed, 40 insertions(+)
> >>>> +
> >>>> +diff --git a/init.d b/init.d
> >>>> +index 0111ed4..24677c8 100644
> >>>> +--- a/init.d
> >>>> ++++ b/init.d
> >>>> +@@ -6,8 +6,48 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin
> >>>> + # Don't modify this line, change or create /etc/default/bind9.
> >>>> + OPTIONS=""
> >>>> +
> >>>> ++test -f /etc/default/rcS && . /etc/default/rcS
> >>>> + test -f /etc/default/bind9 && . /etc/default/bind9
> >>>> +
> >>>> ++# This function is here because it's possible that /var and / are on different partitions.
> >>>> ++is_on_read_only_partition () {
> >>>> ++    DIRECTORY=$1
> >>>> ++    dir=`readlink -f $DIRECTORY`
> >>>> ++    while true; do
> >>>> ++      if [ ! -d "$dir" ]; then
> >>>> ++          echo "ERROR: $dir is not a directory"
> >>>> ++          exit 1
> >>>> ++      else
> >>>> ++          for flag in `awk -v dir=$dir '{ if ($2 == dir) { print "FOUND"; split($4,FLAGS,",") } }; \
> >>>> ++              END { for (f in FLAGS) print FLAGS[f] }' < /proc/mounts`; do
> >>>> ++              [ "$flag" = "FOUND" ] && partition="read-write"
> >>>> ++              [ "$flag" = "ro" ] && { partition="read-only"; break; }
> >>>> ++          done
> >>>> ++          if [ "$dir" = "/" -o -n "$partition" ]; then
> >>>> ++              break
> >>>> ++          else
> >>>> ++              dir=`dirname $dir`
> >>>> ++          fi
> >>>> ++      fi
> >>>> ++    done
> >>>> ++    [ "$partition" = "read-only" ] && echo "yes" || echo "no"
> >>>> ++}
> >>>> ++
> >>>> ++bind_mount () {
> >>>> ++    olddir=$1
> >>>> ++    newdir=$2
> >>>> ++    mkdir -p $olddir
> >>>> ++    cp -a $newdir/* $olddir
> >>>> ++    mount --bind $olddir $newdir
> >>>> ++}
> >>>> ++
> >>>> ++# Deal with read-only rootfs
> >>>> ++if [ "$ROOTFS_READ_ONLY" = "yes" ]; then
> >>>> ++    [ "$VERBOSE" != "no" ] && echo "WARN: start bind service in read-only rootfs"
> >>>> ++    [ `is_on_read_only_partition /etc/bind` = "yes" ] && bind_mount /var/volatile/bind/etc /etc/bind
> >>>> ++    [ `is_on_read_only_partition /var/named` = "yes" ] && bind_mount /var/volatile/bind/named /var/named
> >>>> ++fi
> >>>> ++
> >>>> + test -x /usr/sbin/rndc || exit 0
> >>>> +
> >>>> + case "$1" in
> >>>> +--
> >>>> +1.7.9.5
> >>>> +
> >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
> >>>> new file mode 100644
> >>>> index 00000000000..146f3e35db6
> >>>> --- /dev/null
> >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
> >>>> @@ -0,0 +1,42 @@
> >>>> +bind: make "/etc/init.d/bind stop" work
> >>>> +
> >>>> +Upstream-Status: Inappropriate [configuration]
> >>>> +
> >>>> +Add some configurations, make rndc command be able to controls
> >>>> +the named daemon.
> >>>> +
> >>>> +Signed-off-by: Roy Li <rongqing.li@windriver.com>
> >>>> +---
> >>>> + conf/named.conf |    5 +++++
> >>>> + conf/rndc.conf  |    5 +++++
> >>>> + 2 files changed, 10 insertions(+), 0 deletions(-)
> >>>> + create mode 100644 conf/rndc.conf
> >>>> +
> >>>> +diff --git a/conf/named.conf b/conf/named.conf
> >>>> +index 95829cf..c8899e7 100644
> >>>> +--- a/conf/named.conf
> >>>> ++++ b/conf/named.conf
> >>>> +@@ -47,3 +47,8 @@ zone "255.in-addr.arpa" {
> >>>> + // root-delegation-only exclude { "DE"; "MUSEUM"; };
> >>>> +
> >>>> + include "/etc/bind/named.conf.local";
> >>>> ++include "/etc/bind/rndc.key" ;
> >>>> ++controls {
> >>>> ++      inet 127.0.0.1 allow { localhost; }
> >>>> ++      keys { rndc-key; };
> >>>> ++};
> >>>> +diff --git a/conf/rndc.conf b/conf/rndc.conf
> >>>> +new file mode 100644
> >>>> +index 0000000..a0b481d
> >>>> +--- /dev/null
> >>>> ++++ b/conf/rndc.conf
> >>>> +@@ -0,0 +1,5 @@
> >>>> ++include "/etc/bind/rndc.key";
> >>>> ++options {
> >>>> ++      default-server  localhost;
> >>>> ++      default-key     rndc-key;
> >>>> ++};
> >>>> +
> >>>> +--
> >>>> +1.7.5.4
> >>>> +
> >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/named.service b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
> >>>> new file mode 100644
> >>>> index 00000000000..cda56ef0150
> >>>> --- /dev/null
> >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
> >>>> @@ -0,0 +1,22 @@
> >>>> +[Unit]
> >>>> +Description=Berkeley Internet Name Domain (DNS)
> >>>> +Wants=nss-lookup.target
> >>>> +Before=nss-lookup.target
> >>>> +After=network.target
> >>>> +
> >>>> +[Service]
> >>>> +Type=forking
> >>>> +EnvironmentFile=-/etc/default/bind9
> >>>> +PIDFile=/run/named/named.pid
> >>>> +
> >>>> +ExecStartPre=@SBINDIR@/generate-rndc-key.sh
> >>>> +ExecStart=@SBINDIR@/named $OPTIONS
> >>>> +
> >>>> +ExecReload=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc reload > /dev/null 2>&1 || @BASE_BINDIR@/kill -HUP $MAINPID'
> >>>> +
> >>>> +ExecStop=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc stop > /dev/null 2>&1 || @BASE_BINDIR@/kill -TERM $MAINPID'
> >>>> +
> >>>> +PrivateTmp=true
> >>>> +
> >>>> +[Install]
> >>>> +WantedBy=multi-user.target
> >>>> diff --git a/meta/recipes-connectivity/bind/bind_9.16.5.bb b/meta/recipes-connectivity/bind/bind_9.16.5.bb
> >>>> new file mode 100644
> >>>> index 00000000000..9c20ccc6fa2
> >>>> --- /dev/null
> >>>> +++ b/meta/recipes-connectivity/bind/bind_9.16.5.bb
> >>>> @@ -0,0 +1,125 @@
> >>>> +SUMMARY = "ISC Internet Domain Name Server"
> >>>> +HOMEPAGE = "http://www.isc.org/sw/bind/"
> >>>> +SECTION = "console/network"
> >>>> +
> >>>> +LICENSE = "MPL-2.0"
> >>>> +LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=188b8d0644bd6835df43b84e3f180be1"
> >>>> +
> >>>> +DEPENDS = "openssl libcap zlib libuv"
> >>>> +
> >>>> +SRC_URI = "https://ftp.isc.org/isc/bind9/${PV}/${BPN}-${PV}.tar.xz \
> >>>> +           file://conf.patch \
> >>>> +           file://named.service \
> >>>> +           file://bind9 \
> >>>> +           file://generate-rndc-key.sh \
> >>>> +           file://make-etc-initd-bind-stop-work.patch \
> >>>> +           file://init.d-add-support-for-read-only-rootfs.patch \
> >>>> +           file://bind-ensure-searching-for-json-headers-searches-sysr.patch \
> >>>> +           file://0001-named-lwresd-V-and-start-log-hide-build-options.patch \
> >>>> +           file://0001-avoid-start-failure-with-bind-user.patch \
> >>>> +           "
> >>>> +
> >>>> +SRC_URI[sha256sum] = "6378b3e51fef11a8be4794dc48e8111ba92d211c0dfd129a0c296ed06a3dc075"
> >>>> +
> >>>> +UPSTREAM_CHECK_URI = "https://ftp.isc.org/isc/bind9/"
> >>>> +# stay at 9.16 follow the ESV versions divisible by 4
> >>>> +UPSTREAM_CHECK_REGEX = "(?P<pver>9.(16|20|24|28)(\.\d+)+(-P\d+)*)/"
> >>>> +
> >>>> +inherit autotools update-rc.d systemd useradd pkgconfig multilib_script multilib_header
> >>>> +
> >>>> +MULTILIB_SCRIPTS = "${PN}:${bindir}/bind9-config ${PN}:${bindir}/isc-config.sh"
> >>>> +
> >>>> +# PACKAGECONFIGs readline and libedit should NOT be set at same time
> >>>> +PACKAGECONFIG ?= "readline"
> >>>> +PACKAGECONFIG[httpstats] = "--with-libxml2=${STAGING_DIR_HOST}${prefix},--without-libxml2,libxml2"
> >>>> +PACKAGECONFIG[readline] = "--with-readline=-lreadline,,readline"
> >>>> +PACKAGECONFIG[libedit] = "--with-readline=-ledit,,libedit"
> >>>> +PACKAGECONFIG[python3] = "--with-python=yes --with-python-install-dir=${PYTHON_SITEPACKAGES_DIR} , --without-python, python3-ply-native,"
> >>>> +
> >>>> +EXTRA_OECONF = " --with-libtool --disable-devpoll --enable-epoll \
> >>>> +                 --with-gssapi=no --with-lmdb=no --with-zlib \
> >>>> +                 --sysconfdir=${sysconfdir}/bind \
> >>>> +                 --with-openssl=${STAGING_DIR_HOST}${prefix} \
> >>>> +               "
> >>>> +LDFLAGS_append = " -lz"
> >>>> +
> >>>> +inherit ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3native distutils3-base', '', d)}
> >>>> +
> >>>> +# dhcp needs .la so keep them
> >>>> +REMOVE_LIBTOOL_LA = "0"
> >>>> +
> >>>> +USERADD_PACKAGES = "${PN}"
> >>>> +USERADD_PARAM_${PN} = "--system --home ${localstatedir}/cache/bind --no-create-home \
> >>>> +                       --user-group bind"
> >>>> +
> >>>> +INITSCRIPT_NAME = "bind"
> >>>> +INITSCRIPT_PARAMS = "defaults"
> >>>> +
> >>>> +SYSTEMD_SERVICE_${PN} = "named.service"
> >>>> +
> >>>> +do_install_append() {
> >>>> +
> >>>> +       rmdir "${D}${localstatedir}/run"
> >>>> +       rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
> >>>> +       install -d -o bind "${D}${localstatedir}/cache/bind"
> >>>> +       install -d "${D}${sysconfdir}/bind"
> >>>> +       install -d "${D}${sysconfdir}/init.d"
> >>>> +       install -m 644 ${S}/conf/* "${D}${sysconfdir}/bind/"
> >>>> +       install -m 755 "${S}/init.d" "${D}${sysconfdir}/init.d/bind"
> >>>> +        if ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'true', 'false', d)}; then
> >>>> +               sed -i -e '1s,#!.*python3,#! /usr/bin/python3,' \
> >>>> +               ${D}${sbindir}/dnssec-coverage \
> >>>> +               ${D}${sbindir}/dnssec-checkds \
> >>>> +               ${D}${sbindir}/dnssec-keymgr
> >>>> +       fi
> >>>> +
> >>>> +       # Install systemd related files
> >>>> +       install -d ${D}${sbindir}
> >>>> +       install -m 755 ${WORKDIR}/generate-rndc-key.sh ${D}${sbindir}
> >>>> +       install -d ${D}${systemd_unitdir}/system
> >>>> +       install -m 0644 ${WORKDIR}/named.service ${D}${systemd_unitdir}/system
> >>>> +       sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
> >>>> +              -e 's,@SBINDIR@,${sbindir},g' \
> >>>> +              ${D}${systemd_unitdir}/system/named.service
> >>>> +
> >>>> +       install -d ${D}${sysconfdir}/default
> >>>> +       install -m 0644 ${WORKDIR}/bind9 ${D}${sysconfdir}/default
> >>>> +
> >>>> +       if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
> >>>> +               install -d ${D}${sysconfdir}/tmpfiles.d
> >>>> +               echo "d /run/named 0755 bind bind - -" > ${D}${sysconfdir}/tmpfiles.d/bind.conf
> >>>> +       fi
> >>>> +
> >>>> +    oe_multilib_header isc/platform.h
> >>>> +}
> >>>> +
> >>>> +CONFFILES_${PN} = " \
> >>>> +       ${sysconfdir}/bind/named.conf \
> >>>> +       ${sysconfdir}/bind/named.conf.local \
> >>>> +       ${sysconfdir}/bind/named.conf.options \
> >>>> +       ${sysconfdir}/bind/db.0 \
> >>>> +       ${sysconfdir}/bind/db.127 \
> >>>> +       ${sysconfdir}/bind/db.empty \
> >>>> +       ${sysconfdir}/bind/db.local \
> >>>> +       ${sysconfdir}/bind/db.root \
> >>>> +       "
> >>>> +
> >>>> +ALTERNATIVE_${PN}-utils = "nslookup"
> >>>> +ALTERNATIVE_LINK_NAME[nslookup] = "${bindir}/nslookup"
> >>>> +ALTERNATIVE_PRIORITY = "100"
> >>> I'm seeing this failing with busybox:
> >>> update-alternatives: Error: not linking
> >>> /development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
> >>> to /bin/busybox.nosuid since
> >>> /development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
> >>> exists and is not a link
> >>>
> >>> busybox sets ALTERNATIVE_PRIORITY = "50". Can this be the issue?
> >>
> >> That is weird. I would have expected that to be an issue with the old
> >> version too.
> >>
> >> Got any steps to reproduce this?
> >
> > Sorry for delayed response here, it took me some time but I've finally
> > figured the setup to reproduce the issue.
> >
> > I've used the "vanilla" Poky from master, added IMAGE_INSTALL +=
> > "bind-utils" to core-image-minimal and switched from RPM to IPK
> > format. The last thing turned out to be the trigger for the issue, as
> > with RPM package format I was not able to reproduce the issue, and
> > this was cause of the delay here.
> >
> > After the above is done - following error is produced:
> > WARNING: core-image-minimal-1.0-r0 do_rootfs: busybox.postinst
> > returned 1, marking as unpacked only, configuration required on
> > target.
> > ERROR: core-image-minimal-1.0-r0 do_rootfs: Postinstall scriptlets of
> > ['busybox'] have failed. If the intention is to defer them to first
> > boot,
> > then please place them into pkg_postinst_ontarget_${PN} ().
> > Deferring to first boot via 'exit 1' is no longer supported.
> > Details of the failure are in
> > /development/projects/poky-vanilla/poky/build/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/temp/log.do_rootfs.
> > ERROR: Logfile of failure stored in:
> > /development/projects/poky-vanilla/poky/build/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/temp/log.do_rootfs.6423
> > ERROR: Task (/development/projects/poky-vanilla/poky/meta/recipes-core/images/core-image-minimal.bb:do_rootfs)
> > failed with exit code '1'
> > NOTE: Tasks Summary: Attempted 3554 tasks of which 3552 didn't need to
> > be rerun and 1 failed.
> >
> > Summary: 1 task failed:
> >   /development/projects/poky-vanilla/poky/meta/recipes-core/images/core-image-minimal.bb:do_rootfs
> > ed:
> >
> > 'nslookup' is definitely comming from the bind-utils package, and the
> > only thing I've noted so far it that in bind-9.11.22 result binary
> > name in ${D} is [nslookup.bind], which is different from the one
> > provided in bind-9.16.5 - [nslookup].
> >
> > In case of previous bind version - both versions seems to be
> > installed, and the symlink is fixed onto the nslookup.bind. In the
> > current version though - I guess that the real binary is installed
> > instead, making symlink operation to fail during update-alternative.
>
> If it is competing with busybox then perhaps priority for bind to
> provide nslookup should be higher than busybox. Can you try that ?

busybox has ALTERNATIVE_PRIORITY = "50" while bind is set to
ALTERNATIVE_PRIORITY = "100". IIRC higher number means higher priority
which is already the case...

Nevertheless, I've tried to set 50 and even 40 for 'bind' and had the
same failure...

>
> >
> >
> >
> >>
> >> -armin
> >>>
> >>> Going back to bind 9.11.22 seems to solve it...
> >>>
> >>>> +
> >>>> +PACKAGE_BEFORE_PN += "${PN}-utils"
> >>>> +FILES_${PN}-utils = "${bindir}/host ${bindir}/dig ${bindir}/mdig ${bindir}/nslookup ${bindir}/nsupdate"
> >>>> +FILES_${PN}-dev += "${bindir}/isc-config.h"
> >>>> +FILES_${PN} += "${sbindir}/generate-rndc-key.sh"
> >>>> +
> >>>> +PACKAGE_BEFORE_PN += "${PN}-libs"
> >>>> +FILES_${PN}-libs = "${libdir}/*.so* ${libdir}/named/*.so*"
> >>>> +FILES_${PN}-staticdev += "${libdir}/*.la"
> >>>> +
> >>>> +PACKAGE_BEFORE_PN += "${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3-bind', '', d)}"
> >>>> +FILES_python3-bind = "${sbindir}/dnssec-coverage ${sbindir}/dnssec-checkds \
> >>>> +                ${sbindir}/dnssec-keymgr ${PYTHON_SITEPACKAGES_DIR}"
> >>>> +
> >>>> +RDEPENDS_${PN}-dev = ""
> >>>> +RDEPENDS_python3-bind = "python3-core python3-ply"
> >>>> --
> >>>> 2.17.1
> >>>>
> >>>>
> >>>
> >>>
> >>
> >
> >
> > --
> > Regards,
> > Andrey.
> >
> >
> > 
> >
>


-- 
Regards,
Andrey.

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [OE-core] [PATCH 7/8] bind: Add 9.16.x
  2020-09-10  7:12           ` Andrey Zhizhikin
@ 2020-09-14 17:55             ` Andrey Zhizhikin
  2020-09-14 19:04               ` Khem Raj
  0 siblings, 1 reply; 24+ messages in thread
From: Andrey Zhizhikin @ 2020-09-14 17:55 UTC (permalink / raw)
  To: Khem Raj; +Cc: akuster808, OE Core mailing list

Gentle ping here regarding this issue.

Is thre anyone else experiencing this with IPK packages?

On Thu, Sep 10, 2020 at 9:12 AM Andrey Zhizhikin <andrey.z@gmail.com> wrote:
>
> On Thu, Sep 10, 2020 at 1:53 AM Khem Raj <raj.khem@gmail.com> wrote:
> >
> >
> >
> > On 9/7/20 2:17 PM, Andrey Zhizhikin wrote:
> > > On Mon, Sep 7, 2020 at 5:28 PM akuster808 <akuster808@gmail.com> wrote:
> > >>
> > >>
> > >>
> > >> On 9/4/20 1:39 AM, Andrey Zhizhikin wrote:
> > >>> Hello Armin,
> > >>>
> > >>> On Tue, Sep 1, 2020 at 5:23 PM akuster <akuster808@gmail.com> wrote:
> > >>>> Removed obsolete packageconfig options
> > >>>>
> > >>>> License change to MPL-2.0
> > >>>> https://gitlab.isc.org/isc-projects/bind9/blob/master/LICENSE
> > >>>>
> > >>>> Refreshed:
> > >>>> bind-ensure-searching-for-json-headers-searches-sysr.patch
> > >>>> 0001-named-lwresd-V-and-start-log-hide-build-options.patch
> > >>>> bind-ensure-searching-for-json-headers-searches-sysr.patch
> > >>>>
> > >>>> Drop obsolete patch: 0001-configure.in-remove-useless-L-use_openssl-lib.patch
> > >>>>
> > >>>> Signed-off-by: Armin Kuster <akuster808@gmail.com>
> > >>>> ---
> > >>>>  ...1-avoid-start-failure-with-bind-user.patch |  27 ++
> > >>>>  ...d-V-and-start-log-hide-build-options.patch |  35 ++
> > >>>>  ...ching-for-json-headers-searches-sysr.patch |  47 +++
> > >>>>  .../bind/bind-9.16.5/bind9                    |   2 +
> > >>>>  .../bind/bind-9.16.5/conf.patch               | 330 ++++++++++++++++++
> > >>>>  .../bind/bind-9.16.5/generate-rndc-key.sh     |   8 +
> > >>>>  ...t.d-add-support-for-read-only-rootfs.patch |  65 ++++
> > >>>>  .../make-etc-initd-bind-stop-work.patch       |  42 +++
> > >>>>  .../bind/bind-9.16.5/named.service            |  22 ++
> > >>>>  meta/recipes-connectivity/bind/bind_9.16.5.bb | 125 +++++++
> > >>>>  10 files changed, 703 insertions(+)
> > >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
> > >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
> > >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
> > >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind9
> > >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
> > >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
> > >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
> > >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
> > >>>>  create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/named.service
> > >>>>  create mode 100644 meta/recipes-connectivity/bind/bind_9.16.5.bb
> > >>>>
> > >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
> > >>>> new file mode 100644
> > >>>> index 00000000000..8db96ec049c
> > >>>> --- /dev/null
> > >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
> > >>>> @@ -0,0 +1,27 @@
> > >>>> +From 31dde3562f287429eea94b77250d184818b49063 Mon Sep 17 00:00:00 2001
> > >>>> +From: Chen Qi <Qi.Chen@windriver.com>
> > >>>> +Date: Mon, 15 Oct 2018 16:55:09 +0800
> > >>>> +Subject: [PATCH] avoid start failure with bind user
> > >>>> +
> > >>>> +Upstream-Status: Pending
> > >>>> +
> > >>>> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
> > >>>> +---
> > >>>> + init.d | 1 +
> > >>>> + 1 file changed, 1 insertion(+)
> > >>>> +
> > >>>> +diff --git a/init.d b/init.d
> > >>>> +index b2eec60..6e03936 100644
> > >>>> +--- a/init.d
> > >>>> ++++ b/init.d
> > >>>> +@@ -57,6 +57,7 @@ case "$1" in
> > >>>> +       modprobe capability >/dev/null 2>&1 || true
> > >>>> +       if [ ! -f /etc/bind/rndc.key ]; then
> > >>>> +           /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
> > >>>> ++          chown root:bind /etc/bind/rndc.key >/dev/null 2>&1 || true
> > >>>> +           chmod 0640 /etc/bind/rndc.key
> > >>>> +       fi
> > >>>> +       if [ -f /var/run/named/named.pid ]; then
> > >>>> +--
> > >>>> +2.7.4
> > >>>> +
> > >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
> > >>>> new file mode 100644
> > >>>> index 00000000000..5bcc16c9b2b
> > >>>> --- /dev/null
> > >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
> > >>>> @@ -0,0 +1,35 @@
> > >>>> +From a3af4a405baf5ff582e82aaba392dd9667d94bdc Mon Sep 17 00:00:00 2001
> > >>>> +From: Hongxu Jia <hongxu.jia@windriver.com>
> > >>>> +Date: Mon, 27 Aug 2018 21:24:20 +0800
> > >>>> +Subject: [PATCH] `named/lwresd -V' and start log hide build options
> > >>>> +
> > >>>> +The build options expose build path directories, so hide them.
> > >>>> +[snip]
> > >>>> +$ named -V
> > >>>> +|built by make with *** (options are hidden)
> > >>>> +[snip]
> > >>>> +
> > >>>> +Upstream-Status: Inappropriate [oe-core specific]
> > >>>> +
> > >>>> +Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
> > >>>> +
> > >>>> +Refreshed for 9.16.0
> > >>>> +Signed-off-by: Armin Kuster <akuster@mvista.com>
> > >>>> +
> > >>>> +---
> > >>>> + bin/named/include/named/globals.h | 2 +-
> > >>>> + 1 file changed, 1 insertion(+), 1 deletion(-)
> > >>>> +
> > >>>> +Index: bind-9.16.0/bin/named/include/named/globals.h
> > >>>> +===================================================================
> > >>>> +--- bind-9.16.0.orig/bin/named/include/named/globals.h
> > >>>> ++++ bind-9.16.0/bin/named/include/named/globals.h
> > >>>> +@@ -69,7 +69,7 @@ EXTERN const char *named_g_version     I
> > >>>> + EXTERN const char *named_g_product     INIT(PRODUCT);
> > >>>> + EXTERN const char *named_g_description INIT(DESCRIPTION);
> > >>>> + EXTERN const char *named_g_srcid       INIT(SRCID);
> > >>>> +-EXTERN const char *named_g_configargs  INIT(CONFIGARGS);
> > >>>> ++EXTERN const char *named_g_configargs  INIT("*** (options are hidden)");
> > >>>> + EXTERN const char *named_g_builder     INIT(BUILDER);
> > >>>> + EXTERN in_port_t named_g_port        INIT(0);
> > >>>> + EXTERN isc_dscp_t named_g_dscp               INIT(-1);
> > >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
> > >>>> new file mode 100644
> > >>>> index 00000000000..f9cdc7ca4df
> > >>>> --- /dev/null
> > >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
> > >>>> @@ -0,0 +1,47 @@
> > >>>> +From edda20fb5a6e88548f85e39d34d6c074306e15bc Mon Sep 17 00:00:00 2001
> > >>>> +From: Paul Gortmaker <paul.gortmaker@windriver.com>
> > >>>> +Date: Tue, 9 Jun 2015 11:22:00 -0400
> > >>>> +Subject: [PATCH] bind: ensure searching for json headers searches sysroot
> > >>>> +
> > >>>> +Bind can fail configure by detecting headers w/o libs[1], or
> > >>>> +it can fail the host contamination check as per below:
> > >>>> +
> > >>>> +ERROR: This autoconf log indicates errors, it looked at host include and/or library paths while determining system capabilities.
> > >>>> +Rerun configure task after fixing this. The path was 'build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/build'
> > >>>> +ERROR: Function failed: do_qa_configure
> > >>>> +ERROR: Logfile of failure stored in: build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/temp/log.do_configure.5242
> > >>>> +ERROR: Task 5 (meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure) failed with exit code '1'
> > >>>> +NOTE: Tasks Summary: Attempted 773 tasks of which 768 didn't need to be rerun and 1 failed.
> > >>>> +No currently running tasks (773 of 781)
> > >>>> +
> > >>>> +Summary: 1 task failed:
> > >>>> +  /meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure
> > >>>> +
> > >>>> +One way to fix it would be to unconditionally disable json in bind
> > >>>> +configure[2] but here we fix it by using the path to where we would
> > >>>> +put the header if we had json in the sysroot, in case someone wants
> > >>>> +to make use of the combination some day.
> > >>>> +
> > >>>> +[1] https://trac.macports.org/ticket/45305
> > >>>> +[2] https://trac.macports.org/changeset/126406
> > >>>> +
> > >>>> +Upstream-Status: Inappropriate [OE Specific]
> > >>>> +Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
> > >>>> +
> > >>>> +---
> > >>>> + configure.ac | 2 +-
> > >>>> + 1 file changed, 1 insertion(+), 1 deletion(-)
> > >>>> +
> > >>>> +Index: bind-9.16.4/configure.ac
> > >>>> +===================================================================
> > >>>> +--- bind-9.16.4.orig/configure.ac
> > >>>> ++++ bind-9.16.4/configure.ac
> > >>>> +@@ -1232,7 +1232,7 @@ case "$use_lmdb" in
> > >>>> +               LMDB_LIBS=""
> > >>>> +               ;;
> > >>>> +       auto|yes)
> > >>>> +-              for d in /usr /usr/local /opt/local
> > >>>> ++              for d in "${STAGING_INCDIR}"
> > >>>> +               do
> > >>>> +                       if test -f "${d}/include/lmdb.h"
> > >>>> +                       then
> > >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind9 b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
> > >>>> new file mode 100644
> > >>>> index 00000000000..968679ff7f7
> > >>>> --- /dev/null
> > >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
> > >>>> @@ -0,0 +1,2 @@
> > >>>> +# startup options for the server
> > >>>> +OPTIONS="-u bind"
> > >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
> > >>>> new file mode 100644
> > >>>> index 00000000000..aad345f9fcf
> > >>>> --- /dev/null
> > >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
> > >>>> @@ -0,0 +1,330 @@
> > >>>> +Upstream-Status: Inappropriate [configuration]
> > >>>> +
> > >>>> +the patch is imported from openembedded project
> > >>>> +
> > >>>> +11/30/2010 - Qing He <qing.he@intel.com>
> > >>>> +
> > >>>> +diff -urN bind-9.3.1.orig/conf/db.0 bind-9.3.1/conf/db.0
> > >>>> +--- bind-9.3.1.orig/conf/db.0  1970-01-01 01:00:00.000000000 +0100
> > >>>> ++++ bind-9.3.1/conf/db.0       2005-07-10 22:14:00.000000000 +0200
> > >>>> +@@ -0,0 +1,12 @@
> > >>>> ++;
> > >>>> ++; BIND reverse data file for broadcast zone
> > >>>> ++;
> > >>>> ++$TTL  604800
> > >>>> ++@     IN      SOA     localhost. root.localhost. (
> > >>>> ++                            1         ; Serial
> > >>>> ++                       604800         ; Refresh
> > >>>> ++                        86400         ; Retry
> > >>>> ++                      2419200         ; Expire
> > >>>> ++                       604800 )       ; Negative Cache TTL
> > >>>> ++;
> > >>>> ++@     IN      NS      localhost.
> > >>>> +diff -urN bind-9.3.1.orig/conf/db.127 bind-9.3.1/conf/db.127
> > >>>> +--- bind-9.3.1.orig/conf/db.127        1970-01-01 01:00:00.000000000 +0100
> > >>>> ++++ bind-9.3.1/conf/db.127     2005-07-10 22:14:00.000000000 +0200
> > >>>> +@@ -0,0 +1,13 @@
> > >>>> ++;
> > >>>> ++; BIND reverse data file for local loopback interface
> > >>>> ++;
> > >>>> ++$TTL  604800
> > >>>> ++@     IN      SOA     localhost. root.localhost. (
> > >>>> ++                            1         ; Serial
> > >>>> ++                       604800         ; Refresh
> > >>>> ++                        86400         ; Retry
> > >>>> ++                      2419200         ; Expire
> > >>>> ++                       604800 )       ; Negative Cache TTL
> > >>>> ++;
> > >>>> ++@     IN      NS      localhost.
> > >>>> ++1.0.0 IN      PTR     localhost.
> > >>>> +diff -urN bind-9.3.1.orig/conf/db.empty bind-9.3.1/conf/db.empty
> > >>>> +--- bind-9.3.1.orig/conf/db.empty      1970-01-01 01:00:00.000000000 +0100
> > >>>> ++++ bind-9.3.1/conf/db.empty   2005-07-10 22:14:00.000000000 +0200
> > >>>> +@@ -0,0 +1,14 @@
> > >>>> ++; BIND reverse data file for empty rfc1918 zone
> > >>>> ++;
> > >>>> ++; DO NOT EDIT THIS FILE - it is used for multiple zones.
> > >>>> ++; Instead, copy it, edit named.conf, and use that copy.
> > >>>> ++;
> > >>>> ++$TTL  86400
> > >>>> ++@     IN      SOA     localhost. root.localhost. (
> > >>>> ++                            1         ; Serial
> > >>>> ++                       604800         ; Refresh
> > >>>> ++                        86400         ; Retry
> > >>>> ++                      2419200         ; Expire
> > >>>> ++                        86400 )       ; Negative Cache TTL
> > >>>> ++;
> > >>>> ++@     IN      NS      localhost.
> > >>>> +diff -urN bind-9.3.1.orig/conf/db.255 bind-9.3.1/conf/db.255
> > >>>> +--- bind-9.3.1.orig/conf/db.255        1970-01-01 01:00:00.000000000 +0100
> > >>>> ++++ bind-9.3.1/conf/db.255     2005-07-10 22:14:00.000000000 +0200
> > >>>> +@@ -0,0 +1,12 @@
> > >>>> ++;
> > >>>> ++; BIND reserve data file for broadcast zone
> > >>>> ++;
> > >>>> ++$TTL  604800
> > >>>> ++@     IN      SOA     localhost. root.localhost. (
> > >>>> ++                            1         ; Serial
> > >>>> ++                       604800         ; Refresh
> > >>>> ++                        86400         ; Retry
> > >>>> ++                      2419200         ; Expire
> > >>>> ++                       604800 )       ; Negative Cache TTL
> > >>>> ++;
> > >>>> ++@     IN      NS      localhost.
> > >>>> +diff -urN bind-9.3.1.orig/conf/db.local bind-9.3.1/conf/db.local
> > >>>> +--- bind-9.3.1.orig/conf/db.local      1970-01-01 01:00:00.000000000 +0100
> > >>>> ++++ bind-9.3.1/conf/db.local   2005-07-10 22:14:00.000000000 +0200
> > >>>> +@@ -0,0 +1,13 @@
> > >>>> ++;
> > >>>> ++; BIND data file for local loopback interface
> > >>>> ++;
> > >>>> ++$TTL  604800
> > >>>> ++@     IN      SOA     localhost. root.localhost. (
> > >>>> ++                            1         ; Serial
> > >>>> ++                       604800         ; Refresh
> > >>>> ++                        86400         ; Retry
> > >>>> ++                      2419200         ; Expire
> > >>>> ++                       604800 )       ; Negative Cache TTL
> > >>>> ++;
> > >>>> ++@     IN      NS      localhost.
> > >>>> ++@     IN      A       127.0.0.1
> > >>>> +diff -urN bind-9.3.1.orig/conf/db.root bind-9.3.1/conf/db.root
> > >>>> +--- bind-9.3.1.orig/conf/db.root       1970-01-01 01:00:00.000000000 +0100
> > >>>> ++++ bind-9.3.1/conf/db.root    2005-07-10 22:14:00.000000000 +0200
> > >>>> +@@ -0,0 +1,45 @@
> > >>>> ++
> > >>>> ++; <<>> DiG 9.2.3 <<>> ns . @a.root-servers.net.
> > >>>> ++;; global options:  printcmd
> > >>>> ++;; Got answer:
> > >>>> ++;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 18944
> > >>>> ++;; flags: qr aa rd; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 13
> > >>>> ++
> > >>>> ++;; QUESTION SECTION:
> > >>>> ++;.                            IN      NS
> > >>>> ++
> > >>>> ++;; ANSWER SECTION:
> > >>>> ++.                     518400  IN      NS      A.ROOT-SERVERS.NET.
> > >>>> ++.                     518400  IN      NS      B.ROOT-SERVERS.NET.
> > >>>> ++.                     518400  IN      NS      C.ROOT-SERVERS.NET.
> > >>>> ++.                     518400  IN      NS      D.ROOT-SERVERS.NET.
> > >>>> ++.                     518400  IN      NS      E.ROOT-SERVERS.NET.
> > >>>> ++.                     518400  IN      NS      F.ROOT-SERVERS.NET.
> > >>>> ++.                     518400  IN      NS      G.ROOT-SERVERS.NET.
> > >>>> ++.                     518400  IN      NS      H.ROOT-SERVERS.NET.
> > >>>> ++.                     518400  IN      NS      I.ROOT-SERVERS.NET.
> > >>>> ++.                     518400  IN      NS      J.ROOT-SERVERS.NET.
> > >>>> ++.                     518400  IN      NS      K.ROOT-SERVERS.NET.
> > >>>> ++.                     518400  IN      NS      L.ROOT-SERVERS.NET.
> > >>>> ++.                     518400  IN      NS      M.ROOT-SERVERS.NET.
> > >>>> ++
> > >>>> ++;; ADDITIONAL SECTION:
> > >>>> ++A.ROOT-SERVERS.NET.   3600000 IN      A       198.41.0.4
> > >>>> ++B.ROOT-SERVERS.NET.   3600000 IN      A       192.228.79.201
> > >>>> ++C.ROOT-SERVERS.NET.   3600000 IN      A       192.33.4.12
> > >>>> ++D.ROOT-SERVERS.NET.   3600000 IN      A       128.8.10.90
> > >>>> ++E.ROOT-SERVERS.NET.   3600000 IN      A       192.203.230.10
> > >>>> ++F.ROOT-SERVERS.NET.   3600000 IN      A       192.5.5.241
> > >>>> ++G.ROOT-SERVERS.NET.   3600000 IN      A       192.112.36.4
> > >>>> ++H.ROOT-SERVERS.NET.   3600000 IN      A       128.63.2.53
> > >>>> ++I.ROOT-SERVERS.NET.   3600000 IN      A       192.36.148.17
> > >>>> ++J.ROOT-SERVERS.NET.   3600000 IN      A       192.58.128.30
> > >>>> ++K.ROOT-SERVERS.NET.   3600000 IN      A       193.0.14.129
> > >>>> ++L.ROOT-SERVERS.NET.   3600000 IN      A       198.32.64.12
> > >>>> ++M.ROOT-SERVERS.NET.   3600000 IN      A       202.12.27.33
> > >>>> ++
> > >>>> ++;; Query time: 81 msec
> > >>>> ++;; SERVER: 198.41.0.4#53(a.root-servers.net.)
> > >>>> ++;; WHEN: Sun Feb  1 11:27:14 2004
> > >>>> ++;; MSG SIZE  rcvd: 436
> > >>>> ++
> > >>>> +diff -urN bind-9.3.1.orig/conf/named.conf bind-9.3.1/conf/named.conf
> > >>>> +--- bind-9.3.1.orig/conf/named.conf    1970-01-01 01:00:00.000000000 +0100
> > >>>> ++++ bind-9.3.1/conf/named.conf 2005-07-10 22:33:46.000000000 +0200
> > >>>> +@@ -0,0 +1,49 @@
> > >>>> ++// This is the primary configuration file for the BIND DNS server named.
> > >>>> ++//
> > >>>> ++// If you are just adding zones, please do that in /etc/bind/named.conf.local
> > >>>> ++
> > >>>> ++include "/etc/bind/named.conf.options";
> > >>>> ++
> > >>>> ++// prime the server with knowledge of the root servers
> > >>>> ++zone "." {
> > >>>> ++      type hint;
> > >>>> ++      file "/etc/bind/db.root";
> > >>>> ++};
> > >>>> ++
> > >>>> ++// be authoritative for the localhost forward and reverse zones, and for
> > >>>> ++// broadcast zones as per RFC 1912
> > >>>> ++
> > >>>> ++zone "localhost" {
> > >>>> ++      type master;
> > >>>> ++      file "/etc/bind/db.local";
> > >>>> ++};
> > >>>> ++
> > >>>> ++zone "127.in-addr.arpa" {
> > >>>> ++      type master;
> > >>>> ++      file "/etc/bind/db.127";
> > >>>> ++};
> > >>>> ++
> > >>>> ++zone "0.in-addr.arpa" {
> > >>>> ++      type master;
> > >>>> ++      file "/etc/bind/db.0";
> > >>>> ++};
> > >>>> ++
> > >>>> ++zone "255.in-addr.arpa" {
> > >>>> ++      type master;
> > >>>> ++      file "/etc/bind/db.255";
> > >>>> ++};
> > >>>> ++
> > >>>> ++// zone "com" { type delegation-only; };
> > >>>> ++// zone "net" { type delegation-only; };
> > >>>> ++
> > >>>> ++// From the release notes:
> > >>>> ++//  Because many of our users are uncomfortable receiving undelegated answers
> > >>>> ++//  from root or top level domains, other than a few for whom that behaviour
> > >>>> ++//  has been trusted and expected for quite some length of time, we have now
> > >>>> ++//  introduced the "root-delegations-only" feature which applies delegation-only
> > >>>> ++//  logic to all top level domains, and to the root domain.  An exception list
> > >>>> ++//  should be specified, including "MUSEUM" and "DE", and any other top level
> > >>>> ++//  domains from whom undelegated responses are expected and trusted.
> > >>>> ++// root-delegation-only exclude { "DE"; "MUSEUM"; };
> > >>>> ++
> > >>>> ++include "/etc/bind/named.conf.local";
> > >>>> +diff -urN bind-9.3.1.orig/conf/named.conf.local bind-9.3.1/conf/named.conf.local
> > >>>> +--- bind-9.3.1.orig/conf/named.conf.local      1970-01-01 01:00:00.000000000 +0100
> > >>>> ++++ bind-9.3.1/conf/named.conf.local   2005-07-10 22:14:06.000000000 +0200
> > >>>> +@@ -0,0 +1,8 @@
> > >>>> ++//
> > >>>> ++// Do any local configuration here
> > >>>> ++//
> > >>>> ++
> > >>>> ++// Consider adding the 1918 zones here, if they are not used in your
> > >>>> ++// organization
> > >>>> ++//include "/etc/bind/zones.rfc1918";
> > >>>> ++
> > >>>> +diff -urN bind-9.3.1.orig/conf/named.conf.options bind-9.3.1/conf/named.conf.options
> > >>>> +--- bind-9.3.1.orig/conf/named.conf.options    1970-01-01 01:00:00.000000000 +0100
> > >>>> ++++ bind-9.3.1/conf/named.conf.options 2005-07-10 22:14:06.000000000 +0200
> > >>>> +@@ -0,0 +1,24 @@
> > >>>> ++options {
> > >>>> ++      directory "/var/cache/bind";
> > >>>> ++
> > >>>> ++      // If there is a firewall between you and nameservers you want
> > >>>> ++      // to talk to, you might need to uncomment the query-source
> > >>>> ++      // directive below.  Previous versions of BIND always asked
> > >>>> ++      // questions using port 53, but BIND 8.1 and later use an unprivileged
> > >>>> ++      // port by default.
> > >>>> ++
> > >>>> ++      // query-source address * port 53;
> > >>>> ++
> > >>>> ++      // If your ISP provided one or more IP addresses for stable
> > >>>> ++      // nameservers, you probably want to use them as forwarders.
> > >>>> ++      // Uncomment the following block, and insert the addresses replacing
> > >>>> ++      // the all-0's placeholder.
> > >>>> ++
> > >>>> ++      // forwarders {
> > >>>> ++      //      0.0.0.0;
> > >>>> ++      // };
> > >>>> ++
> > >>>> ++      auth-nxdomain no;    # conform to RFC1035
> > >>>> ++
> > >>>> ++};
> > >>>> ++
> > >>>> +diff -urN bind-9.3.1.orig/conf/zones.rfc1918 bind-9.3.1/conf/zones.rfc1918
> > >>>> +--- bind-9.3.1.orig/conf/zones.rfc1918 1970-01-01 01:00:00.000000000 +0100
> > >>>> ++++ bind-9.3.1/conf/zones.rfc1918      2005-07-10 22:14:10.000000000 +0200
> > >>>> +@@ -0,0 +1,20 @@
> > >>>> ++zone "10.in-addr.arpa"      { type master; file "/etc/bind/db.empty"; };
> > >>>> ++
> > >>>> ++zone "16.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++zone "17.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++zone "18.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++zone "19.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++zone "20.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++zone "21.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++zone "22.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++zone "23.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++zone "24.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++zone "25.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++zone "26.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++zone "27.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++zone "28.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++zone "29.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++zone "30.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++zone "31.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> > >>>> ++
> > >>>> ++zone "168.192.in-addr.arpa" { type master; file "/etc/bind/db.empty"; };
> > >>>> +diff -urN bind-9.3.1.orig/init.d bind-9.3.1/init.d
> > >>>> +--- bind-9.3.1.orig/init.d     1970-01-01 01:00:00.000000000 +0100
> > >>>> ++++ bind-9.3.1/init.d  2005-07-10 23:09:58.000000000 +0200
> > >>>> +@@ -0,0 +1,70 @@
> > >>>> ++#!/bin/sh
> > >>>> ++
> > >>>> ++PATH=/sbin:/bin:/usr/sbin:/usr/bin
> > >>>> ++
> > >>>> ++# for a chrooted server: "-u bind -t /var/lib/named"
> > >>>> ++# Don't modify this line, change or create /etc/default/bind9.
> > >>>> ++OPTIONS=""
> > >>>> ++
> > >>>> ++test -f /etc/default/bind9 && . /etc/default/bind9
> > >>>> ++
> > >>>> ++test -x /usr/sbin/rndc || exit 0
> > >>>> ++
> > >>>> ++case "$1" in
> > >>>> ++    start)
> > >>>> ++      echo -n "Starting domain name service: named"
> > >>>> ++
> > >>>> ++      modprobe capability >/dev/null 2>&1 || true
> > >>>> ++      if [ ! -f /etc/bind/rndc.key ]; then
> > >>>> ++          /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
> > >>>> ++          chmod 0640 /etc/bind/rndc.key
> > >>>> ++      fi
> > >>>> ++      if [ -f /var/run/named/named.pid ]; then
> > >>>> ++          ps `cat /var/run/named/named.pid` > /dev/null && exit 1
> > >>>> ++      fi
> > >>>> ++
> > >>>> ++      # dirs under /var/run can go away on reboots.
> > >>>> ++      mkdir -p /var/run/named
> > >>>> ++      mkdir -p /var/cache/bind
> > >>>> ++      chmod 775 /var/run/named
> > >>>> ++      chown root:bind /var/run/named >/dev/null 2>&1 || true
> > >>>> ++
> > >>>> ++      if [ ! -x /usr/sbin/named ]; then
> > >>>> ++          echo "named binary missing - not starting"
> > >>>> ++          exit 1
> > >>>> ++      fi
> > >>>> ++      if start-stop-daemon --start --quiet --exec /usr/sbin/named \
> > >>>> ++              --pidfile /var/run/named/named.pid -- $OPTIONS; then
> > >>>> ++          if [ -x /sbin/resolvconf ] ; then
> > >>>> ++              echo "nameserver 127.0.0.1" | /sbin/resolvconf -a lo
> > >>>> ++          fi
> > >>>> ++      fi
> > >>>> ++      echo "."
> > >>>> ++    ;;
> > >>>> ++
> > >>>> ++    stop)
> > >>>> ++      echo -n "Stopping domain name service: named"
> > >>>> ++      if [ -x /sbin/resolvconf ]; then
> > >>>> ++          /sbin/resolvconf -d lo
> > >>>> ++      fi
> > >>>> ++      /usr/sbin/rndc stop >/dev/null 2>&1
> > >>>> ++      echo "."
> > >>>> ++    ;;
> > >>>> ++
> > >>>> ++    reload)
> > >>>> ++      /usr/sbin/rndc reload
> > >>>> ++    ;;
> > >>>> ++
> > >>>> ++    restart|force-reload)
> > >>>> ++      $0 stop
> > >>>> ++      sleep 2
> > >>>> ++      $0 start
> > >>>> ++    ;;
> > >>>> ++
> > >>>> ++    *)
> > >>>> ++      echo "Usage: /etc/init.d/bind {start|stop|reload|restart|force-reload}" >&2
> > >>>> ++      exit 1
> > >>>> ++    ;;
> > >>>> ++esac
> > >>>> ++
> > >>>> ++exit 0
> > >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
> > >>>> new file mode 100644
> > >>>> index 00000000000..ef915c0ae5a
> > >>>> --- /dev/null
> > >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
> > >>>> @@ -0,0 +1,8 @@
> > >>>> +#!/bin/sh
> > >>>> +
> > >>>> +if [ ! -s /etc/bind/rndc.key ]; then
> > >>>> +    echo -n "Generating /etc/bind/rndc.key:"
> > >>>> +    /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
> > >>>> +    chown root:bind /etc/bind/rndc.key
> > >>>> +    chmod 0640 /etc/bind/rndc.key
> > >>>> +fi
> > >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
> > >>>> new file mode 100644
> > >>>> index 00000000000..11db95ede12
> > >>>> --- /dev/null
> > >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
> > >>>> @@ -0,0 +1,65 @@
> > >>>> +Subject: init.d: add support for read-only rootfs
> > >>>> +
> > >>>> +Upstream-Status: Inappropriate [oe specific]
> > >>>> +
> > >>>> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
> > >>>> +---
> > >>>> + init.d |   40 ++++++++++++++++++++++++++++++++++++++++
> > >>>> + 1 file changed, 40 insertions(+)
> > >>>> +
> > >>>> +diff --git a/init.d b/init.d
> > >>>> +index 0111ed4..24677c8 100644
> > >>>> +--- a/init.d
> > >>>> ++++ b/init.d
> > >>>> +@@ -6,8 +6,48 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin
> > >>>> + # Don't modify this line, change or create /etc/default/bind9.
> > >>>> + OPTIONS=""
> > >>>> +
> > >>>> ++test -f /etc/default/rcS && . /etc/default/rcS
> > >>>> + test -f /etc/default/bind9 && . /etc/default/bind9
> > >>>> +
> > >>>> ++# This function is here because it's possible that /var and / are on different partitions.
> > >>>> ++is_on_read_only_partition () {
> > >>>> ++    DIRECTORY=$1
> > >>>> ++    dir=`readlink -f $DIRECTORY`
> > >>>> ++    while true; do
> > >>>> ++      if [ ! -d "$dir" ]; then
> > >>>> ++          echo "ERROR: $dir is not a directory"
> > >>>> ++          exit 1
> > >>>> ++      else
> > >>>> ++          for flag in `awk -v dir=$dir '{ if ($2 == dir) { print "FOUND"; split($4,FLAGS,",") } }; \
> > >>>> ++              END { for (f in FLAGS) print FLAGS[f] }' < /proc/mounts`; do
> > >>>> ++              [ "$flag" = "FOUND" ] && partition="read-write"
> > >>>> ++              [ "$flag" = "ro" ] && { partition="read-only"; break; }
> > >>>> ++          done
> > >>>> ++          if [ "$dir" = "/" -o -n "$partition" ]; then
> > >>>> ++              break
> > >>>> ++          else
> > >>>> ++              dir=`dirname $dir`
> > >>>> ++          fi
> > >>>> ++      fi
> > >>>> ++    done
> > >>>> ++    [ "$partition" = "read-only" ] && echo "yes" || echo "no"
> > >>>> ++}
> > >>>> ++
> > >>>> ++bind_mount () {
> > >>>> ++    olddir=$1
> > >>>> ++    newdir=$2
> > >>>> ++    mkdir -p $olddir
> > >>>> ++    cp -a $newdir/* $olddir
> > >>>> ++    mount --bind $olddir $newdir
> > >>>> ++}
> > >>>> ++
> > >>>> ++# Deal with read-only rootfs
> > >>>> ++if [ "$ROOTFS_READ_ONLY" = "yes" ]; then
> > >>>> ++    [ "$VERBOSE" != "no" ] && echo "WARN: start bind service in read-only rootfs"
> > >>>> ++    [ `is_on_read_only_partition /etc/bind` = "yes" ] && bind_mount /var/volatile/bind/etc /etc/bind
> > >>>> ++    [ `is_on_read_only_partition /var/named` = "yes" ] && bind_mount /var/volatile/bind/named /var/named
> > >>>> ++fi
> > >>>> ++
> > >>>> + test -x /usr/sbin/rndc || exit 0
> > >>>> +
> > >>>> + case "$1" in
> > >>>> +--
> > >>>> +1.7.9.5
> > >>>> +
> > >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
> > >>>> new file mode 100644
> > >>>> index 00000000000..146f3e35db6
> > >>>> --- /dev/null
> > >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
> > >>>> @@ -0,0 +1,42 @@
> > >>>> +bind: make "/etc/init.d/bind stop" work
> > >>>> +
> > >>>> +Upstream-Status: Inappropriate [configuration]
> > >>>> +
> > >>>> +Add some configurations, make rndc command be able to controls
> > >>>> +the named daemon.
> > >>>> +
> > >>>> +Signed-off-by: Roy Li <rongqing.li@windriver.com>
> > >>>> +---
> > >>>> + conf/named.conf |    5 +++++
> > >>>> + conf/rndc.conf  |    5 +++++
> > >>>> + 2 files changed, 10 insertions(+), 0 deletions(-)
> > >>>> + create mode 100644 conf/rndc.conf
> > >>>> +
> > >>>> +diff --git a/conf/named.conf b/conf/named.conf
> > >>>> +index 95829cf..c8899e7 100644
> > >>>> +--- a/conf/named.conf
> > >>>> ++++ b/conf/named.conf
> > >>>> +@@ -47,3 +47,8 @@ zone "255.in-addr.arpa" {
> > >>>> + // root-delegation-only exclude { "DE"; "MUSEUM"; };
> > >>>> +
> > >>>> + include "/etc/bind/named.conf.local";
> > >>>> ++include "/etc/bind/rndc.key" ;
> > >>>> ++controls {
> > >>>> ++      inet 127.0.0.1 allow { localhost; }
> > >>>> ++      keys { rndc-key; };
> > >>>> ++};
> > >>>> +diff --git a/conf/rndc.conf b/conf/rndc.conf
> > >>>> +new file mode 100644
> > >>>> +index 0000000..a0b481d
> > >>>> +--- /dev/null
> > >>>> ++++ b/conf/rndc.conf
> > >>>> +@@ -0,0 +1,5 @@
> > >>>> ++include "/etc/bind/rndc.key";
> > >>>> ++options {
> > >>>> ++      default-server  localhost;
> > >>>> ++      default-key     rndc-key;
> > >>>> ++};
> > >>>> +
> > >>>> +--
> > >>>> +1.7.5.4
> > >>>> +
> > >>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/named.service b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
> > >>>> new file mode 100644
> > >>>> index 00000000000..cda56ef0150
> > >>>> --- /dev/null
> > >>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
> > >>>> @@ -0,0 +1,22 @@
> > >>>> +[Unit]
> > >>>> +Description=Berkeley Internet Name Domain (DNS)
> > >>>> +Wants=nss-lookup.target
> > >>>> +Before=nss-lookup.target
> > >>>> +After=network.target
> > >>>> +
> > >>>> +[Service]
> > >>>> +Type=forking
> > >>>> +EnvironmentFile=-/etc/default/bind9
> > >>>> +PIDFile=/run/named/named.pid
> > >>>> +
> > >>>> +ExecStartPre=@SBINDIR@/generate-rndc-key.sh
> > >>>> +ExecStart=@SBINDIR@/named $OPTIONS
> > >>>> +
> > >>>> +ExecReload=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc reload > /dev/null 2>&1 || @BASE_BINDIR@/kill -HUP $MAINPID'
> > >>>> +
> > >>>> +ExecStop=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc stop > /dev/null 2>&1 || @BASE_BINDIR@/kill -TERM $MAINPID'
> > >>>> +
> > >>>> +PrivateTmp=true
> > >>>> +
> > >>>> +[Install]
> > >>>> +WantedBy=multi-user.target
> > >>>> diff --git a/meta/recipes-connectivity/bind/bind_9.16.5.bb b/meta/recipes-connectivity/bind/bind_9.16.5.bb
> > >>>> new file mode 100644
> > >>>> index 00000000000..9c20ccc6fa2
> > >>>> --- /dev/null
> > >>>> +++ b/meta/recipes-connectivity/bind/bind_9.16.5.bb
> > >>>> @@ -0,0 +1,125 @@
> > >>>> +SUMMARY = "ISC Internet Domain Name Server"
> > >>>> +HOMEPAGE = "http://www.isc.org/sw/bind/"
> > >>>> +SECTION = "console/network"
> > >>>> +
> > >>>> +LICENSE = "MPL-2.0"
> > >>>> +LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=188b8d0644bd6835df43b84e3f180be1"
> > >>>> +
> > >>>> +DEPENDS = "openssl libcap zlib libuv"
> > >>>> +
> > >>>> +SRC_URI = "https://ftp.isc.org/isc/bind9/${PV}/${BPN}-${PV}.tar.xz \
> > >>>> +           file://conf.patch \
> > >>>> +           file://named.service \
> > >>>> +           file://bind9 \
> > >>>> +           file://generate-rndc-key.sh \
> > >>>> +           file://make-etc-initd-bind-stop-work.patch \
> > >>>> +           file://init.d-add-support-for-read-only-rootfs.patch \
> > >>>> +           file://bind-ensure-searching-for-json-headers-searches-sysr.patch \
> > >>>> +           file://0001-named-lwresd-V-and-start-log-hide-build-options.patch \
> > >>>> +           file://0001-avoid-start-failure-with-bind-user.patch \
> > >>>> +           "
> > >>>> +
> > >>>> +SRC_URI[sha256sum] = "6378b3e51fef11a8be4794dc48e8111ba92d211c0dfd129a0c296ed06a3dc075"
> > >>>> +
> > >>>> +UPSTREAM_CHECK_URI = "https://ftp.isc.org/isc/bind9/"
> > >>>> +# stay at 9.16 follow the ESV versions divisible by 4
> > >>>> +UPSTREAM_CHECK_REGEX = "(?P<pver>9.(16|20|24|28)(\.\d+)+(-P\d+)*)/"
> > >>>> +
> > >>>> +inherit autotools update-rc.d systemd useradd pkgconfig multilib_script multilib_header
> > >>>> +
> > >>>> +MULTILIB_SCRIPTS = "${PN}:${bindir}/bind9-config ${PN}:${bindir}/isc-config.sh"
> > >>>> +
> > >>>> +# PACKAGECONFIGs readline and libedit should NOT be set at same time
> > >>>> +PACKAGECONFIG ?= "readline"
> > >>>> +PACKAGECONFIG[httpstats] = "--with-libxml2=${STAGING_DIR_HOST}${prefix},--without-libxml2,libxml2"
> > >>>> +PACKAGECONFIG[readline] = "--with-readline=-lreadline,,readline"
> > >>>> +PACKAGECONFIG[libedit] = "--with-readline=-ledit,,libedit"
> > >>>> +PACKAGECONFIG[python3] = "--with-python=yes --with-python-install-dir=${PYTHON_SITEPACKAGES_DIR} , --without-python, python3-ply-native,"
> > >>>> +
> > >>>> +EXTRA_OECONF = " --with-libtool --disable-devpoll --enable-epoll \
> > >>>> +                 --with-gssapi=no --with-lmdb=no --with-zlib \
> > >>>> +                 --sysconfdir=${sysconfdir}/bind \
> > >>>> +                 --with-openssl=${STAGING_DIR_HOST}${prefix} \
> > >>>> +               "
> > >>>> +LDFLAGS_append = " -lz"
> > >>>> +
> > >>>> +inherit ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3native distutils3-base', '', d)}
> > >>>> +
> > >>>> +# dhcp needs .la so keep them
> > >>>> +REMOVE_LIBTOOL_LA = "0"
> > >>>> +
> > >>>> +USERADD_PACKAGES = "${PN}"
> > >>>> +USERADD_PARAM_${PN} = "--system --home ${localstatedir}/cache/bind --no-create-home \
> > >>>> +                       --user-group bind"
> > >>>> +
> > >>>> +INITSCRIPT_NAME = "bind"
> > >>>> +INITSCRIPT_PARAMS = "defaults"
> > >>>> +
> > >>>> +SYSTEMD_SERVICE_${PN} = "named.service"
> > >>>> +
> > >>>> +do_install_append() {
> > >>>> +
> > >>>> +       rmdir "${D}${localstatedir}/run"
> > >>>> +       rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
> > >>>> +       install -d -o bind "${D}${localstatedir}/cache/bind"
> > >>>> +       install -d "${D}${sysconfdir}/bind"
> > >>>> +       install -d "${D}${sysconfdir}/init.d"
> > >>>> +       install -m 644 ${S}/conf/* "${D}${sysconfdir}/bind/"
> > >>>> +       install -m 755 "${S}/init.d" "${D}${sysconfdir}/init.d/bind"
> > >>>> +        if ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'true', 'false', d)}; then
> > >>>> +               sed -i -e '1s,#!.*python3,#! /usr/bin/python3,' \
> > >>>> +               ${D}${sbindir}/dnssec-coverage \
> > >>>> +               ${D}${sbindir}/dnssec-checkds \
> > >>>> +               ${D}${sbindir}/dnssec-keymgr
> > >>>> +       fi
> > >>>> +
> > >>>> +       # Install systemd related files
> > >>>> +       install -d ${D}${sbindir}
> > >>>> +       install -m 755 ${WORKDIR}/generate-rndc-key.sh ${D}${sbindir}
> > >>>> +       install -d ${D}${systemd_unitdir}/system
> > >>>> +       install -m 0644 ${WORKDIR}/named.service ${D}${systemd_unitdir}/system
> > >>>> +       sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
> > >>>> +              -e 's,@SBINDIR@,${sbindir},g' \
> > >>>> +              ${D}${systemd_unitdir}/system/named.service
> > >>>> +
> > >>>> +       install -d ${D}${sysconfdir}/default
> > >>>> +       install -m 0644 ${WORKDIR}/bind9 ${D}${sysconfdir}/default
> > >>>> +
> > >>>> +       if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
> > >>>> +               install -d ${D}${sysconfdir}/tmpfiles.d
> > >>>> +               echo "d /run/named 0755 bind bind - -" > ${D}${sysconfdir}/tmpfiles.d/bind.conf
> > >>>> +       fi
> > >>>> +
> > >>>> +    oe_multilib_header isc/platform.h
> > >>>> +}
> > >>>> +
> > >>>> +CONFFILES_${PN} = " \
> > >>>> +       ${sysconfdir}/bind/named.conf \
> > >>>> +       ${sysconfdir}/bind/named.conf.local \
> > >>>> +       ${sysconfdir}/bind/named.conf.options \
> > >>>> +       ${sysconfdir}/bind/db.0 \
> > >>>> +       ${sysconfdir}/bind/db.127 \
> > >>>> +       ${sysconfdir}/bind/db.empty \
> > >>>> +       ${sysconfdir}/bind/db.local \
> > >>>> +       ${sysconfdir}/bind/db.root \
> > >>>> +       "
> > >>>> +
> > >>>> +ALTERNATIVE_${PN}-utils = "nslookup"
> > >>>> +ALTERNATIVE_LINK_NAME[nslookup] = "${bindir}/nslookup"
> > >>>> +ALTERNATIVE_PRIORITY = "100"
> > >>> I'm seeing this failing with busybox:
> > >>> update-alternatives: Error: not linking
> > >>> /development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
> > >>> to /bin/busybox.nosuid since
> > >>> /development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
> > >>> exists and is not a link
> > >>>
> > >>> busybox sets ALTERNATIVE_PRIORITY = "50". Can this be the issue?
> > >>
> > >> That is weird. I would have expected that to be an issue with the old
> > >> version too.
> > >>
> > >> Got any steps to reproduce this?
> > >
> > > Sorry for delayed response here, it took me some time but I've finally
> > > figured the setup to reproduce the issue.
> > >
> > > I've used the "vanilla" Poky from master, added IMAGE_INSTALL +=
> > > "bind-utils" to core-image-minimal and switched from RPM to IPK
> > > format. The last thing turned out to be the trigger for the issue, as
> > > with RPM package format I was not able to reproduce the issue, and
> > > this was cause of the delay here.
> > >
> > > After the above is done - following error is produced:
> > > WARNING: core-image-minimal-1.0-r0 do_rootfs: busybox.postinst
> > > returned 1, marking as unpacked only, configuration required on
> > > target.
> > > ERROR: core-image-minimal-1.0-r0 do_rootfs: Postinstall scriptlets of
> > > ['busybox'] have failed. If the intention is to defer them to first
> > > boot,
> > > then please place them into pkg_postinst_ontarget_${PN} ().
> > > Deferring to first boot via 'exit 1' is no longer supported.
> > > Details of the failure are in
> > > /development/projects/poky-vanilla/poky/build/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/temp/log.do_rootfs.
> > > ERROR: Logfile of failure stored in:
> > > /development/projects/poky-vanilla/poky/build/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/temp/log.do_rootfs.6423
> > > ERROR: Task (/development/projects/poky-vanilla/poky/meta/recipes-core/images/core-image-minimal.bb:do_rootfs)
> > > failed with exit code '1'
> > > NOTE: Tasks Summary: Attempted 3554 tasks of which 3552 didn't need to
> > > be rerun and 1 failed.
> > >
> > > Summary: 1 task failed:
> > >   /development/projects/poky-vanilla/poky/meta/recipes-core/images/core-image-minimal.bb:do_rootfs
> > > ed:
> > >
> > > 'nslookup' is definitely comming from the bind-utils package, and the
> > > only thing I've noted so far it that in bind-9.11.22 result binary
> > > name in ${D} is [nslookup.bind], which is different from the one
> > > provided in bind-9.16.5 - [nslookup].
> > >
> > > In case of previous bind version - both versions seems to be
> > > installed, and the symlink is fixed onto the nslookup.bind. In the
> > > current version though - I guess that the real binary is installed
> > > instead, making symlink operation to fail during update-alternative.
> >
> > If it is competing with busybox then perhaps priority for bind to
> > provide nslookup should be higher than busybox. Can you try that ?
>
> busybox has ALTERNATIVE_PRIORITY = "50" while bind is set to
> ALTERNATIVE_PRIORITY = "100". IIRC higher number means higher priority
> which is already the case...
>
> Nevertheless, I've tried to set 50 and even 40 for 'bind' and had the
> same failure...
>
> >
> > >
> > >
> > >
> > >>
> > >> -armin
> > >>>
> > >>> Going back to bind 9.11.22 seems to solve it...
> > >>>
> > >>>> +
> > >>>> +PACKAGE_BEFORE_PN += "${PN}-utils"
> > >>>> +FILES_${PN}-utils = "${bindir}/host ${bindir}/dig ${bindir}/mdig ${bindir}/nslookup ${bindir}/nsupdate"
> > >>>> +FILES_${PN}-dev += "${bindir}/isc-config.h"
> > >>>> +FILES_${PN} += "${sbindir}/generate-rndc-key.sh"
> > >>>> +
> > >>>> +PACKAGE_BEFORE_PN += "${PN}-libs"
> > >>>> +FILES_${PN}-libs = "${libdir}/*.so* ${libdir}/named/*.so*"
> > >>>> +FILES_${PN}-staticdev += "${libdir}/*.la"
> > >>>> +
> > >>>> +PACKAGE_BEFORE_PN += "${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3-bind', '', d)}"
> > >>>> +FILES_python3-bind = "${sbindir}/dnssec-coverage ${sbindir}/dnssec-checkds \
> > >>>> +                ${sbindir}/dnssec-keymgr ${PYTHON_SITEPACKAGES_DIR}"
> > >>>> +
> > >>>> +RDEPENDS_${PN}-dev = ""
> > >>>> +RDEPENDS_python3-bind = "python3-core python3-ply"
> > >>>> --
> > >>>> 2.17.1
> > >>>>
> > >>>>
> > >>>
> > >>>
> > >>
> > >
> > >
> > > --
> > > Regards,
> > > Andrey.
> > >
> > >
> > > 
> > >
> >
>
>
> --
> Regards,
> Andrey.



-- 
Regards,
Andrey.

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [OE-core] [PATCH 7/8] bind: Add 9.16.x
  2020-09-14 17:55             ` Andrey Zhizhikin
@ 2020-09-14 19:04               ` Khem Raj
  2020-09-14 20:48                 ` Andrey Zhizhikin
  0 siblings, 1 reply; 24+ messages in thread
From: Khem Raj @ 2020-09-14 19:04 UTC (permalink / raw)
  To: Andrey Zhizhikin; +Cc: akuster808, OE Core mailing list



On 9/14/20 10:55 AM, Andrey Zhizhikin wrote:
> Gentle ping here regarding this issue.
> 
> Is thre anyone else experiencing this with IPK packages?

Alright thanks for being persist it has paid off :) I have taken a look 
at it and sent a fix to ml


> 
> On Thu, Sep 10, 2020 at 9:12 AM Andrey Zhizhikin <andrey.z@gmail.com> wrote:
>>
>> On Thu, Sep 10, 2020 at 1:53 AM Khem Raj <raj.khem@gmail.com> wrote:
>>>
>>>
>>>
>>> On 9/7/20 2:17 PM, Andrey Zhizhikin wrote:
>>>> On Mon, Sep 7, 2020 at 5:28 PM akuster808 <akuster808@gmail.com> wrote:
>>>>>
>>>>>
>>>>>
>>>>> On 9/4/20 1:39 AM, Andrey Zhizhikin wrote:
>>>>>> Hello Armin,
>>>>>>
>>>>>> On Tue, Sep 1, 2020 at 5:23 PM akuster <akuster808@gmail.com> wrote:
>>>>>>> Removed obsolete packageconfig options
>>>>>>>
>>>>>>> License change to MPL-2.0
>>>>>>> https://gitlab.isc.org/isc-projects/bind9/blob/master/LICENSE
>>>>>>>
>>>>>>> Refreshed:
>>>>>>> bind-ensure-searching-for-json-headers-searches-sysr.patch
>>>>>>> 0001-named-lwresd-V-and-start-log-hide-build-options.patch
>>>>>>> bind-ensure-searching-for-json-headers-searches-sysr.patch
>>>>>>>
>>>>>>> Drop obsolete patch: 0001-configure.in-remove-useless-L-use_openssl-lib.patch
>>>>>>>
>>>>>>> Signed-off-by: Armin Kuster <akuster808@gmail.com>
>>>>>>> ---
>>>>>>>   ...1-avoid-start-failure-with-bind-user.patch |  27 ++
>>>>>>>   ...d-V-and-start-log-hide-build-options.patch |  35 ++
>>>>>>>   ...ching-for-json-headers-searches-sysr.patch |  47 +++
>>>>>>>   .../bind/bind-9.16.5/bind9                    |   2 +
>>>>>>>   .../bind/bind-9.16.5/conf.patch               | 330 ++++++++++++++++++
>>>>>>>   .../bind/bind-9.16.5/generate-rndc-key.sh     |   8 +
>>>>>>>   ...t.d-add-support-for-read-only-rootfs.patch |  65 ++++
>>>>>>>   .../make-etc-initd-bind-stop-work.patch       |  42 +++
>>>>>>>   .../bind/bind-9.16.5/named.service            |  22 ++
>>>>>>>   meta/recipes-connectivity/bind/bind_9.16.5.bb | 125 +++++++
>>>>>>>   10 files changed, 703 insertions(+)
>>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
>>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
>>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
>>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind9
>>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
>>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
>>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
>>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
>>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/named.service
>>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind_9.16.5.bb
>>>>>>>
>>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
>>>>>>> new file mode 100644
>>>>>>> index 00000000000..8db96ec049c
>>>>>>> --- /dev/null
>>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
>>>>>>> @@ -0,0 +1,27 @@
>>>>>>> +From 31dde3562f287429eea94b77250d184818b49063 Mon Sep 17 00:00:00 2001
>>>>>>> +From: Chen Qi <Qi.Chen@windriver.com>
>>>>>>> +Date: Mon, 15 Oct 2018 16:55:09 +0800
>>>>>>> +Subject: [PATCH] avoid start failure with bind user
>>>>>>> +
>>>>>>> +Upstream-Status: Pending
>>>>>>> +
>>>>>>> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
>>>>>>> +---
>>>>>>> + init.d | 1 +
>>>>>>> + 1 file changed, 1 insertion(+)
>>>>>>> +
>>>>>>> +diff --git a/init.d b/init.d
>>>>>>> +index b2eec60..6e03936 100644
>>>>>>> +--- a/init.d
>>>>>>> ++++ b/init.d
>>>>>>> +@@ -57,6 +57,7 @@ case "$1" in
>>>>>>> +       modprobe capability >/dev/null 2>&1 || true
>>>>>>> +       if [ ! -f /etc/bind/rndc.key ]; then
>>>>>>> +           /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
>>>>>>> ++          chown root:bind /etc/bind/rndc.key >/dev/null 2>&1 || true
>>>>>>> +           chmod 0640 /etc/bind/rndc.key
>>>>>>> +       fi
>>>>>>> +       if [ -f /var/run/named/named.pid ]; then
>>>>>>> +--
>>>>>>> +2.7.4
>>>>>>> +
>>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
>>>>>>> new file mode 100644
>>>>>>> index 00000000000..5bcc16c9b2b
>>>>>>> --- /dev/null
>>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
>>>>>>> @@ -0,0 +1,35 @@
>>>>>>> +From a3af4a405baf5ff582e82aaba392dd9667d94bdc Mon Sep 17 00:00:00 2001
>>>>>>> +From: Hongxu Jia <hongxu.jia@windriver.com>
>>>>>>> +Date: Mon, 27 Aug 2018 21:24:20 +0800
>>>>>>> +Subject: [PATCH] `named/lwresd -V' and start log hide build options
>>>>>>> +
>>>>>>> +The build options expose build path directories, so hide them.
>>>>>>> +[snip]
>>>>>>> +$ named -V
>>>>>>> +|built by make with *** (options are hidden)
>>>>>>> +[snip]
>>>>>>> +
>>>>>>> +Upstream-Status: Inappropriate [oe-core specific]
>>>>>>> +
>>>>>>> +Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
>>>>>>> +
>>>>>>> +Refreshed for 9.16.0
>>>>>>> +Signed-off-by: Armin Kuster <akuster@mvista.com>
>>>>>>> +
>>>>>>> +---
>>>>>>> + bin/named/include/named/globals.h | 2 +-
>>>>>>> + 1 file changed, 1 insertion(+), 1 deletion(-)
>>>>>>> +
>>>>>>> +Index: bind-9.16.0/bin/named/include/named/globals.h
>>>>>>> +===================================================================
>>>>>>> +--- bind-9.16.0.orig/bin/named/include/named/globals.h
>>>>>>> ++++ bind-9.16.0/bin/named/include/named/globals.h
>>>>>>> +@@ -69,7 +69,7 @@ EXTERN const char *named_g_version     I
>>>>>>> + EXTERN const char *named_g_product     INIT(PRODUCT);
>>>>>>> + EXTERN const char *named_g_description INIT(DESCRIPTION);
>>>>>>> + EXTERN const char *named_g_srcid       INIT(SRCID);
>>>>>>> +-EXTERN const char *named_g_configargs  INIT(CONFIGARGS);
>>>>>>> ++EXTERN const char *named_g_configargs  INIT("*** (options are hidden)");
>>>>>>> + EXTERN const char *named_g_builder     INIT(BUILDER);
>>>>>>> + EXTERN in_port_t named_g_port        INIT(0);
>>>>>>> + EXTERN isc_dscp_t named_g_dscp               INIT(-1);
>>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
>>>>>>> new file mode 100644
>>>>>>> index 00000000000..f9cdc7ca4df
>>>>>>> --- /dev/null
>>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
>>>>>>> @@ -0,0 +1,47 @@
>>>>>>> +From edda20fb5a6e88548f85e39d34d6c074306e15bc Mon Sep 17 00:00:00 2001
>>>>>>> +From: Paul Gortmaker <paul.gortmaker@windriver.com>
>>>>>>> +Date: Tue, 9 Jun 2015 11:22:00 -0400
>>>>>>> +Subject: [PATCH] bind: ensure searching for json headers searches sysroot
>>>>>>> +
>>>>>>> +Bind can fail configure by detecting headers w/o libs[1], or
>>>>>>> +it can fail the host contamination check as per below:
>>>>>>> +
>>>>>>> +ERROR: This autoconf log indicates errors, it looked at host include and/or library paths while determining system capabilities.
>>>>>>> +Rerun configure task after fixing this. The path was 'build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/build'
>>>>>>> +ERROR: Function failed: do_qa_configure
>>>>>>> +ERROR: Logfile of failure stored in: build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/temp/log.do_configure.5242
>>>>>>> +ERROR: Task 5 (meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure) failed with exit code '1'
>>>>>>> +NOTE: Tasks Summary: Attempted 773 tasks of which 768 didn't need to be rerun and 1 failed.
>>>>>>> +No currently running tasks (773 of 781)
>>>>>>> +
>>>>>>> +Summary: 1 task failed:
>>>>>>> +  /meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure
>>>>>>> +
>>>>>>> +One way to fix it would be to unconditionally disable json in bind
>>>>>>> +configure[2] but here we fix it by using the path to where we would
>>>>>>> +put the header if we had json in the sysroot, in case someone wants
>>>>>>> +to make use of the combination some day.
>>>>>>> +
>>>>>>> +[1] https://trac.macports.org/ticket/45305
>>>>>>> +[2] https://trac.macports.org/changeset/126406
>>>>>>> +
>>>>>>> +Upstream-Status: Inappropriate [OE Specific]
>>>>>>> +Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
>>>>>>> +
>>>>>>> +---
>>>>>>> + configure.ac | 2 +-
>>>>>>> + 1 file changed, 1 insertion(+), 1 deletion(-)
>>>>>>> +
>>>>>>> +Index: bind-9.16.4/configure.ac
>>>>>>> +===================================================================
>>>>>>> +--- bind-9.16.4.orig/configure.ac
>>>>>>> ++++ bind-9.16.4/configure.ac
>>>>>>> +@@ -1232,7 +1232,7 @@ case "$use_lmdb" in
>>>>>>> +               LMDB_LIBS=""
>>>>>>> +               ;;
>>>>>>> +       auto|yes)
>>>>>>> +-              for d in /usr /usr/local /opt/local
>>>>>>> ++              for d in "${STAGING_INCDIR}"
>>>>>>> +               do
>>>>>>> +                       if test -f "${d}/include/lmdb.h"
>>>>>>> +                       then
>>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind9 b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
>>>>>>> new file mode 100644
>>>>>>> index 00000000000..968679ff7f7
>>>>>>> --- /dev/null
>>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
>>>>>>> @@ -0,0 +1,2 @@
>>>>>>> +# startup options for the server
>>>>>>> +OPTIONS="-u bind"
>>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
>>>>>>> new file mode 100644
>>>>>>> index 00000000000..aad345f9fcf
>>>>>>> --- /dev/null
>>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
>>>>>>> @@ -0,0 +1,330 @@
>>>>>>> +Upstream-Status: Inappropriate [configuration]
>>>>>>> +
>>>>>>> +the patch is imported from openembedded project
>>>>>>> +
>>>>>>> +11/30/2010 - Qing He <qing.he@intel.com>
>>>>>>> +
>>>>>>> +diff -urN bind-9.3.1.orig/conf/db.0 bind-9.3.1/conf/db.0
>>>>>>> +--- bind-9.3.1.orig/conf/db.0  1970-01-01 01:00:00.000000000 +0100
>>>>>>> ++++ bind-9.3.1/conf/db.0       2005-07-10 22:14:00.000000000 +0200
>>>>>>> +@@ -0,0 +1,12 @@
>>>>>>> ++;
>>>>>>> ++; BIND reverse data file for broadcast zone
>>>>>>> ++;
>>>>>>> ++$TTL  604800
>>>>>>> ++@     IN      SOA     localhost. root.localhost. (
>>>>>>> ++                            1         ; Serial
>>>>>>> ++                       604800         ; Refresh
>>>>>>> ++                        86400         ; Retry
>>>>>>> ++                      2419200         ; Expire
>>>>>>> ++                       604800 )       ; Negative Cache TTL
>>>>>>> ++;
>>>>>>> ++@     IN      NS      localhost.
>>>>>>> +diff -urN bind-9.3.1.orig/conf/db.127 bind-9.3.1/conf/db.127
>>>>>>> +--- bind-9.3.1.orig/conf/db.127        1970-01-01 01:00:00.000000000 +0100
>>>>>>> ++++ bind-9.3.1/conf/db.127     2005-07-10 22:14:00.000000000 +0200
>>>>>>> +@@ -0,0 +1,13 @@
>>>>>>> ++;
>>>>>>> ++; BIND reverse data file for local loopback interface
>>>>>>> ++;
>>>>>>> ++$TTL  604800
>>>>>>> ++@     IN      SOA     localhost. root.localhost. (
>>>>>>> ++                            1         ; Serial
>>>>>>> ++                       604800         ; Refresh
>>>>>>> ++                        86400         ; Retry
>>>>>>> ++                      2419200         ; Expire
>>>>>>> ++                       604800 )       ; Negative Cache TTL
>>>>>>> ++;
>>>>>>> ++@     IN      NS      localhost.
>>>>>>> ++1.0.0 IN      PTR     localhost.
>>>>>>> +diff -urN bind-9.3.1.orig/conf/db.empty bind-9.3.1/conf/db.empty
>>>>>>> +--- bind-9.3.1.orig/conf/db.empty      1970-01-01 01:00:00.000000000 +0100
>>>>>>> ++++ bind-9.3.1/conf/db.empty   2005-07-10 22:14:00.000000000 +0200
>>>>>>> +@@ -0,0 +1,14 @@
>>>>>>> ++; BIND reverse data file for empty rfc1918 zone
>>>>>>> ++;
>>>>>>> ++; DO NOT EDIT THIS FILE - it is used for multiple zones.
>>>>>>> ++; Instead, copy it, edit named.conf, and use that copy.
>>>>>>> ++;
>>>>>>> ++$TTL  86400
>>>>>>> ++@     IN      SOA     localhost. root.localhost. (
>>>>>>> ++                            1         ; Serial
>>>>>>> ++                       604800         ; Refresh
>>>>>>> ++                        86400         ; Retry
>>>>>>> ++                      2419200         ; Expire
>>>>>>> ++                        86400 )       ; Negative Cache TTL
>>>>>>> ++;
>>>>>>> ++@     IN      NS      localhost.
>>>>>>> +diff -urN bind-9.3.1.orig/conf/db.255 bind-9.3.1/conf/db.255
>>>>>>> +--- bind-9.3.1.orig/conf/db.255        1970-01-01 01:00:00.000000000 +0100
>>>>>>> ++++ bind-9.3.1/conf/db.255     2005-07-10 22:14:00.000000000 +0200
>>>>>>> +@@ -0,0 +1,12 @@
>>>>>>> ++;
>>>>>>> ++; BIND reserve data file for broadcast zone
>>>>>>> ++;
>>>>>>> ++$TTL  604800
>>>>>>> ++@     IN      SOA     localhost. root.localhost. (
>>>>>>> ++                            1         ; Serial
>>>>>>> ++                       604800         ; Refresh
>>>>>>> ++                        86400         ; Retry
>>>>>>> ++                      2419200         ; Expire
>>>>>>> ++                       604800 )       ; Negative Cache TTL
>>>>>>> ++;
>>>>>>> ++@     IN      NS      localhost.
>>>>>>> +diff -urN bind-9.3.1.orig/conf/db.local bind-9.3.1/conf/db.local
>>>>>>> +--- bind-9.3.1.orig/conf/db.local      1970-01-01 01:00:00.000000000 +0100
>>>>>>> ++++ bind-9.3.1/conf/db.local   2005-07-10 22:14:00.000000000 +0200
>>>>>>> +@@ -0,0 +1,13 @@
>>>>>>> ++;
>>>>>>> ++; BIND data file for local loopback interface
>>>>>>> ++;
>>>>>>> ++$TTL  604800
>>>>>>> ++@     IN      SOA     localhost. root.localhost. (
>>>>>>> ++                            1         ; Serial
>>>>>>> ++                       604800         ; Refresh
>>>>>>> ++                        86400         ; Retry
>>>>>>> ++                      2419200         ; Expire
>>>>>>> ++                       604800 )       ; Negative Cache TTL
>>>>>>> ++;
>>>>>>> ++@     IN      NS      localhost.
>>>>>>> ++@     IN      A       127.0.0.1
>>>>>>> +diff -urN bind-9.3.1.orig/conf/db.root bind-9.3.1/conf/db.root
>>>>>>> +--- bind-9.3.1.orig/conf/db.root       1970-01-01 01:00:00.000000000 +0100
>>>>>>> ++++ bind-9.3.1/conf/db.root    2005-07-10 22:14:00.000000000 +0200
>>>>>>> +@@ -0,0 +1,45 @@
>>>>>>> ++
>>>>>>> ++; <<>> DiG 9.2.3 <<>> ns . @a.root-servers.net.
>>>>>>> ++;; global options:  printcmd
>>>>>>> ++;; Got answer:
>>>>>>> ++;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 18944
>>>>>>> ++;; flags: qr aa rd; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 13
>>>>>>> ++
>>>>>>> ++;; QUESTION SECTION:
>>>>>>> ++;.                            IN      NS
>>>>>>> ++
>>>>>>> ++;; ANSWER SECTION:
>>>>>>> ++.                     518400  IN      NS      A.ROOT-SERVERS.NET.
>>>>>>> ++.                     518400  IN      NS      B.ROOT-SERVERS.NET.
>>>>>>> ++.                     518400  IN      NS      C.ROOT-SERVERS.NET.
>>>>>>> ++.                     518400  IN      NS      D.ROOT-SERVERS.NET.
>>>>>>> ++.                     518400  IN      NS      E.ROOT-SERVERS.NET.
>>>>>>> ++.                     518400  IN      NS      F.ROOT-SERVERS.NET.
>>>>>>> ++.                     518400  IN      NS      G.ROOT-SERVERS.NET.
>>>>>>> ++.                     518400  IN      NS      H.ROOT-SERVERS.NET.
>>>>>>> ++.                     518400  IN      NS      I.ROOT-SERVERS.NET.
>>>>>>> ++.                     518400  IN      NS      J.ROOT-SERVERS.NET.
>>>>>>> ++.                     518400  IN      NS      K.ROOT-SERVERS.NET.
>>>>>>> ++.                     518400  IN      NS      L.ROOT-SERVERS.NET.
>>>>>>> ++.                     518400  IN      NS      M.ROOT-SERVERS.NET.
>>>>>>> ++
>>>>>>> ++;; ADDITIONAL SECTION:
>>>>>>> ++A.ROOT-SERVERS.NET.   3600000 IN      A       198.41.0.4
>>>>>>> ++B.ROOT-SERVERS.NET.   3600000 IN      A       192.228.79.201
>>>>>>> ++C.ROOT-SERVERS.NET.   3600000 IN      A       192.33.4.12
>>>>>>> ++D.ROOT-SERVERS.NET.   3600000 IN      A       128.8.10.90
>>>>>>> ++E.ROOT-SERVERS.NET.   3600000 IN      A       192.203.230.10
>>>>>>> ++F.ROOT-SERVERS.NET.   3600000 IN      A       192.5.5.241
>>>>>>> ++G.ROOT-SERVERS.NET.   3600000 IN      A       192.112.36.4
>>>>>>> ++H.ROOT-SERVERS.NET.   3600000 IN      A       128.63.2.53
>>>>>>> ++I.ROOT-SERVERS.NET.   3600000 IN      A       192.36.148.17
>>>>>>> ++J.ROOT-SERVERS.NET.   3600000 IN      A       192.58.128.30
>>>>>>> ++K.ROOT-SERVERS.NET.   3600000 IN      A       193.0.14.129
>>>>>>> ++L.ROOT-SERVERS.NET.   3600000 IN      A       198.32.64.12
>>>>>>> ++M.ROOT-SERVERS.NET.   3600000 IN      A       202.12.27.33
>>>>>>> ++
>>>>>>> ++;; Query time: 81 msec
>>>>>>> ++;; SERVER: 198.41.0.4#53(a.root-servers.net.)
>>>>>>> ++;; WHEN: Sun Feb  1 11:27:14 2004
>>>>>>> ++;; MSG SIZE  rcvd: 436
>>>>>>> ++
>>>>>>> +diff -urN bind-9.3.1.orig/conf/named.conf bind-9.3.1/conf/named.conf
>>>>>>> +--- bind-9.3.1.orig/conf/named.conf    1970-01-01 01:00:00.000000000 +0100
>>>>>>> ++++ bind-9.3.1/conf/named.conf 2005-07-10 22:33:46.000000000 +0200
>>>>>>> +@@ -0,0 +1,49 @@
>>>>>>> ++// This is the primary configuration file for the BIND DNS server named.
>>>>>>> ++//
>>>>>>> ++// If you are just adding zones, please do that in /etc/bind/named.conf.local
>>>>>>> ++
>>>>>>> ++include "/etc/bind/named.conf.options";
>>>>>>> ++
>>>>>>> ++// prime the server with knowledge of the root servers
>>>>>>> ++zone "." {
>>>>>>> ++      type hint;
>>>>>>> ++      file "/etc/bind/db.root";
>>>>>>> ++};
>>>>>>> ++
>>>>>>> ++// be authoritative for the localhost forward and reverse zones, and for
>>>>>>> ++// broadcast zones as per RFC 1912
>>>>>>> ++
>>>>>>> ++zone "localhost" {
>>>>>>> ++      type master;
>>>>>>> ++      file "/etc/bind/db.local";
>>>>>>> ++};
>>>>>>> ++
>>>>>>> ++zone "127.in-addr.arpa" {
>>>>>>> ++      type master;
>>>>>>> ++      file "/etc/bind/db.127";
>>>>>>> ++};
>>>>>>> ++
>>>>>>> ++zone "0.in-addr.arpa" {
>>>>>>> ++      type master;
>>>>>>> ++      file "/etc/bind/db.0";
>>>>>>> ++};
>>>>>>> ++
>>>>>>> ++zone "255.in-addr.arpa" {
>>>>>>> ++      type master;
>>>>>>> ++      file "/etc/bind/db.255";
>>>>>>> ++};
>>>>>>> ++
>>>>>>> ++// zone "com" { type delegation-only; };
>>>>>>> ++// zone "net" { type delegation-only; };
>>>>>>> ++
>>>>>>> ++// From the release notes:
>>>>>>> ++//  Because many of our users are uncomfortable receiving undelegated answers
>>>>>>> ++//  from root or top level domains, other than a few for whom that behaviour
>>>>>>> ++//  has been trusted and expected for quite some length of time, we have now
>>>>>>> ++//  introduced the "root-delegations-only" feature which applies delegation-only
>>>>>>> ++//  logic to all top level domains, and to the root domain.  An exception list
>>>>>>> ++//  should be specified, including "MUSEUM" and "DE", and any other top level
>>>>>>> ++//  domains from whom undelegated responses are expected and trusted.
>>>>>>> ++// root-delegation-only exclude { "DE"; "MUSEUM"; };
>>>>>>> ++
>>>>>>> ++include "/etc/bind/named.conf.local";
>>>>>>> +diff -urN bind-9.3.1.orig/conf/named.conf.local bind-9.3.1/conf/named.conf.local
>>>>>>> +--- bind-9.3.1.orig/conf/named.conf.local      1970-01-01 01:00:00.000000000 +0100
>>>>>>> ++++ bind-9.3.1/conf/named.conf.local   2005-07-10 22:14:06.000000000 +0200
>>>>>>> +@@ -0,0 +1,8 @@
>>>>>>> ++//
>>>>>>> ++// Do any local configuration here
>>>>>>> ++//
>>>>>>> ++
>>>>>>> ++// Consider adding the 1918 zones here, if they are not used in your
>>>>>>> ++// organization
>>>>>>> ++//include "/etc/bind/zones.rfc1918";
>>>>>>> ++
>>>>>>> +diff -urN bind-9.3.1.orig/conf/named.conf.options bind-9.3.1/conf/named.conf.options
>>>>>>> +--- bind-9.3.1.orig/conf/named.conf.options    1970-01-01 01:00:00.000000000 +0100
>>>>>>> ++++ bind-9.3.1/conf/named.conf.options 2005-07-10 22:14:06.000000000 +0200
>>>>>>> +@@ -0,0 +1,24 @@
>>>>>>> ++options {
>>>>>>> ++      directory "/var/cache/bind";
>>>>>>> ++
>>>>>>> ++      // If there is a firewall between you and nameservers you want
>>>>>>> ++      // to talk to, you might need to uncomment the query-source
>>>>>>> ++      // directive below.  Previous versions of BIND always asked
>>>>>>> ++      // questions using port 53, but BIND 8.1 and later use an unprivileged
>>>>>>> ++      // port by default.
>>>>>>> ++
>>>>>>> ++      // query-source address * port 53;
>>>>>>> ++
>>>>>>> ++      // If your ISP provided one or more IP addresses for stable
>>>>>>> ++      // nameservers, you probably want to use them as forwarders.
>>>>>>> ++      // Uncomment the following block, and insert the addresses replacing
>>>>>>> ++      // the all-0's placeholder.
>>>>>>> ++
>>>>>>> ++      // forwarders {
>>>>>>> ++      //      0.0.0.0;
>>>>>>> ++      // };
>>>>>>> ++
>>>>>>> ++      auth-nxdomain no;    # conform to RFC1035
>>>>>>> ++
>>>>>>> ++};
>>>>>>> ++
>>>>>>> +diff -urN bind-9.3.1.orig/conf/zones.rfc1918 bind-9.3.1/conf/zones.rfc1918
>>>>>>> +--- bind-9.3.1.orig/conf/zones.rfc1918 1970-01-01 01:00:00.000000000 +0100
>>>>>>> ++++ bind-9.3.1/conf/zones.rfc1918      2005-07-10 22:14:10.000000000 +0200
>>>>>>> +@@ -0,0 +1,20 @@
>>>>>>> ++zone "10.in-addr.arpa"      { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++
>>>>>>> ++zone "16.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++zone "17.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++zone "18.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++zone "19.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++zone "20.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++zone "21.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++zone "22.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++zone "23.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++zone "24.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++zone "25.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++zone "26.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++zone "27.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++zone "28.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++zone "29.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++zone "30.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++zone "31.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
>>>>>>> ++
>>>>>>> ++zone "168.192.in-addr.arpa" { type master; file "/etc/bind/db.empty"; };
>>>>>>> +diff -urN bind-9.3.1.orig/init.d bind-9.3.1/init.d
>>>>>>> +--- bind-9.3.1.orig/init.d     1970-01-01 01:00:00.000000000 +0100
>>>>>>> ++++ bind-9.3.1/init.d  2005-07-10 23:09:58.000000000 +0200
>>>>>>> +@@ -0,0 +1,70 @@
>>>>>>> ++#!/bin/sh
>>>>>>> ++
>>>>>>> ++PATH=/sbin:/bin:/usr/sbin:/usr/bin
>>>>>>> ++
>>>>>>> ++# for a chrooted server: "-u bind -t /var/lib/named"
>>>>>>> ++# Don't modify this line, change or create /etc/default/bind9.
>>>>>>> ++OPTIONS=""
>>>>>>> ++
>>>>>>> ++test -f /etc/default/bind9 && . /etc/default/bind9
>>>>>>> ++
>>>>>>> ++test -x /usr/sbin/rndc || exit 0
>>>>>>> ++
>>>>>>> ++case "$1" in
>>>>>>> ++    start)
>>>>>>> ++      echo -n "Starting domain name service: named"
>>>>>>> ++
>>>>>>> ++      modprobe capability >/dev/null 2>&1 || true
>>>>>>> ++      if [ ! -f /etc/bind/rndc.key ]; then
>>>>>>> ++          /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
>>>>>>> ++          chmod 0640 /etc/bind/rndc.key
>>>>>>> ++      fi
>>>>>>> ++      if [ -f /var/run/named/named.pid ]; then
>>>>>>> ++          ps `cat /var/run/named/named.pid` > /dev/null && exit 1
>>>>>>> ++      fi
>>>>>>> ++
>>>>>>> ++      # dirs under /var/run can go away on reboots.
>>>>>>> ++      mkdir -p /var/run/named
>>>>>>> ++      mkdir -p /var/cache/bind
>>>>>>> ++      chmod 775 /var/run/named
>>>>>>> ++      chown root:bind /var/run/named >/dev/null 2>&1 || true
>>>>>>> ++
>>>>>>> ++      if [ ! -x /usr/sbin/named ]; then
>>>>>>> ++          echo "named binary missing - not starting"
>>>>>>> ++          exit 1
>>>>>>> ++      fi
>>>>>>> ++      if start-stop-daemon --start --quiet --exec /usr/sbin/named \
>>>>>>> ++              --pidfile /var/run/named/named.pid -- $OPTIONS; then
>>>>>>> ++          if [ -x /sbin/resolvconf ] ; then
>>>>>>> ++              echo "nameserver 127.0.0.1" | /sbin/resolvconf -a lo
>>>>>>> ++          fi
>>>>>>> ++      fi
>>>>>>> ++      echo "."
>>>>>>> ++    ;;
>>>>>>> ++
>>>>>>> ++    stop)
>>>>>>> ++      echo -n "Stopping domain name service: named"
>>>>>>> ++      if [ -x /sbin/resolvconf ]; then
>>>>>>> ++          /sbin/resolvconf -d lo
>>>>>>> ++      fi
>>>>>>> ++      /usr/sbin/rndc stop >/dev/null 2>&1
>>>>>>> ++      echo "."
>>>>>>> ++    ;;
>>>>>>> ++
>>>>>>> ++    reload)
>>>>>>> ++      /usr/sbin/rndc reload
>>>>>>> ++    ;;
>>>>>>> ++
>>>>>>> ++    restart|force-reload)
>>>>>>> ++      $0 stop
>>>>>>> ++      sleep 2
>>>>>>> ++      $0 start
>>>>>>> ++    ;;
>>>>>>> ++
>>>>>>> ++    *)
>>>>>>> ++      echo "Usage: /etc/init.d/bind {start|stop|reload|restart|force-reload}" >&2
>>>>>>> ++      exit 1
>>>>>>> ++    ;;
>>>>>>> ++esac
>>>>>>> ++
>>>>>>> ++exit 0
>>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
>>>>>>> new file mode 100644
>>>>>>> index 00000000000..ef915c0ae5a
>>>>>>> --- /dev/null
>>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
>>>>>>> @@ -0,0 +1,8 @@
>>>>>>> +#!/bin/sh
>>>>>>> +
>>>>>>> +if [ ! -s /etc/bind/rndc.key ]; then
>>>>>>> +    echo -n "Generating /etc/bind/rndc.key:"
>>>>>>> +    /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
>>>>>>> +    chown root:bind /etc/bind/rndc.key
>>>>>>> +    chmod 0640 /etc/bind/rndc.key
>>>>>>> +fi
>>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
>>>>>>> new file mode 100644
>>>>>>> index 00000000000..11db95ede12
>>>>>>> --- /dev/null
>>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
>>>>>>> @@ -0,0 +1,65 @@
>>>>>>> +Subject: init.d: add support for read-only rootfs
>>>>>>> +
>>>>>>> +Upstream-Status: Inappropriate [oe specific]
>>>>>>> +
>>>>>>> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
>>>>>>> +---
>>>>>>> + init.d |   40 ++++++++++++++++++++++++++++++++++++++++
>>>>>>> + 1 file changed, 40 insertions(+)
>>>>>>> +
>>>>>>> +diff --git a/init.d b/init.d
>>>>>>> +index 0111ed4..24677c8 100644
>>>>>>> +--- a/init.d
>>>>>>> ++++ b/init.d
>>>>>>> +@@ -6,8 +6,48 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin
>>>>>>> + # Don't modify this line, change or create /etc/default/bind9.
>>>>>>> + OPTIONS=""
>>>>>>> +
>>>>>>> ++test -f /etc/default/rcS && . /etc/default/rcS
>>>>>>> + test -f /etc/default/bind9 && . /etc/default/bind9
>>>>>>> +
>>>>>>> ++# This function is here because it's possible that /var and / are on different partitions.
>>>>>>> ++is_on_read_only_partition () {
>>>>>>> ++    DIRECTORY=$1
>>>>>>> ++    dir=`readlink -f $DIRECTORY`
>>>>>>> ++    while true; do
>>>>>>> ++      if [ ! -d "$dir" ]; then
>>>>>>> ++          echo "ERROR: $dir is not a directory"
>>>>>>> ++          exit 1
>>>>>>> ++      else
>>>>>>> ++          for flag in `awk -v dir=$dir '{ if ($2 == dir) { print "FOUND"; split($4,FLAGS,",") } }; \
>>>>>>> ++              END { for (f in FLAGS) print FLAGS[f] }' < /proc/mounts`; do
>>>>>>> ++              [ "$flag" = "FOUND" ] && partition="read-write"
>>>>>>> ++              [ "$flag" = "ro" ] && { partition="read-only"; break; }
>>>>>>> ++          done
>>>>>>> ++          if [ "$dir" = "/" -o -n "$partition" ]; then
>>>>>>> ++              break
>>>>>>> ++          else
>>>>>>> ++              dir=`dirname $dir`
>>>>>>> ++          fi
>>>>>>> ++      fi
>>>>>>> ++    done
>>>>>>> ++    [ "$partition" = "read-only" ] && echo "yes" || echo "no"
>>>>>>> ++}
>>>>>>> ++
>>>>>>> ++bind_mount () {
>>>>>>> ++    olddir=$1
>>>>>>> ++    newdir=$2
>>>>>>> ++    mkdir -p $olddir
>>>>>>> ++    cp -a $newdir/* $olddir
>>>>>>> ++    mount --bind $olddir $newdir
>>>>>>> ++}
>>>>>>> ++
>>>>>>> ++# Deal with read-only rootfs
>>>>>>> ++if [ "$ROOTFS_READ_ONLY" = "yes" ]; then
>>>>>>> ++    [ "$VERBOSE" != "no" ] && echo "WARN: start bind service in read-only rootfs"
>>>>>>> ++    [ `is_on_read_only_partition /etc/bind` = "yes" ] && bind_mount /var/volatile/bind/etc /etc/bind
>>>>>>> ++    [ `is_on_read_only_partition /var/named` = "yes" ] && bind_mount /var/volatile/bind/named /var/named
>>>>>>> ++fi
>>>>>>> ++
>>>>>>> + test -x /usr/sbin/rndc || exit 0
>>>>>>> +
>>>>>>> + case "$1" in
>>>>>>> +--
>>>>>>> +1.7.9.5
>>>>>>> +
>>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
>>>>>>> new file mode 100644
>>>>>>> index 00000000000..146f3e35db6
>>>>>>> --- /dev/null
>>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
>>>>>>> @@ -0,0 +1,42 @@
>>>>>>> +bind: make "/etc/init.d/bind stop" work
>>>>>>> +
>>>>>>> +Upstream-Status: Inappropriate [configuration]
>>>>>>> +
>>>>>>> +Add some configurations, make rndc command be able to controls
>>>>>>> +the named daemon.
>>>>>>> +
>>>>>>> +Signed-off-by: Roy Li <rongqing.li@windriver.com>
>>>>>>> +---
>>>>>>> + conf/named.conf |    5 +++++
>>>>>>> + conf/rndc.conf  |    5 +++++
>>>>>>> + 2 files changed, 10 insertions(+), 0 deletions(-)
>>>>>>> + create mode 100644 conf/rndc.conf
>>>>>>> +
>>>>>>> +diff --git a/conf/named.conf b/conf/named.conf
>>>>>>> +index 95829cf..c8899e7 100644
>>>>>>> +--- a/conf/named.conf
>>>>>>> ++++ b/conf/named.conf
>>>>>>> +@@ -47,3 +47,8 @@ zone "255.in-addr.arpa" {
>>>>>>> + // root-delegation-only exclude { "DE"; "MUSEUM"; };
>>>>>>> +
>>>>>>> + include "/etc/bind/named.conf.local";
>>>>>>> ++include "/etc/bind/rndc.key" ;
>>>>>>> ++controls {
>>>>>>> ++      inet 127.0.0.1 allow { localhost; }
>>>>>>> ++      keys { rndc-key; };
>>>>>>> ++};
>>>>>>> +diff --git a/conf/rndc.conf b/conf/rndc.conf
>>>>>>> +new file mode 100644
>>>>>>> +index 0000000..a0b481d
>>>>>>> +--- /dev/null
>>>>>>> ++++ b/conf/rndc.conf
>>>>>>> +@@ -0,0 +1,5 @@
>>>>>>> ++include "/etc/bind/rndc.key";
>>>>>>> ++options {
>>>>>>> ++      default-server  localhost;
>>>>>>> ++      default-key     rndc-key;
>>>>>>> ++};
>>>>>>> +
>>>>>>> +--
>>>>>>> +1.7.5.4
>>>>>>> +
>>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/named.service b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
>>>>>>> new file mode 100644
>>>>>>> index 00000000000..cda56ef0150
>>>>>>> --- /dev/null
>>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
>>>>>>> @@ -0,0 +1,22 @@
>>>>>>> +[Unit]
>>>>>>> +Description=Berkeley Internet Name Domain (DNS)
>>>>>>> +Wants=nss-lookup.target
>>>>>>> +Before=nss-lookup.target
>>>>>>> +After=network.target
>>>>>>> +
>>>>>>> +[Service]
>>>>>>> +Type=forking
>>>>>>> +EnvironmentFile=-/etc/default/bind9
>>>>>>> +PIDFile=/run/named/named.pid
>>>>>>> +
>>>>>>> +ExecStartPre=@SBINDIR@/generate-rndc-key.sh
>>>>>>> +ExecStart=@SBINDIR@/named $OPTIONS
>>>>>>> +
>>>>>>> +ExecReload=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc reload > /dev/null 2>&1 || @BASE_BINDIR@/kill -HUP $MAINPID'
>>>>>>> +
>>>>>>> +ExecStop=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc stop > /dev/null 2>&1 || @BASE_BINDIR@/kill -TERM $MAINPID'
>>>>>>> +
>>>>>>> +PrivateTmp=true
>>>>>>> +
>>>>>>> +[Install]
>>>>>>> +WantedBy=multi-user.target
>>>>>>> diff --git a/meta/recipes-connectivity/bind/bind_9.16.5.bb b/meta/recipes-connectivity/bind/bind_9.16.5.bb
>>>>>>> new file mode 100644
>>>>>>> index 00000000000..9c20ccc6fa2
>>>>>>> --- /dev/null
>>>>>>> +++ b/meta/recipes-connectivity/bind/bind_9.16.5.bb
>>>>>>> @@ -0,0 +1,125 @@
>>>>>>> +SUMMARY = "ISC Internet Domain Name Server"
>>>>>>> +HOMEPAGE = "http://www.isc.org/sw/bind/"
>>>>>>> +SECTION = "console/network"
>>>>>>> +
>>>>>>> +LICENSE = "MPL-2.0"
>>>>>>> +LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=188b8d0644bd6835df43b84e3f180be1"
>>>>>>> +
>>>>>>> +DEPENDS = "openssl libcap zlib libuv"
>>>>>>> +
>>>>>>> +SRC_URI = "https://ftp.isc.org/isc/bind9/${PV}/${BPN}-${PV}.tar.xz \
>>>>>>> +           file://conf.patch \
>>>>>>> +           file://named.service \
>>>>>>> +           file://bind9 \
>>>>>>> +           file://generate-rndc-key.sh \
>>>>>>> +           file://make-etc-initd-bind-stop-work.patch \
>>>>>>> +           file://init.d-add-support-for-read-only-rootfs.patch \
>>>>>>> +           file://bind-ensure-searching-for-json-headers-searches-sysr.patch \
>>>>>>> +           file://0001-named-lwresd-V-and-start-log-hide-build-options.patch \
>>>>>>> +           file://0001-avoid-start-failure-with-bind-user.patch \
>>>>>>> +           "
>>>>>>> +
>>>>>>> +SRC_URI[sha256sum] = "6378b3e51fef11a8be4794dc48e8111ba92d211c0dfd129a0c296ed06a3dc075"
>>>>>>> +
>>>>>>> +UPSTREAM_CHECK_URI = "https://ftp.isc.org/isc/bind9/"
>>>>>>> +# stay at 9.16 follow the ESV versions divisible by 4
>>>>>>> +UPSTREAM_CHECK_REGEX = "(?P<pver>9.(16|20|24|28)(\.\d+)+(-P\d+)*)/"
>>>>>>> +
>>>>>>> +inherit autotools update-rc.d systemd useradd pkgconfig multilib_script multilib_header
>>>>>>> +
>>>>>>> +MULTILIB_SCRIPTS = "${PN}:${bindir}/bind9-config ${PN}:${bindir}/isc-config.sh"
>>>>>>> +
>>>>>>> +# PACKAGECONFIGs readline and libedit should NOT be set at same time
>>>>>>> +PACKAGECONFIG ?= "readline"
>>>>>>> +PACKAGECONFIG[httpstats] = "--with-libxml2=${STAGING_DIR_HOST}${prefix},--without-libxml2,libxml2"
>>>>>>> +PACKAGECONFIG[readline] = "--with-readline=-lreadline,,readline"
>>>>>>> +PACKAGECONFIG[libedit] = "--with-readline=-ledit,,libedit"
>>>>>>> +PACKAGECONFIG[python3] = "--with-python=yes --with-python-install-dir=${PYTHON_SITEPACKAGES_DIR} , --without-python, python3-ply-native,"
>>>>>>> +
>>>>>>> +EXTRA_OECONF = " --with-libtool --disable-devpoll --enable-epoll \
>>>>>>> +                 --with-gssapi=no --with-lmdb=no --with-zlib \
>>>>>>> +                 --sysconfdir=${sysconfdir}/bind \
>>>>>>> +                 --with-openssl=${STAGING_DIR_HOST}${prefix} \
>>>>>>> +               "
>>>>>>> +LDFLAGS_append = " -lz"
>>>>>>> +
>>>>>>> +inherit ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3native distutils3-base', '', d)}
>>>>>>> +
>>>>>>> +# dhcp needs .la so keep them
>>>>>>> +REMOVE_LIBTOOL_LA = "0"
>>>>>>> +
>>>>>>> +USERADD_PACKAGES = "${PN}"
>>>>>>> +USERADD_PARAM_${PN} = "--system --home ${localstatedir}/cache/bind --no-create-home \
>>>>>>> +                       --user-group bind"
>>>>>>> +
>>>>>>> +INITSCRIPT_NAME = "bind"
>>>>>>> +INITSCRIPT_PARAMS = "defaults"
>>>>>>> +
>>>>>>> +SYSTEMD_SERVICE_${PN} = "named.service"
>>>>>>> +
>>>>>>> +do_install_append() {
>>>>>>> +
>>>>>>> +       rmdir "${D}${localstatedir}/run"
>>>>>>> +       rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
>>>>>>> +       install -d -o bind "${D}${localstatedir}/cache/bind"
>>>>>>> +       install -d "${D}${sysconfdir}/bind"
>>>>>>> +       install -d "${D}${sysconfdir}/init.d"
>>>>>>> +       install -m 644 ${S}/conf/* "${D}${sysconfdir}/bind/"
>>>>>>> +       install -m 755 "${S}/init.d" "${D}${sysconfdir}/init.d/bind"
>>>>>>> +        if ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'true', 'false', d)}; then
>>>>>>> +               sed -i -e '1s,#!.*python3,#! /usr/bin/python3,' \
>>>>>>> +               ${D}${sbindir}/dnssec-coverage \
>>>>>>> +               ${D}${sbindir}/dnssec-checkds \
>>>>>>> +               ${D}${sbindir}/dnssec-keymgr
>>>>>>> +       fi
>>>>>>> +
>>>>>>> +       # Install systemd related files
>>>>>>> +       install -d ${D}${sbindir}
>>>>>>> +       install -m 755 ${WORKDIR}/generate-rndc-key.sh ${D}${sbindir}
>>>>>>> +       install -d ${D}${systemd_unitdir}/system
>>>>>>> +       install -m 0644 ${WORKDIR}/named.service ${D}${systemd_unitdir}/system
>>>>>>> +       sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
>>>>>>> +              -e 's,@SBINDIR@,${sbindir},g' \
>>>>>>> +              ${D}${systemd_unitdir}/system/named.service
>>>>>>> +
>>>>>>> +       install -d ${D}${sysconfdir}/default
>>>>>>> +       install -m 0644 ${WORKDIR}/bind9 ${D}${sysconfdir}/default
>>>>>>> +
>>>>>>> +       if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
>>>>>>> +               install -d ${D}${sysconfdir}/tmpfiles.d
>>>>>>> +               echo "d /run/named 0755 bind bind - -" > ${D}${sysconfdir}/tmpfiles.d/bind.conf
>>>>>>> +       fi
>>>>>>> +
>>>>>>> +    oe_multilib_header isc/platform.h
>>>>>>> +}
>>>>>>> +
>>>>>>> +CONFFILES_${PN} = " \
>>>>>>> +       ${sysconfdir}/bind/named.conf \
>>>>>>> +       ${sysconfdir}/bind/named.conf.local \
>>>>>>> +       ${sysconfdir}/bind/named.conf.options \
>>>>>>> +       ${sysconfdir}/bind/db.0 \
>>>>>>> +       ${sysconfdir}/bind/db.127 \
>>>>>>> +       ${sysconfdir}/bind/db.empty \
>>>>>>> +       ${sysconfdir}/bind/db.local \
>>>>>>> +       ${sysconfdir}/bind/db.root \
>>>>>>> +       "
>>>>>>> +
>>>>>>> +ALTERNATIVE_${PN}-utils = "nslookup"
>>>>>>> +ALTERNATIVE_LINK_NAME[nslookup] = "${bindir}/nslookup"
>>>>>>> +ALTERNATIVE_PRIORITY = "100"
>>>>>> I'm seeing this failing with busybox:
>>>>>> update-alternatives: Error: not linking
>>>>>> /development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
>>>>>> to /bin/busybox.nosuid since
>>>>>> /development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
>>>>>> exists and is not a link
>>>>>>
>>>>>> busybox sets ALTERNATIVE_PRIORITY = "50". Can this be the issue?
>>>>>
>>>>> That is weird. I would have expected that to be an issue with the old
>>>>> version too.
>>>>>
>>>>> Got any steps to reproduce this?
>>>>
>>>> Sorry for delayed response here, it took me some time but I've finally
>>>> figured the setup to reproduce the issue.
>>>>
>>>> I've used the "vanilla" Poky from master, added IMAGE_INSTALL +=
>>>> "bind-utils" to core-image-minimal and switched from RPM to IPK
>>>> format. The last thing turned out to be the trigger for the issue, as
>>>> with RPM package format I was not able to reproduce the issue, and
>>>> this was cause of the delay here.
>>>>
>>>> After the above is done - following error is produced:
>>>> WARNING: core-image-minimal-1.0-r0 do_rootfs: busybox.postinst
>>>> returned 1, marking as unpacked only, configuration required on
>>>> target.
>>>> ERROR: core-image-minimal-1.0-r0 do_rootfs: Postinstall scriptlets of
>>>> ['busybox'] have failed. If the intention is to defer them to first
>>>> boot,
>>>> then please place them into pkg_postinst_ontarget_${PN} ().
>>>> Deferring to first boot via 'exit 1' is no longer supported.
>>>> Details of the failure are in
>>>> /development/projects/poky-vanilla/poky/build/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/temp/log.do_rootfs.
>>>> ERROR: Logfile of failure stored in:
>>>> /development/projects/poky-vanilla/poky/build/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/temp/log.do_rootfs.6423
>>>> ERROR: Task (/development/projects/poky-vanilla/poky/meta/recipes-core/images/core-image-minimal.bb:do_rootfs)
>>>> failed with exit code '1'
>>>> NOTE: Tasks Summary: Attempted 3554 tasks of which 3552 didn't need to
>>>> be rerun and 1 failed.
>>>>
>>>> Summary: 1 task failed:
>>>>    /development/projects/poky-vanilla/poky/meta/recipes-core/images/core-image-minimal.bb:do_rootfs
>>>> ed:
>>>>
>>>> 'nslookup' is definitely comming from the bind-utils package, and the
>>>> only thing I've noted so far it that in bind-9.11.22 result binary
>>>> name in ${D} is [nslookup.bind], which is different from the one
>>>> provided in bind-9.16.5 - [nslookup].
>>>>
>>>> In case of previous bind version - both versions seems to be
>>>> installed, and the symlink is fixed onto the nslookup.bind. In the
>>>> current version though - I guess that the real binary is installed
>>>> instead, making symlink operation to fail during update-alternative.
>>>
>>> If it is competing with busybox then perhaps priority for bind to
>>> provide nslookup should be higher than busybox. Can you try that ?
>>
>> busybox has ALTERNATIVE_PRIORITY = "50" while bind is set to
>> ALTERNATIVE_PRIORITY = "100". IIRC higher number means higher priority
>> which is already the case...
>>
>> Nevertheless, I've tried to set 50 and even 40 for 'bind' and had the
>> same failure...
>>
>>>
>>>>
>>>>
>>>>
>>>>>
>>>>> -armin
>>>>>>
>>>>>> Going back to bind 9.11.22 seems to solve it...
>>>>>>
>>>>>>> +
>>>>>>> +PACKAGE_BEFORE_PN += "${PN}-utils"
>>>>>>> +FILES_${PN}-utils = "${bindir}/host ${bindir}/dig ${bindir}/mdig ${bindir}/nslookup ${bindir}/nsupdate"
>>>>>>> +FILES_${PN}-dev += "${bindir}/isc-config.h"
>>>>>>> +FILES_${PN} += "${sbindir}/generate-rndc-key.sh"
>>>>>>> +
>>>>>>> +PACKAGE_BEFORE_PN += "${PN}-libs"
>>>>>>> +FILES_${PN}-libs = "${libdir}/*.so* ${libdir}/named/*.so*"
>>>>>>> +FILES_${PN}-staticdev += "${libdir}/*.la"
>>>>>>> +
>>>>>>> +PACKAGE_BEFORE_PN += "${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3-bind', '', d)}"
>>>>>>> +FILES_python3-bind = "${sbindir}/dnssec-coverage ${sbindir}/dnssec-checkds \
>>>>>>> +                ${sbindir}/dnssec-keymgr ${PYTHON_SITEPACKAGES_DIR}"
>>>>>>> +
>>>>>>> +RDEPENDS_${PN}-dev = ""
>>>>>>> +RDEPENDS_python3-bind = "python3-core python3-ply"
>>>>>>> --
>>>>>>> 2.17.1
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Regards,
>>>> Andrey.
>>>>
>>>>
>>>> 
>>>>
>>>
>>
>>
>> --
>> Regards,
>> Andrey.
> 
> 
> 

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [OE-core] [PATCH 7/8] bind: Add 9.16.x
  2020-09-14 19:04               ` Khem Raj
@ 2020-09-14 20:48                 ` Andrey Zhizhikin
  0 siblings, 0 replies; 24+ messages in thread
From: Andrey Zhizhikin @ 2020-09-14 20:48 UTC (permalink / raw)
  To: Khem Raj; +Cc: akuster808, OE Core mailing list

On Mon, Sep 14, 2020 at 9:04 PM Khem Raj <raj.khem@gmail.com> wrote:
>
>
>
> On 9/14/20 10:55 AM, Andrey Zhizhikin wrote:
> > Gentle ping here regarding this issue.
> >
> > Is thre anyone else experiencing this with IPK packages?
>
> Alright thanks for being persist it has paid off :) I have taken a look
> at it and sent a fix to ml

Thanks a lot! :)

Actually, it was such an obvious thing that I managed to overlook - it
didn't cross my eye that update-alternative inheritance was missing in
the first place! :)

The mystery that still remains however: why did it work for RPM
package types? Is there a check that is missing somewhere, or
update-alternatives are inherited implicitly?

I guess if not because of the fact that it did work out for RPM in the
first place - those kinds of obvious failures could be avoided at the
very start.

>
>
> >
> > On Thu, Sep 10, 2020 at 9:12 AM Andrey Zhizhikin <andrey.z@gmail.com> wrote:
> >>
> >> On Thu, Sep 10, 2020 at 1:53 AM Khem Raj <raj.khem@gmail.com> wrote:
> >>>
> >>>
> >>>
> >>> On 9/7/20 2:17 PM, Andrey Zhizhikin wrote:
> >>>> On Mon, Sep 7, 2020 at 5:28 PM akuster808 <akuster808@gmail.com> wrote:
> >>>>>
> >>>>>
> >>>>>
> >>>>> On 9/4/20 1:39 AM, Andrey Zhizhikin wrote:
> >>>>>> Hello Armin,
> >>>>>>
> >>>>>> On Tue, Sep 1, 2020 at 5:23 PM akuster <akuster808@gmail.com> wrote:
> >>>>>>> Removed obsolete packageconfig options
> >>>>>>>
> >>>>>>> License change to MPL-2.0
> >>>>>>> https://gitlab.isc.org/isc-projects/bind9/blob/master/LICENSE
> >>>>>>>
> >>>>>>> Refreshed:
> >>>>>>> bind-ensure-searching-for-json-headers-searches-sysr.patch
> >>>>>>> 0001-named-lwresd-V-and-start-log-hide-build-options.patch
> >>>>>>> bind-ensure-searching-for-json-headers-searches-sysr.patch
> >>>>>>>
> >>>>>>> Drop obsolete patch: 0001-configure.in-remove-useless-L-use_openssl-lib.patch
> >>>>>>>
> >>>>>>> Signed-off-by: Armin Kuster <akuster808@gmail.com>
> >>>>>>> ---
> >>>>>>>   ...1-avoid-start-failure-with-bind-user.patch |  27 ++
> >>>>>>>   ...d-V-and-start-log-hide-build-options.patch |  35 ++
> >>>>>>>   ...ching-for-json-headers-searches-sysr.patch |  47 +++
> >>>>>>>   .../bind/bind-9.16.5/bind9                    |   2 +
> >>>>>>>   .../bind/bind-9.16.5/conf.patch               | 330 ++++++++++++++++++
> >>>>>>>   .../bind/bind-9.16.5/generate-rndc-key.sh     |   8 +
> >>>>>>>   ...t.d-add-support-for-read-only-rootfs.patch |  65 ++++
> >>>>>>>   .../make-etc-initd-bind-stop-work.patch       |  42 +++
> >>>>>>>   .../bind/bind-9.16.5/named.service            |  22 ++
> >>>>>>>   meta/recipes-connectivity/bind/bind_9.16.5.bb | 125 +++++++
> >>>>>>>   10 files changed, 703 insertions(+)
> >>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
> >>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
> >>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
> >>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/bind9
> >>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
> >>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
> >>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
> >>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
> >>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind-9.16.5/named.service
> >>>>>>>   create mode 100644 meta/recipes-connectivity/bind/bind_9.16.5.bb
> >>>>>>>
> >>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
> >>>>>>> new file mode 100644
> >>>>>>> index 00000000000..8db96ec049c
> >>>>>>> --- /dev/null
> >>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-avoid-start-failure-with-bind-user.patch
> >>>>>>> @@ -0,0 +1,27 @@
> >>>>>>> +From 31dde3562f287429eea94b77250d184818b49063 Mon Sep 17 00:00:00 2001
> >>>>>>> +From: Chen Qi <Qi.Chen@windriver.com>
> >>>>>>> +Date: Mon, 15 Oct 2018 16:55:09 +0800
> >>>>>>> +Subject: [PATCH] avoid start failure with bind user
> >>>>>>> +
> >>>>>>> +Upstream-Status: Pending
> >>>>>>> +
> >>>>>>> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
> >>>>>>> +---
> >>>>>>> + init.d | 1 +
> >>>>>>> + 1 file changed, 1 insertion(+)
> >>>>>>> +
> >>>>>>> +diff --git a/init.d b/init.d
> >>>>>>> +index b2eec60..6e03936 100644
> >>>>>>> +--- a/init.d
> >>>>>>> ++++ b/init.d
> >>>>>>> +@@ -57,6 +57,7 @@ case "$1" in
> >>>>>>> +       modprobe capability >/dev/null 2>&1 || true
> >>>>>>> +       if [ ! -f /etc/bind/rndc.key ]; then
> >>>>>>> +           /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
> >>>>>>> ++          chown root:bind /etc/bind/rndc.key >/dev/null 2>&1 || true
> >>>>>>> +           chmod 0640 /etc/bind/rndc.key
> >>>>>>> +       fi
> >>>>>>> +       if [ -f /var/run/named/named.pid ]; then
> >>>>>>> +--
> >>>>>>> +2.7.4
> >>>>>>> +
> >>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
> >>>>>>> new file mode 100644
> >>>>>>> index 00000000000..5bcc16c9b2b
> >>>>>>> --- /dev/null
> >>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/0001-named-lwresd-V-and-start-log-hide-build-options.patch
> >>>>>>> @@ -0,0 +1,35 @@
> >>>>>>> +From a3af4a405baf5ff582e82aaba392dd9667d94bdc Mon Sep 17 00:00:00 2001
> >>>>>>> +From: Hongxu Jia <hongxu.jia@windriver.com>
> >>>>>>> +Date: Mon, 27 Aug 2018 21:24:20 +0800
> >>>>>>> +Subject: [PATCH] `named/lwresd -V' and start log hide build options
> >>>>>>> +
> >>>>>>> +The build options expose build path directories, so hide them.
> >>>>>>> +[snip]
> >>>>>>> +$ named -V
> >>>>>>> +|built by make with *** (options are hidden)
> >>>>>>> +[snip]
> >>>>>>> +
> >>>>>>> +Upstream-Status: Inappropriate [oe-core specific]
> >>>>>>> +
> >>>>>>> +Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
> >>>>>>> +
> >>>>>>> +Refreshed for 9.16.0
> >>>>>>> +Signed-off-by: Armin Kuster <akuster@mvista.com>
> >>>>>>> +
> >>>>>>> +---
> >>>>>>> + bin/named/include/named/globals.h | 2 +-
> >>>>>>> + 1 file changed, 1 insertion(+), 1 deletion(-)
> >>>>>>> +
> >>>>>>> +Index: bind-9.16.0/bin/named/include/named/globals.h
> >>>>>>> +===================================================================
> >>>>>>> +--- bind-9.16.0.orig/bin/named/include/named/globals.h
> >>>>>>> ++++ bind-9.16.0/bin/named/include/named/globals.h
> >>>>>>> +@@ -69,7 +69,7 @@ EXTERN const char *named_g_version     I
> >>>>>>> + EXTERN const char *named_g_product     INIT(PRODUCT);
> >>>>>>> + EXTERN const char *named_g_description INIT(DESCRIPTION);
> >>>>>>> + EXTERN const char *named_g_srcid       INIT(SRCID);
> >>>>>>> +-EXTERN const char *named_g_configargs  INIT(CONFIGARGS);
> >>>>>>> ++EXTERN const char *named_g_configargs  INIT("*** (options are hidden)");
> >>>>>>> + EXTERN const char *named_g_builder     INIT(BUILDER);
> >>>>>>> + EXTERN in_port_t named_g_port        INIT(0);
> >>>>>>> + EXTERN isc_dscp_t named_g_dscp               INIT(-1);
> >>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
> >>>>>>> new file mode 100644
> >>>>>>> index 00000000000..f9cdc7ca4df
> >>>>>>> --- /dev/null
> >>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind-ensure-searching-for-json-headers-searches-sysr.patch
> >>>>>>> @@ -0,0 +1,47 @@
> >>>>>>> +From edda20fb5a6e88548f85e39d34d6c074306e15bc Mon Sep 17 00:00:00 2001
> >>>>>>> +From: Paul Gortmaker <paul.gortmaker@windriver.com>
> >>>>>>> +Date: Tue, 9 Jun 2015 11:22:00 -0400
> >>>>>>> +Subject: [PATCH] bind: ensure searching for json headers searches sysroot
> >>>>>>> +
> >>>>>>> +Bind can fail configure by detecting headers w/o libs[1], or
> >>>>>>> +it can fail the host contamination check as per below:
> >>>>>>> +
> >>>>>>> +ERROR: This autoconf log indicates errors, it looked at host include and/or library paths while determining system capabilities.
> >>>>>>> +Rerun configure task after fixing this. The path was 'build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/build'
> >>>>>>> +ERROR: Function failed: do_qa_configure
> >>>>>>> +ERROR: Logfile of failure stored in: build/tmp/work/core2-64-poky-linux/bind/9.10.2-r1/temp/log.do_configure.5242
> >>>>>>> +ERROR: Task 5 (meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure) failed with exit code '1'
> >>>>>>> +NOTE: Tasks Summary: Attempted 773 tasks of which 768 didn't need to be rerun and 1 failed.
> >>>>>>> +No currently running tasks (773 of 781)
> >>>>>>> +
> >>>>>>> +Summary: 1 task failed:
> >>>>>>> +  /meta/recipes-connectivity/bind/bind_9.10.2.bb, do_configure
> >>>>>>> +
> >>>>>>> +One way to fix it would be to unconditionally disable json in bind
> >>>>>>> +configure[2] but here we fix it by using the path to where we would
> >>>>>>> +put the header if we had json in the sysroot, in case someone wants
> >>>>>>> +to make use of the combination some day.
> >>>>>>> +
> >>>>>>> +[1] https://trac.macports.org/ticket/45305
> >>>>>>> +[2] https://trac.macports.org/changeset/126406
> >>>>>>> +
> >>>>>>> +Upstream-Status: Inappropriate [OE Specific]
> >>>>>>> +Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
> >>>>>>> +
> >>>>>>> +---
> >>>>>>> + configure.ac | 2 +-
> >>>>>>> + 1 file changed, 1 insertion(+), 1 deletion(-)
> >>>>>>> +
> >>>>>>> +Index: bind-9.16.4/configure.ac
> >>>>>>> +===================================================================
> >>>>>>> +--- bind-9.16.4.orig/configure.ac
> >>>>>>> ++++ bind-9.16.4/configure.ac
> >>>>>>> +@@ -1232,7 +1232,7 @@ case "$use_lmdb" in
> >>>>>>> +               LMDB_LIBS=""
> >>>>>>> +               ;;
> >>>>>>> +       auto|yes)
> >>>>>>> +-              for d in /usr /usr/local /opt/local
> >>>>>>> ++              for d in "${STAGING_INCDIR}"
> >>>>>>> +               do
> >>>>>>> +                       if test -f "${d}/include/lmdb.h"
> >>>>>>> +                       then
> >>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/bind9 b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
> >>>>>>> new file mode 100644
> >>>>>>> index 00000000000..968679ff7f7
> >>>>>>> --- /dev/null
> >>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/bind9
> >>>>>>> @@ -0,0 +1,2 @@
> >>>>>>> +# startup options for the server
> >>>>>>> +OPTIONS="-u bind"
> >>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
> >>>>>>> new file mode 100644
> >>>>>>> index 00000000000..aad345f9fcf
> >>>>>>> --- /dev/null
> >>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/conf.patch
> >>>>>>> @@ -0,0 +1,330 @@
> >>>>>>> +Upstream-Status: Inappropriate [configuration]
> >>>>>>> +
> >>>>>>> +the patch is imported from openembedded project
> >>>>>>> +
> >>>>>>> +11/30/2010 - Qing He <qing.he@intel.com>
> >>>>>>> +
> >>>>>>> +diff -urN bind-9.3.1.orig/conf/db.0 bind-9.3.1/conf/db.0
> >>>>>>> +--- bind-9.3.1.orig/conf/db.0  1970-01-01 01:00:00.000000000 +0100
> >>>>>>> ++++ bind-9.3.1/conf/db.0       2005-07-10 22:14:00.000000000 +0200
> >>>>>>> +@@ -0,0 +1,12 @@
> >>>>>>> ++;
> >>>>>>> ++; BIND reverse data file for broadcast zone
> >>>>>>> ++;
> >>>>>>> ++$TTL  604800
> >>>>>>> ++@     IN      SOA     localhost. root.localhost. (
> >>>>>>> ++                            1         ; Serial
> >>>>>>> ++                       604800         ; Refresh
> >>>>>>> ++                        86400         ; Retry
> >>>>>>> ++                      2419200         ; Expire
> >>>>>>> ++                       604800 )       ; Negative Cache TTL
> >>>>>>> ++;
> >>>>>>> ++@     IN      NS      localhost.
> >>>>>>> +diff -urN bind-9.3.1.orig/conf/db.127 bind-9.3.1/conf/db.127
> >>>>>>> +--- bind-9.3.1.orig/conf/db.127        1970-01-01 01:00:00.000000000 +0100
> >>>>>>> ++++ bind-9.3.1/conf/db.127     2005-07-10 22:14:00.000000000 +0200
> >>>>>>> +@@ -0,0 +1,13 @@
> >>>>>>> ++;
> >>>>>>> ++; BIND reverse data file for local loopback interface
> >>>>>>> ++;
> >>>>>>> ++$TTL  604800
> >>>>>>> ++@     IN      SOA     localhost. root.localhost. (
> >>>>>>> ++                            1         ; Serial
> >>>>>>> ++                       604800         ; Refresh
> >>>>>>> ++                        86400         ; Retry
> >>>>>>> ++                      2419200         ; Expire
> >>>>>>> ++                       604800 )       ; Negative Cache TTL
> >>>>>>> ++;
> >>>>>>> ++@     IN      NS      localhost.
> >>>>>>> ++1.0.0 IN      PTR     localhost.
> >>>>>>> +diff -urN bind-9.3.1.orig/conf/db.empty bind-9.3.1/conf/db.empty
> >>>>>>> +--- bind-9.3.1.orig/conf/db.empty      1970-01-01 01:00:00.000000000 +0100
> >>>>>>> ++++ bind-9.3.1/conf/db.empty   2005-07-10 22:14:00.000000000 +0200
> >>>>>>> +@@ -0,0 +1,14 @@
> >>>>>>> ++; BIND reverse data file for empty rfc1918 zone
> >>>>>>> ++;
> >>>>>>> ++; DO NOT EDIT THIS FILE - it is used for multiple zones.
> >>>>>>> ++; Instead, copy it, edit named.conf, and use that copy.
> >>>>>>> ++;
> >>>>>>> ++$TTL  86400
> >>>>>>> ++@     IN      SOA     localhost. root.localhost. (
> >>>>>>> ++                            1         ; Serial
> >>>>>>> ++                       604800         ; Refresh
> >>>>>>> ++                        86400         ; Retry
> >>>>>>> ++                      2419200         ; Expire
> >>>>>>> ++                        86400 )       ; Negative Cache TTL
> >>>>>>> ++;
> >>>>>>> ++@     IN      NS      localhost.
> >>>>>>> +diff -urN bind-9.3.1.orig/conf/db.255 bind-9.3.1/conf/db.255
> >>>>>>> +--- bind-9.3.1.orig/conf/db.255        1970-01-01 01:00:00.000000000 +0100
> >>>>>>> ++++ bind-9.3.1/conf/db.255     2005-07-10 22:14:00.000000000 +0200
> >>>>>>> +@@ -0,0 +1,12 @@
> >>>>>>> ++;
> >>>>>>> ++; BIND reserve data file for broadcast zone
> >>>>>>> ++;
> >>>>>>> ++$TTL  604800
> >>>>>>> ++@     IN      SOA     localhost. root.localhost. (
> >>>>>>> ++                            1         ; Serial
> >>>>>>> ++                       604800         ; Refresh
> >>>>>>> ++                        86400         ; Retry
> >>>>>>> ++                      2419200         ; Expire
> >>>>>>> ++                       604800 )       ; Negative Cache TTL
> >>>>>>> ++;
> >>>>>>> ++@     IN      NS      localhost.
> >>>>>>> +diff -urN bind-9.3.1.orig/conf/db.local bind-9.3.1/conf/db.local
> >>>>>>> +--- bind-9.3.1.orig/conf/db.local      1970-01-01 01:00:00.000000000 +0100
> >>>>>>> ++++ bind-9.3.1/conf/db.local   2005-07-10 22:14:00.000000000 +0200
> >>>>>>> +@@ -0,0 +1,13 @@
> >>>>>>> ++;
> >>>>>>> ++; BIND data file for local loopback interface
> >>>>>>> ++;
> >>>>>>> ++$TTL  604800
> >>>>>>> ++@     IN      SOA     localhost. root.localhost. (
> >>>>>>> ++                            1         ; Serial
> >>>>>>> ++                       604800         ; Refresh
> >>>>>>> ++                        86400         ; Retry
> >>>>>>> ++                      2419200         ; Expire
> >>>>>>> ++                       604800 )       ; Negative Cache TTL
> >>>>>>> ++;
> >>>>>>> ++@     IN      NS      localhost.
> >>>>>>> ++@     IN      A       127.0.0.1
> >>>>>>> +diff -urN bind-9.3.1.orig/conf/db.root bind-9.3.1/conf/db.root
> >>>>>>> +--- bind-9.3.1.orig/conf/db.root       1970-01-01 01:00:00.000000000 +0100
> >>>>>>> ++++ bind-9.3.1/conf/db.root    2005-07-10 22:14:00.000000000 +0200
> >>>>>>> +@@ -0,0 +1,45 @@
> >>>>>>> ++
> >>>>>>> ++; <<>> DiG 9.2.3 <<>> ns . @a.root-servers.net.
> >>>>>>> ++;; global options:  printcmd
> >>>>>>> ++;; Got answer:
> >>>>>>> ++;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 18944
> >>>>>>> ++;; flags: qr aa rd; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 13
> >>>>>>> ++
> >>>>>>> ++;; QUESTION SECTION:
> >>>>>>> ++;.                            IN      NS
> >>>>>>> ++
> >>>>>>> ++;; ANSWER SECTION:
> >>>>>>> ++.                     518400  IN      NS      A.ROOT-SERVERS.NET.
> >>>>>>> ++.                     518400  IN      NS      B.ROOT-SERVERS.NET.
> >>>>>>> ++.                     518400  IN      NS      C.ROOT-SERVERS.NET.
> >>>>>>> ++.                     518400  IN      NS      D.ROOT-SERVERS.NET.
> >>>>>>> ++.                     518400  IN      NS      E.ROOT-SERVERS.NET.
> >>>>>>> ++.                     518400  IN      NS      F.ROOT-SERVERS.NET.
> >>>>>>> ++.                     518400  IN      NS      G.ROOT-SERVERS.NET.
> >>>>>>> ++.                     518400  IN      NS      H.ROOT-SERVERS.NET.
> >>>>>>> ++.                     518400  IN      NS      I.ROOT-SERVERS.NET.
> >>>>>>> ++.                     518400  IN      NS      J.ROOT-SERVERS.NET.
> >>>>>>> ++.                     518400  IN      NS      K.ROOT-SERVERS.NET.
> >>>>>>> ++.                     518400  IN      NS      L.ROOT-SERVERS.NET.
> >>>>>>> ++.                     518400  IN      NS      M.ROOT-SERVERS.NET.
> >>>>>>> ++
> >>>>>>> ++;; ADDITIONAL SECTION:
> >>>>>>> ++A.ROOT-SERVERS.NET.   3600000 IN      A       198.41.0.4
> >>>>>>> ++B.ROOT-SERVERS.NET.   3600000 IN      A       192.228.79.201
> >>>>>>> ++C.ROOT-SERVERS.NET.   3600000 IN      A       192.33.4.12
> >>>>>>> ++D.ROOT-SERVERS.NET.   3600000 IN      A       128.8.10.90
> >>>>>>> ++E.ROOT-SERVERS.NET.   3600000 IN      A       192.203.230.10
> >>>>>>> ++F.ROOT-SERVERS.NET.   3600000 IN      A       192.5.5.241
> >>>>>>> ++G.ROOT-SERVERS.NET.   3600000 IN      A       192.112.36.4
> >>>>>>> ++H.ROOT-SERVERS.NET.   3600000 IN      A       128.63.2.53
> >>>>>>> ++I.ROOT-SERVERS.NET.   3600000 IN      A       192.36.148.17
> >>>>>>> ++J.ROOT-SERVERS.NET.   3600000 IN      A       192.58.128.30
> >>>>>>> ++K.ROOT-SERVERS.NET.   3600000 IN      A       193.0.14.129
> >>>>>>> ++L.ROOT-SERVERS.NET.   3600000 IN      A       198.32.64.12
> >>>>>>> ++M.ROOT-SERVERS.NET.   3600000 IN      A       202.12.27.33
> >>>>>>> ++
> >>>>>>> ++;; Query time: 81 msec
> >>>>>>> ++;; SERVER: 198.41.0.4#53(a.root-servers.net.)
> >>>>>>> ++;; WHEN: Sun Feb  1 11:27:14 2004
> >>>>>>> ++;; MSG SIZE  rcvd: 436
> >>>>>>> ++
> >>>>>>> +diff -urN bind-9.3.1.orig/conf/named.conf bind-9.3.1/conf/named.conf
> >>>>>>> +--- bind-9.3.1.orig/conf/named.conf    1970-01-01 01:00:00.000000000 +0100
> >>>>>>> ++++ bind-9.3.1/conf/named.conf 2005-07-10 22:33:46.000000000 +0200
> >>>>>>> +@@ -0,0 +1,49 @@
> >>>>>>> ++// This is the primary configuration file for the BIND DNS server named.
> >>>>>>> ++//
> >>>>>>> ++// If you are just adding zones, please do that in /etc/bind/named.conf.local
> >>>>>>> ++
> >>>>>>> ++include "/etc/bind/named.conf.options";
> >>>>>>> ++
> >>>>>>> ++// prime the server with knowledge of the root servers
> >>>>>>> ++zone "." {
> >>>>>>> ++      type hint;
> >>>>>>> ++      file "/etc/bind/db.root";
> >>>>>>> ++};
> >>>>>>> ++
> >>>>>>> ++// be authoritative for the localhost forward and reverse zones, and for
> >>>>>>> ++// broadcast zones as per RFC 1912
> >>>>>>> ++
> >>>>>>> ++zone "localhost" {
> >>>>>>> ++      type master;
> >>>>>>> ++      file "/etc/bind/db.local";
> >>>>>>> ++};
> >>>>>>> ++
> >>>>>>> ++zone "127.in-addr.arpa" {
> >>>>>>> ++      type master;
> >>>>>>> ++      file "/etc/bind/db.127";
> >>>>>>> ++};
> >>>>>>> ++
> >>>>>>> ++zone "0.in-addr.arpa" {
> >>>>>>> ++      type master;
> >>>>>>> ++      file "/etc/bind/db.0";
> >>>>>>> ++};
> >>>>>>> ++
> >>>>>>> ++zone "255.in-addr.arpa" {
> >>>>>>> ++      type master;
> >>>>>>> ++      file "/etc/bind/db.255";
> >>>>>>> ++};
> >>>>>>> ++
> >>>>>>> ++// zone "com" { type delegation-only; };
> >>>>>>> ++// zone "net" { type delegation-only; };
> >>>>>>> ++
> >>>>>>> ++// From the release notes:
> >>>>>>> ++//  Because many of our users are uncomfortable receiving undelegated answers
> >>>>>>> ++//  from root or top level domains, other than a few for whom that behaviour
> >>>>>>> ++//  has been trusted and expected for quite some length of time, we have now
> >>>>>>> ++//  introduced the "root-delegations-only" feature which applies delegation-only
> >>>>>>> ++//  logic to all top level domains, and to the root domain.  An exception list
> >>>>>>> ++//  should be specified, including "MUSEUM" and "DE", and any other top level
> >>>>>>> ++//  domains from whom undelegated responses are expected and trusted.
> >>>>>>> ++// root-delegation-only exclude { "DE"; "MUSEUM"; };
> >>>>>>> ++
> >>>>>>> ++include "/etc/bind/named.conf.local";
> >>>>>>> +diff -urN bind-9.3.1.orig/conf/named.conf.local bind-9.3.1/conf/named.conf.local
> >>>>>>> +--- bind-9.3.1.orig/conf/named.conf.local      1970-01-01 01:00:00.000000000 +0100
> >>>>>>> ++++ bind-9.3.1/conf/named.conf.local   2005-07-10 22:14:06.000000000 +0200
> >>>>>>> +@@ -0,0 +1,8 @@
> >>>>>>> ++//
> >>>>>>> ++// Do any local configuration here
> >>>>>>> ++//
> >>>>>>> ++
> >>>>>>> ++// Consider adding the 1918 zones here, if they are not used in your
> >>>>>>> ++// organization
> >>>>>>> ++//include "/etc/bind/zones.rfc1918";
> >>>>>>> ++
> >>>>>>> +diff -urN bind-9.3.1.orig/conf/named.conf.options bind-9.3.1/conf/named.conf.options
> >>>>>>> +--- bind-9.3.1.orig/conf/named.conf.options    1970-01-01 01:00:00.000000000 +0100
> >>>>>>> ++++ bind-9.3.1/conf/named.conf.options 2005-07-10 22:14:06.000000000 +0200
> >>>>>>> +@@ -0,0 +1,24 @@
> >>>>>>> ++options {
> >>>>>>> ++      directory "/var/cache/bind";
> >>>>>>> ++
> >>>>>>> ++      // If there is a firewall between you and nameservers you want
> >>>>>>> ++      // to talk to, you might need to uncomment the query-source
> >>>>>>> ++      // directive below.  Previous versions of BIND always asked
> >>>>>>> ++      // questions using port 53, but BIND 8.1 and later use an unprivileged
> >>>>>>> ++      // port by default.
> >>>>>>> ++
> >>>>>>> ++      // query-source address * port 53;
> >>>>>>> ++
> >>>>>>> ++      // If your ISP provided one or more IP addresses for stable
> >>>>>>> ++      // nameservers, you probably want to use them as forwarders.
> >>>>>>> ++      // Uncomment the following block, and insert the addresses replacing
> >>>>>>> ++      // the all-0's placeholder.
> >>>>>>> ++
> >>>>>>> ++      // forwarders {
> >>>>>>> ++      //      0.0.0.0;
> >>>>>>> ++      // };
> >>>>>>> ++
> >>>>>>> ++      auth-nxdomain no;    # conform to RFC1035
> >>>>>>> ++
> >>>>>>> ++};
> >>>>>>> ++
> >>>>>>> +diff -urN bind-9.3.1.orig/conf/zones.rfc1918 bind-9.3.1/conf/zones.rfc1918
> >>>>>>> +--- bind-9.3.1.orig/conf/zones.rfc1918 1970-01-01 01:00:00.000000000 +0100
> >>>>>>> ++++ bind-9.3.1/conf/zones.rfc1918      2005-07-10 22:14:10.000000000 +0200
> >>>>>>> +@@ -0,0 +1,20 @@
> >>>>>>> ++zone "10.in-addr.arpa"      { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++
> >>>>>>> ++zone "16.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++zone "17.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++zone "18.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++zone "19.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++zone "20.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++zone "21.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++zone "22.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++zone "23.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++zone "24.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++zone "25.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++zone "26.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++zone "27.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++zone "28.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++zone "29.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++zone "30.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++zone "31.172.in-addr.arpa"  { type master; file "/etc/bind/db.empty"; };
> >>>>>>> ++
> >>>>>>> ++zone "168.192.in-addr.arpa" { type master; file "/etc/bind/db.empty"; };
> >>>>>>> +diff -urN bind-9.3.1.orig/init.d bind-9.3.1/init.d
> >>>>>>> +--- bind-9.3.1.orig/init.d     1970-01-01 01:00:00.000000000 +0100
> >>>>>>> ++++ bind-9.3.1/init.d  2005-07-10 23:09:58.000000000 +0200
> >>>>>>> +@@ -0,0 +1,70 @@
> >>>>>>> ++#!/bin/sh
> >>>>>>> ++
> >>>>>>> ++PATH=/sbin:/bin:/usr/sbin:/usr/bin
> >>>>>>> ++
> >>>>>>> ++# for a chrooted server: "-u bind -t /var/lib/named"
> >>>>>>> ++# Don't modify this line, change or create /etc/default/bind9.
> >>>>>>> ++OPTIONS=""
> >>>>>>> ++
> >>>>>>> ++test -f /etc/default/bind9 && . /etc/default/bind9
> >>>>>>> ++
> >>>>>>> ++test -x /usr/sbin/rndc || exit 0
> >>>>>>> ++
> >>>>>>> ++case "$1" in
> >>>>>>> ++    start)
> >>>>>>> ++      echo -n "Starting domain name service: named"
> >>>>>>> ++
> >>>>>>> ++      modprobe capability >/dev/null 2>&1 || true
> >>>>>>> ++      if [ ! -f /etc/bind/rndc.key ]; then
> >>>>>>> ++          /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
> >>>>>>> ++          chmod 0640 /etc/bind/rndc.key
> >>>>>>> ++      fi
> >>>>>>> ++      if [ -f /var/run/named/named.pid ]; then
> >>>>>>> ++          ps `cat /var/run/named/named.pid` > /dev/null && exit 1
> >>>>>>> ++      fi
> >>>>>>> ++
> >>>>>>> ++      # dirs under /var/run can go away on reboots.
> >>>>>>> ++      mkdir -p /var/run/named
> >>>>>>> ++      mkdir -p /var/cache/bind
> >>>>>>> ++      chmod 775 /var/run/named
> >>>>>>> ++      chown root:bind /var/run/named >/dev/null 2>&1 || true
> >>>>>>> ++
> >>>>>>> ++      if [ ! -x /usr/sbin/named ]; then
> >>>>>>> ++          echo "named binary missing - not starting"
> >>>>>>> ++          exit 1
> >>>>>>> ++      fi
> >>>>>>> ++      if start-stop-daemon --start --quiet --exec /usr/sbin/named \
> >>>>>>> ++              --pidfile /var/run/named/named.pid -- $OPTIONS; then
> >>>>>>> ++          if [ -x /sbin/resolvconf ] ; then
> >>>>>>> ++              echo "nameserver 127.0.0.1" | /sbin/resolvconf -a lo
> >>>>>>> ++          fi
> >>>>>>> ++      fi
> >>>>>>> ++      echo "."
> >>>>>>> ++    ;;
> >>>>>>> ++
> >>>>>>> ++    stop)
> >>>>>>> ++      echo -n "Stopping domain name service: named"
> >>>>>>> ++      if [ -x /sbin/resolvconf ]; then
> >>>>>>> ++          /sbin/resolvconf -d lo
> >>>>>>> ++      fi
> >>>>>>> ++      /usr/sbin/rndc stop >/dev/null 2>&1
> >>>>>>> ++      echo "."
> >>>>>>> ++    ;;
> >>>>>>> ++
> >>>>>>> ++    reload)
> >>>>>>> ++      /usr/sbin/rndc reload
> >>>>>>> ++    ;;
> >>>>>>> ++
> >>>>>>> ++    restart|force-reload)
> >>>>>>> ++      $0 stop
> >>>>>>> ++      sleep 2
> >>>>>>> ++      $0 start
> >>>>>>> ++    ;;
> >>>>>>> ++
> >>>>>>> ++    *)
> >>>>>>> ++      echo "Usage: /etc/init.d/bind {start|stop|reload|restart|force-reload}" >&2
> >>>>>>> ++      exit 1
> >>>>>>> ++    ;;
> >>>>>>> ++esac
> >>>>>>> ++
> >>>>>>> ++exit 0
> >>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
> >>>>>>> new file mode 100644
> >>>>>>> index 00000000000..ef915c0ae5a
> >>>>>>> --- /dev/null
> >>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/generate-rndc-key.sh
> >>>>>>> @@ -0,0 +1,8 @@
> >>>>>>> +#!/bin/sh
> >>>>>>> +
> >>>>>>> +if [ ! -s /etc/bind/rndc.key ]; then
> >>>>>>> +    echo -n "Generating /etc/bind/rndc.key:"
> >>>>>>> +    /usr/sbin/rndc-confgen -a -b 512 -r /dev/urandom
> >>>>>>> +    chown root:bind /etc/bind/rndc.key
> >>>>>>> +    chmod 0640 /etc/bind/rndc.key
> >>>>>>> +fi
> >>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
> >>>>>>> new file mode 100644
> >>>>>>> index 00000000000..11db95ede12
> >>>>>>> --- /dev/null
> >>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/init.d-add-support-for-read-only-rootfs.patch
> >>>>>>> @@ -0,0 +1,65 @@
> >>>>>>> +Subject: init.d: add support for read-only rootfs
> >>>>>>> +
> >>>>>>> +Upstream-Status: Inappropriate [oe specific]
> >>>>>>> +
> >>>>>>> +Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
> >>>>>>> +---
> >>>>>>> + init.d |   40 ++++++++++++++++++++++++++++++++++++++++
> >>>>>>> + 1 file changed, 40 insertions(+)
> >>>>>>> +
> >>>>>>> +diff --git a/init.d b/init.d
> >>>>>>> +index 0111ed4..24677c8 100644
> >>>>>>> +--- a/init.d
> >>>>>>> ++++ b/init.d
> >>>>>>> +@@ -6,8 +6,48 @@ PATH=/sbin:/bin:/usr/sbin:/usr/bin
> >>>>>>> + # Don't modify this line, change or create /etc/default/bind9.
> >>>>>>> + OPTIONS=""
> >>>>>>> +
> >>>>>>> ++test -f /etc/default/rcS && . /etc/default/rcS
> >>>>>>> + test -f /etc/default/bind9 && . /etc/default/bind9
> >>>>>>> +
> >>>>>>> ++# This function is here because it's possible that /var and / are on different partitions.
> >>>>>>> ++is_on_read_only_partition () {
> >>>>>>> ++    DIRECTORY=$1
> >>>>>>> ++    dir=`readlink -f $DIRECTORY`
> >>>>>>> ++    while true; do
> >>>>>>> ++      if [ ! -d "$dir" ]; then
> >>>>>>> ++          echo "ERROR: $dir is not a directory"
> >>>>>>> ++          exit 1
> >>>>>>> ++      else
> >>>>>>> ++          for flag in `awk -v dir=$dir '{ if ($2 == dir) { print "FOUND"; split($4,FLAGS,",") } }; \
> >>>>>>> ++              END { for (f in FLAGS) print FLAGS[f] }' < /proc/mounts`; do
> >>>>>>> ++              [ "$flag" = "FOUND" ] && partition="read-write"
> >>>>>>> ++              [ "$flag" = "ro" ] && { partition="read-only"; break; }
> >>>>>>> ++          done
> >>>>>>> ++          if [ "$dir" = "/" -o -n "$partition" ]; then
> >>>>>>> ++              break
> >>>>>>> ++          else
> >>>>>>> ++              dir=`dirname $dir`
> >>>>>>> ++          fi
> >>>>>>> ++      fi
> >>>>>>> ++    done
> >>>>>>> ++    [ "$partition" = "read-only" ] && echo "yes" || echo "no"
> >>>>>>> ++}
> >>>>>>> ++
> >>>>>>> ++bind_mount () {
> >>>>>>> ++    olddir=$1
> >>>>>>> ++    newdir=$2
> >>>>>>> ++    mkdir -p $olddir
> >>>>>>> ++    cp -a $newdir/* $olddir
> >>>>>>> ++    mount --bind $olddir $newdir
> >>>>>>> ++}
> >>>>>>> ++
> >>>>>>> ++# Deal with read-only rootfs
> >>>>>>> ++if [ "$ROOTFS_READ_ONLY" = "yes" ]; then
> >>>>>>> ++    [ "$VERBOSE" != "no" ] && echo "WARN: start bind service in read-only rootfs"
> >>>>>>> ++    [ `is_on_read_only_partition /etc/bind` = "yes" ] && bind_mount /var/volatile/bind/etc /etc/bind
> >>>>>>> ++    [ `is_on_read_only_partition /var/named` = "yes" ] && bind_mount /var/volatile/bind/named /var/named
> >>>>>>> ++fi
> >>>>>>> ++
> >>>>>>> + test -x /usr/sbin/rndc || exit 0
> >>>>>>> +
> >>>>>>> + case "$1" in
> >>>>>>> +--
> >>>>>>> +1.7.9.5
> >>>>>>> +
> >>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
> >>>>>>> new file mode 100644
> >>>>>>> index 00000000000..146f3e35db6
> >>>>>>> --- /dev/null
> >>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/make-etc-initd-bind-stop-work.patch
> >>>>>>> @@ -0,0 +1,42 @@
> >>>>>>> +bind: make "/etc/init.d/bind stop" work
> >>>>>>> +
> >>>>>>> +Upstream-Status: Inappropriate [configuration]
> >>>>>>> +
> >>>>>>> +Add some configurations, make rndc command be able to controls
> >>>>>>> +the named daemon.
> >>>>>>> +
> >>>>>>> +Signed-off-by: Roy Li <rongqing.li@windriver.com>
> >>>>>>> +---
> >>>>>>> + conf/named.conf |    5 +++++
> >>>>>>> + conf/rndc.conf  |    5 +++++
> >>>>>>> + 2 files changed, 10 insertions(+), 0 deletions(-)
> >>>>>>> + create mode 100644 conf/rndc.conf
> >>>>>>> +
> >>>>>>> +diff --git a/conf/named.conf b/conf/named.conf
> >>>>>>> +index 95829cf..c8899e7 100644
> >>>>>>> +--- a/conf/named.conf
> >>>>>>> ++++ b/conf/named.conf
> >>>>>>> +@@ -47,3 +47,8 @@ zone "255.in-addr.arpa" {
> >>>>>>> + // root-delegation-only exclude { "DE"; "MUSEUM"; };
> >>>>>>> +
> >>>>>>> + include "/etc/bind/named.conf.local";
> >>>>>>> ++include "/etc/bind/rndc.key" ;
> >>>>>>> ++controls {
> >>>>>>> ++      inet 127.0.0.1 allow { localhost; }
> >>>>>>> ++      keys { rndc-key; };
> >>>>>>> ++};
> >>>>>>> +diff --git a/conf/rndc.conf b/conf/rndc.conf
> >>>>>>> +new file mode 100644
> >>>>>>> +index 0000000..a0b481d
> >>>>>>> +--- /dev/null
> >>>>>>> ++++ b/conf/rndc.conf
> >>>>>>> +@@ -0,0 +1,5 @@
> >>>>>>> ++include "/etc/bind/rndc.key";
> >>>>>>> ++options {
> >>>>>>> ++      default-server  localhost;
> >>>>>>> ++      default-key     rndc-key;
> >>>>>>> ++};
> >>>>>>> +
> >>>>>>> +--
> >>>>>>> +1.7.5.4
> >>>>>>> +
> >>>>>>> diff --git a/meta/recipes-connectivity/bind/bind-9.16.5/named.service b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
> >>>>>>> new file mode 100644
> >>>>>>> index 00000000000..cda56ef0150
> >>>>>>> --- /dev/null
> >>>>>>> +++ b/meta/recipes-connectivity/bind/bind-9.16.5/named.service
> >>>>>>> @@ -0,0 +1,22 @@
> >>>>>>> +[Unit]
> >>>>>>> +Description=Berkeley Internet Name Domain (DNS)
> >>>>>>> +Wants=nss-lookup.target
> >>>>>>> +Before=nss-lookup.target
> >>>>>>> +After=network.target
> >>>>>>> +
> >>>>>>> +[Service]
> >>>>>>> +Type=forking
> >>>>>>> +EnvironmentFile=-/etc/default/bind9
> >>>>>>> +PIDFile=/run/named/named.pid
> >>>>>>> +
> >>>>>>> +ExecStartPre=@SBINDIR@/generate-rndc-key.sh
> >>>>>>> +ExecStart=@SBINDIR@/named $OPTIONS
> >>>>>>> +
> >>>>>>> +ExecReload=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc reload > /dev/null 2>&1 || @BASE_BINDIR@/kill -HUP $MAINPID'
> >>>>>>> +
> >>>>>>> +ExecStop=@BASE_BINDIR@/sh -c '@SBINDIR@/rndc stop > /dev/null 2>&1 || @BASE_BINDIR@/kill -TERM $MAINPID'
> >>>>>>> +
> >>>>>>> +PrivateTmp=true
> >>>>>>> +
> >>>>>>> +[Install]
> >>>>>>> +WantedBy=multi-user.target
> >>>>>>> diff --git a/meta/recipes-connectivity/bind/bind_9.16.5.bb b/meta/recipes-connectivity/bind/bind_9.16.5.bb
> >>>>>>> new file mode 100644
> >>>>>>> index 00000000000..9c20ccc6fa2
> >>>>>>> --- /dev/null
> >>>>>>> +++ b/meta/recipes-connectivity/bind/bind_9.16.5.bb
> >>>>>>> @@ -0,0 +1,125 @@
> >>>>>>> +SUMMARY = "ISC Internet Domain Name Server"
> >>>>>>> +HOMEPAGE = "http://www.isc.org/sw/bind/"
> >>>>>>> +SECTION = "console/network"
> >>>>>>> +
> >>>>>>> +LICENSE = "MPL-2.0"
> >>>>>>> +LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=188b8d0644bd6835df43b84e3f180be1"
> >>>>>>> +
> >>>>>>> +DEPENDS = "openssl libcap zlib libuv"
> >>>>>>> +
> >>>>>>> +SRC_URI = "https://ftp.isc.org/isc/bind9/${PV}/${BPN}-${PV}.tar.xz \
> >>>>>>> +           file://conf.patch \
> >>>>>>> +           file://named.service \
> >>>>>>> +           file://bind9 \
> >>>>>>> +           file://generate-rndc-key.sh \
> >>>>>>> +           file://make-etc-initd-bind-stop-work.patch \
> >>>>>>> +           file://init.d-add-support-for-read-only-rootfs.patch \
> >>>>>>> +           file://bind-ensure-searching-for-json-headers-searches-sysr.patch \
> >>>>>>> +           file://0001-named-lwresd-V-and-start-log-hide-build-options.patch \
> >>>>>>> +           file://0001-avoid-start-failure-with-bind-user.patch \
> >>>>>>> +           "
> >>>>>>> +
> >>>>>>> +SRC_URI[sha256sum] = "6378b3e51fef11a8be4794dc48e8111ba92d211c0dfd129a0c296ed06a3dc075"
> >>>>>>> +
> >>>>>>> +UPSTREAM_CHECK_URI = "https://ftp.isc.org/isc/bind9/"
> >>>>>>> +# stay at 9.16 follow the ESV versions divisible by 4
> >>>>>>> +UPSTREAM_CHECK_REGEX = "(?P<pver>9.(16|20|24|28)(\.\d+)+(-P\d+)*)/"
> >>>>>>> +
> >>>>>>> +inherit autotools update-rc.d systemd useradd pkgconfig multilib_script multilib_header
> >>>>>>> +
> >>>>>>> +MULTILIB_SCRIPTS = "${PN}:${bindir}/bind9-config ${PN}:${bindir}/isc-config.sh"
> >>>>>>> +
> >>>>>>> +# PACKAGECONFIGs readline and libedit should NOT be set at same time
> >>>>>>> +PACKAGECONFIG ?= "readline"
> >>>>>>> +PACKAGECONFIG[httpstats] = "--with-libxml2=${STAGING_DIR_HOST}${prefix},--without-libxml2,libxml2"
> >>>>>>> +PACKAGECONFIG[readline] = "--with-readline=-lreadline,,readline"
> >>>>>>> +PACKAGECONFIG[libedit] = "--with-readline=-ledit,,libedit"
> >>>>>>> +PACKAGECONFIG[python3] = "--with-python=yes --with-python-install-dir=${PYTHON_SITEPACKAGES_DIR} , --without-python, python3-ply-native,"
> >>>>>>> +
> >>>>>>> +EXTRA_OECONF = " --with-libtool --disable-devpoll --enable-epoll \
> >>>>>>> +                 --with-gssapi=no --with-lmdb=no --with-zlib \
> >>>>>>> +                 --sysconfdir=${sysconfdir}/bind \
> >>>>>>> +                 --with-openssl=${STAGING_DIR_HOST}${prefix} \
> >>>>>>> +               "
> >>>>>>> +LDFLAGS_append = " -lz"
> >>>>>>> +
> >>>>>>> +inherit ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3native distutils3-base', '', d)}
> >>>>>>> +
> >>>>>>> +# dhcp needs .la so keep them
> >>>>>>> +REMOVE_LIBTOOL_LA = "0"
> >>>>>>> +
> >>>>>>> +USERADD_PACKAGES = "${PN}"
> >>>>>>> +USERADD_PARAM_${PN} = "--system --home ${localstatedir}/cache/bind --no-create-home \
> >>>>>>> +                       --user-group bind"
> >>>>>>> +
> >>>>>>> +INITSCRIPT_NAME = "bind"
> >>>>>>> +INITSCRIPT_PARAMS = "defaults"
> >>>>>>> +
> >>>>>>> +SYSTEMD_SERVICE_${PN} = "named.service"
> >>>>>>> +
> >>>>>>> +do_install_append() {
> >>>>>>> +
> >>>>>>> +       rmdir "${D}${localstatedir}/run"
> >>>>>>> +       rmdir --ignore-fail-on-non-empty "${D}${localstatedir}"
> >>>>>>> +       install -d -o bind "${D}${localstatedir}/cache/bind"
> >>>>>>> +       install -d "${D}${sysconfdir}/bind"
> >>>>>>> +       install -d "${D}${sysconfdir}/init.d"
> >>>>>>> +       install -m 644 ${S}/conf/* "${D}${sysconfdir}/bind/"
> >>>>>>> +       install -m 755 "${S}/init.d" "${D}${sysconfdir}/init.d/bind"
> >>>>>>> +        if ${@bb.utils.contains('PACKAGECONFIG', 'python3', 'true', 'false', d)}; then
> >>>>>>> +               sed -i -e '1s,#!.*python3,#! /usr/bin/python3,' \
> >>>>>>> +               ${D}${sbindir}/dnssec-coverage \
> >>>>>>> +               ${D}${sbindir}/dnssec-checkds \
> >>>>>>> +               ${D}${sbindir}/dnssec-keymgr
> >>>>>>> +       fi
> >>>>>>> +
> >>>>>>> +       # Install systemd related files
> >>>>>>> +       install -d ${D}${sbindir}
> >>>>>>> +       install -m 755 ${WORKDIR}/generate-rndc-key.sh ${D}${sbindir}
> >>>>>>> +       install -d ${D}${systemd_unitdir}/system
> >>>>>>> +       install -m 0644 ${WORKDIR}/named.service ${D}${systemd_unitdir}/system
> >>>>>>> +       sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' \
> >>>>>>> +              -e 's,@SBINDIR@,${sbindir},g' \
> >>>>>>> +              ${D}${systemd_unitdir}/system/named.service
> >>>>>>> +
> >>>>>>> +       install -d ${D}${sysconfdir}/default
> >>>>>>> +       install -m 0644 ${WORKDIR}/bind9 ${D}${sysconfdir}/default
> >>>>>>> +
> >>>>>>> +       if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
> >>>>>>> +               install -d ${D}${sysconfdir}/tmpfiles.d
> >>>>>>> +               echo "d /run/named 0755 bind bind - -" > ${D}${sysconfdir}/tmpfiles.d/bind.conf
> >>>>>>> +       fi
> >>>>>>> +
> >>>>>>> +    oe_multilib_header isc/platform.h
> >>>>>>> +}
> >>>>>>> +
> >>>>>>> +CONFFILES_${PN} = " \
> >>>>>>> +       ${sysconfdir}/bind/named.conf \
> >>>>>>> +       ${sysconfdir}/bind/named.conf.local \
> >>>>>>> +       ${sysconfdir}/bind/named.conf.options \
> >>>>>>> +       ${sysconfdir}/bind/db.0 \
> >>>>>>> +       ${sysconfdir}/bind/db.127 \
> >>>>>>> +       ${sysconfdir}/bind/db.empty \
> >>>>>>> +       ${sysconfdir}/bind/db.local \
> >>>>>>> +       ${sysconfdir}/bind/db.root \
> >>>>>>> +       "
> >>>>>>> +
> >>>>>>> +ALTERNATIVE_${PN}-utils = "nslookup"
> >>>>>>> +ALTERNATIVE_LINK_NAME[nslookup] = "${bindir}/nslookup"
> >>>>>>> +ALTERNATIVE_PRIORITY = "100"
> >>>>>> I'm seeing this failing with busybox:
> >>>>>> update-alternatives: Error: not linking
> >>>>>> /development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
> >>>>>> to /bin/busybox.nosuid since
> >>>>>> /development/yocto-master/build-output/work/imx8mmevk-fsl-linux/image-cmdline-validation/1.0-r0/rootfs/usr/bin/nslookup
> >>>>>> exists and is not a link
> >>>>>>
> >>>>>> busybox sets ALTERNATIVE_PRIORITY = "50". Can this be the issue?
> >>>>>
> >>>>> That is weird. I would have expected that to be an issue with the old
> >>>>> version too.
> >>>>>
> >>>>> Got any steps to reproduce this?
> >>>>
> >>>> Sorry for delayed response here, it took me some time but I've finally
> >>>> figured the setup to reproduce the issue.
> >>>>
> >>>> I've used the "vanilla" Poky from master, added IMAGE_INSTALL +=
> >>>> "bind-utils" to core-image-minimal and switched from RPM to IPK
> >>>> format. The last thing turned out to be the trigger for the issue, as
> >>>> with RPM package format I was not able to reproduce the issue, and
> >>>> this was cause of the delay here.
> >>>>
> >>>> After the above is done - following error is produced:
> >>>> WARNING: core-image-minimal-1.0-r0 do_rootfs: busybox.postinst
> >>>> returned 1, marking as unpacked only, configuration required on
> >>>> target.
> >>>> ERROR: core-image-minimal-1.0-r0 do_rootfs: Postinstall scriptlets of
> >>>> ['busybox'] have failed. If the intention is to defer them to first
> >>>> boot,
> >>>> then please place them into pkg_postinst_ontarget_${PN} ().
> >>>> Deferring to first boot via 'exit 1' is no longer supported.
> >>>> Details of the failure are in
> >>>> /development/projects/poky-vanilla/poky/build/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/temp/log.do_rootfs.
> >>>> ERROR: Logfile of failure stored in:
> >>>> /development/projects/poky-vanilla/poky/build/tmp/work/qemux86_64-poky-linux/core-image-minimal/1.0-r0/temp/log.do_rootfs.6423
> >>>> ERROR: Task (/development/projects/poky-vanilla/poky/meta/recipes-core/images/core-image-minimal.bb:do_rootfs)
> >>>> failed with exit code '1'
> >>>> NOTE: Tasks Summary: Attempted 3554 tasks of which 3552 didn't need to
> >>>> be rerun and 1 failed.
> >>>>
> >>>> Summary: 1 task failed:
> >>>>    /development/projects/poky-vanilla/poky/meta/recipes-core/images/core-image-minimal.bb:do_rootfs
> >>>> ed:
> >>>>
> >>>> 'nslookup' is definitely comming from the bind-utils package, and the
> >>>> only thing I've noted so far it that in bind-9.11.22 result binary
> >>>> name in ${D} is [nslookup.bind], which is different from the one
> >>>> provided in bind-9.16.5 - [nslookup].
> >>>>
> >>>> In case of previous bind version - both versions seems to be
> >>>> installed, and the symlink is fixed onto the nslookup.bind. In the
> >>>> current version though - I guess that the real binary is installed
> >>>> instead, making symlink operation to fail during update-alternative.
> >>>
> >>> If it is competing with busybox then perhaps priority for bind to
> >>> provide nslookup should be higher than busybox. Can you try that ?
> >>
> >> busybox has ALTERNATIVE_PRIORITY = "50" while bind is set to
> >> ALTERNATIVE_PRIORITY = "100". IIRC higher number means higher priority
> >> which is already the case...
> >>
> >> Nevertheless, I've tried to set 50 and even 40 for 'bind' and had the
> >> same failure...
> >>
> >>>
> >>>>
> >>>>
> >>>>
> >>>>>
> >>>>> -armin
> >>>>>>
> >>>>>> Going back to bind 9.11.22 seems to solve it...
> >>>>>>
> >>>>>>> +
> >>>>>>> +PACKAGE_BEFORE_PN += "${PN}-utils"
> >>>>>>> +FILES_${PN}-utils = "${bindir}/host ${bindir}/dig ${bindir}/mdig ${bindir}/nslookup ${bindir}/nsupdate"
> >>>>>>> +FILES_${PN}-dev += "${bindir}/isc-config.h"
> >>>>>>> +FILES_${PN} += "${sbindir}/generate-rndc-key.sh"
> >>>>>>> +
> >>>>>>> +PACKAGE_BEFORE_PN += "${PN}-libs"
> >>>>>>> +FILES_${PN}-libs = "${libdir}/*.so* ${libdir}/named/*.so*"
> >>>>>>> +FILES_${PN}-staticdev += "${libdir}/*.la"
> >>>>>>> +
> >>>>>>> +PACKAGE_BEFORE_PN += "${@bb.utils.contains('PACKAGECONFIG', 'python3', 'python3-bind', '', d)}"
> >>>>>>> +FILES_python3-bind = "${sbindir}/dnssec-coverage ${sbindir}/dnssec-checkds \
> >>>>>>> +                ${sbindir}/dnssec-keymgr ${PYTHON_SITEPACKAGES_DIR}"
> >>>>>>> +
> >>>>>>> +RDEPENDS_${PN}-dev = ""
> >>>>>>> +RDEPENDS_python3-bind = "python3-core python3-ply"
> >>>>>>> --
> >>>>>>> 2.17.1
> >>>>>>>
> >>>>>>>
> >>>>>>
> >>>>>>
> >>>>>
> >>>>
> >>>>
> >>>> --
> >>>> Regards,
> >>>> Andrey.
> >>>>
> >>>>
> >>>> 
> >>>>
> >>>
> >>
> >>
> >> --
> >> Regards,
> >> Andrey.
> >
> >
> >



-- 
Regards,
Andrey.

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: [OE-core] [PATCH 6/8] dhcp: remove from core
  2020-09-01 15:22 ` [PATCH 6/8] dhcp: remove from core akuster
  2020-09-01 18:10   ` [OE-core] " Khem Raj
@ 2020-10-21  1:34   ` Paul Eggleton
  1 sibling, 0 replies; 24+ messages in thread
From: Paul Eggleton @ 2020-10-21  1:34 UTC (permalink / raw)
  To: akuster; +Cc: openembedded-core

On Wednesday, 2 September 2020 03:22:34 NZDT akuster wrote:
> update maintainers.inc too
> 
> Signed-off-by: Armin Kuster <akuster808@gmail.com>

Thanks for doing this work. One request for the future though, if you could 
include in the commit message a brief explanation for changes like this (as 
simple as "Functionally replaced by kea (server-side) and dhcpcd (client 
side)" that would be much appreciated by folks looking back through the 
history :)

Cheers
Paul




^ permalink raw reply	[flat|nested] 24+ messages in thread

end of thread, other threads:[~2020-10-21  1:34 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-01 15:22 [PATCH 1/8] log4cplus: move meta-oe pkg to core akuster
2020-09-01 15:22 ` [PATCH 2/8] kea: Move from meta-networking akuster
2020-09-01 15:22 ` [PATCH 3/8] maintainers.inc: Add me as kea & log4plus maintainer akuster
2020-09-01 15:22 ` [PATCH 4/8] dhcpd: move from meta-network need a client akuster
2020-09-02  1:38   ` [OE-core] " Chen Qi
2020-09-02 15:06     ` Richard Purdie
2020-09-01 15:22 ` [PATCH 5/8] maintainers.inc: Add me as dhcpd maintainer akuster
2020-09-01 15:22 ` [PATCH 6/8] dhcp: remove from core akuster
2020-09-01 18:10   ` [OE-core] " Khem Raj
2020-09-01 19:15     ` Diego Sueiro
2020-09-02 15:05       ` Richard Purdie
2020-09-01 20:39     ` akuster
2020-10-21  1:34   ` Paul Eggleton
2020-09-01 15:22 ` [PATCH 7/8] bind: Add 9.16.x akuster
2020-09-04  8:39   ` [OE-core] " Andrey Zhizhikin
2020-09-07 15:28     ` akuster
2020-09-07 21:17       ` Andrey Zhizhikin
2020-09-09 23:53         ` Khem Raj
2020-09-10  7:12           ` Andrey Zhizhikin
2020-09-14 17:55             ` Andrey Zhizhikin
2020-09-14 19:04               ` Khem Raj
2020-09-14 20:48                 ` Andrey Zhizhikin
2020-09-01 15:22 ` [PATCH 8/8] bind: 9.11 remove akuster
2020-09-01 15:32 ` ✗ patchtest: failure for "log4cplus: move meta-oe pkg to..." and 7 more Patchwork

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.