diff options
| author | tmk <hasu@tmk-kbd.com> | 2015-04-10 01:32:04 +0900 |
|---|---|---|
| committer | tmk <hasu@tmk-kbd.com> | 2015-04-10 01:32:04 +0900 |
| commit | 1a02ebcc612e9a9c0d87e02295c7258de3a70ccc (patch) | |
| tree | e517f3c70bb2d542797e57d13e9023c84af230fb /tmk_core/common.mk | |
| parent | 6746e37088ce8ba03529c1226bd216705edb2b1f (diff) | |
| parent | a074364c3731d66b56d988c8a6c960a83ea0e0a1 (diff) | |
| download | qmk_firmware-1a02ebcc612e9a9c0d87e02295c7258de3a70ccc.tar.gz qmk_firmware-1a02ebcc612e9a9c0d87e02295c7258de3a70ccc.zip | |
Merge commit 'a074364c3731d66b56d988c8a6c960a83ea0e0a1' as 'tmk_core'
Diffstat (limited to 'tmk_core/common.mk')
| -rw-r--r-- | tmk_core/common.mk | 77 |
1 files changed, 77 insertions, 0 deletions
diff --git a/tmk_core/common.mk b/tmk_core/common.mk new file mode 100644 index 000000000..d22adff51 --- /dev/null +++ b/tmk_core/common.mk | |||
| @@ -0,0 +1,77 @@ | |||
| 1 | COMMON_DIR = common | ||
| 2 | SRC += $(COMMON_DIR)/host.c \ | ||
| 3 | $(COMMON_DIR)/keyboard.c \ | ||
| 4 | $(COMMON_DIR)/action.c \ | ||
| 5 | $(COMMON_DIR)/action_tapping.c \ | ||
| 6 | $(COMMON_DIR)/action_macro.c \ | ||
| 7 | $(COMMON_DIR)/action_layer.c \ | ||
| 8 | $(COMMON_DIR)/action_util.c \ | ||
| 9 | $(COMMON_DIR)/keymap.c \ | ||
| 10 | $(COMMON_DIR)/print.c \ | ||
| 11 | $(COMMON_DIR)/debug.c \ | ||
| 12 | $(COMMON_DIR)/util.c \ | ||
| 13 | $(COMMON_DIR)/avr/suspend.c \ | ||
| 14 | $(COMMON_DIR)/avr/xprintf.S \ | ||
| 15 | $(COMMON_DIR)/avr/timer.c \ | ||
| 16 | $(COMMON_DIR)/avr/bootloader.c | ||
| 17 | |||
| 18 | |||
| 19 | # Option modules | ||
| 20 | ifdef BOOTMAGIC_ENABLE | ||
| 21 | SRC += $(COMMON_DIR)/bootmagic.c | ||
| 22 | SRC += $(COMMON_DIR)/avr/eeconfig.c | ||
| 23 | OPT_DEFS += -DBOOTMAGIC_ENABLE | ||
| 24 | endif | ||
| 25 | |||
| 26 | ifdef MOUSEKEY_ENABLE | ||
| 27 | SRC += $(COMMON_DIR)/mousekey.c | ||
| 28 | OPT_DEFS += -DMOUSEKEY_ENABLE | ||
| 29 | OPT_DEFS += -DMOUSE_ENABLE | ||
| 30 | endif | ||
| 31 | |||
| 32 | ifdef EXTRAKEY_ENABLE | ||
| 33 | OPT_DEFS += -DEXTRAKEY_ENABLE | ||
| 34 | endif | ||
| 35 | |||
| 36 | ifdef CONSOLE_ENABLE | ||
| 37 | OPT_DEFS += -DCONSOLE_ENABLE | ||
| 38 | else | ||
| 39 | OPT_DEFS += -DNO_PRINT | ||
| 40 | OPT_DEFS += -DNO_DEBUG | ||
| 41 | endif | ||
| 42 | |||
| 43 | ifdef COMMAND_ENABLE | ||
| 44 | SRC += $(COMMON_DIR)/command.c | ||
| 45 | OPT_DEFS += -DCOMMAND_ENABLE | ||
| 46 | endif | ||
| 47 | |||
| 48 | ifdef NKRO_ENABLE | ||
| 49 | OPT_DEFS += -DNKRO_ENABLE | ||
| 50 | endif | ||
| 51 | |||
| 52 | ifdef USB_6KRO_ENABLE | ||
| 53 | OPT_DEFS += -DUSB_6KRO_ENABLE | ||
| 54 | endif | ||
| 55 | |||
| 56 | ifdef SLEEP_LED_ENABLE | ||
| 57 | SRC += $(COMMON_DIR)/sleep_led.c | ||
| 58 | OPT_DEFS += -DSLEEP_LED_ENABLE | ||
| 59 | OPT_DEFS += -DNO_SUSPEND_POWER_DOWN | ||
| 60 | endif | ||
| 61 | |||
| 62 | ifdef BACKLIGHT_ENABLE | ||
| 63 | SRC += $(COMMON_DIR)/backlight.c | ||
| 64 | OPT_DEFS += -DBACKLIGHT_ENABLE | ||
| 65 | endif | ||
| 66 | |||
| 67 | ifdef KEYMAP_SECTION_ENABLE | ||
| 68 | OPT_DEFS += -DKEYMAP_SECTION_ENABLE | ||
| 69 | EXTRALDFLAGS = -Wl,-L$(TMK_DIR),-Tldscript_keymap_avr5.x | ||
| 70 | endif | ||
| 71 | |||
| 72 | # Version string | ||
| 73 | OPT_DEFS += -DVERSION=$(shell (git describe --always --dirty || echo 'unknown') 2> /dev/null) | ||
| 74 | |||
| 75 | |||
| 76 | # Search Path | ||
| 77 | VPATH += $(TMK_DIR)/common | ||
