[vala] GIR writer: Always include GLib and GObject
- From: Jürg Billeter <juergbi src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [vala] GIR writer: Always include GLib and GObject
- Date: Sun, 17 Jan 2010 12:49:26 +0000 (UTC)
commit 81084a45a913a69e69d50892ac0db038d981e5fe
Author: Abderrahim Kitouni <a kitouni gmail com>
Date: Fri Sep 4 16:18:38 2009 +0100
GIR writer: Always include GLib and GObject
codegen/valagirwriter.vala | 9 +++++++++
1 files changed, 9 insertions(+), 0 deletions(-)
---
diff --git a/codegen/valagirwriter.vala b/codegen/valagirwriter.vala
index 1f4f00b..d5677fe 100644
--- a/codegen/valagirwriter.vala
+++ b/codegen/valagirwriter.vala
@@ -66,6 +66,10 @@ public class Vala.GIRWriter : CodeVisitor {
stream.printf (">\n");
indent++;
+ // FIXME: find a way to include everything
+ write_gir_include ("GLib", "2.0");
+ write_gir_include ("GObject", "2.0");
+
write_package (package);
context.accept (this);
@@ -76,6 +80,11 @@ public class Vala.GIRWriter : CodeVisitor {
stream = null;
}
+ private void write_gir_include (string name, string version) {
+ write_indent ();
+ stream.printf ("<include name=\"%s\" version=\"%s\"/>\n", name, version);
+ }
+
private void write_package (string package) {
write_indent ();
stream.printf ("<package name=\"%s\"/>\n", package);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]