use heap_and_reap memory manager
[firmware_header_edit.git] / Makefile
index 5c2a249..40f9374 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,14 +1,17 @@
-PROG=fwheaditor
-SRC=firmware_header_editor.c
-CFLAGS=-std=c11 -g
+PROG = fwheaditor
+OBJS = heap_reap.o firmware_header_editor.o
+CFLAGS = -std=c11 -g
 
 export PROG
 
-$(PROG): $(SRC)
-       $(CC) $(CFLAGS) -o $@ $<
+$(PROG): $(OBJS)
+       $(CC) $(CFLAGS) -o $@ $(OBJS)
+
+%.c:
+       $(CC) $(CFLAGS) -c $@
 
 clean:
-       -rm -f $(PROG)
+       -rm -f $(PROG) $(OBJ)
 
 tests:
        $(MAKE) -C testsuite