aboutsummaryrefslogtreecommitdiffstats
path: root/testing/memdump/03-build-flags-support.patch
diff options
context:
space:
mode:
authorNiklas Cathor <niklas.cathor@gmx.de>2020-04-08 15:26:05 +0200
committerRasmus Thomsen <oss@cogitri.dev>2020-04-10 09:03:15 +0000
commitb58feaab7a22d8ddf49a6929fc4579929b7ee5bd (patch)
tree6b15ad0f27bf5fb125255a36e6d8a64b86ce2050 /testing/memdump/03-build-flags-support.patch
parent2edb15dec95097e45c960d433bc3bd9ffb99d4ea (diff)
downloadaports-b58feaab7a22d8ddf49a6929fc4579929b7ee5bd.tar.bz2
aports-b58feaab7a22d8ddf49a6929fc4579929b7ee5bd.tar.xz
testing/memdump: new aport
http://www.porcupine.org/forensics/tct.html utility to dump memory contents to standard output
Diffstat (limited to 'testing/memdump/03-build-flags-support.patch')
-rw-r--r--testing/memdump/03-build-flags-support.patch48
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