summaryrefslogtreecommitdiff
path: root/giscanner/girwriter.py
diff options
context:
space:
mode:
authorColin Walters <walters@verbum.org>2013-02-24 12:07:28 -0500
committerColin Walters <walters@verbum.org>2013-02-26 16:25:11 -0500
commitc0ebb1e9888ee745437e87482d0b89c30cab355f (patch)
tree160cda71e4102e7e0dc8f6d25081e84295435eb3 /giscanner/girwriter.py
parent95f80c1ae03dfe8a68d3c7ec21ce696ac839ea57 (diff)
downloadgobject-introspection-c0ebb1e9888ee745437e87482d0b89c30cab355f.tar.gz
scanner: internals cleanup: Move c_includes to Namespace
Continuation of previous work.
Diffstat (limited to 'giscanner/girwriter.py')
-rw-r--r--giscanner/girwriter.py12
1 files changed, 4 insertions, 8 deletions
diff --git a/giscanner/girwriter.py b/giscanner/girwriter.py
index e15ad51f..58169eba 100644
--- a/giscanner/girwriter.py
+++ b/giscanner/girwriter.py
@@ -30,21 +30,17 @@ COMPATIBLE_GIR_VERSION = '1.2'
class GIRWriter(XMLWriter):
- def __init__(self, namespace, pkgs, c_includes):
+ def __init__(self, namespace, pkgs):
super(GIRWriter, self).__init__()
self.write_comment(
'''This file was automatically generated from C sources - DO NOT EDIT!
To affect the contents of this file, edit the original C definitions,
and/or use gtk-doc annotations. ''')
- self._write_repository(namespace, pkgs,
- c_includes)
+ self._write_repository(namespace, pkgs)
- def _write_repository(self, namespace,
- packages=None, c_includes=None):
+ def _write_repository(self, namespace, packages=None):
if packages is None:
packages = frozenset()
- if c_includes is None:
- c_includes = frozenset()
attrs = [
('version', COMPATIBLE_GIR_VERSION),
('xmlns', 'http://www.gtk.org/introspection/core/1.0'),
@@ -56,7 +52,7 @@ and/or use gtk-doc annotations. ''')
self._write_include(include)
for pkg in sorted(set(packages)):
self._write_pkgconfig_pkg(pkg)
- for c_include in sorted(set(c_includes)):
+ for c_include in sorted(set(namespace.c_includes)):
self._write_c_include(c_include)
self._namespace = namespace
self._write_namespace(namespace)