Bug#875405: armadillo FTBFS: runs cmake for the build architecture

Helmut Grohne helmut at subdivi.de
Mon Sep 11 08:44:17 UTC 2017


Source: armadillo
Version: 1:7.960.1+dfsg-1
Tags: patch
User: helmutg at debian.org
Usertags: rebootstrap

armadillo fails to cross build from source, because it runs cmake for
the build architecture. Since passing the right flags to cmake is
tedious, it is best to defer that task to dh_auto_configure and once
doing so, armadillo cross builds successfully. Please consider applying
the attached patch.

Helmut
-------------- next part --------------
diff --minimal -Nru armadillo-7.960.1+dfsg/debian/changelog armadillo-7.960.1+dfsg/debian/changelog
--- armadillo-7.960.1+dfsg/debian/changelog	2017-08-23 19:08:28.000000000 +0200
+++ armadillo-7.960.1+dfsg/debian/changelog	2017-09-11 10:36:29.000000000 +0200
@@ -1,3 +1,11 @@
+armadillo (1:7.960.1+dfsg-1.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Fix FTCBFS: Let dh_auto_configure pass cross compilers to cmake. (Closes:
+    #-1)
+
+ -- Helmut Grohne <helmut at subdivi.de>  Mon, 11 Sep 2017 10:36:29 +0200
+
 armadillo (1:7.960.1+dfsg-1) unstable; urgency=medium
 
   * New upstream release
diff --minimal -Nru armadillo-7.960.1+dfsg/debian/rules armadillo-7.960.1+dfsg/debian/rules
--- armadillo-7.960.1+dfsg/debian/rules	2017-08-23 19:06:47.000000000 +0200
+++ armadillo-7.960.1+dfsg/debian/rules	2017-09-11 10:36:29.000000000 +0200
@@ -1,14 +1,6 @@
 #!/usr/bin/make -f
 # -*- makefile -*-
 
-DEB_HOST_GNU_TYPE   ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
-DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
-ifneq ($(DEB_HOST_GNU_TYPE),$(DEB_BUILD_GNU_TYPE))
-CROSS= --build $(DEB_BUILD_GNU_TYPE) --host $(DEB_HOST_GNU_TYPE)
-else
-CROSS= --build $(DEB_BUILD_GNU_TYPE)
-endif
-
 DPKG_EXPORT_BUILDFLAGS = 1
 include /usr/share/dpkg/buildflags.mk
 include /usr/share/quilt/quilt.make
@@ -21,7 +13,7 @@
 
 build-stamp:
 	dh_testdir
-	cmake -DCMAKE_VERBOSE_MAKEFILE=ON -D INSTALL_LIB_DIR=lib -D CMAKE_INpppSTALL_PREFIX_INITIALIZED_TO_DEFAULT:BOOL=ON  . # specified to install to the debian/tmp directory.
+	dh_auto_configure --buildsystem=cmake --builddirectory=. -- -D INSTALL_LIB_DIR=lib -D CMAKE_INpppSTALL_PREFIX_INITIALIZED_TO_DEFAULT:BOOL=ON  . # specified to install to the debian/tmp directory.
 	$(MAKE)
 	touch $@
 


More information about the debian-science-maintainers mailing list