diff options
author | Mattias Andrée <maandree@kth.se> | 2018-08-28 12:36:31 +0200 |
---|---|---|
committer | Mattias Andrée <maandree@kth.se> | 2018-08-28 12:36:31 +0200 |
commit | 6fda2a0697d9d49db823e1569edf27378cf31daf (patch) | |
tree | 9c088ca8932b98a33bfe92c2300d2940b5ca8353 /Makefile | |
parent | Add test function to all .c files (diff) | |
download | libsimple-6fda2a0697d9d49db823e1569edf27378cf31daf.tar.gz libsimple-6fda2a0697d9d49db823e1569edf27378cf31daf.tar.bz2 libsimple-6fda2a0697d9d49db823e1569edf27378cf31daf.tar.xz |
Add tests for allocation functions
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to '')
-rw-r--r-- | Makefile | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -63,15 +63,16 @@ TESTS = $(OBJ:.o=.test) all: libsimple.a $(TESTS) $(OBJ): $(@:.o=.c) libsimple.h -$(TESTS): $(@:=.o) libsimple.a +$(TESTS): $(@:=.o) test.o libsimple.a $(TESTS:=.o): $(@:.test.o=.c) libsimple.h test.h +test.o: test.c libsimple.h test.h libsimple.a: $(OBJ) $(AR) rc $@ $? $(AR) -s $@ .test.o.test: - $(CC) -o $@ $< libsimple.a $(LDFLAGS) + $(CC) -o $@ $< libsimple.a test.o $(LDFLAGS) .c.test.o: $(CC) -c -o $@ $< $(CFLAGS) -DTEST |