Logo
Explore Help
Sign In
espressif/esp-idf
1
0
Fork 1
You've already forked esp-idf
mirror of https://github.com/espressif/esp-idf.git synced 2025-10-05 03:21:09 +02:00
Code Issues Packages Projects Releases Wiki Activity
Files
2f15eacdebeb51b33a1ccb9df3dd93d309c09630
esp-idf/components/driver/component.mk

13 lines
204 B
Makefile
Raw Normal View History

add gpio driver code
2016-09-19 17:33:21 +08:00
#
# Component Makefile
#
COMPONENT_ADD_INCLUDEDIRS := include
COMPONENT_PRIV_INCLUDEDIRS := include/driver
spi_master: compile as C11 due to use of stdatomic.h stdatomic.h is available both in newlib and GCC include directories. Normally (if you invoke the compiler without any flags) GCC include directories are first on the list, so GCC’s stdatomic.h is used. In IDF, we used to pass newlib include path as an extra include directory, so newlib’s stdint.h got included instead. Newlib 2.2.0 stdatomic implementation is compatible with -std=gnu99 but incompatible with -std=gnu11. And GCC doesn’t support atomic_load with -std=gnu99 (it’s a C11 feature). So when we used atomic_load with -std=gnu99, it worked due to newlib’s header. Since we are no longer going to be including newlib headers into IDF, GCC stdatomic will be used instead. Hence, add -std=gnu11 for source files which use atomic features.
2019-03-08 14:57:00 +08:00
ifeq ($(GCC_NOT_5_2_0), 1)
# uses C11 atomic feature
spi_master.o: CFLAGS += -std=gnu11
endif
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.24.3 Page: 69ms Template: 1ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API