summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorJohn Hawthorn <john.hawthorn@gmail.com>2014-07-12 15:07:22 -0700
committerJohn Hawthorn <john.hawthorn@gmail.com>2014-07-12 15:17:04 -0700
commitafeeb5bb458042c353573c2b2f464d35123e5aad (patch)
tree5e81c336692403148e8d77c915f066191d66ae2a /Makefile
parente550feae6dd230ceff8ebaab91f7e41ea333d1c7 (diff)
Add tests and split matching into match.c
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile17
1 files changed, 11 insertions, 6 deletions
diff --git a/Makefile b/Makefile
index 7944bcb..974332c 100644
--- a/Makefile
+++ b/Makefile
@@ -1,10 +1,15 @@
-LIBS=
CFLAGS+=-Wall -Wextra -g
-TARGET=fzy
-OBJECTS=fzy.o
-$(TARGET): $(OBJECTS)
- $(CC) $(CCFLAGS) -o $@ $^ $(LIBS)
+all: fzy testscore
+
+testscore: testscore.o match.o
+ $(CC) $(CCFLAGS) -o $@ $^
+
+test: testscore
+ ruby test.rb
+
+fzy: fzy.o match.o
+ $(CC) $(CCFLAGS) -o $@ $^
clean:
- $(RM) $(TARGET) *.o
+ $(RM) fzy testscore *.o