-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
93 lines (82 loc) · 2.47 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
.POSIX:
CC = arm-none-eabi-gcc
CXX = arm-none-eabi-gcc
CFLAGS += -O1 -std=c99 -mcpu=cortex-m0plus -mthumb
CFLAGS += -DTARGET_LPC11U68
CFLAGS += -D__MBED__=1
CFLAGS += -DDEVICE_I2CSLAVE=1
CFLAGS += -DTARGET_LIKE_MBED
CFLAGS += -DTARGET_NXP
CFLAGS += -D__MBED_CMSIS_RTOS_CM
CFLAGS += -DDEVICE_RTC=1
CFLAGS += -DTOOLCHAIN_object
CFLAGS += -D__CMSIS_RTOS
CFLAGS += -DTOOLCHAIN_GCC
CFLAGS += -DTARGET_CORTEX_M
CFLAGS += -DTARGET_M0P
CFLAGS += -DTARGET_UVISOR_UNSUPPORTED
CFLAGS += -DDEVICE_SERIAL=1
CFLAGS += -DDEVICE_INTERRUPTIN=1
CFLAGS += -DTARGET_LPCTarget
CFLAGS += -DTARGET_CORTEX
CFLAGS += -DDEVICE_I2C=1
CFLAGS += -D__CORTEX_M0PLUS
CFLAGS += -DTARGET_FF_ARDUINO
CFLAGS += -DTARGET_RELEASE
CFLAGS += -DMBED_BUILD_TIMESTAMP=1526394586.66
CFLAGS += -DARM_MATH_CM0PLUS
CFLAGS += -DTARGET_LPC11U6X
CFLAGS += -DDEVICE_SLEEP=1
CFLAGS += -DTOOLCHAIN_GCC_ARM
CFLAGS += -DDEVICE_SPI=1
CFLAGS += -DDEVICE_ANALOGIN=1
CFLAGS += -DDEVICE_PWMOUT=1
CFLAGS += -DTARGET_LIKE_CORTEX_M0
CPPFLAGS += -O1 -std=c++17 -mcpu=cortex-m0plus -mthumb
CPPFLAGS += -fno-rtti
CPPFLAGS += -Wvla
CPPFLAGS += -DTARGET_LPC11U68
CPPFLAGS += -D__MBED__=1
CPPFLAGS += -DDEVICE_I2CSLAVE=1
CPPFLAGS += -DTARGET_LIKE_MBED
CPPFLAGS += -DTARGET_NXP
CPPFLAGS += -D__MBED_CMSIS_RTOS_CM
CPPFLAGS += -DDEVICE_RTC=1
CPPFLAGS += -DTOOLCHAIN_object
CPPFLAGS += -D__CMSIS_RTOS
CPPFLAGS += -DTOOLCHAIN_GCC
CPPFLAGS += -DTARGET_CORTEX_M
CPPFLAGS += -DTARGET_M0P
CPPFLAGS += -DTARGET_UVISOR_UNSUPPORTED
CPPFLAGS += -DDEVICE_SERIAL=1
CPPFLAGS += -DDEVICE_INTERRUPTIN=1
CPPFLAGS += -DTARGET_LPCTarget
CPPFLAGS += -DTARGET_CORTEX
CPPFLAGS += -DDEVICE_I2C=1
CPPFLAGS += -D__CORTEX_M0PLUS
CPPFLAGS += -DTARGET_FF_ARDUINO
CPPFLAGS += -DTARGET_RELEASE
CPPFLAGS += -DMBED_BUILD_TIMESTAMP=1526394586.66
CPPFLAGS += -DARM_MATH_CM0PLUS
CPPFLAGS += -DTARGET_LPC11U6X
CPPFLAGS += -DDEVICE_SLEEP=1
CPPFLAGS += -DTOOLCHAIN_GCC_ARM
CPPFLAGS += -DDEVICE_SPI=1
CPPFLAGS += -DDEVICE_ANALOGIN=1
CPPFLAGS += -DDEVICE_PWMOUT=1
CPPFLAGS += -DTARGET_LIKE_CORTEX_M0
OBJCOPY = arm-none-eabi-objcopy
LDFLAGS = -L. -lpokitto -lstdc++ -lsupc++ -lm -lc -lgcc -lnosys -T LPC11U68.ld
LDFLAGS += -Wl,--gc-sections -Wl,--wrap,main -Wl,--wrap,_memalign_r -Wl,-n --specs=nano.specs -mcpu=cortex-m0plus -mthumb
OBJS = main.o sprites.o game.o trail.o
all: gamejarm2021.bin
.elf.bin:
$(OBJCOPY) -O binary $< $@
.c.o:
$(CC) $(CFLAGS) -c $<
.SUFFIXES: .elf .bin
gamejarm2021.elf: $(OBJS)
$(CC) $(LDFLAGS) -o $@ $(OBJS)
main.o: maps.h sprites.h Smile.h
game.o: game.h trail.h util.h
trail.o: trail.h util.h