gobject-introspection r547 - in trunk: giscanner tests/scanner



Author: walters
Date: Sun Aug 31 15:25:48 2008
New Revision: 547
URL: http://svn.gnome.org/viewvc/gobject-introspection?rev=547&view=rev

Log:
Look for libtool library in current directory

	* giscanner/glibtransformer.py: Look for libtool
	library in current directory
	* tests/scanner - Update.


Modified:
   trunk/giscanner/glibtransformer.py
   trunk/tests/scanner/Makefile.am
   trunk/tests/scanner/annotation-expected.gir
   trunk/tests/scanner/drawable-expected.gir
   trunk/tests/scanner/foo-expected.gir
   trunk/tests/scanner/utility-expected.gir

Modified: trunk/giscanner/glibtransformer.py
==============================================================================
--- trunk/giscanner/glibtransformer.py	(original)
+++ trunk/giscanner/glibtransformer.py	Sun Aug 31 15:25:48 2008
@@ -18,6 +18,7 @@
 # 02110-1301, USA.
 #
 
+import os
 import ctypes
 from ctypes.util import find_library
 
@@ -67,7 +68,10 @@
 
     def add_library(self, libname):
         # For testing mainly.
-        if libname.endswith('.la'):
+        libtool_libname = 'lib' + libname + '.la'
+        if os.path.exists(libtool_libname):
+            found_libname = extract_libtool(libtool_libname)
+        elif libname.endswith('.la'):
             found_libname = extract_libtool(libname)
         else:
             found_libname = find_library(libname)

Modified: trunk/tests/scanner/Makefile.am
==============================================================================
--- trunk/tests/scanner/Makefile.am	(original)
+++ trunk/tests/scanner/Makefile.am	Sun Aug 31 15:25:48 2008
@@ -38,7 +38,7 @@
 	$(CHECK_DEBUG) $(SCANNER) -v \
 	--include=$(top_srcdir)/gir/GObject.gir \
 	--include=$(top_builddir)/tests/scanner/utility.gir \
-	--library=$< \
+	--library=$* \
 	--namespace=$* \
 	--pkg gobject-2.0 \
 	$(srcdir)/$*.h $(srcdir)/$*.c \
@@ -50,7 +50,7 @@
 utility.gir: libutility.la utility.h $(SCANNER) $(SCANNER_LIBS) Makefile
 	$(CHECK_DEBUG) $(SCANNER) -v \
 	--include=$(top_srcdir)/gir/GObject.gir \
-	--library=$< \
+	--library=utility \
 	--namespace=utility \
 	--pkg gobject-2.0 \
 	$(libutility_la_SOURCES) \

Modified: trunk/tests/scanner/annotation-expected.gir
==============================================================================
--- trunk/tests/scanner/annotation-expected.gir	(original)
+++ trunk/tests/scanner/annotation-expected.gir	Sun Aug 31 15:25:48 2008
@@ -6,7 +6,7 @@
   <include name="GLib"/>
   <include name="GObject"/>
   <include name="utility"/>
-  <namespace name="annotation" shared-library="libannotation.la">
+  <namespace name="annotation" shared-library="annotation">
     <record name="Object" c:type="AnnotationObject">
       <field name="parent_instance">
         <type name="GObject.Object" c:type="GObject"/>

Modified: trunk/tests/scanner/drawable-expected.gir
==============================================================================
--- trunk/tests/scanner/drawable-expected.gir	(original)
+++ trunk/tests/scanner/drawable-expected.gir	Sun Aug 31 15:25:48 2008
@@ -6,7 +6,7 @@
   <include name="GLib"/>
   <include name="GObject"/>
   <include name="utility"/>
-  <namespace name="drawable" shared-library="libdrawable.la">
+  <namespace name="drawable" shared-library="drawable">
     <class name="TestDrawable"
            c:type="TestDrawable"
            parent="GObject.Object"

Modified: trunk/tests/scanner/foo-expected.gir
==============================================================================
--- trunk/tests/scanner/foo-expected.gir	(original)
+++ trunk/tests/scanner/foo-expected.gir	Sun Aug 31 15:25:48 2008
@@ -6,7 +6,7 @@
   <include name="GLib"/>
   <include name="GObject"/>
   <include name="utility"/>
-  <namespace name="foo" shared-library="libfoo.la">
+  <namespace name="foo" shared-library="foo">
     <alias name="List" target="GLib.SList" c:type="FooList"/>
     <alias name="XEvent" target="none" c:type="FooXEvent"/>
     <interface name="Interface"

Modified: trunk/tests/scanner/utility-expected.gir
==============================================================================
--- trunk/tests/scanner/utility-expected.gir	(original)
+++ trunk/tests/scanner/utility-expected.gir	Sun Aug 31 15:25:48 2008
@@ -5,7 +5,7 @@
             xmlns:glib="http://www.gtk.org/introspection/glib/1.0";>
   <include name="GLib"/>
   <include name="GObject"/>
-  <namespace name="utility" shared-library="libutility.la">
+  <namespace name="utility" shared-library="utility">
     <class name="Object"
            c:type="UtilityObject"
            parent="GObject.Object"



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]