summaryrefslogtreecommitdiff
path: root/build_keyboard.mk
diff options
context:
space:
mode:
authorTakeshi ISHII <2170248+mtei@users.noreply.github.com>2021-08-29 08:42:57 +0900
committerGitHub <noreply@github.com>2021-08-29 09:42:57 +1000
commit9fe7b5307a1b520f844fd389b0cc5b67e30aa412 (patch)
tree7255bf760f0f04b06b6bdd6c787f264ef20d6b59 /build_keyboard.mk
parentf061ca497464fe85284906fb163a33eaee7a91ef (diff)
downloadqmk_firmware-9fe7b5307a1b520f844fd389b0cc5b67e30aa412.tar.gz
qmk_firmware-9fe7b5307a1b520f844fd389b0cc5b67e30aa412.zip
add 'include keyboard_features.mk' into build_keyboard.mk (#8422)
* add 'include keyboard_features.mk' into build_keyboard.mk keyboard_features.mk is a keyboard-local version of the functions performed by common_features.mk. * add comment into build_keyboard.mk * added description of keyboard_features.mk in hardware_keyboard_guidelines.md. * rename `keyboard_features.mk` to `post_rules.mk`
Diffstat (limited to 'build_keyboard.mk')
-rw-r--r--build_keyboard.mk19
1 files changed, 19 insertions, 0 deletions
diff --git a/build_keyboard.mk b/build_keyboard.mk
index 37fa6852f8..420643c3e7 100644
--- a/build_keyboard.mk
+++ b/build_keyboard.mk
@@ -115,6 +115,7 @@ include $(INFO_RULES_MK)
# Check for keymap.json first, so we can regenerate keymap.c
include build_json.mk
+# Pull in keymap level rules.mk
ifeq ("$(wildcard $(KEYMAP_PATH))", "")
# Look through the possible keymap folders until we find a matching keymap.c
ifneq ("$(wildcard $(MAIN_KEYMAP_PATH_5)/keymap.c)","")
@@ -345,6 +346,7 @@ ifeq ("$(USER_NAME)","")
endif
USER_PATH := users/$(USER_NAME)
+# Pull in user level rules.mk
-include $(USER_PATH)/rules.mk
ifneq ("$(wildcard $(USER_PATH)/config.h)","")
CONFIG_H += $(USER_PATH)/config.h
@@ -356,6 +358,23 @@ endif
# Disable features that a keyboard doesn't support
-include disable_features.mk
+# Pull in post_rules.mk files from all our subfolders
+ifneq ("$(wildcard $(KEYBOARD_PATH_1)/post_rules.mk)","")
+ include $(KEYBOARD_PATH_1)/post_rules.mk
+endif
+ifneq ("$(wildcard $(KEYBOARD_PATH_2)/post_rules.mk)","")
+ include $(KEYBOARD_PATH_2)/post_rules.mk
+endif
+ifneq ("$(wildcard $(KEYBOARD_PATH_3)/post_rules.mk)","")
+ include $(KEYBOARD_PATH_3)/post_rules.mk
+endif
+ifneq ("$(wildcard $(KEYBOARD_PATH_4)/post_rules.mk)","")
+ include $(KEYBOARD_PATH_4)/post_rules.mk
+endif
+ifneq ("$(wildcard $(KEYBOARD_PATH_5)/post_rules.mk)","")
+ include $(KEYBOARD_PATH_5)/post_rules.mk
+endif
+
ifneq ("$(wildcard $(KEYMAP_PATH)/config.h)","")
CONFIG_H += $(KEYMAP_PATH)/config.h
endif