Toggle bind configure options
cover Toggle bind configure options
From: Kai Kang <[email protected]>
The following changes since commit 94646f4828c2aa11a89996763edaa2e9d57106a9:
oeqa/buildiptables: Switch from netfilter.org to yoctoproject.org mirror (2016-08-23 17:59:43 +0100)
are available in the git repository at:
git://git.pokylinux.org/poky-contrib kangkai/bind
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=kangkai/bind
Kai Kang (2):
bind: enable threads support and use epoll
dhcp: build shared libraries
meta/recipes-connectivity/bind/bind_9.10.3-P3.bb | 6 +- meta/recipes-connectivity/dhcp/dhcp.inc | 6 +- .../dhcp/dhcp/build-shared-libs.patch | 186 +++++++++++++++++++++ meta/recipes-connectivity/dhcp/dhcp_4.3.4.bb | 1 + 4 files changed, 194 insertions(+), 5 deletions(-) create mode 100644 meta/recipes-connectivity/dhcp/dhcp/build-shared-libs.patch
Signature · 1 line
2.9.3
PATCH 1/2 bind: enable threads support and use epoll
From: Kai Kang <[email protected]>
Disable threads support for bind is inherited from legacy openembedded. And all libc's support proper threading on Linux now, so enable threads support for bind.
But static libraries cause package dhcp fails to compile after enable threads support. So enable to build shared libraries rather than static libs to fix the failure.
Options devpoll and epoll are configured to choose most preferable multiplex method for unix socket. The priorities are: epoll > poll > select. When set '--enable-epoll', it just defines a var and include header file that is available for cross compile. So use epoll for bind.
--- meta/recipes-connectivity/bind/bind_9.10.3-P3.bb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
meta/recipes-connectivity/bind/bind_9.10.3-P3.bb +3 -3
@@ -31,9 +31,9 @@ SRC_URI[md5sum] = "bcf7e772b616f7259420a3edc5df350a" SRC_URI[sha256sum] = "690810d1fbb72afa629e74638d19cd44e28d2b2e5eb63f55c705ad85d1a4cb83" ENABLE_IPV6 = "--enable-ipv6=${@bb.utils.contains('DISTRO_FEATURES', 'ipv6', 'yes', 'no', d)}" -EXTRA_OECONF = " ${ENABLE_IPV6} --with-randomdev=/dev/random --disable-threads \ - --disable-devpoll --disable-epoll --with-gost=no \ - --with-gssapi=no --with-ecdsa=yes \ +EXTRA_OECONF = " ${ENABLE_IPV6} --with-randomdev=/dev/random --with-libtool \ + --enable-threads --disable-devpoll --enable-epoll \ + --with-gost=no --with-gssapi=no --with-ecdsa=yes \ --sysconfdir=${sysconfdir}/bind \ --with-openssl=${STAGING_LIBDIR}/.. \ "
Signature · 1 line
2.9.3
PATCH 2/2 dhcp: build shared libraries
In reply to [email protected]From: Kai Kang <[email protected]>
When enable bind threads support, it fails to compile dhcp:
| tmp/work/armv5e-poky-linux-gnueabi/bind/9.10.3-P3-r0/build/lib/isc/pthreads/../../../../bind-9.10.3-P3/lib/isc/pthreads/thread.c:64: undefined reference to `pthread_create'
Enable build shared libraries for bind and dhcp to fix the build failure. And the patch is ported from Fedora.
Add sub-package dhcp-libs to package shared libraries.
--- meta/recipes-connectivity/dhcp/dhcp.inc | 6 +- .../dhcp/dhcp/build-shared-libs.patch | 186 +++++++++++++++++++++ meta/recipes-connectivity/dhcp/dhcp_4.3.4.bb | 1 + 3 files changed, 191 insertions(+), 2 deletions(-) create mode 100644 meta/recipes-connectivity/dhcp/dhcp/build-shared-libs.patch
meta/recipes-connectivity/dhcp/dhcp.inc +4 -2
@@ -46,7 +46,7 @@ EXTRA_OECONF = "--with-srv-lease-file=${localstatedir}/lib/dhcp/dhcpd.leases \ --with-cli-lease-file=${localstatedir}/lib/dhcp/dhclient.leases \ --with-cli6-lease-file=${localstatedir}/lib/dhcp/dhclient6.leases \ --with-libbind=${STAGING_LIBDIR}/ \ - --enable-paranoia \ + --enable-paranoia --disable-static \ --with-randomdev=/dev/random \ "
@@ -82,12 +82,14 @@ do_install_append () { sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' ${D}${systemd_unitdir}/system/dhcrelay.service } -PACKAGES += "dhcp-server dhcp-server-config dhcp-client dhcp-relay dhcp-omshell" +PACKAGES += "dhcp-libs dhcp-server dhcp-server-config dhcp-client dhcp-relay dhcp-omshell" FILES_${PN} = "" RDEPENDS_${PN}-dev = "" RDEPENDS_${PN}-staticdev = "" +FILES_${PN}-libs = "${libdir}/libdhcpctl.so.0* ${libdir}/libomapi.so.0*" + FILES_${PN}-server = "${sbindir}/dhcpd ${sysconfdir}/init.d/dhcp-server" RRECOMMENDS_${PN}-server = "dhcp-server-config"
meta/recipes-connectivity/dhcp/dhcp/build-shared-libs.patch new file +186 -0
186 lines not on this page · raw message
meta/recipes-connectivity/dhcp/dhcp_4.3.4.bb +1 -0
@@ -9,6 +9,7 @@ SRC_URI += "file://dhcp-3.0.3-dhclient-dbus.patch;striplevel=0 \ file://libxml2-configure-argument.patch \ file://tweak-to-support-external-bind.patch \ file://remove-dhclient-script-bash-dependency.patch \ + file://build-shared-libs.patch \ " SRC_URI[md5sum] = "0138319fe2b788cf4bdf34fbeaf9ff54"
Signature · 1 line
2.9.3
Quoted 6 lines · On 2016年08月24日 09:27, [email protected] wrote:
From: Kai Kang <[email protected]>
The following changes since commit
94646f4828c2aa11a89996763edaa2e9d57106a9:oeqa/buildiptables: Switch from netfilter.org to yoctoproject.org mirror (2016-08-23 17:59:43 +0100)
Quoted 8 lines
are available in the git repository at:
git://git.pokylinux.org/poky-contribkangkai/bind
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=kangkai/bindKai Kang (2):
bind: enable threads support and use epoll
dhcp: build shared libraries
I didn't see Wangxin's work to upgrade bind. So please comment the patches, and I will rebase them when the upgrade patch is merged.
Thanks.
--Kai
Quoted 7 lines
meta/recipes-connectivity/bind/bind_9.10.3-P3.bb | 6 +- meta/recipes-connectivity/dhcp/dhcp.inc | 6 +- .../dhcp/dhcp/build-shared-libs.patch | 186 +++++++++++++++++++++ meta/recipes-connectivity/dhcp/dhcp_4.3.4.bb | 1 + 4 files changed, 194 insertions(+), 5 deletions(-)create mode 100644
meta/recipes-connectivity/dhcp/dhcp/build-shared-libs.patch
Signature · 2 lines
Regards, Neil | Kai Kang
Quoted 3 lines · Kang Kai
I didn't see Wangxin's work to upgrade bind. So please comment the patches, and I will rebase them when the upgrade patch is merged.
Looks good to me!
Ross
Quoted 8 lines · Ross
On 24 August 2016 at 02:46, Kang Kai <[email protected] <mailto:[email protected]>> wrote:
I didn't see Wangxin's work to upgrade bind. So please comment the patches, and I will rebase them when the upgrade patch is merged.
Looks good to me!
Thanks.
--Kai
Quoted 2 lines
Ross
Signature · 2 lines
Regards, Neil | Kai Kang