-
Notifications
You must be signed in to change notification settings - Fork 0
/
makefile
52 lines (37 loc) · 1.17 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
# VEXcode makefile 2019_03_26_01
# show compiler output
VERBOSE = 0
# include toolchain options
include vex/mkenv.mk
# location of the project source cpp and c files
SRC_C += $(wildcard src/*.c)
SRC_C += $(wildcard lvgl/src/*/*.c)
OBJA = $(addprefix $(BUILD)/, $(addsuffix .o, $(basename $(SRC_C))) )
OBJ = $(BUILD)/demo/demo.o
# location of include files that c and cpp files depend on
SRC_H = $(wildcard include/*.h)
SRC_H += ./lv_conf.h
# additional dependancies
SRC_A = makefile
# project header file locations
INC_F = include . lvgl lvgl/src
# headers needed to use library
LV_SRC_H += $(wildcard lvgl/lvgl.h)
LV_SRC_H += $(wildcard lvgl/src/*.h)
LV_SRC_H += $(wildcard lvgl/src/*/*.h)
LV_DST_H = $(addprefix $(BUILD)/include/, $(LV_SRC_H) )
LV_DST_H += $(BUILD)/include/lv_conf.h $(BUILD)/include/v5lvgl.h
$(BUILD)/include/%: %
$(Q)$(MKDIR)
$(Q) $(call copyfile,$^, $@)
vpath %.h lvgl/ include/
# override default library name
PROJECTLIB = libv5lvgl
# build targets
all: $(BUILD)/$(PROJECT).bin $(BUILD)/$(PROJECTLIB).a inc
# copy lvgl header files
.PHONY: inc
inc: $(LV_DST_H)
$(ECHO) "Copy headers to build folder"
# include build rules
include vex/mkrules.mk