[Debian-med-packaging] Bug#908353: ncbi-tools6 FTCBFS: uses the build architecture compiler

Helmut Grohne helmut at subdivi.de
Sat Sep 8 22:10:37 BST 2018


Source: ncbi-tools6
Version: 6.1.20170106-4
Tags: patch
User: helmutg at debian.org
Usertags: rebootstrap

ncbi-tools6 fails to cross build from source, because debian/rules
forces the build architecture compiler. Letting dpkg's buildtools.mk
initialize the CC variables fixes that part. Unfortunately, the cross
build still fails with a weired linker error:

| /usr/lib/gcc-cross/powerpc64le-linux-gnu/8/../../../../powerpc64le-linux-gnu/bin/ld: warning: libnetcli.so.6, needed by ../shlib/libncbiacc.so, not found (try using -rpath or -rpath-link)
| /usr/lib/gcc-cross/powerpc64le-linux-gnu/8/../../../../powerpc64le-linux-gnu/bin/ld: ../shlib/libncbiacc.so: undefined reference to `NI_GenericGetService'
| /usr/lib/gcc-cross/powerpc64le-linux-gnu/8/../../../../powerpc64le-linux-gnu/bin/ld: ../shlib/libncbiacc.so: undefined reference to `NI_GenericInit'
| /usr/lib/gcc-cross/powerpc64le-linux-gnu/8/../../../../powerpc64le-linux-gnu/bin/ld: ../shlib/libncbiacc.so: undefined reference to `x_ni_errno'
| /usr/lib/gcc-cross/powerpc64le-linux-gnu/8/../../../../powerpc64le-linux-gnu/bin/ld: ../shlib/libncbiacc.so: undefined reference to `x_ni_errlist'
| /usr/lib/gcc-cross/powerpc64le-linux-gnu/8/../../../../powerpc64le-linux-gnu/bin/ld: ../shlib/libncbiacc.so: undefined reference to `NI_ServiceDisconnect'
| /usr/lib/gcc-cross/powerpc64le-linux-gnu/8/../../../../powerpc64le-linux-gnu/bin/ld: ../shlib/libncbiacc.so: undefined reference to `x_ni_errtext'
| /usr/lib/gcc-cross/powerpc64le-linux-gnu/8/../../../../powerpc64le-linux-gnu/bin/ld: ../shlib/libncbiacc.so: undefined reference to `NI_EndServices'
| collect2: error: ld returned 1 exit status
| make[2]: *** [makedemo.unx:249: entrcmd] Error 1
| make[2]: Leaving directory '/<<PKGBUILDDIR>>/build'
| make[1]: *** [debian/rules:86: override_dh_auto_build-arch] Error 2
| make[1]: Leaving directory '/<<PKGBUILDDIR>>'
| make: *** [debian/rules:72: binary-arch] Error 2

I have no idea on how to fix that. Still, could you apply the attached
patch and close this bug when doing so? That'd make the real issue more
visible to others.

Helmut
-------------- next part --------------
diff --minimal -Nru ncbi-tools6-6.1.20170106/debian/changelog ncbi-tools6-6.1.20170106/debian/changelog
--- ncbi-tools6-6.1.20170106/debian/changelog	2018-06-26 03:36:10.000000000 +0200
+++ ncbi-tools6-6.1.20170106/debian/changelog	2018-09-08 21:42:29.000000000 +0200
@@ -1,3 +1,11 @@
+ncbi-tools6 (6.1.20170106-4.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Improve cross building: Don't force the build architecture compiler.
+    (Closes: #-1)
+
+ -- Helmut Grohne <helmut at subdivi.de>  Sat, 08 Sep 2018 21:42:29 +0200
+
 ncbi-tools6 (6.1.20170106-4) unstable; urgency=medium
 
   * debian/compat: Advance to Debhelper 11.
diff --minimal -Nru ncbi-tools6-6.1.20170106/debian/rules ncbi-tools6-6.1.20170106/debian/rules
--- ncbi-tools6-6.1.20170106/debian/rules	2016-12-06 03:21:38.000000000 +0100
+++ ncbi-tools6-6.1.20170106/debian/rules	2018-09-08 21:42:27.000000000 +0200
@@ -12,7 +12,7 @@
 
 # Set these here, rather than using the csh hackage that passes for an
 # upstream build system.  Mostly taken from ../platform/{ppc,}linux.ncbi.mk.
-CC = gcc # -pipe
+-include /usr/share/dpkg/buildtools.mk
 VIBFLAG = -DWIN_MOTIF
 VIBLIBS = -lXm -lXmu -lXt -lX11 # -lXext # -lXp
 OTHERLIBS = -lm


More information about the Debian-med-packaging mailing list