diff mbox

[1/7] volatile-test: Simplify makefile and add testfile generation

Message ID 1375133480-5597-2-git-send-email-john.stultz@linaro.org
State Accepted
Headers show

Commit Message

John Stultz July 29, 2013, 9:31 p.m. UTC
Simplify the makefile and test file generation for file based testing

Signed-off-by: John Stultz <john.stultz@linaro.org>
---
 Makefile | 16 ++++++++++------
 1 file changed, 10 insertions(+), 6 deletions(-)
diff mbox

Patch

diff --git a/Makefile b/Makefile
index 7f01f20..e41fea2 100644
--- a/Makefile
+++ b/Makefile
@@ -1,9 +1,13 @@ 
-CFLAGS=-g -Wall
+CFLAGS += -g -Wall -O3 -Wl,-no-as-needed
 
-all:	volatile-test volatile-test-signal
+bins = volatile-test volatile-test-signal
+testfile = test
 
-volatile-test:	volatile-test.c
-	${CC} ${CFLAGS} -o $@ $@.c
+all: ${bins}
+
+testfile:
+	dd if=/dev/zero of=${testfile} bs=1M count=26
+
+clean:
+	rm -f ${bins} ${testfile}
 
-volatile-test-signal:	volatile-test-signal.c
-	${CC} ${CFLAGS} -o $@ $@.c