From 30158424e993919b9a4d8fe4b14793df3affe7ff Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Tue, 19 Oct 2021 05:53:34 -0500 Subject: [PATCH] =?UTF-8?q?=F0=9F=94=A8=20Fix=20older=20GCC=20CXXFLAGS=20w?= =?UTF-8?q?arning?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- buildroot/share/PlatformIO/scripts/common-cxxflags.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/buildroot/share/PlatformIO/scripts/common-cxxflags.py b/buildroot/share/PlatformIO/scripts/common-cxxflags.py index 856a246fba..26bff515a6 100644 --- a/buildroot/share/PlatformIO/scripts/common-cxxflags.py +++ b/buildroot/share/PlatformIO/scripts/common-cxxflags.py @@ -3,13 +3,16 @@ # Convenience script to apply customizations to CPP flags # Import("env") -env.Append(CXXFLAGS=[ - "-Wno-register" + +cxxflags = [ #"-Wno-incompatible-pointer-types", #"-Wno-unused-const-variable", #"-Wno-maybe-uninitialized", #"-Wno-sign-compare" -]) +] +if "teensy" not in env['PIOENV']: + cxxflags += ["-Wno-register"] +env.Append(CXXFLAGS=cxxflags) # # Add CPU frequency as a compile time constant instead of a runtime variable