diff --git a/Makefile b/Makefile index 99c8660..b973201 100644 --- a/Makefile +++ b/Makefile @@ -82,7 +82,17 @@ endef .PHONY: default default: -include makefile.mk + +INCLUDE += include + +SRC_DIR = src +include $(SRC_DIR)/makefile.mk + +TOOLS_DIR = tools +-include $(TOOLS_DIR)/makefile.mk + +TEST_DIR := test +-include $(TEST_DIR)/makefile.mk # diff --git a/makefile.mk b/src/makefile.mk similarity index 91% rename from makefile.mk rename to src/makefile.mk index a7b3976..968ec43 100644 --- a/makefile.mk +++ b/src/makefile.mk @@ -14,9 +14,6 @@ # limitations under the License. # -INCLUDE += include -SRC_DIR := src - liblc3_src += \ $(SRC_DIR)/attdet.c \ $(SRC_DIR)/bits.c \ @@ -36,6 +33,3 @@ liblc3_cflags += -ffast-math $(eval $(call add-lib,liblc3)) default: liblc3 - --include tools/makefile.mk --include test/makefile.mk diff --git a/test/makefile.mk b/test/makefile.mk index b52b7ac..a7bcb04 100644 --- a/test/makefile.mk +++ b/test/makefile.mk @@ -14,8 +14,6 @@ # limitations under the License. # -TEST_DIR := test - test_py: $(V)cd $(TEST_DIR) && python3 setup.py && PYTHONPATH=build python3 run.py diff --git a/tools/makefile.mk b/tools/makefile.mk index 066003e..cc19c29 100644 --- a/tools/makefile.mk +++ b/tools/makefile.mk @@ -14,9 +14,6 @@ # limitations under the License. # -TOOLS_DIR = tools - - elc3_src += \ $(TOOLS_DIR)/elc3.c \ $(TOOLS_DIR)/lc3bin.c \