]> git.scottworley.com Git - overonion/blobdiff - Makefile
Test reverse
[overonion] / Makefile
index fee4ea93ce8b72e858b783f78fb5801ae2e96513..fe978d38c88269922e50e5925f60db2828a7d8c7 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -4,7 +4,7 @@ CFLAGS = -Wall -Wextra -pedantic -Wstrict-overflow
 all: reverse
 
 clean:
-       -rm *.o reverse
+       -rm *.o reverse reverse_test
 
 distclean: clean
        -rm deps.makefile deps.makefile.bak
@@ -12,9 +12,13 @@ distclean: clean
 depend: *.c
        makedepend -f- $^ > deps.makefile
 
-.PHONY: clean distclean depend
+test: reverse_test
+       ./reverse_test
 
-reverse: reverse.o
+.PHONY: clean distclean depend test
+
+reverse: reverse.o reverse_lib.o
+reverse_test: reverse_test.o reverse_lib.o
        $(CC) -o $@ $^ $(CFLAGS)
 
 %.o: %.c