aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--Makefile14
1 files changed, 11 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index df46d2b..515e737 100644
--- a/Makefile
+++ b/Makefile
@@ -3,10 +3,15 @@
CONFIGFILE = config.mk
include $(CONFIGFILE)
+
all: test
+test.o: binary-multisearch.h
+
+.c.o:
+ $(CC) -c -o $@ $< $(CFLAGS) $(CPPFLAGS)
-test: test.c binary-multisearch.h
- $(CC) -o $@ test.c $(CPPFLAGS) $(CFLAGS) $(LDFLAGS)
+.o:
+ $(CC) -o $@ $< $(LDFLAGS)
check: test
./test
@@ -19,6 +24,9 @@ uninstall:
-rm -f -- "$(DESTDIR)$(PREFIX)/include/binary-multisearch.h"
clean:
- -rm -f -- *.o test
+ -rm -f -- *.o *.su test
+
+.SUFFIXES:
+.SUFFIXES: .o .c
.PHONY: all check install uninstall clean