Bug#923269: passage FTCBFS: builds for the wrong architecture

Helmut Grohne helmut at subdivi.de
Mon Feb 25 16:53:53 GMT 2019


Source: passage
Version: 4+dfsg1-3
Tags: patch
User: helmutg at debian.org
Usertags: rebootstrap

passage fails to cross build from source. The upstream Makefile hard
codes the build architecture compiler and debian/rules does not pass
cross tools either. The attached fixes both. Note that dh_auto_build
needs to be forced the makefile build system, as the presence of
configure prevents it from passing cross tools otherwise. Please
consider applying the attached patch.

Helmut
-------------- next part --------------
diff --minimal -Nru passage-4+dfsg1/debian/changelog passage-4+dfsg1/debian/changelog
--- passage-4+dfsg1/debian/changelog	2017-08-01 16:43:37.000000000 +0200
+++ passage-4+dfsg1/debian/changelog	2019-02-25 17:48:51.000000000 +0100
@@ -1,3 +1,13 @@
+passage (4+dfsg1-3.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Fix FTCBFS: (Closes: #-1)
+    + cross.patch: Make the compiler substitutable.
+    + Let dh_auto_build's makefile build system pass cross tools to make.
+      (Closes: #-1)
+
+ -- Helmut Grohne <helmut at subdivi.de>  Mon, 25 Feb 2019 17:48:51 +0100
+
 passage (4+dfsg1-3) unstable; urgency=medium
 
   * Fix build reproducibility issues due to use of imagemagick  (Closes: #779136)
diff --minimal -Nru passage-4+dfsg1/debian/patches/cross.patch passage-4+dfsg1/debian/patches/cross.patch
--- passage-4+dfsg1/debian/patches/cross.patch	1970-01-01 01:00:00.000000000 +0100
+++ passage-4+dfsg1/debian/patches/cross.patch	2019-02-25 17:48:51.000000000 +0100
@@ -0,0 +1,13 @@
+--- passage-4+dfsg1.orig/gamma256/gameSource/Makefile.all
++++ passage-4+dfsg1/gamma256/gameSource/Makefile.all
+@@ -1,8 +1,8 @@
+ 
+ ROOT_PATH = ../..
+ 
+-COMPILE = g++ ${PLATFORM_COMPILE_FLAGS} -Wall -Wwrite-strings -Wchar-subscripts -Wparentheses -g -I${ROOT_PATH} -c
+-LINK = g++ -I${ROOT_PATH}
++COMPILE = $(CXX) ${PLATFORM_COMPILE_FLAGS} -Wall -Wwrite-strings -Wchar-subscripts -Wparentheses -g -I${ROOT_PATH} -c
++LINK = $(CXX) -I${ROOT_PATH}
+ 
+ 
+ 
diff --minimal -Nru passage-4+dfsg1/debian/patches/series passage-4+dfsg1/debian/patches/series
--- passage-4+dfsg1/debian/patches/series	2010-10-30 10:27:40.000000000 +0200
+++ passage-4+dfsg1/debian/patches/series	2019-02-25 17:48:51.000000000 +0100
@@ -1 +1,2 @@
 abs_path.patch
+cross.patch
diff --minimal -Nru passage-4+dfsg1/debian/rules passage-4+dfsg1/debian/rules
--- passage-4+dfsg1/debian/rules	2014-11-26 09:44:13.000000000 +0100
+++ passage-4+dfsg1/debian/rules	2019-02-25 17:48:49.000000000 +0100
@@ -21,7 +21,7 @@
 	convert 32x32/passage.png 32x32/passage.xpm
 	sed -i -e 's/PLATFORM_COMPILE_FLAGS = */PLATFORM_COMPILE_FLAGS = $$(CFLAGS) $$(CPPFLAGS) /' gamma256/gameSource/Makefile
 	sed -i -e 's/PLATFORM_LINK_FLAGS = */PLATFORM_LINK_FLAGS = $$(LDFLAGS) /' gamma256/gameSource/Makefile
-	$(MAKE) -C gamma256/gameSource LDFLAGS="$(LDFLAGS)" CPPFLAGS="$(CPPFLAGS)" CFLAGS="$(CFLAGS) -DETCDIR=\\\"/etc/passage\\\" -DDATADIR=\\\"/usr/share/games/passage/\\\""
+	dh_auto_build --buildsystem=makefile --sourcedirectory=gamma256/gameSource -- LDFLAGS="$(LDFLAGS)" CPPFLAGS="$(CPPFLAGS)" CFLAGS="$(CFLAGS) -DETCDIR=\\\"/etc/passage\\\" -DDATADIR=\\\"/usr/share/games/passage/\\\""
 
 override_dh_auto_clean:
 	find gamma256 -name "*.o" -delete


More information about the Pkg-games-devel mailing list