1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-04-19 23:22:16 +03:00

Dynamically configure exceptions support (#7834)

This commit is contained in:
Valerii Koval 2021-01-22 17:08:45 +02:00 committed by GitHub
parent 2402958208
commit 11a2fb3872
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -75,7 +75,6 @@ env.Append(
"-U__STRICT_ANSI__", "-U__STRICT_ANSI__",
"-ffunction-sections", "-ffunction-sections",
"-fdata-sections", "-fdata-sections",
"-fno-exceptions",
"-Wall" "-Wall"
], ],
@ -130,7 +129,7 @@ env.Append(
LIBS=[ LIBS=[
"hal", "phy", "pp", "net80211", "wpa", "crypto", "main", "hal", "phy", "pp", "net80211", "wpa", "crypto", "main",
"wps", "bearssl", "espnow", "smartconfig", "airkiss", "wpa2", "wps", "bearssl", "espnow", "smartconfig", "airkiss", "wpa2",
"stdc++", "m", "c", "gcc" "m", "c", "gcc"
], ],
LIBSOURCE_DIRS=[ LIBSOURCE_DIRS=[
@ -250,6 +249,20 @@ if "PIO_FRAMEWORK_ARDUINO_WAVEFORM_LOCKED_PHASE" in flatten_cppdefines:
env.Append(CPPDEFINES=[("WAVEFORM_LOCKED_PHASE", 1)]) env.Append(CPPDEFINES=[("WAVEFORM_LOCKED_PHASE", 1)])
# PIO_FRAMEWORK_ARDUINO_WAVEFORM_LOCKED_PWM will be used by default # PIO_FRAMEWORK_ARDUINO_WAVEFORM_LOCKED_PWM will be used by default
#
# Exceptions
#
if "PIO_FRAMEWORK_ARDUINO_ENABLE_EXCEPTIONS" in flatten_cppdefines:
env.Append(
CXXFLAGS=["-fexceptions"],
LIBS=["stdc++-exc"]
)
else:
env.Append(
CXXFLAGS=["-fno-exceptions"],
LIBS=["stdc++"]
)
# #
# VTables # VTables
# #