[rtems-tools commit] misc/wscript trace/wscript: Add -std=c99 to CFLAGS

Joel Sherrill joel at rtems.org
Thu Dec 16 21:26:47 UTC 2021


Module:    rtems-tools
Branch:    5
Commit:    e6a4bc55959d884e9889a76d360b6bfc3de138a1
Changeset: http://git.rtems.org/rtems-tools/commit/?id=e6a4bc55959d884e9889a76d360b6bfc3de138a1

Author:    Joel Sherrill <joel at rtems.org>
Date:      Thu Dec 16 15:32:10 2021 -0600

misc/wscript trace/wscript: Add -std=c99 to CFLAGS

CentOS 7 has gcc 4.8.5 which defaults to C90.

---

 misc/wscript  | 1 +
 trace/wscript | 1 +
 2 files changed, 2 insertions(+)

diff --git a/misc/wscript b/misc/wscript
index b3faf7b..f1e64ab 100644
--- a/misc/wscript
+++ b/misc/wscript
@@ -52,6 +52,7 @@ def build(bld):
     conf['warningflags'] = ['-Wall', '-Wextra', '-pedantic']
     conf['optflags'] = bld.env.C_OPTS
     conf['cflags'] = ['-pipe', '-g'] + conf['optflags']
+    conf['cflags'] = ['-std=c99'] + conf['cflags']
     conf['linkflags'] = ['-g']
 
     #
diff --git a/trace/wscript b/trace/wscript
index 53a1ab4..63ddd50 100644
--- a/trace/wscript
+++ b/trace/wscript
@@ -65,6 +65,7 @@ def build(bld):
     if bld.env.HAVE_STD_CXX14:
         cxxstd = '-std=c++14'
     conf['cxxflags'] = [cxxstd] + conf['cflags']
+    conf['cflags'] = ['-std=c99'] + conf['cflags']
     conf['linkflags'] = ['-g']
     conf['lib'] = []
     if bld.env.LIB_WS2_32:



More information about the vc mailing list