source: azure_iot_hub_riscv/trunk/azure_iot_sdk/Makefile@ 453

Last change on this file since 453 was 453, checked in by coas-nagasima, 4 years ago

ファイルを追加

File size: 10.3 KB
Line 
1# This file was automagically generated by mbed.org. For more information,
2# see http://mbed.org/handbook/Exporting-to-GCC-ARM-Embedded
3
4###############################################################################
5# Boiler-plate
6
7# cross-platform directory manipulation
8ifeq ($(shell echo $$OS),$$OS)
9 MAKEDIR = if not exist "$(1)" mkdir "$(1)"
10 RM = rmdir /S /Q "$(1)"
11else
12 MAKEDIR = '$(SHELL)' -c "mkdir -p \"$(1)\""
13 RM = '$(SHELL)' -c "rm -rf \"$(1)\""
14endif
15
16OBJDIR := Debug
17# Move to the build directory
18ifeq (,$(filter $(OBJDIR),$(notdir $(CURDIR))))
19.SUFFIXES:
20mkfile_path := $(abspath $(lastword $(MAKEFILE_LIST)))
21MAKETARGET = '$(MAKE)' --no-print-directory -C $(OBJDIR) -f '$(mkfile_path)' \
22 'SRCDIR=$(CURDIR)' $(MAKECMDGOALS)
23.PHONY: $(OBJDIR) clean
24all:
25 +@$(call MAKEDIR,$(OBJDIR))
26 +@$(MAKETARGET)
27$(OBJDIR): all
28Makefile : ;
29% :: $(OBJDIR) ; :
30clean :
31 $(call RM,$(OBJDIR))
32
33else
34
35# trick rules into thinking we are in the root, when we are in the bulid dir
36VPATH = ../../azure_iot_sdk
37
38# Boiler-plate
39###############################################################################
40# Project settings
41
42PROJECT := azure_iot_sdk
43
44
45# Project settings
46###############################################################################
47# Objects and Paths
48
49OBJECTS += c-utility/adapters/agenttime_mbed.o
50OBJECTS += c-utility/adapters/httpapi_compact.o
51OBJECTS += c-utility/adapters/lock_toppers.o
52OBJECTS += c-utility/adapters/platform_toppers.o
53OBJECTS += c-utility/adapters/socketio_esp_at.o
54OBJECTS += c-utility/adapters/threadapi_toppers.o
55OBJECTS += c-utility/adapters/tickcounter_toppers.o
56OBJECTS += c-utility/adapters/tlsio_esp_at.o
57OBJECTS += c-utility/adapters/tlsio_wolfssl.o
58OBJECTS += c-utility/adapters/uniqueid_stub.o
59OBJECTS += c-utility/src/azure_base32.o
60OBJECTS += c-utility/src/azure_base64.o
61OBJECTS += c-utility/src/buffer.o
62OBJECTS += c-utility/src/connection_string_parser.o
63OBJECTS += c-utility/src/consolelogger.o
64OBJECTS += c-utility/src/constbuffer.o
65OBJECTS += c-utility/src/constmap.o
66OBJECTS += c-utility/src/crt_abstractions.o
67#OBJECTS += c-utility/src/dns_resolver_sync.o
68OBJECTS += c-utility/src/doublylinkedlist.o
69OBJECTS += c-utility/src/gb_rand.o
70OBJECTS += c-utility/src/gb_stdio.o
71OBJECTS += c-utility/src/gb_time.o
72OBJECTS += c-utility/src/gballoc.o
73OBJECTS += c-utility/src/hmac.o
74OBJECTS += c-utility/src/hmacsha256.o
75OBJECTS += c-utility/src/http_proxy_io.o
76OBJECTS += c-utility/src/httpapiex.o
77OBJECTS += c-utility/src/httpapiexsas.o
78OBJECTS += c-utility/src/httpheaders.o
79OBJECTS += c-utility/src/map.o
80OBJECTS += c-utility/src/optionhandler.o
81OBJECTS += c-utility/src/sastoken.o
82OBJECTS += c-utility/src/sha1.o
83OBJECTS += c-utility/src/sha224.o
84OBJECTS += c-utility/src/sha384-512.o
85OBJECTS += c-utility/src/singlylinkedlist.o
86OBJECTS += c-utility/src/string_token.o
87OBJECTS += c-utility/src/string_tokenizer.o
88OBJECTS += c-utility/src/strings.o
89OBJECTS += c-utility/src/urlencode.o
90OBJECTS += c-utility/src/usha.o
91OBJECTS += c-utility/src/utf8_checker.o
92OBJECTS += c-utility/src/uuid.o
93OBJECTS += c-utility/src/uws_client.o
94OBJECTS += c-utility/src/uws_frame_encoder.o
95OBJECTS += c-utility/src/vector.o
96OBJECTS += c-utility/src/wsio.o
97OBJECTS += c-utility/src/xio.o
98OBJECTS += c-utility/src/xlogging.o
99OBJECTS += certs/certs.o
100OBJECTS += deps/parson/parson.o
101OBJECTS += iothub_client/src/blob.o
102OBJECTS += iothub_client/src/iothub.o
103OBJECTS += iothub_client/src/iothub_client.o
104OBJECTS += iothub_client/src/iothub_client_authorization.o
105OBJECTS += iothub_client/src/iothub_client_core.o
106OBJECTS += iothub_client/src/iothub_client_core_ll.o
107OBJECTS += iothub_client/src/iothub_client_diagnostic.o
108OBJECTS += iothub_client/src/iothub_client_ll.o
109OBJECTS += iothub_client/src/iothub_client_ll_uploadtoblob.o
110OBJECTS += iothub_client/src/iothub_client_retry_control.o
111OBJECTS += iothub_client/src/iothub_device_client_ll.o
112OBJECTS += iothub_client/src/iothub_message.o
113OBJECTS += iothub_client/src/iothub_transport_ll_private.o
114OBJECTS += iothub_client/src/iothubtransport.o
115OBJECTS += iothub_client/src/iothubtransport_mqtt_common.o
116OBJECTS += iothub_client/src/iothubtransporthttp.o
117OBJECTS += iothub_client/src/iothubtransportmqtt.o
118OBJECTS += iothub_client/src/iothubtransportmqtt_websockets.o
119OBJECTS += iothub_client/src/version.o
120OBJECTS += provisioning_client/adapters/hsm_client_data.o
121OBJECTS += provisioning_client/adapters/hsm_client_key.o
122OBJECTS += provisioning_client/src/iothub_auth_client.o
123OBJECTS += provisioning_client/src/iothub_security_factory.o
124OBJECTS += provisioning_client/src/prov_auth_client.o
125OBJECTS += provisioning_client/src/prov_device_client.o
126OBJECTS += provisioning_client/src/prov_device_ll_client.o
127OBJECTS += provisioning_client/src/prov_security_factory.o
128OBJECTS += provisioning_client/src/prov_transport_http_client.o
129OBJECTS += provisioning_client/src/prov_transport_mqtt_client.o
130OBJECTS += provisioning_client/src/prov_transport_mqtt_common.o
131OBJECTS += provisioning_client/src/prov_transport_mqtt_ws_client.o
132OBJECTS += serializer/src/methodreturn.o
133OBJECTS += serializer/src/multitree.o
134OBJECTS += serializer/src/schema.o
135OBJECTS += serializer/src/schemalib.o
136OBJECTS += serializer/src/schemaserializer.o
137OBJECTS += serializer/src/datamarshaller.o
138OBJECTS += serializer/src/datapublisher.o
139OBJECTS += serializer/src/dataserializer.o
140OBJECTS += serializer/src/iotdevice.o
141OBJECTS += serializer/src/jsondecoder.o
142OBJECTS += serializer/src/jsonencoder.o
143OBJECTS += serializer/src/agenttypesystem.o
144OBJECTS += serializer/src/codefirst.o
145OBJECTS += serializer/src/commanddecoder.o
146OBJECTS += uhttp/src/uhttp.o
147OBJECTS += umqtt/src/mqtt_client.o
148OBJECTS += umqtt/src/mqtt_codec.o
149OBJECTS += umqtt/src/mqtt_message.o
150
151INCLUDE_PATHS += -I../../asp_baseplatform
152INCLUDE_PATHS += -I../../asp_baseplatform/include
153INCLUDE_PATHS += -I../../asp_baseplatform/arch
154INCLUDE_PATHS += -I../../asp_baseplatform/arch/riscv_gcc
155INCLUDE_PATHS += -I../../asp_baseplatform/target/k210_gcc
156INCLUDE_PATHS += -I../../asp_baseplatform/OBJ/K210_GCC/DEMO
157INCLUDE_PATHS += -I../../asp_baseplatform/monitor
158INCLUDE_PATHS += -I../../asp_baseplatform/files
159INCLUDE_PATHS += -I../../azure_iot_sdk/c-utility/inc
160INCLUDE_PATHS += -I../../azure_iot_sdk/c-utility/pal/toppers
161INCLUDE_PATHS += -I../../azure_iot_sdk/iothub_client/inc
162INCLUDE_PATHS += -I../../azure_iot_sdk/iothub_client/inc/internal
163INCLUDE_PATHS += -I../../azure_iot_sdk/provisioning_client/adapters
164INCLUDE_PATHS += -I../../azure_iot_sdk/provisioning_client/inc
165INCLUDE_PATHS += -I../../azure_iot_sdk/provisioning_client/inc/azure_prov_client/internal
166INCLUDE_PATHS += -I../../azure_iot_sdk/deps/parson
167INCLUDE_PATHS += -I../../azure_iot_sdk/deps/azure-macro-utils-c/inc
168INCLUDE_PATHS += -I../../azure_iot_sdk/deps/umock-c/inc
169INCLUDE_PATHS += -I../../azure_iot_sdk/serializer/inc
170INCLUDE_PATHS += -I../../azure_iot_sdk/uhttp/inc
171INCLUDE_PATHS += -I../../azure_iot_sdk/umqtt/inc
172INCLUDE_PATHS += -I../../wolfssl-4.4.0/wolfssl
173INCLUDE_PATHS += -I../../wolfssl-4.4.0/wolfssl/wolfcrypt
174INCLUDE_PATHS += -I../../wolfssl-4.4.0
175INCLUDE_PATHS += -I../../zlib-1.2.11/src
176
177# Objects and Paths
178###############################################################################
179# Tools and Flags
180
181AS = riscv-none-embed-gcc
182CC = riscv-none-embed-gcc
183CPP = riscv-none-embed-g++
184AR = riscv-none-embed-ar
185RANLIB = riscv-none-embed-ranlib
186
187
188C_FLAGS += -std=gnu11
189C_FLAGS += -march=rv64imafdc
190C_FLAGS += -mabi=lp64d
191C_FLAGS += -mcmodel=medany
192C_FLAGS += -O2
193C_FLAGS += -fmessage-length=0
194C_FLAGS += -fsigned-char
195C_FLAGS += -ffunction-sections
196C_FLAGS += -fdata-sections
197C_FLAGS += -Wall
198C_FLAGS += -Wextra
199C_FLAGS += -Wno-unused-parameter
200C_FLAGS += -Wno-missing-field-initializers
201C_FLAGS += -Wnull-dereference
202
203C_FLAGS += -Wno-unused-variable
204C_FLAGS += -Wno-unused-function
205
206C_FLAGS += -g3
207C_FLAGS += -Wstack-usage=256
208
209C_FLAGS += -DWOLFSSL_USER_SETTINGS
210C_FLAGS += -DCYASSL_USER_SETTINGS
211C_FLAGS += -DUSE_WOLFSSL=1
212C_FLAGS += -DHSM_TYPE_SYMM_KEY
213C_FLAGS += -DUSE_PROV_MODULE
214C_FLAGS += -Dget_time=azure_get_time
215
216CXX_FLAGS += -std=gnu++11
217CXX_FLAGS += -march=rv64imafdc
218CXX_FLAGS += -mabi=lp64d
219CXX_FLAGS += -mcmodel=medany
220CXX_FLAGS += -O2
221CXX_FLAGS += -fmessage-length=0
222CXX_FLAGS += -fsigned-char
223CXX_FLAGS += -ffunction-sections
224CXX_FLAGS += -fdata-sections
225CXX_FLAGS += -Wall
226CXX_FLAGS += -Wextra
227CXX_FLAGS += -Wno-unused-parameter
228CXX_FLAGS += -Wno-missing-field-initializers
229CXX_FLAGS += -Wnull-dereference
230
231CXX_FLAGS += -g3
232CXX_FLAGS += -Wstack-usage=256
233
234CXX_FLAGS += -DWOLFSSL_USER_SETTINGS
235CXX_FLAGS += -DCYASSL_USER_SETTINGS
236CXX_FLAGS += -DUSE_WOLFSSL=1
237CXX_FLAGS += -DHSM_TYPE_SYMM_KEY
238CXX_FLAGS += -DUSE_PROV_MODULE
239CXX_FLAGS += -Dget_time=azure_get_time
240
241ASM_FLAGS += -x
242ASM_FLAGS += assembler-with-cpp
243ASM_FLAGS += -march=rv64imafdc
244ASM_FLAGS += -mabi=lp64d
245ASM_FLAGS += -mcmodel=medany
246ASM_FLAGS += -O2
247ASM_FLAGS += -fmessage-length=0
248ASM_FLAGS += -fsigned-char
249ASM_FLAGS += -ffunction-sections
250ASM_FLAGS += -fdata-sections
251ASM_FLAGS += -Wall
252ASM_FLAGS += -Wextra
253ASM_FLAGS += -Wno-unused-parameter
254ASM_FLAGS += -Wno-missing-field-initializers
255ASM_FLAGS += -Wnull-dereference
256ASM_FLAGS += -g3
257ASM_FLAGS += -Wstack-usage=256
258
259
260# Tools and Flags
261###############################################################################
262# Rules
263
264.PHONY: all lst size
265
266
267all: lib$(PROJECT).a
268
269
270.s.o:
271 +@$(call MAKEDIR,$(dir $@))
272 +@echo "Assemble: $(notdir $<)"
273 @$(AS) -c $(ASM_FLAGS) -o $@ $<
274
275
276.S.o:
277 +@$(call MAKEDIR,$(dir $@))
278 +@echo "Assemble: $(notdir $<)"
279 @$(AS) -c $(ASM_FLAGS) -o $@ $<
280
281.c.o:
282 +@$(call MAKEDIR,$(dir $@))
283 +@echo "Compile: $(notdir $<)"
284 @$(CC) $(C_FLAGS) $(INCLUDE_PATHS) -MMD -MP -MF"$(@:%.o=%.d)" -MT"$(@)" -c -o "$@" "$<"
285
286.cpp.o:
287 +@$(call MAKEDIR,$(dir $@))
288 +@echo "Compile: $(notdir $<)"
289 @$(CPP) $(CXX_FLAGS) $(INCLUDE_PATHS) -MMD -MP -MF"$(@:%.o=%.d)" -MT"$(@)" -c -o "$@" "$<"
290
291lib$(PROJECT).a: $(OBJECTS)
292 rm -f lib$(PROJECT).a
293 $(AR) -rcs lib$(PROJECT).a $(OBJECTS)
294 $(RANLIB) lib$(PROJECT).a
295
296
297
298# Rules
299###############################################################################
300# Dependencies
301
302DEPS = $(OBJECTS:.o=.d) $(SYS_OBJECTS:.o=.d)
303-include $(DEPS)
304endif
305
306# Dependencies
307###############################################################################
Note: See TracBrowser for help on using the repository browser.