mirror of
https://github.com/esphome/esphome.git
synced 2024-11-10 09:17:46 +01:00
platformio: use c++17
This commit is contained in:
parent
b5938dbc10
commit
86f2621d95
1 changed files with 55 additions and 0 deletions
|
@ -44,6 +44,9 @@ lib_deps =
|
|||
https://github.com/Sensirion/arduino-gas-index-algorithm.git#3.2.1 ; Sensirion Gas Index Algorithm Arduino Library
|
||||
build_flags =
|
||||
-DESPHOME_LOG_LEVEL=ESPHOME_LOG_LEVEL_VERY_VERBOSE
|
||||
-std=gnu++17
|
||||
build_unflags =
|
||||
-std=gnu++11
|
||||
src_filter =
|
||||
+<./>
|
||||
+<../tests/dummy_main.cpp>
|
||||
|
@ -68,6 +71,8 @@ lib_deps =
|
|||
build_flags =
|
||||
${common.build_flags}
|
||||
-DUSE_ARDUINO
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
; This are common settings for all IDF-framework based environments.
|
||||
[common:idf]
|
||||
|
@ -75,6 +80,8 @@ extends = common
|
|||
build_flags =
|
||||
${common.build_flags}
|
||||
-DUSE_ESP_IDF
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
; This are common settings for the ESP8266 using Arduino.
|
||||
[common:esp8266-arduino]
|
||||
|
@ -99,6 +106,8 @@ build_flags =
|
|||
-Wno-nonnull-compare
|
||||
-DUSE_ESP8266
|
||||
-DUSE_ESP8266_FRAMEWORK_ARDUINO
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
extra_scripts = post:esphome/components/esp8266/post_build.py.script
|
||||
|
||||
; This are common settings for the ESP32 (all variants) using Arduino.
|
||||
|
@ -128,6 +137,8 @@ build_flags =
|
|||
-DUSE_ESP32
|
||||
-DUSE_ESP32_FRAMEWORK_ARDUINO
|
||||
-DAUDIO_NO_SD_FS ; i2s_audio
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
extra_scripts = post:esphome/components/esp32/post_build.py.script
|
||||
|
||||
; This are common settings for the ESP32 (all variants) using IDF.
|
||||
|
@ -146,6 +157,8 @@ build_flags =
|
|||
-Wno-nonnull-compare
|
||||
-DUSE_ESP32
|
||||
-DUSE_ESP32_FRAMEWORK_ESP_IDF
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
extra_scripts = post:esphome/components/esp32/post_build.py.script
|
||||
|
||||
; These are common settings for the RP2040 using Arduino.
|
||||
|
@ -166,6 +179,8 @@ build_flags =
|
|||
${common:arduino.build_flags}
|
||||
-DUSE_RP2040
|
||||
-DUSE_RP2040_FRAMEWORK_ARDUINO
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
; All the actual environments are defined below.
|
||||
|
||||
|
@ -177,6 +192,8 @@ board = nodemcuv2
|
|||
build_flags =
|
||||
${common:esp8266-arduino.build_flags}
|
||||
${flags:runtime.build_flags}
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
[env:esp8266-arduino-tidy]
|
||||
extends = common:esp8266-arduino
|
||||
|
@ -184,6 +201,8 @@ board = nodemcuv2
|
|||
build_flags =
|
||||
${common:esp8266-arduino.build_flags}
|
||||
${flags:clangtidy.build_flags}
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
;;;;;;;; ESP32 ;;;;;;;;
|
||||
|
||||
|
@ -195,6 +214,8 @@ build_flags =
|
|||
${common:esp32-arduino.build_flags}
|
||||
${flags:runtime.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
[env:esp32-arduino-tidy]
|
||||
extends = common:esp32-arduino
|
||||
|
@ -203,6 +224,8 @@ build_flags =
|
|||
${common:esp32-arduino.build_flags}
|
||||
${flags:clangtidy.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
[env:esp32-idf]
|
||||
extends = common:esp32-idf
|
||||
|
@ -212,6 +235,8 @@ build_flags =
|
|||
${common:esp32-idf.build_flags}
|
||||
${flags:runtime.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
[env:esp32-idf-tidy]
|
||||
extends = common:esp32-idf
|
||||
|
@ -221,6 +246,8 @@ build_flags =
|
|||
${common:esp32-idf.build_flags}
|
||||
${flags:clangtidy.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
;;;;;;;; ESP32-C3 ;;;;;;;;
|
||||
|
||||
|
@ -231,6 +258,8 @@ build_flags =
|
|||
${common:esp32-arduino.build_flags}
|
||||
${flags:runtime.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32C3
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
[env:esp32c3-arduino-tidy]
|
||||
extends = common:esp32-arduino
|
||||
|
@ -239,6 +268,8 @@ build_flags =
|
|||
${common:esp32-arduino.build_flags}
|
||||
${flags:clangtidy.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32C3
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
[env:esp32c3-idf]
|
||||
extends = common:esp32-idf
|
||||
|
@ -248,6 +279,8 @@ build_flags =
|
|||
${common:esp32-idf.build_flags}
|
||||
${flags:runtime.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32C3
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
[env:esp32c3-idf-tidy]
|
||||
extends = common:esp32-idf
|
||||
|
@ -257,6 +290,8 @@ build_flags =
|
|||
${common:esp32-idf.build_flags}
|
||||
${flags:clangtidy.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32C3
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
;;;;;;;; ESP32-S2 ;;;;;;;;
|
||||
|
||||
|
@ -267,6 +302,8 @@ build_flags =
|
|||
${common:esp32-arduino.build_flags}
|
||||
${flags:runtime.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32S2
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
[env:esp32s2-arduino-tidy]
|
||||
extends = common:esp32-arduino
|
||||
|
@ -275,6 +312,8 @@ build_flags =
|
|||
${common:esp32-arduino.build_flags}
|
||||
${flags:clangtidy.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32S2
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
[env:esp32s2-idf]
|
||||
extends = common:esp32-idf
|
||||
|
@ -284,6 +323,8 @@ build_flags =
|
|||
${common:esp32-idf.build_flags}
|
||||
${flags:runtime.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32S2
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
[env:esp32s2-idf-tidy]
|
||||
extends = common:esp32-idf
|
||||
|
@ -293,6 +334,8 @@ build_flags =
|
|||
${common:esp32-idf.build_flags}
|
||||
${flags:clangtidy.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32S2
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
;;;;;;;; ESP32-S3 ;;;;;;;;
|
||||
|
||||
|
@ -303,6 +346,8 @@ build_flags =
|
|||
${common:esp32-arduino.build_flags}
|
||||
${flags:runtime.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32S3
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
[env:esp32s3-arduino-tidy]
|
||||
extends = common:esp32-arduino
|
||||
|
@ -311,6 +356,8 @@ build_flags =
|
|||
${common:esp32-arduino.build_flags}
|
||||
${flags:clangtidy.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32S3
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
[env:esp32s3-idf]
|
||||
extends = common:esp32-idf
|
||||
|
@ -320,6 +367,8 @@ build_flags =
|
|||
${common:esp32-idf.build_flags}
|
||||
${flags:runtime.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32S3
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
[env:esp32s3-idf-tidy]
|
||||
extends = common:esp32-idf
|
||||
|
@ -329,6 +378,8 @@ build_flags =
|
|||
${common:esp32-idf.build_flags}
|
||||
${flags:clangtidy.build_flags}
|
||||
-DUSE_ESP32_VARIANT_ESP32S3
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
;;;;;;;; RP2040 ;;;;;;;;
|
||||
|
||||
|
@ -338,6 +389,8 @@ board = rpipico
|
|||
build_flags =
|
||||
${common:rp2040-arduino.build_flags}
|
||||
${flags:runtime.build_flags}
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
||||
[env:host]
|
||||
extends = common
|
||||
|
@ -347,3 +400,5 @@ lib_deps =
|
|||
build_flags =
|
||||
${common.build_flags}
|
||||
-DUSE_HOST
|
||||
build_unflags =
|
||||
${common.build_unflags}
|
||||
|
|
Loading…
Reference in a new issue