Source: rbdoom3bfg
Version: 1.2.0+dfsg~git20200327-1
Tags: patch
User: [email protected]
Usertags: ftcbfs

rbdoom3bfg fails to cross build from source, because debian/rules
confuses the terms build and host. Please refer to man dpkg-architecture
for their definition. The attached patch also generalizes the detection
to other possible architectures such as hurd-amd64 (if ever). Please
consider applying it.

Helmut
diff --minimal -Nru rbdoom3bfg-1.2.0+dfsg~git20200327/debian/changelog 
rbdoom3bfg-1.2.0+dfsg~git20200327/debian/changelog
--- rbdoom3bfg-1.2.0+dfsg~git20200327/debian/changelog  2020-03-31 
11:27:50.000000000 +0200
+++ rbdoom3bfg-1.2.0+dfsg~git20200327/debian/changelog  2020-06-07 
09:04:25.000000000 +0200
@@ -1,3 +1,10 @@
+rbdoom3bfg (1.2.0+dfsg~git20200327-1.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Fix FTCBFS: fix build/host confusion. (Closes: #-1)
+
+ -- Helmut Grohne <[email protected]>  Sun, 07 Jun 2020 09:04:25 +0200
+
 rbdoom3bfg (1.2.0+dfsg~git20200327-1) unstable; urgency=medium
 
   * New upstream git snapshot.
diff --minimal -Nru rbdoom3bfg-1.2.0+dfsg~git20200327/debian/rules 
rbdoom3bfg-1.2.0+dfsg~git20200327/debian/rules
--- rbdoom3bfg-1.2.0+dfsg~git20200327/debian/rules      2020-03-31 
10:41:47.000000000 +0200
+++ rbdoom3bfg-1.2.0+dfsg~git20200327/debian/rules      2020-06-07 
09:04:25.000000000 +0200
@@ -1,5 +1,6 @@
 #!/usr/bin/make -f
 
+include /usr/share/dpkg/architecture.mk
 include /usr/share/dpkg/pkg-info.mk
 
 # output every command that modifies files on the build system.
@@ -9,10 +10,8 @@
 export DEB_CFLAGS_MAINT_APPEND  = -Wall -pedantic
 export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed
 
-DEB_BUILD_ARCH ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH)
-
 CMAKE_ADDTIONAL_FLAGS ?=
-ifeq ($(findstring $(DEB_BUILD_ARCH), amd64 kfreebsd-amd64),)
+ifneq ($(DEB_HOST_ARCH_CPU),amd64)
 CMAKE_ADDITIONAL_FLAGS ?= -DUSE_INTRINSICS=OFF
 endif
 

Reply via email to