Source: xbattbar Version: 1.4.9-2 Tags: patch User: debian-cr...@lists.debian.org Usertags: ftcbfs
xbattbar fails to cross build from source, because the upstream Makefile hard codes the build architecture compiler and the debian packaging does not pass cross tools to make. The attached patch fixes both aspects. Please consider applying it. Helmut
diff --minimal -Nru xbattbar-1.4.9/debian/changelog xbattbar-1.4.9/debian/changelog --- xbattbar-1.4.9/debian/changelog 2020-01-01 08:49:59.000000000 +0100 +++ xbattbar-1.4.9/debian/changelog 2020-01-02 20:30:46.000000000 +0100 @@ -1,3 +1,12 @@ +xbattbar (1.4.9-2.1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Fix FTCBFS: (Closes: #-1) + + cross.patch: Make gcc substitutable. + + Let dh_auto_build substitute $(CC). + + -- Helmut Grohne <hel...@subdivi.de> Thu, 02 Jan 2020 20:30:46 +0100 + xbattbar (1.4.9-2) unstable; urgency=medium * Rebuild package with pbuilder:SOURCE_ONLY_CHANGES=yes. diff --minimal -Nru xbattbar-1.4.9/debian/patches/cross.patch xbattbar-1.4.9/debian/patches/cross.patch --- xbattbar-1.4.9/debian/patches/cross.patch 1970-01-01 01:00:00.000000000 +0100 +++ xbattbar-1.4.9/debian/patches/cross.patch 2020-01-02 20:30:45.000000000 +0100 @@ -0,0 +1,23 @@ +--- xbattbar-1.4.9.orig/Makefile ++++ xbattbar-1.4.9/Makefile +@@ -11,16 +11,16 @@ + all: $(TARGET) $(APM_CHECK) + + $(TARGET): obj/xbattbar.o +- gcc -o $@ $< -lX11 $(LDFLAGS) ++ $(CC) -o $@ $< -lX11 $(LDFLAGS) + + obj/xbattbar.o: xbattbar.c obj/stamp +- gcc -MMD -o $@ -c $< $(CFLAGS) ++ $(CC) -MMD -o $@ -c $< $(CFLAGS) + + $(APM_CHECK): obj/xbattbar-check-apm.o +- gcc -o $@ $< $(LDFLAGS) ++ $(CC) -o $@ $< $(LDFLAGS) + + obj/xbattbar-check-apm.o: xbattbar-check-apm.c obj/stamp +- gcc -MMD -D$(OS_TYPE) -o $@ -c $< $(CFLAGS) ++ $(CC) -MMD -D$(OS_TYPE) -o $@ -c $< $(CFLAGS) + + obj/stamp: + mkdir obj diff --minimal -Nru xbattbar-1.4.9/debian/patches/series xbattbar-1.4.9/debian/patches/series --- xbattbar-1.4.9/debian/patches/series 1970-01-01 01:00:00.000000000 +0100 +++ xbattbar-1.4.9/debian/patches/series 2020-01-02 20:30:24.000000000 +0100 @@ -0,0 +1 @@ +cross.patch diff --minimal -Nru xbattbar-1.4.9/debian/rules xbattbar-1.4.9/debian/rules --- xbattbar-1.4.9/debian/rules 2019-12-31 11:01:08.000000000 +0100 +++ xbattbar-1.4.9/debian/rules 2020-01-02 20:29:16.000000000 +0100 @@ -5,7 +5,7 @@ build-stamp: dh_testdir - $(MAKE) + dh_auto_build touch build-stamp clean: