diff options
Diffstat (limited to 'testing/memdump/03-build-flags-support.patch')
-rw-r--r-- | testing/memdump/03-build-flags-support.patch | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/testing/memdump/03-build-flags-support.patch b/testing/memdump/03-build-flags-support.patch new file mode 100644 index 0000000000..4485cc2640 --- /dev/null +++ b/testing/memdump/03-build-flags-support.patch @@ -0,0 +1,48 @@ +Description: Support build flags injection + Proper support of LDFLAGS / CFLAGS / CPPFLAGS is required so + that dpkg-buildflags can inject supplementary build options. +Author: Raphaƫl Hertzog <hertzog@debian.org> +Origin: vendor +Last-Update: 2015-07-28 +--- +This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ +Index: memdump/Makefile +=================================================================== +--- memdump.orig/Makefile ++++ memdump/Makefile +@@ -1,9 +1,13 @@ + SHELL = /bin/sh +-CC = gcc -Wformat -Wunused ++CC = gcc + OPT = -O + DEBUG = -g + PROGS = memdump +-CFLAGS = $(OPT) $(DEBUG) -I. $(XFLAGS) $(DEFS) ++ifneq ($(DEFS),) ++# Only complete variables once when we're called with make DEFS="something" ++CPPFLAGS += -I. $(DEFS) ++CFLAGS += -Wall -Wno-comment ++endif + OBJS = memdump.o convert_size.o error.o mymalloc.o + PROGS = memdump + MAN = memdump.1 +@@ -16,7 +20,7 @@ all: $(PROGS) + manpages: $(MAN) + + memdump: $(OBJS) +- $(CC) $(CFLAGS) -o $@ $(OBJS) $(SYSLIBS) ++ $(CC) $(LDFLAGS) -o $@ $(OBJS) $(SYSLIBS) + + memdump.1: memdump.c + srctoman $? >$@ +Index: memdump/makedefs +=================================================================== +--- memdump.orig/makedefs ++++ memdump/makedefs +@@ -40,5 +40,5 @@ esac + + unset MAKELEVEL # shut up chatty GNU make + +-make DEFS="$DEFS" CC="${CC-gcc -Wunused}" RANLIB="${RANLIB-ranlib}" \ ++make DEFS="$DEFS" CC="${CC-gcc}" RANLIB="${RANLIB-ranlib}" \ + AR="${AR-ar rv}" SYSLIBS="$SYSLIBS" all |