pygtk r3006 - in trunk: . codegen gtk



Author: paulp
Date: Sun Jul 13 21:58:19 2008
New Revision: 3006
URL: http://svn.gnome.org/viewvc/pygtk?rev=3006&view=rev

Log:
2008-07-14  Paul Pogonyshev  <pogonyshev gmx net>

	bug 542821:

	* codegen: Remove directory, we will use PyGObject's codegen from
	now on.

	* configure.in: Remove local codegen mentions.
	(CODEGENDIR): New AC_SUBST: determine where installed PyGObject's
	codegen is.

	* Makefile.am:
	* gtk/Makefile.am: Remove local codegen mentions and use
	'CODEGENDIR' instead.

	* MANIFEST.in:
	* pygtk.spec.in:
	* setup.py: Remove all mentions of codegen.

	* pygobject-2.0.pc.in: Remove file (unused).

	* pygtk-2.0.pc.in: Change 'codegendir' to refer to PyGObject's
	codegen.


Removed:
   trunk/codegen/
   trunk/pygobject-2.0.pc.in
Modified:
   trunk/ChangeLog
   trunk/MANIFEST.in
   trunk/Makefile.am
   trunk/configure.in
   trunk/gtk/Makefile.am
   trunk/pygtk-2.0.pc.in
   trunk/pygtk.spec.in
   trunk/setup.py

Modified: trunk/MANIFEST.in
==============================================================================
--- trunk/MANIFEST.in	(original)
+++ trunk/MANIFEST.in	Sun Jul 13 21:58:19 2008
@@ -6,6 +6,5 @@
 include pygtk.py pygtk-2.0.pc.in
 include dsextras.py
 recursive-include gtk *.override *.defs *.h
-recursive-include codegen README.defs *.py pygtk-codegen-2.0.in 
 recursive-include examples README *.py *.xpm 
 global-exclude */CVS/* .cvsignore

Modified: trunk/Makefile.am
==============================================================================
--- trunk/Makefile.am	(original)
+++ trunk/Makefile.am	Sun Jul 13 21:58:19 2008
@@ -4,7 +4,7 @@
   GTK_SUBDIR = gtk
 endif
 
-SUBDIRS = codegen . $(GTK_SUBDIR) examples tests docs
+SUBDIRS = . $(GTK_SUBDIR) examples tests docs
 
 PLATFORM_VERSION = 2.0
 
@@ -107,7 +107,7 @@
 # code generator
 .defs.c:
 	(cd $(srcdir)\
-	 && $(PYTHON) codegen/codegen.py \
+	 && $(PYTHON) $(CODEGENDIR)/codegen.py \
 	    --py_ssize_t-clean \
 	    --register pango-types.defs \
 	    --register atk-types.defs \

Modified: trunk/configure.in
==============================================================================
--- trunk/configure.in	(original)
+++ trunk/configure.in	Sun Jul 13 21:58:19 2008
@@ -169,6 +169,18 @@
   PANGO_LIBS=`echo $PANGO_LIBS | sed -e "s/$export_dynamic//"`
 fi
 
+dnl codegen from PyGObject
+AC_SUBST([CODEGENDIR])
+
+AC_MSG_CHECKING([for codegen])
+CODEGENDIR=`$PKG_CONFIG --variable codegendir pygobject-2.0`
+
+if test -z $CODEGENDIR; then
+  AC_MSG_ERROR([unable to find PyGObject codegen])
+else
+  AC_MSG_RESULT($CODEGENDIR)
+fi
+
 dnl pycairo
 PYGTK_CODEGEN_DEFINES=""
 AC_SUBST([PYGTK_CODEGEN_DEFINES])
@@ -338,13 +350,11 @@
 AC_CONFIG_FILES(
   Makefile
   pygtk-2.0.pc
-  codegen/Makefile
   gtk/Makefile
   docs/Makefile
   docs/reference/entities.docbook
   examples/Makefile
   tests/Makefile
-  codegen/pygtk-codegen-2.0
   pygtk.spec
   PKG-INFO)
 AC_OUTPUT

Modified: trunk/gtk/Makefile.am
==============================================================================
--- trunk/gtk/Makefile.am	(original)
+++ trunk/gtk/Makefile.am	Sun Jul 13 21:58:19 2008
@@ -61,7 +61,7 @@
 GTK_TYPES_DEFS += gtk-2.12-types.defs
 endif
 
-CREATEDEFS = $(PYTHON) $(top_srcdir)/codegen/createdefs.py
+CREATEDEFS = $(PYTHON) $(CODEGENDIR)/createdefs.py
 
 GDK_OVERRIDES = \
 	gdk.override 		\
@@ -178,7 +178,7 @@
 
 
 .defs.c: 
-	($(PYTHON) $(top_srcdir)/codegen/codegen.py \
+	($(PYTHON) $(CODEGENDIR)/codegen.py \
 	   $(PYGTK_CODEGEN_DEFINES) \
 	    -I $(srcdir) \
 	    --py_ssize_t-clean \

Modified: trunk/pygtk-2.0.pc.in
==============================================================================
--- trunk/pygtk-2.0.pc.in	(original)
+++ trunk/pygtk-2.0.pc.in	Sun Jul 13 21:58:19 2008
@@ -12,7 +12,11 @@
 
 # same here.  Useful when calling the code generator in addon packages.
 defsdir=${datadir}/pygtk/2.0/defs
-codegendir=${datadir}/pygtk/2.0/codegen
+
+# This is strictly speaking not necessarily so (we refer to another
+# package), but we want to preserve compatibility with times codegen
+# was in PyGTK, not PyGObject.
+codegendir=${datadir}/pygobject/2.0/codegen
 
 Name: PyGTK
 Description: Python bindings for GTK+ and related libraries

Modified: trunk/pygtk.spec.in
==============================================================================
--- trunk/pygtk.spec.in	(original)
+++ trunk/pygtk.spec.in	Sun Jul 13 21:58:19 2008
@@ -103,7 +103,6 @@
 
 %files devel
 %defattr(755, root, root, 755)
-%{_prefix}/bin/pygtk-codegen-2.0
 %defattr(644, root, root, 755)
 %dir %{_prefix}/include/pygtk-2.0
 %{_prefix}/include/pygtk-2.0/*.h
@@ -112,9 +111,7 @@
 %{_libdir}/pkgconfig/pygtk-2.0.pc
 %dir %{_prefix}/share/pygtk
 %dir %{_prefix}/share/pygtk/2.0
-%dir %{_prefix}/share/pygtk/2.0/codegen
 %dir %{_prefix}/share/pygtk/2.0/defs
-%{_prefix}/share/pygtk/2.0/codegen/*
 %{_prefix}/share/pygtk/2.0/defs/atk.defs
 %{_prefix}/share/pygtk/2.0/defs/atk-types.defs
 %{_prefix}/share/pygtk/2.0/defs/pango.defs

Modified: trunk/setup.py
==============================================================================
--- trunk/setup.py	(original)
+++ trunk/setup.py	Sun Jul 13 21:58:19 2008
@@ -4,7 +4,6 @@
 #
 # TODO:
 # pygtk.spec(.in)
-# install *.pyc for codegen
 #
 """Python Bindings for the GTK Widget Set.
 
@@ -74,7 +73,6 @@
     GLOBAL_MACROS.append(('VERSION', '"%s"' % VERSION))
 
 DEFS_DIR    = os.path.join('share', 'pygtk', PYGTK_SUFFIX, 'defs')
-CODEGEN_DIR = os.path.join('share', 'pygtk', PYGTK_SUFFIX, 'codegen')
 INCLUDE_DIR = os.path.join('include', 'pygtk-%s' % PYGTK_SUFFIX)
 HTML_DIR = os.path.join('share', 'gtk-doc', 'html', 'pygtk')
 
@@ -109,9 +107,6 @@
         InstallData.run(self)
 
     def install_templates(self):
-        file = self.install_template('codegen/pygtk-codegen-2.0.in',
-                                     os.path.join(self.install_dir, 'bin'))
-        os.chmod(file, 0755)
         self.install_template('pygtk-2.0.pc.in',
                               os.path.join(self.install_dir,
                                            'lib','pkgconfig'))
@@ -216,7 +211,7 @@
 data_files = []
 ext_modules = []
 py_modules = []
-packages = ['codegen']
+packages = []
 
 if not have_pkgconfig():
     print "Error, could not find pkg-config"



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