tests: filter_cflags: fix test 2
This commit is contained in:
parent
0fdbd2d950
commit
2582333969
@ -9,7 +9,7 @@ def configure(conf):
|
||||
conf.load('compiler_c compiler_cxx')
|
||||
|
||||
c_only_flags = [
|
||||
'-DSOME_DEFINITION', # let's guess this flag always exist
|
||||
'-Wall', # let's guess this flag always exist
|
||||
'-Wsomething-that-does-not-exist'
|
||||
]
|
||||
|
||||
@ -17,7 +17,12 @@ def configure(conf):
|
||||
'-std=c++11', # let's guess this flag always exist only for C++ compiler
|
||||
]
|
||||
|
||||
if '-Wsomething-that-does-not-exist' in conf.filter_cflags(c_only_flags):
|
||||
filtered_cflags = conf.filter_cflags(c_only_flags)
|
||||
|
||||
if '-Wall' not in filtered_cflags:
|
||||
conf.fatal('TEST FAILED')
|
||||
|
||||
if '-Wsomething-that-does-not-exist' in filtered_cflags:
|
||||
conf.fatal('TEST FAILED')
|
||||
|
||||
if '-std=c++11' in conf.filter_cflags(cxx_only_flags):
|
||||
|
Loading…
Reference in New Issue
Block a user