diff options
author | Fred Sundvik <fsundvik@gmail.com> | 2016-07-06 15:36:45 +0300 |
---|---|---|
committer | Fred Sundvik <fsundvik@gmail.com> | 2016-07-06 16:06:53 +0300 |
commit | e5726b017a9de2922ea923818c6e215600f68a85 (patch) | |
tree | 2d1470d076017af6d089a00f4bb317abdb331346 /Makefile | |
parent | 4b45deb652045aac73e5fdd7412a73bcef19c0c8 (diff) |
Add setting of the master side to the makefile
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 14 |
1 files changed, 14 insertions, 0 deletions
@@ -59,6 +59,12 @@ ifndef KEYBOARD KEYBOARD=planck endif +MASTER ?= left +ifdef master + MASTER = $(master) +endif + + # converts things to keyboards/subproject ifneq (,$(findstring /,$(KEYBOARD))) TEMP:=$(KEYBOARD) @@ -212,6 +218,14 @@ ifeq ($(strip $(SERIAL_LINK_ENABLE)), yes) VAPTH += $(SERIAL_PATH) endif +ifeq ($(MASTER),right) + OPT_DEFS += -DMASTER_IS_ON_RIGHT +else + ifneq ($(MASTER),left) +$(error MASTER does not have a valid value(left/right)) + endif +endif + # Optimize size but this may cause error "relocation truncated to fit" #EXTRALDFLAGS = -Wl,--relax |