]> git.donarmstrong.com Git - qmk_firmware.git/blob - tool/mbed/common.mk
Squashed 'tmk_core/' content from commit 05caacc
[qmk_firmware.git] / tool / mbed / common.mk
1 OBJECTS += \
2         $(OBJDIR)/common/action.o \
3         $(OBJDIR)/common/action_tapping.o \
4         $(OBJDIR)/common/action_macro.o \
5         $(OBJDIR)/common/action_layer.o \
6         $(OBJDIR)/common/action_util.o \
7         $(OBJDIR)/common/host.o \
8         $(OBJDIR)/common/keymap.o \
9         $(OBJDIR)/common/keyboard.o \
10         $(OBJDIR)/common/print.o \
11         $(OBJDIR)/common/debug.o \
12         $(OBJDIR)/common/util.o \
13         $(OBJDIR)/common/mbed/suspend.o \
14         $(OBJDIR)/common/mbed/timer.o \
15         $(OBJDIR)/common/mbed/xprintf.o \
16         $(OBJDIR)/common/mbed/bootloader.o \
17
18 INCLUDE_PATHS += \
19         -I$(TMK_DIR)/common \
20         -I$(TMK_DIR)/protocol
21
22 CC_FLAGS += -include $(CONFIG_H)
23
24
25
26 # Option modules
27 ifdef BOOTMAGIC_ENABLE
28     $(error Not Supported)
29     OBJECTS += $(OBJDIR)/common/bootmagic.o
30     OBJECTS += $(OBJDIR)/common/mbed/eeprom.o
31     OPT_DEFS += -DBOOTMAGIC_ENABLE
32 endif
33
34 ifdef MOUSEKEY_ENABLE
35     OBJECTS += $(OBJDIR)/common/mousekey.o
36     OPT_DEFS += -DMOUSEKEY_ENABLE
37     OPT_DEFS += -DMOUSE_ENABLE
38 endif
39
40 ifdef EXTRAKEY_ENABLE
41     $(error Not Supported)
42     OPT_DEFS += -DEXTRAKEY_ENABLE
43 endif
44
45 ifdef CONSOLE_ENABLE
46     $(error Not Supported)
47     OPT_DEFS += -DCONSOLE_ENABLE
48 else
49     OPT_DEFS += -DNO_PRINT
50     OPT_DEFS += -DNO_DEBUG
51 endif
52
53 ifdef COMMAND_ENABLE
54     $(error Not Supported)
55     SRC += common/command.c
56     OPT_DEFS += -DCOMMAND_ENABLE
57 endif
58
59 ifdef NKRO_ENABLE
60     $(error Not Supported)
61     OPT_DEFS += -DNKRO_ENABLE
62 endif
63
64 ifdef SLEEP_LED_ENABLE
65     $(error Not Supported)
66     SRC += common/sleep_led.c
67     OPT_DEFS += -DSLEEP_LED_ENABLE
68     OPT_DEFS += -DNO_SUSPEND_POWER_DOWN
69 endif
70
71 ifdef BACKLIGHT_ENABLE
72     $(error Not Supported)
73     SRC += common/backlight.c
74     OPT_DEFS += -DBACKLIGHT_ENABLE
75 endif
76
77 ifdef KEYMAP_SECTION_ENABLE
78     $(error Not Supported)
79     OPT_DEFS += -DKEYMAP_SECTION_ENABLE
80     EXTRALDFLAGS = -Wl,-L$(TMK_DIR),-Tldscript_keymap_avr5.x
81 endif