summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJosé Fonseca <[email protected]>2009-03-13 16:21:30 +0000
committerJosé Fonseca <[email protected]>2009-03-16 12:01:44 +0000
commit102cb5c9cd5ce12fc43828e44e7baf390d4c351d (patch)
treee57fc60ceb3eed95b8e5d539a44477e7c9783a7f
parente5a3aa5672af11f69daa67182123cdf353eecbde (diff)
scons: Promote declaration-after-statement to error. Detect more warnings.
-rw-r--r--scons/gallium.py6
-rw-r--r--scons/generic.py8
2 files changed, 11 insertions, 3 deletions
diff --git a/scons/gallium.py b/scons/gallium.py
index 31236c4b016..ecdeef06fdf 100644
--- a/scons/gallium.py
+++ b/scons/gallium.py
@@ -330,11 +330,15 @@ def generate(env):
]
if env['machine'] == 'x86_64':
cflags += ['-m64']
+ # See also:
+ # - http://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html
cflags += [
+ '-Werror=declaration-after-statement',
'-Wall',
'-Wmissing-prototypes',
+ '-Wmissing-field-initializers',
+ '-Wpointer-arith',
'-Wno-long-long',
- '-Wdeclaration-after-statement',
'-ffast-math',
'-std=gnu99',
'-fmessage-length=0', # be nice to Eclipse
diff --git a/scons/generic.py b/scons/generic.py
index 26ba309d686..01a374e3633 100644
--- a/scons/generic.py
+++ b/scons/generic.py
@@ -405,13 +405,17 @@ def generate(env):
]
if env['machine'] == 'x86_64':
ccflags += ['-m64']
+ # See also:
+ # - http://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html
ccflags += [
+ '-Werror=declaration-after-statement',
'-Wall',
'-Wmissing-prototypes',
+ '-Wmissing-field-initializers',
+ '-Wpointer-arith',
'-Wno-long-long',
- '-Wdeclaration-after-statement',
'-ffast-math',
- '-pedantic',
+ '-std=gnu99',
'-fmessage-length=0', # be nice to Eclipse
]
if msvc: