diff options
Diffstat (limited to 'Bootloaders/TeensyHID/makefile')
-rw-r--r-- | Bootloaders/TeensyHID/makefile | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/Bootloaders/TeensyHID/makefile b/Bootloaders/TeensyHID/makefile index fb3f1eb28..f4b884308 100644 --- a/Bootloaders/TeensyHID/makefile +++ b/Bootloaders/TeensyHID/makefile @@ -110,6 +110,16 @@ OBJDIR = . LUFA_PATH = ../..
+# LUFA library compile-time options
+LUFA_OPTS = USB_DEVICE_ONLY
+LUFA_OPTS += USE_NONSTANDARD_DESCRIPTOR_NAMES
+LUFA_OPTS += CONTROL_ONLY_DEVICE
+LUFA_OPTS += FIXED_CONTROL_ENDPOINT_SIZE=8
+LUFA_OPTS += USE_SINGLE_DEVICE_CONFIGURATION
+LUFA_OPTS += USE_STATIC_OPTIONS="(USB_DEVICE_OPT_FULLSPEED | USB_OPT_REG_ENABLED | USB_OPT_AUTO_PLL)"
+LUFA_OPTS += USE_RAM_DESCRIPTORS
+
+
# List C source files here. (C dependencies are automatically generated.)
SRC = $(TARGET).c \
Descriptors.c \
@@ -172,11 +182,8 @@ BOOT_START = 0xC000 # Place -D or -U options here for C sources
-CDEFS = -DF_CPU=$(F_CPU)UL -DF_CLOCK=$(F_CLOCK)UL -DBOARD=BOARD_$(BOARD)
-CDEFS += -DUSB_DEVICE_ONLY -DUSE_NONSTANDARD_DESCRIPTOR_NAMES -DCONTROL_ONLY_DEVICE
-CDEFS += -DFIXED_CONTROL_ENDPOINT_SIZE=8 -DUSE_SINGLE_DEVICE_CONFIGURATION
-CDEFS += -DUSE_STATIC_OPTIONS="(USB_DEVICE_OPT_FULLSPEED | USB_OPT_REG_ENABLED | USB_OPT_AUTO_PLL)"
-CDEFS += -DUSE_RAM_DESCRIPTORS -DBOOT_START_ADDR=$(BOOT_START)UL
+CDEFS = -DF_CPU=$(F_CPU)UL -DF_CLOCK=$(F_CLOCK)UL -DBOARD=BOARD_$(BOARD) $(patsubst %,-D%,$(LUFA_OPTS))
+CDEFS += -DBOOT_START_ADDR=$(BOOT_START)UL
# Place -D or -U options here for ASM sources
|