Add a file to include with Makefile fragments useful for scanner invocation
authorColin Walters <walters@src.gnome.org>
Thu, 13 Nov 2008 19:57:07 +0000 (19:57 +0000)
committerColin Walters <walters@src.gnome.org>
Thu, 13 Nov 2008 19:57:07 +0000 (19:57 +0000)
svn path=/trunk/; revision=910

ChangeLog
common.mk [new file with mode: 0644]

index c7ddb7e..4d55a55 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2008-11-13  Colin Walters  <walters@verbum.org>
+
+       * common.mk: Add a file to include with Makefile fragments
+       useful for scanner invocation.
+
 2008-11-13  Tommi Komulainen  <tommi.komulainen@iki.fi>
 
        * tests/everything/gitesttypes.c (test_filename_return): Return
diff --git a/common.mk b/common.mk
new file mode 100644 (file)
index 0000000..7458e5f
--- /dev/null
+++ b/common.mk
@@ -0,0 +1,10 @@
+SCANNER_BIN = $(top_srcdir)/tools/g-ir-scanner
+SCANNER_PYTHONPATH = $(top_builddir):$(top_srcdir):$$PYTHONPATH
+SCANNER_ENV = env PYTHONPATH=$(SCANNER_PYTHONPATH) \
+       UNINSTALLED_INTROSPECTION_SRCDIR=$(top_srcdir) \
+       UNINSTALLED_INTROSPECTION_BUILDDIR=$(top_builddir)
+SCANNER_ARGS = -v --add-include-path=$(top_builddir)/gir --add-include-path=.
+SCANNER = $(SCANNER_ENV) $(SCANNER_BIN) $(SCANNER_ARGS)
+SCANNER_LIBS = \
+       $(top_srcdir)/giscanner/*.py \
+       $(top_builddir)/giscanner/libgiscanner.la