Source: petris Version: 1.0.1-10 Tags: patch User: [email protected] Usertags: rebootstrap
petris fails to cross build from source, because Makefile hard codes the build architecture compiler "gcc". After making it substitutable, petris cross builds successfully. Please consider applying the attached patch. Helmut
diff --minimal -Nru petris-1.0.1/debian/changelog petris-1.0.1/debian/changelog --- petris-1.0.1/debian/changelog 2016-11-14 08:29:08.000000000 +0100 +++ petris-1.0.1/debian/changelog 2018-06-06 19:57:32.000000000 +0200 @@ -1,3 +1,11 @@ +petris (1.0.1-10.1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Fix FTCBFS: update use-variables-in-Makefile.patch to use CC. (Closes: + #-1) + + -- Helmut Grohne <[email protected]> Wed, 06 Jun 2018 19:57:32 +0200 + petris (1.0.1-10) unstable; urgency=low * Use debian/manpages instead of debian/rules stanza. diff --minimal -Nru petris-1.0.1/debian/patches/use-variables-in-Makefile.patch petris-1.0.1/debian/patches/use-variables-in-Makefile.patch --- petris-1.0.1/debian/patches/use-variables-in-Makefile.patch 2016-09-08 05:12:58.000000000 +0200 +++ petris-1.0.1/debian/patches/use-variables-in-Makefile.patch 2018-06-06 19:57:26.000000000 +0200 @@ -1,28 +1,28 @@ Description: Use variables in Makefile - Added variables CFLAGS & LIBS to Makefile so build system can use them. + Added variables CC, CFLAGS & LIBS to Makefile so build system can use them. Move ${LIBS} to the end of line for petris target so that ld --as needed works. Author: Andree Leidenfrost <[email protected]> --- a/Makefile +++ b/Makefile @@ -1,14 +1,17 @@ +CFLAGS+=-Wall +LIBS=-lncurses + petris : main.o game.o highscore.o - gcc -o petris main.o game.o highscore.o -lncurses -+ gcc -o petris main.o game.o highscore.o ${LIBS} ++ $(CC) -o petris main.o game.o highscore.o ${LIBS} main.o : main.c game.h petris.h - gcc -Wall -c main.c -+ gcc ${CFLAGS} -c main.c ++ $(CC) ${CFLAGS} -c main.c game.o : game.c game.h petris.h config.h - gcc -Wall -c game.c -+ gcc ${CFLAGS} -c game.c ++ $(CC) ${CFLAGS} -c game.c highscore.o : highscore.c highscore.h config.h - gcc -Wall -c highscore.c -+ gcc ${CFLAGS} -c highscore.c ++ $(CC) ${CFLAGS} -c highscore.c clean: - rm main.o game.o highscore.o

