Source: jade Version: 1.2.1-49 Tags: patch User: helm...@debian.org Usertags: rebootstrap
jade fails to cross build from source, because it passes the build architecture compiler to ./configure and does not pass --host to ./configure. The attached patch fixes both and thus makes cross builds succeed. Please consider applying it. Alternatively, consider switching to dh_auto_configure and a higher debhelper compatibility level, as dh_auto_configure passes these flags for you. Helmut
diff -u jade-1.2.1/debian/changelog jade-1.2.1/debian/changelog --- jade-1.2.1/debian/changelog +++ jade-1.2.1/debian/changelog @@ -1,3 +1,12 @@ +jade (1.2.1-49.1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Fix FTCBFS: (Closes: #-1). + + Use triplet-prefixed compilers. + + Pass --host to ./configure. + + -- Helmut Grohne <hel...@subdivi.de> Mon, 07 Nov 2016 06:02:46 +0100 + jade (1.2.1-49) unstable; urgency=medium * Changed d/compat to 5 (no other changes for this) (Closes: #817507). diff -u jade-1.2.1/debian/rules jade-1.2.1/debian/rules --- jade-1.2.1/debian/rules +++ jade-1.2.1/debian/rules @@ -9,6 +9,8 @@ #export DH_VERBOSE=1 +include /usr/share/dpkg/architecture.mk + pkg-sp := sp pkg-jade := jade pkg-libsp1 := libsp1c2 @@ -69,12 +71,15 @@ CFLAGS := -g -pipe -fpermissive CXXFLAGS := -g -pipe -D_REENTRANT -fpermissive -CC := gcc -CXX := g++ +ifeq ($(origin CC),default) +CC := $(DEB_HOST_GNU_TYPE)-gcc +endif +ifeq ($(origin CXX),default) +CXX := $(DEB_HOST_GNU_TYPE)-g++ +endif # work around broken C++ compiler 4.0 on hppa -DEB_BUILD_ARCH := $(shell dpkg-architecture -qDEB_BUILD_ARCH) # ifeq ($(DEB_BUILD_ARCH),hppa) # CC := gcc-3.4 # CXX := g++-3.4 @@ -101,13 +106,17 @@ @echo Debian version is $(SRC_VERSION) @echo upstream version is $(UPSTREAM_VERSION) +ifneq ($(DEB_BUILD_ARCH),$(DEB_HOST_ARCH)) +CONFIGURE_FLAGS += --build=$(DEB_BUILD_GNU_TYPE) --host=$(DEB_HOST_GNU_TYPE) +endif config.status: dh_buildinfo generate cat CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" CC="$(CXX)" CXX="$(CXX)" \ ./configure --prefix=/usr --enable-html \ --enable-http --enable-static --enable-shared --enable-mif \ --enable-default-catalog=$(default-catalogs) \ - --enable-default-search-path=$(default-sgml-path) + --enable-default-search-path=$(default-sgml-path) \ + $(CONFIGURE_FLAGS) build: config.status dh_testdir