summaryrefslogtreecommitdiff
path: root/tests/warn/warningtester.py
diff options
context:
space:
mode:
authorTim Lunn <tim@feathertop.org>2013-02-24 17:34:56 +1100
committerTim Lunn <tim@feathertop.org>2013-03-06 08:19:04 +1100
commit95b03cf87efbd4fea4b7d55601c9752cefd29bfc (patch)
treeccb47a22b628973575044505b238db29fe7dd107 /tests/warn/warningtester.py
parent8f7acc600b45ea5bf8ea1d6ce1fbedb5c6f9cfd5 (diff)
downloadgobject-introspection-95b03cf87efbd4fea4b7d55601c9752cefd29bfc.tar.gz
gi-r-scanner: add support for raw CFLAGS flags option
gi-r-scanner chokes when gir_CFLAGS have an '-include <header>' since this is not a recognised option. This commit adds a new --cflags option that passes cflags directly to the spawned gcc. https://bugzilla.gnome.org/show_bug.cgi?id=695182
Diffstat (limited to 'tests/warn/warningtester.py')
-rw-r--r--tests/warn/warningtester.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/warn/warningtester.py b/tests/warn/warningtester.py
index 27e0a5e6..fba8f0ce 100644
--- a/tests/warn/warningtester.py
+++ b/tests/warn/warningtester.py
@@ -40,6 +40,7 @@ class ChunkedIO(object):
class Options:
def __init__(self):
+ self.cpp_cflags = ""
self.cpp_includes = []
self.cpp_defines = []
self.cpp_undefines = []
@@ -110,7 +111,7 @@ def check(args):
exit_code = process_packages(options, ['gobject-2.0'])
if exit_code:
sys.exit(exit_code)
- ss.set_cpp_options(options.cpp_includes, options.cpp_defines, options.cpp_undefines)
+ ss.set_cpp_options(options.cpp_cflags, options.cpp_includes, options.cpp_defines, options.cpp_undefines)
ss.parse_files([filename])
ss.parse_macros([filename])
transformer.parse(ss.get_symbols())