-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
126 lines (114 loc) · 4.7 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
# Makefile for micronfcboard
GCC_BIN =
TARGET = TARGET_APPNEARME_MICRONFCBOARD
TOOLCHAIN = TOOLCHAIN_GCC_ARM
INCLUDE_PATHS = -I./intfs/ -I./types/
LIBRARY = libnxprdlib.a
SOURCES = ./comps/phacDiscLoop/src/phacDiscLoop.c \
./comps/phacDiscLoop/src/Sw/phacDiscLoop_Sw.c \
./comps/phacDiscLoop/src/Sw/phacDiscLoop_Sw_Int.c \
./comps/phalFelica/src/phalFelica.c \
./comps/phalFelica/src/Sw/phalFelica_Sw.c \
./comps/phalMfc/src/phalMfc.c \
./comps/phalMfc/src/phalMfc_Int.c \
./comps/phalMfc/src/Sw/phalMfc_Sw.c \
./comps/phalMfdf/src/phalMfdf.c \
./comps/phalMfdf/src/phalMfdf_Int.c \
./comps/phalMfdf/src/Sw/phalMfdf_Sw.c \
./comps/phalMfdf/src/Sw/phalMfdf_Sw_Int.c \
./comps/phalMful/src/phalMful.c \
./comps/phalMful/src/phalMful_Int.c \
./comps/phalMful/src/Sw/phalMful_Sw.c \
./comps/phalT1T/src/phalT1T.c \
./comps/phalT1T/src/Sw/phalT1T_Sw.c \
./comps/phalTop/src/phalTop.c \
./comps/phalTop/src/Sw/phalTop_Sw.c \
./comps/phalTop/src/Sw/phalTop_Sw_Int_T1T.c \
./comps/phalTop/src/Sw/phalTop_Sw_Int_T2T.c \
./comps/phalTop/src/Sw/phalTop_Sw_Int_T3T.c \
./comps/phalTop/src/Sw/phalTop_Sw_Int_T4T.c \
./comps/phbalReg/src/phbalReg.c \
./comps/phCidManager/src/phCidManager.c \
./comps/phCidManager/src/Sw/phCidManager_Sw.c \
./comps/phhalHw/src/Callback/phhalHw_Callback.c \
./comps/phhalHw/src/phhalHw.c \
./comps/phhalHw/src/Rc523/phhalHw_Rc523.c \
./comps/phhalHw/src/Rc523/phhalHw_Rc523_Cmd.c \
./comps/phhalHw/src/Rc523/phhalHw_Rc523_Int.c \
./comps/phhalHw/src/Rc523/phhalHw_Rc523_Wait.c \
./comps/phhalHw/src/Rc663/phhalHw_Rc663.c \
./comps/phhalHw/src/Rc663/phhalHw_Rc663_Cmd.c \
./comps/phhalHw/src/Rc663/phhalHw_Rc663_Int.c \
./comps/phhalHw/src/Rc663/phhalHw_Rc663_Wait.c \
./comps/phKeyStore/src/phKeyStore.c \
./comps/phKeyStore/src/Rc663/phKeyStore_Rc663.c \
./comps/phKeyStore/src/Sw/phKeyStore_Sw.c \
./comps/phlnLlcp/src/Fri/phlnLlcp_Fri_Llcp.c \
./comps/phlnLlcp/src/Fri/phlnLlcp_Fri_Mac.c \
./comps/phlnLlcp/src/Fri/phlnLlcp_Fri_MacNfcip.c \
./comps/phlnLlcp/src/Fri/phlnLlcp_Fri_OvrHal.c \
./comps/phlnLlcp/src/Fri/phlnLlcp_Fri_Transport.c \
./comps/phlnLlcp/src/Fri/phlnLlcp_Fri_Transport_Connection.c \
./comps/phlnLlcp/src/Fri/phlnLlcp_Fri_Transport_Connectionless.c \
./comps/phlnLlcp/src/Fri/phlnLlcp_Fri_Utils.c \
./comps/phlnLlcp/src/phlnLlcp.c \
./comps/phLog/src/phLog.c \
./comps/phnpSnep/src/Fri/phnpSnep_Fri.c \
./comps/phnpSnep/src/Fri/phnpSnep_Fri_ContextMgmt.c \
./comps/phnpSnep/src/Fri/phnpSnep_Fri_Utils.c \
./comps/phnpSnep/src/phnpSnep.c \
./comps/phOsal/src/phOsal.c \
./comps/phpalFelica/src/phpalFelica.c \
./comps/phpalFelica/src/Sw/phpalFelica_Sw.c \
./comps/phpalI14443p3a/src/phpalI14443p3a.c \
./comps/phpalI14443p3a/src/Sw/phpalI14443p3a_Sw.c \
./comps/phpalI14443p3b/src/phpalI14443p3b.c \
./comps/phpalI14443p3b/src/Sw/phpalI14443p3b_Sw.c \
./comps/phpalI14443p4/src/phpalI14443p4.c \
./comps/phpalI14443p4/src/Sw/phpalI14443p4_Sw.c \
./comps/phpalI14443p4a/src/phpalI14443p4a.c \
./comps/phpalI14443p4a/src/Sw/phpalI14443p4a_Sw.c \
./comps/phpalI18092mPI/src/phpalI18092mPI.c \
./comps/phpalI18092mPI/src/Sw/phpalI18092mPI_Sw.c \
./comps/phpalI18092mPI/src/Sw/phpalI18092mPI_Sw_Int.c \
./comps/phpalI18092mT/src/phpalI18092mT.c \
./comps/phpalI18092mT/src/Sw/phpalI18092mT_Sw.c \
./comps/phpalI18092mT/src/Sw/phpalI18092mT_Sw_Int.c \
./comps/phpalMifare/src/phpalMifare.c \
./comps/phpalMifare/src/Sw/phpalMifare_Sw.c \
./comps/phTools/src/phTools.c \
./comps/phOsal/src/phOsal_GLib.c \
./comps/phbalReg/src/phBalReg_RpiSpi.c
OBJECTS=$(SOURCES:.c=.o)
###############################################################################
AS = $(GCC_BIN)arm-none-eabi-as
CC = $(GCC_BIN)arm-none-eabi-gcc
CPP = $(GCC_BIN)arm-none-eabi-g++
LD = $(GCC_BIN)arm-none-eabi-gcc
OBJCOPY = $(GCC_BIN)arm-none-eabi-objcopy
OBJDUMP = $(GCC_BIN)arm-none-eabi-objdump
SIZE = $(GCC_BIN)arm-none-eabi-size
AR = $(GCC_BIN)arm-none-eabi-ar
CPU = -mcpu=cortex-m0 -mthumb
CC_FLAGS = $(CPU) -c -g -fno-common -fmessage-length=0 -Wall -fno-exceptions -ffunction-sections -fdata-sections -fomit-frame-pointer
CC_FLAGS += -MMD -MP
CC_SYMBOLS = -DTARGET_APPNEARME_MICRONFCBOARD -DTARGET_M0 -DTARGET_CORTEX_M -DTARGET_NXP -DTARGET_LPC11UXX -D$(TOOLCHAIN) -DTOOLCHAIN_GCC -D__CORTEX_M0 -DARM_MATH_CM0 -DMBED_BUILD_TIMESTAMP=1427405354.12 -D__MBED__=1
ARFLAGS = -r
ifeq ($(DEBUG), 1)
CC_FLAGS += -DDEBUG -O0
else
CC_FLAGS += -DNDEBUG -Os
endif
all: $(LIBRARY)
clean:
rm -f $(PROJECT).bin $(PROJECT).elf $(PROJECT).hex $(PROJECT).map $(PROJECT).lst $(OBJECTS) $(DEPS)
.s.o:
$(AS) $(CPU) -o $@ $<
.c.o:
$(CC) $(CC_FLAGS) $(CC_SYMBOLS) -std=gnu99 $(INCLUDE_PATHS) -o $@ $<
.cpp.o:
$(CPP) $(CC_FLAGS) $(CC_SYMBOLS) -std=gnu++98 -fno-rtti $(INCLUDE_PATHS) -o $@ $<
$(LIBRARY): $(OBJECTS)
$(AR) $(ARFLAGS) $@ $^
DEPS = $(OBJECTS:.o=.d)
-include $(DEPS)