From 755db9e7384895889a676efea3393b372be59364ea7f69e2ca503b5af3d60338 Mon Sep 17 00:00:00 2001 From: Marcus Meissner Date: Thu, 18 Jun 2015 12:30:16 +0000 Subject: [PATCH] Accepting request 311393 from home:guohouzuo:freeipa Fix inappropriate use of /var/lib/named for locating dynamic-DB plugins. Dynamic-DB plugins are now loaded from %{_libexecdir}/bind, consistent with openSUSE packaging guideline. Install additional header files which are helpful to the development of dynamic-DB plugins. Please note that - the so-far only implementation of dyanmic-DB plugin does not support running in chroot environment very well, there is great performance impact in doing so. OBS-URL: https://build.opensuse.org/request/show/311393 OBS-URL: https://build.opensuse.org/package/show/network/bind?expand=0&rev=169 --- bind.changes | 7 +++++++ bind.spec | 14 +++++++++++--- dns_dynamic_db.patch | 2 +- 3 files changed, 19 insertions(+), 4 deletions(-) diff --git a/bind.changes b/bind.changes index 73cbe6c..89ad921 100644 --- a/bind.changes +++ b/bind.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Wed May 13 09:35:40 UTC 2015 - hguo@suse.com + +- Fix inappropriate use of /var/lib/named for locating dynamic-DB plugins. + Dynamic-DB plugins are now loaded from %{_libexecdir}/bind, consistent with openSUSE packaging guideline. +- Install additional header files which are helpful to the development of dynamic-DB plugins. + ------------------------------------------------------------------- Fri May 8 18:00:41 UTC 2015 - lmuelle@suse.com diff --git a/bind.spec b/bind.spec index 27a6e79..0e15c59 100644 --- a/bind.spec +++ b/bind.spec @@ -490,13 +490,18 @@ mkdir -p \ ${RPM_BUILD_ROOT}/var/adm/fillup-templates \ ${RPM_BUILD_ROOT}/%{_rundir} \ ${RPM_BUILD_ROOT}/%{_sysconfdir}/sysconfig/SuSEfirewall2.d/services \ - ${RPM_BUILD_ROOT}%{_includedir}/bind/dns + ${RPM_BUILD_ROOT}%{_includedir}/bind/dns \ + ${RPM_BUILD_ROOT}%{_libexecdir}/bind %{__make} DESTDIR=${RPM_BUILD_ROOT} install pushd contrib/idn/idnkit-1.0-src %{__make} DESTDIR=${RPM_BUILD_ROOT} install popd -# install header file for developing Dynamic DB plugin -install -m 0644 ./lib/dns/include/dns/dynamic_db.h ${RPM_BUILD_ROOT}%{_includedir}/bind/dns/ +# install interface header file for developing Dynamic DB plugin +install -m 0644 lib/dns/include/dns/dynamic_db.h ${RPM_BUILD_ROOT}%{_includedir}/bind/dns/ +# install errno2result.h, some dynamic DB plugins could use it. +install -m 0755 -d ${RPM_BUILD_ROOT}%{_includedir}/isc/ +install -m 0644 lib/isc/unix/errno2result.h ${RPM_BUILD_ROOT}%{_includedir}/isc/ + # remove useless .la files rm -f ${RPM_BUILD_ROOT}/%{_lib}/libidnkit.la rm -f ${RPM_BUILD_ROOT}/%{_lib}/libidnkitlite.la @@ -834,6 +839,7 @@ fi %ghost %{_var}/lib/named/etc/localtime %attr(0644,root,named) %ghost %{_var}/lib/named/etc/named.conf.include %attr(-,named,named) %dir %{_var}/lib/named/var/run/named +%dir %{_libexecdir}/bind %files -n idnkit %defattr(-,root,root) @@ -920,6 +926,8 @@ fi %files devel %defattr(-,root,root) +%dir %{_includedir}/isc +%{_includedir}/isc/errno2result.h %{_bindir}/isc-config.sh %{_libdir}/libbind9.so %{_libdir}/libdns.so diff --git a/dns_dynamic_db.patch b/dns_dynamic_db.patch index 57e19b5..d1144f8 100644 --- a/dns_dynamic_db.patch +++ b/dns_dynamic_db.patch @@ -670,7 +670,7 @@ diff -rupN bind-9.10.1-P1-orig/lib/dns/Makefile.in bind-9.10.1-P1-patched/lib/dn +dynamic_db.@O@: dynamic_db.c + ${LIBTOOL_MODE_COMPILE} ${CC} ${ALL_CFLAGS} \ -+ -DDYNDB_LIBDIR=\"/var/lib/named/\" \ ++ -DDYNDB_LIBDIR=\"/usr/lib/bind/\" \ + -c ${srcdir}/dynamic_db.c + libdns.@SA@: ${OBJS}