diff options
author | Emmanuele Bassi <ebassi@gnome.org> | 2018-03-10 16:00:53 +0000 |
---|---|---|
committer | Emmanuele Bassi <ebassi@gnome.org> | 2018-03-10 16:02:44 +0000 |
commit | 53bde6ead14c62606b2cb04d2fd96a271f9ca9f9 (patch) | |
tree | 104f5b5366447df5478e6d6125542605612a2578 /giscanner/scannermain.py | |
parent | 334877eccf62fde389c9dedd6a751bcdb4345f15 (diff) | |
download | gobject-introspection-53bde6ead14c62606b2cb04d2fd96a271f9ca9f9.tar.gz |
Revert "giscanner: Fix options in the preprocessor group"
This reverts commit 17323d2b966146ad19af6285e4eea4cd76bd2c7e.
This commit breaks the build of every module using g-ir-scanner with
compiler flags that are not just -I directives.
Diffstat (limited to 'giscanner/scannermain.py')
-rwxr-xr-x | giscanner/scannermain.py | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/giscanner/scannermain.py b/giscanner/scannermain.py index 1366c04c..ffcb95cd 100755 --- a/giscanner/scannermain.py +++ b/giscanner/scannermain.py @@ -52,14 +52,11 @@ from . import utils def process_cflags_begin(option, opt, value, parser): cflags = getattr(parser.values, option.dest) - # Copy instead of consuming else cpp_defines, cpp_includes, etc will be empty - rargs = parser.rargs[:] - while len(rargs) > 0 and rargs[0] != '--cflags-end': - arg = rargs.pop(0) - if arg == "-I" and rargs and rargs[0] != '--cflags-end': + while len(parser.rargs) > 0 and parser.rargs[0] != '--cflags-end': + arg = parser.rargs.pop(0) + if arg == "-I" and parser.rargs and parser.rargs[0] != '--cflags-end': # This is a special case where there's a space between -I and the path. - arg += rargs.pop(0) - incdir = utils.cflag_real_include_path(arg) + arg += parser.rargs.pop(0) cflags.append(utils.cflag_real_include_path(arg)) |