Add rules to build test binary.
This commit is contained in:
parent
18f2f4efcd
commit
d787da74bb
5
Makefile
5
Makefile
@ -16,16 +16,15 @@ TEST_SRC = $(filter-out src/main.c, $(SRC) $(wildcard test/*.c))
|
|||||||
$(TARGETNAME): $(TARGET)
|
$(TARGETNAME): $(TARGET)
|
||||||
|
|
||||||
$(TARGET): $(SRC)
|
$(TARGET): $(SRC)
|
||||||
mkdir -p build
|
mkdir -p $(BUILDFOLDER)
|
||||||
cc -o $@ $^ $(CPPFLAGS) $(CFLAGS) $(INC) -lm -lftdi1
|
cc -o $@ $^ $(CPPFLAGS) $(CFLAGS) $(INC) -lm -lftdi1
|
||||||
|
|
||||||
$(TEST_TARGETNAME): $(TEST_TARGET)
|
$(TEST_TARGETNAME): $(TEST_TARGET)
|
||||||
|
|
||||||
$(TEST_TARGET): $(TEST_SRC)
|
$(TEST_TARGET): $(TEST_SRC)
|
||||||
echo $(TEST_SRC)
|
|
||||||
mkdir -p $(TEST_BUILDFOLDER)
|
mkdir -p $(TEST_BUILDFOLDER)
|
||||||
cc -o $@ $^ $(CPPFLAGS) $(CFLAGS) $(INC) -lm -lftdi1 -lcunit
|
cc -o $@ $^ $(CPPFLAGS) $(CFLAGS) $(INC) -lm -lftdi1 -lcunit
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm -fr ./src/*.o ./build/*
|
rm -fr ./src/*.o $(BUILDFOLDER)*
|
||||||
rm -fr $(TEST_BUILDFOLDER)*
|
rm -fr $(TEST_BUILDFOLDER)*
|
||||||
|
Loading…
Reference in New Issue
Block a user