aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile4
1 files changed, 2 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 45b2a03..1add784 100644
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,7 @@
1OBJS:=$(patsubst %.cpp,%.o,$(wildcard src/*.cpp)) 1OBJS:=$(patsubst %.cpp,%.o,$(wildcard src/*.cpp))
2TOBJS:=$(patsubst %.cpp,%.o,$(wildcard src/test/*.cpp)) 2TOBJS:=$(patsubst %.cpp,%.o,$(wildcard src/test/*.cpp))
3TDIRS:=$(filter-out %.o %.cpp %.h %.d,$(wildcard src/test/*)) 3TDIRS:=$(filter-out %.o %.cpp %.h %.d,$(wildcard src/test/*))
4TESTS:=$(patsubst src/test/%.o,%,$(TOBJS)) $(patsubst src/test/%,%,$(TDIRS)) 4TESTS:=$(patsubst src/test/%.o,tests/%,$(TOBJS)) $(patsubst src/test/%,tests/%,$(TDIRS))
5ATOBJS:=$(TOBJS) $(patsubst %.cpp,%.o,$(foreach dr,$(TDIRS),$(wildcard $(dr)/*.cpp))) 5ATOBJS:=$(TOBJS) $(patsubst %.cpp,%.o,$(foreach dr,$(TDIRS),$(wildcard $(dr)/*.cpp)))
6LIB:=libbu++.a 6LIB:=libbu++.a
7DATE:=$(shell date +%F) 7DATE:=$(shell date +%F)
@@ -39,7 +39,7 @@ $(LIB): $(OBJS)
39 39
40$(TESTS): $(ATOBJS) $(LIB) 40$(TESTS): $(ATOBJS) $(LIB)
41 echo "$(TXTLNK)$@" 41 echo "$(TXTLNK)$@"
42 g++ $(LDFLAGS) -ggdb $(filter %$@.o, $(TOBJS) ) $(patsubst %.cpp,%.o,$(wildcard $(filter %$@, $(TDIRS))/*.cpp)) -L. -lbu++ -o $@ 42 g++ $(LDFLAGS) -ggdb $(filter %$(patsubst tests/%,%,$@).o, $(TOBJS) ) $(patsubst %.cpp,%.o,$(wildcard $(filter %$(patsubst tests/%,%,$@), $(TDIRS))/*.cpp)) -L. -lbu++ -o $@
43 43
44tests: $(TESTS) 44tests: $(TESTS)
45 45