Fixed Makefile

This commit is contained in:
Bob Polis 2023-03-23 14:43:03 +01:00
parent cd249bc9dd
commit 36589ccfbc

View File

@ -7,6 +7,7 @@ MANPAGE := $(BIN).$(MANSECTION)
SRCS := $(notdir $(wildcard src/*.cpp)) SRCS := $(notdir $(wildcard src/*.cpp))
OBJS := $(SRCS:.cpp=.o) OBJS := $(SRCS:.cpp=.o)
DEPS := $(SRCS:.cpp=.d)
BUILDDIR := build/intermediates/ BUILDDIR := build/intermediates/
PREFIX ?= /usr/local PREFIX ?= /usr/local
@ -49,7 +50,7 @@ $(OUTDIR)$(BIN): $(OBJS)
$(CXX) $(CXXFLAGS) -MMD -MP -MT $@ -MF $*.d -c $< $(CXX) $(CXXFLAGS) -MMD -MP -MT $@ -MF $*.d -c $<
@mv $@ $*.d $(BUILDDIR) @mv $@ $*.d $(BUILDDIR)
-include $(BUILDDIR)$(SRCS:.cpp=.d) -include $(addprefix $(BUILDDIR), $(DEPS))
test: test:
$(MAKE) -C tests && tests/tests $(MAKE) -C tests && tests/tests