[Debian-astro-maintainers] Bug#939518: dpuser FTCBFS: does not pass cross tools to make

Helmut Grohne helmut at subdivi.de
Thu Sep 5 21:16:58 BST 2019


Source: dpuser
Version: 4.0+dfsg-1
Tags: patch
User: debian-cross at lists.debian.org
Usertags: ftcbfs

dpuser fails to cross build from source, because it does not pass cross
tools to make. For the dpuser subdirectory, the easiest way of mostly
fixing this is using dh_auto_build. There are two places where g++ is
hard coded rather than using $(CXX), which also need to be fixed. The
attached patch fixes these issues.

Then it comes to the QFitsView. There a makefile calls qmake without the
appropriate flags. This is more difficult. Usually, we try to call qmake
through dh_auto_configure, but the qmake call is wrapped here
unfortunately. I don't have a simple solution here.

Please consider applying the attached patch anyway as an incremental
step and close this bug when doing so.

Helmut
-------------- next part --------------
diff --minimal -Nru dpuser-4.0+dfsg/debian/changelog dpuser-4.0+dfsg/debian/changelog
--- dpuser-4.0+dfsg/debian/changelog	2019-09-04 20:56:42.000000000 +0200
+++ dpuser-4.0+dfsg/debian/changelog	2019-09-05 21:54:55.000000000 +0200
@@ -1,3 +1,10 @@
+dpuser (4.0+dfsg-1.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Improve cross building: Build dpuser with the right compiler. (Closes: #-1)
+
+ -- Helmut Grohne <helmut at subdivi.de>  Thu, 05 Sep 2019 21:54:55 +0200
+
 dpuser (4.0+dfsg-1) unstable; urgency=low
 
   * Update VCS fields to use salsa.d.o
diff --minimal -Nru dpuser-4.0+dfsg/debian/patches/cross.patch dpuser-4.0+dfsg/debian/patches/cross.patch
--- dpuser-4.0+dfsg/debian/patches/cross.patch	1970-01-01 01:00:00.000000000 +0100
+++ dpuser-4.0+dfsg/debian/patches/cross.patch	2019-09-05 21:54:55.000000000 +0200
@@ -0,0 +1,20 @@
+--- dpuser-4.0+dfsg.orig/dpuser/Makefile
++++ dpuser-4.0+dfsg/dpuser/Makefile
+@@ -31,7 +31,7 @@
+ SED         = sed
+ CC          = gcc
+ CXX         = g++
+-LINK        = g++
++LINK        = $(CXX)
+ QF          =
+ GDL         =
+ PY          =
+@@ -262,7 +262,7 @@
+ endif # end LINUX & MACOSX
+ 
+ $(TARGET_DLL): $(DLL_OBJECTS)
+-	g++ -shared -o $(TARGET_DLL) $(DLL_OBJECTS) $(DLL_LIBS)
++	$(LINK) -shared -o $(TARGET_DLL) $(DLL_OBJECTS) $(DLL_LIBS)
+ 
+ $(TARGET_WIN): $(OBJECTS)
+ 	$(LINK) $(LDFLAG) -o $(TARGET_WIN) $(OBJECTS) $(LIBS)
diff --minimal -Nru dpuser-4.0+dfsg/debian/patches/series dpuser-4.0+dfsg/debian/patches/series
--- dpuser-4.0+dfsg/debian/patches/series	2019-09-04 20:56:42.000000000 +0200
+++ dpuser-4.0+dfsg/debian/patches/series	2019-09-05 21:54:55.000000000 +0200
@@ -8,3 +8,4 @@
 Don-t-use-SVN-version.patch
 Fix-gcc-optimization-bug-in-ifNode-evaluate.patch
 Fix-test-script.patch
+cross.patch
diff --minimal -Nru dpuser-4.0+dfsg/debian/rules dpuser-4.0+dfsg/debian/rules
--- dpuser-4.0+dfsg/debian/rules	2019-09-04 20:56:42.000000000 +0200
+++ dpuser-4.0+dfsg/debian/rules	2019-09-05 21:54:55.000000000 +0200
@@ -9,7 +9,7 @@
 	dh  $@
 
 override_dh_auto_build:
-	$(MAKE) -C dpuser
+	dh_auto_build --sourcedirectory=dpuser --no-parallel
 	$(MAKE) -C QFitsView release_shared
 
 ifeq ($(filter nocheck,$(DEB_BUILD_OPTIONS)),)


More information about the Debian-astro-maintainers mailing list