Source: psad Version: 2.4.3-1.2 Tags: patch User: helm...@debian.org Usertags: rebootstrap
psad fails to cross build from source, because the upstream Makefile hard codes the build architecture compiler. To fix that, we need to make it substitutable and actually substitute it. The attached patch implements that and makes psad cross buildable. Please consider applying it. Helmut
diff --minimal -Nru psad-2.4.3/debian/changelog psad-2.4.3/debian/changelog --- psad-2.4.3/debian/changelog 2018-02-03 13:53:36.000000000 +0100 +++ psad-2.4.3/debian/changelog 2019-02-24 14:54:10.000000000 +0100 @@ -1,3 +1,12 @@ +psad (2.4.3-1.3) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Fix FTCBFS: (Closes: #-1) + + cross.patch: Make C compiler substitutable. + + Let dh_auto_build substitute the C compiler. + + -- Helmut Grohne <hel...@subdivi.de> Sun, 24 Feb 2019 14:54:10 +0100 + psad (2.4.3-1.2) unstable; urgency=medium * Non-maintainer upload. diff --minimal -Nru psad-2.4.3/debian/patches/cross.patch psad-2.4.3/debian/patches/cross.patch --- psad-2.4.3/debian/patches/cross.patch 1970-01-01 01:00:00.000000000 +0100 +++ psad-2.4.3/debian/patches/cross.patch 2019-02-24 14:54:10.000000000 +0100 @@ -0,0 +1,20 @@ +--- psad-2.4.3.orig/Makefile ++++ psad-2.4.3/Makefile +@@ -28,13 +28,13 @@ + + ### default + all : psadwatchd.c psad_funcs.c strlcpy.c strlcat.c psad.h +- /usr/bin/gcc $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) kmsgsd.c psad_funcs.c strlcpy.c strlcat.c -o kmsgsd +- /usr/bin/gcc $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) psadwatchd.c psad_funcs.c strlcpy.c strlcat.c -o psadwatchd ++ $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) kmsgsd.c psad_funcs.c strlcpy.c strlcat.c -o kmsgsd ++ $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) psadwatchd.c psad_funcs.c strlcpy.c strlcat.c -o psadwatchd + + ### debug mode + debug : kmsgsd.c psadwatchd.c psad_funcs.c strlcpy.c strlcat.c psad.h +- /usr/bin/gcc -Wall -g -DDEBUG kmsgsd.c psad_funcs.c strlcpy.c strlcat.c -o kmsgsd +- /usr/bin/gcc -Wall -g -DDEBUG psadwatchd.c psad_funcs.c strlcpy.c strlcat.c -o psadwatchd ++ $(CC) -Wall -g -DDEBUG kmsgsd.c psad_funcs.c strlcpy.c strlcat.c -o kmsgsd ++ $(CC) -Wall -g -DDEBUG psadwatchd.c psad_funcs.c strlcpy.c strlcat.c -o psadwatchd + + #install : kmsgsd + # if [ -x kmsgsd ]; then \ diff --minimal -Nru psad-2.4.3/debian/patches/series psad-2.4.3/debian/patches/series --- psad-2.4.3/debian/patches/series 2016-09-28 21:29:49.000000000 +0200 +++ psad-2.4.3/debian/patches/series 2019-02-24 14:53:51.000000000 +0100 @@ -1,2 +1,3 @@ fix_spelling.diff fixes_build.diff +cross.patch diff --minimal -Nru psad-2.4.3/debian/rules psad-2.4.3/debian/rules --- psad-2.4.3/debian/rules 2016-09-30 20:39:07.000000000 +0200 +++ psad-2.4.3/debian/rules 2019-02-24 14:53:48.000000000 +0100 @@ -19,7 +19,7 @@ build-arch: build-stamp build-stamp: dh_testdir - make all + dh_auto_build touch $@ build-indep: