aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/hal.mk
diff options
context:
space:
mode:
Diffstat (limited to 'os/hal/hal.mk')
-rw-r--r--os/hal/hal.mk8
1 files changed, 7 insertions, 1 deletions
diff --git a/os/hal/hal.mk b/os/hal/hal.mk
index 905dbfd5d..9691e4b23 100644
--- a/os/hal/hal.mk
+++ b/os/hal/hal.mk
@@ -1,7 +1,13 @@
# List of all the ChibiOS/HAL files, there is no need to remove the files
# from this list, you can disable parts of the HAL by editing halconf.h.
ifeq ($(USE_SMART_BUILD),yes)
-HALCONF := $(strip $(shell cat halconf.h | egrep -e "\#define"))
+
+# Configuration files directory
+ifeq ($(CONFDIR),)
+ CONFDIR = .
+endif
+
+HALCONF := $(strip $(shell cat $(CONFDIR)/halconf.h | egrep -e "\#define"))
HALSRC := $(CHIBIOS)/os/hal/src/hal.c \
$(CHIBIOS)/os/hal/src/hal_st.c \