Source: libbind
Version: 6.0-1
Severity: wishlist
Tags: patch
User: debian-...@lists.debian.org
Usertags: port-x32 ftbfs-libtool

The libbind source package is getting this build failure on the unofficial
Debian x32 port:

<URL:http://buildd.debian-ports.org/status/fetch.php?pkg=libbind&arch=x32&ver=6.0-1&stamp=1361154971>:
...
/bin/bash /build/buildd-libbind_6.0-1-x32-0R7Mxq/libbind-6.0/libtool 
--mode=link \
        gcc  -g -O2 -I/build/buildd-libbind_6.0-1-x32-0R7Mxq/libbind-6.0 
-I/build/buildd-libbind_6.0-1-x32-0R7Mxq/libbind-6.0/port/linux/include     
-D_GNU_SOURCE  -W -Wall -Wmissing-prototypes -Wcast-qual -Wwrite-strings 
-Wformat -
Wpointer-arith -fno-strict-aliasing   -o libbind.la -rpath /usr/lib \
                -version-info 6:1:2 \
                bsd/ftruncate.lo bsd/gettimeofday.lo bsd/mktemp.lo 
bsd/putenv.lo bsd/readv.lo bsd/setenv.lo bsd/setitimer.lo bsd/strcasecmp.lo 
bsd/strdup.lo bsd/strerror.lo bsd/strpbrk.lo bsd/strtoul.lo bsd/utimes.lo 
bsd/writev.lo 
dst/dst_api.lo dst/hmac_link.lo dst/md5_dgst.lo dst/support.lo 
inet/inet_addr.lo inet/inet_cidr_ntop.lo inet/inet_cidr_pton.lo 
inet/inet_data.lo inet/inet_lnaof.lo inet/inet_makeaddr.lo 
inet/inet_net_ntop.lo inet/inet_net_pton.lo 
inet/inet_neta.lo inet/inet_netof.lo inet/inet_network.lo inet/inet_ntoa.lo 
inet/inet_ntop.lo inet/inet_pton.lo inet/nsap_addr.lo irs/dns.lo irs/dns_ho.lo 
irs/dns_nw.lo irs/dns_pr.lo irs/dns_sv.lo irs/gai_strerror.lo irs/gen.lo 
irs/gen_ho.lo irs/gen_ng.lo irs/gen_nw.lo irs/gen_pr.lo irs/gen_sv.lo 
irs/getaddrinfo.lo irs/gethostent.lo  irs/getnameinfo.lo irs/getnetent.lo 
irs/getnetgrent.lo irs/getprotoent.lo irs/getservent.lo irs/hesiod.lo 
irs/irp.lo irs/irp_ho.lo 
irs/irp_ng.lo irs/irp_nw.lo irs/irp_pr.lo irs/irp_sv.lo irs/irpmarshall.lo 
irs/irs_data.lo irs/lcl.lo irs/lcl_ho.lo irs/lcl_ng.lo irs/lcl_nw.lo 
irs/lcl_pr.lo irs/lcl_sv.lo irs/nis.lo irs/nul_ng.lo irs/util.lo 
isc/assertions.lo isc/base64.lo isc/bitncmp.lo 
isc/ctl_clnt.lo isc/ctl_p.lo isc/ctl_srvr.lo isc/ev_connects.lo isc/ev_files.lo 
isc/ev_streams.lo isc/ev_timers.lo isc/ev_waits.lo isc/eventlib.lo isc/heap.lo 
isc/hex.lo isc/logging.lo isc/memcluster.lo isc/movefile.lo isc/tree.lo 
nameser/ns_date.lo nameser/ns_name.lo nameser/ns_netint.lo nameser/ns_parse.lo 
nameser/ns_print.lo  nameser/ns_samedomain.lo nameser/ns_sign.lo 
nameser/ns_ttl.lo nameser/ns_verify.lo nameser/ns_rdata.lo 
nameser/ns_newmsg.lo resolv/herror.lo resolv/mtctxres.lo resolv/res_comp.lo 
resolv/res_data.lo resolv/res_debug.lo resolv/res_findzonecut.lo 
resolv/res_init.lo resolv/res_mkquery.lo resolv/res_mkupdate.lo 
resolv/res_query.lo 
resolv/res_send.lo resolv/res_sendsigned.lo resolv/res_update.lo -lrt 
mkdir .libs
/build/buildd-libbind_6.0-1-x32-0R7Mxq/libbind-6.0/libtool: line 4506: test: : 
integer expression expected
/build/buildd-libbind_6.0-1-x32-0R7Mxq/libbind-6.0/libtool: line 4506: test: : 
integer expression expected
creating reloadable object files...
/build/buildd-libbind_6.0-1-x32-0R7Mxq/libbind-6.0/libtool: line 4541: test: : 
integer expression expected
/build/buildd-libbind_6.0-1-x32-0R7Mxq/libbind-6.0/libtool: line 4541: test: : 
integer expression expected
...
/build/buildd-libbind_6.0-1-x32-0R7Mxq/libbind-6.0/libtool: line 4541: test: : 
integer expression expected
creating a temporary reloadable object file: .libs/libbind.la-112.o
/usr/bin/ld -m elf_i386 -r -o .libs/libbind.la-1.o bsd/.libs/ftruncate.o 
/usr/bin/ld: Relocatable linking with relocations from format elf32-x86-64 
(bsd/.libs/ftruncate.o) to format elf32-i386 (.libs/libbind.la-1.o) is not 
supported
make[1]: *** [libbind.la] Error 1
make[1]: Leaving directory `/build/buildd-libbind_6.0-1-x32-0R7Mxq/libbind-6.0'
dh_auto_build: make -j1 returned exit code 2
make: *** [build-arch] Error 2
dpkg-buildpackage: error: debian/rules build-arch gave error exit status 2

The fix is to update libtool using the current sid package (>= 2.4.2-1.2).
The attached debdiff does this at build time using dh-autoreconf.
(Considering the shenanigans I had to go through to get a working configure
script, you might want to add a proper AC_PROG_LIBTOOL call to the script
so that libtoolize will do the right thing.)
-- 
Daniel Schepler
diff -u libbind-6.0/debian/rules libbind-6.0/debian/rules
--- libbind-6.0/debian/rules
+++ libbind-6.0/debian/rules
@@ -1,21 +1,25 @@
 #!/usr/bin/make -f
 %:
-	dh $@
+	dh $@ --with autoreconf
 
 build: build-stamp
 build-stamp:
-	dh build
+	dh build --with autoreconf
 	touch $@
 
 clean:
-	dh clean 
+	dh clean --with autoreconf
 	find . -name '*.o' -delete
 
 install: build
-	dh install
+	dh install --with autoreconf
 
 binary-arch: install
-	dh binary-arch
+	dh binary-arch --with autoreconf
+
+override_dh_autoreconf:
+	chmod +x debian/autogen.sh
+	dh_autoreconf debian/autogen.sh
 
 override_dh_auto_configure:
 	dh_auto_configure -- -with-libtool
diff -u libbind-6.0/debian/changelog libbind-6.0/debian/changelog
--- libbind-6.0/debian/changelog
+++ libbind-6.0/debian/changelog
@@ -1,3 +1,10 @@
+libbind (6.0-1+libtool) unreleased; urgency=low
+
+  * Update libtool at build time using dh-autoreconf, in order to fix a
+    build failure on x32.
+
+ -- Daniel Schepler <schep...@debian.org>  Sat, 02 Mar 2013 08:01:48 -0800
+
 libbind (6.0-1) unstable; urgency=low
 
   * Initial release; closes: #527985.
diff -u libbind-6.0/debian/control libbind-6.0/debian/control
--- libbind-6.0/debian/control
+++ libbind-6.0/debian/control
@@ -1,7 +1,7 @@
 Source: libbind
 Priority: extra
 Maintainer: Robert S. Edmonds <edmo...@debian.org>
-Build-Depends: debhelper (>= 7.0.50)
+Build-Depends: debhelper (>= 7.0.50), dh-autoreconf
 Standards-Version: 3.8.1
 Section: libs
 Homepage: http://www.isc.org/software/libbind
only in patch2:
unchanged:
--- libbind-6.0.orig/debian/autogen.sh
+++ libbind-6.0/debian/autogen.sh
@@ -0,0 +1,8 @@
+#!/bin/sh
+cat /usr/share/aclocal/ltoptions.m4 \
+    /usr/share/aclocal/ltsugar.m4 \
+    /usr/share/aclocal/ltversion.m4 \
+    /usr/share/aclocal/lt~obsolete.m4 \
+    /usr/share/aclocal/libtool.m4 > ./libtool.m4
+libtoolize --force --copy
+autoconf

Reply via email to