[pkg-dhcp-devel] Bug#602312: isc-dhcp: fails to build with 'ld --no-as-needed'

Colin Watson cjwatson at ubuntu.com
Wed Nov 3 17:03:44 UTC 2010


Package: isc-dhcp
Version: 4.1.1-P1-11
Severity: normal
Tags: patch
User: ubuntu-devel at lists.ubuntu.com
Usertags: origin-ubuntu ubuntu-patch natty

isc-dhcp fails to build when --no-add-needed is the default in the
linker (see http://wiki.debian.org/ToolChain/DSOLinking) due to a bug in
the LDAP configure.ac patch.  Calling AC_SEARCH_LIBS twice in succession
for the same function simply results in the second call using the cached
value from the first call; you need to unset the cache variable to avoid
this.

diff -u isc-dhcp-4.1.1-P1/debian/patches/dhcp-4.1.0-ldap-code.dpatch isc-dhcp-4.1.1-P1/debian/patches/dhcp-4.1.0-ldap-code.dpatch
--- isc-dhcp-4.1.1-P1/debian/patches/dhcp-4.1.0-ldap-code.dpatch
+++ isc-dhcp-4.1.1-P1/debian/patches/dhcp-4.1.0-ldap-code.dpatch
@@ -2754,7 +2754,7 @@
 diff -urNad '--exclude=CVS' '--exclude=.svn' '--exclude=.git' '--exclude=.arch' '--exclude=.hg' '--exclude=_darcs' '--exclude=.bzr' isc-dhcp-4.1.1-P1~/configure.ac isc-dhcp-4.1.1-P1/configure.ac
 --- isc-dhcp-4.1.1-P1~/configure.ac	2010-10-20 22:14:33.694570303 +0100
 +++ isc-dhcp-4.1.1-P1/configure.ac	2010-10-20 22:17:15.682086336 +0100
-@@ -419,6 +419,74 @@
+@@ -419,6 +419,75 @@
  # Look for optional headers.
  AC_CHECK_HEADERS(sys/socket.h net/if_dl.h net/if6.h regex.h)
  
@@ -2775,6 +2775,7 @@
 +	AC_SEARCH_LIBS([ber_init], [ldap], [
 +		LDAP_LIBS="-lldap"
 +	],[
++		AS_UNSET([ac_cv_search_ber_init])
 +		AC_SEARCH_LIBS([ber_init], [lber], [
 +			LDAP_LIBS="-lldap -llber"
 +		], [

Thanks,

-- 
Colin Watson                                       [cjwatson at ubuntu.com]





More information about the pkg-dhcp-devel mailing list