-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathMakefile
130 lines (108 loc) · 3.37 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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
# Keep this first line.
GOSSAMER_PATH=gossamer
# Which board are we building for?
BOARD=sensorwatch_pro
# Which screen are we building for?
DISPLAY=CLASSIC
# Which sensor board?
SENSOR=NONE
# Support USB features?
TINYUSB_CDC=1
# Leave this line here.
include $(GOSSAMER_PATH)/make.mk
ifeq ($(SENSOR), MOTION)
DEFINES += -DHAS_ACCELEROMETER
endif
ifeq ($(SENSOR), TEMPERATURE)
DEFINES += -DTEMPERATURE_BOARD_INSTALLED
endif
ifdef EMSCRIPTEN
all: $(BUILD)/$(BIN).elf $(BUILD)/$(BIN).html
$(BUILD)/$(BIN).html: $(OBJS)
@echo HTML $@
@$(CC) $(LDFLAGS) $(OBJS) $(LIBS) -o $@ \
-s ASYNCIFY=1 \
-s EXPORTED_RUNTIME_METHODS=lengthBytesUTF8,printErr \
-s EXPORTED_FUNCTIONS=_main \
--shell-file=./watch-library/simulator/shell.html
endif
# Add your include directories here.
INCLUDES += \
-I./ \
-I./tinyusb/src \
-I./littlefs \
-I./utz \
-I./filesystem \
-I./shell \
-I./lib/sunriset \
-I./lib/chirpy_tx \
-I./lib/base64 \
-I./watch-library/shared/watch \
-I./watch-library/shared/driver \
-I./watch-faces/clock \
-I./watch-faces/complication \
-I./watch-faces/demo \
-I./watch-faces/sensor \
-I./watch-faces/settings \
-I./watch-faces/io \
# Add your source files here.
SRCS += \
./littlefs/lfs.c \
./littlefs/lfs_util.c \
./filesystem/filesystem.c \
./utz/utz.c \
./utz/zones.c \
./shell/shell.c \
./shell/shell_cmd_list.c \
./lib/sunriset/sunriset.c \
./lib/chirpy_tx/chirpy_tx.c \
./lib/base64/base64.c \
./watch-library/shared/driver/thermistor_driver.c \
./watch-library/shared/watch/watch_common_buzzer.c \
./watch-library/shared/watch/watch_common_display.c \
./watch-library/shared/watch/watch_utility.c \
ifeq ($(SENSOR), MOTION)
SRCS += ./watch-library/shared/driver/lis2dw.c
endif
ifdef EMSCRIPTEN
INCLUDES += \
-I./watch-library/simulator/watch \
SRCS += \
./watch-library/simulator/watch/watch.c \
./watch-library/simulator/watch/watch_adc.c \
./watch-library/simulator/watch/watch_deepsleep.c \
./watch-library/simulator/watch/watch_extint.c \
./watch-library/simulator/watch/watch_gpio.c \
./watch-library/simulator/watch/watch_i2c.c \
./watch-library/simulator/watch/watch_private.c \
./watch-library/simulator/watch/watch_rtc.c \
./watch-library/simulator/watch/watch_slcd.c \
./watch-library/simulator/watch/watch_spi.c \
./watch-library/simulator/watch/watch_storage.c \
./watch-library/simulator/watch/watch_tcc.c \
./watch-library/simulator/watch/watch_uart.c \
else
INCLUDES += \
-I./watch-library/hardware/watch \
SRCS += \
./watch-library/hardware/watch/watch.c \
./watch-library/hardware/watch/watch_adc.c \
./watch-library/hardware/watch/watch_deepsleep.c \
./watch-library/hardware/watch/watch_extint.c \
./watch-library/hardware/watch/watch_gpio.c \
./watch-library/hardware/watch/watch_i2c.c \
./watch-library/hardware/watch/watch_private.c \
./watch-library/hardware/watch/watch_rtc.c \
./watch-library/hardware/watch/watch_slcd.c \
./watch-library/hardware/watch/watch_spi.c \
./watch-library/hardware/watch/watch_storage.c \
./watch-library/hardware/watch/watch_tcc.c \
./watch-library/hardware/watch/watch_uart.c \
./watch-library/hardware/watch/watch_usb_descriptors.c \
./watch-library/hardware/watch/watch_usb_cdc.c \
endif
include watch-faces.mk
SRCS += \
./movement.c \
# Finally, leave this line at the bottom of the file.
include $(GOSSAMER_PATH)/rules.mk