The attached patch marks the *_register_classes functions as internal.
It depends on the patch
http://bugzilla.gnome.org/attachment.cgi?id=69130&action=view
Rafael,
Python for Maemo,
INdT
Index: atkmodule.c
===================================================================
RCS file: /cvs/gnome/pygtk/atkmodule.c,v
retrieving revision 1.4
diff -u -r1.4 atkmodule.c
--- atkmodule.c 6 Jul 2006 07:26:54 -0000 1.4
+++ atkmodule.c 18 Jul 2006 18:23:11 -0000
@@ -27,7 +27,7 @@
/* include this first, before NO_IMPORT_PYGOBJECT is defined */
#include <pygobject.h>
-void pyatk_register_classes (PyObject *d);
+void G_GNUC_INTERNAL pyatk_register_classes (PyObject *d);
void pyatk_add_constants(PyObject *module, const gchar *strip_prefix);
void _pyatk_register_boxed_types(void);
Index: pangocairomodule.c
===================================================================
RCS file: /cvs/gnome/pygtk/pangocairomodule.c,v
retrieving revision 1.3
diff -u -r1.3 pangocairomodule.c
--- pangocairomodule.c 1 Apr 2006 15:49:48 -0000 1.3
+++ pangocairomodule.c 18 Jul 2006 18:23:11 -0000
@@ -30,7 +30,7 @@
/* include any extra headers needed here */
-void pypangocairo_register_classes(PyObject *d);
+void G_GNUC_INTERNAL pypangocairo_register_classes(PyObject *d);
void pypangocairo_add_constants(PyObject *module, const gchar *strip_prefix);
extern PyMethodDef pypangocairo_functions[];
Index: pangomodule.c
===================================================================
RCS file: /cvs/gnome/pygtk/pangomodule.c,v
retrieving revision 1.10
diff -u -r1.10 pangomodule.c
--- pangomodule.c 7 May 2006 21:48:21 -0000 1.10
+++ pangomodule.c 18 Jul 2006 18:23:11 -0000
@@ -29,7 +29,7 @@
/* include any extra headers needed here */
-void pypango_register_classes(PyObject *d);
+void G_GNUC_INTERNAL pypango_register_classes(PyObject *d);
void pypango_add_constants(PyObject *module, const gchar *strip_prefix);
extern PyMethodDef pypango_functions[];
Index: codegen/codegen.py
===================================================================
RCS file: /cvs/gnome/pygtk/codegen/codegen.py,v
retrieving revision 1.118
diff -u -r1.118 codegen.py
--- codegen/codegen.py 14 Jul 2006 01:39:07 -0000 1.118
+++ codegen/codegen.py 18 Jul 2006 18:23:12 -0000
@@ -1410,7 +1410,7 @@
def write_extension_init(self):
self.fp.write('/* initialise stuff extension classes */\n')
- self.fp.write('void\n' + self.prefix + '_register_classes(PyObject *d)\n{\n')
+ self.fp.write('void\n' + visibility + self.prefix + '_register_classes(PyObject *d)\n{\n')
self.write_object_imports()
self.fp.write(self.overrides.get_init() + '\n')
self.fp.resetline()
Index: codegen/mkskel.py
===================================================================
RCS file: /cvs/gnome/pygtk/codegen/mkskel.py,v
retrieving revision 1.3
diff -u -r1.3 mkskel.py
--- codegen/mkskel.py 3 Apr 2006 17:04:40 -0000 1.3
+++ codegen/mkskel.py 18 Jul 2006 18:23:12 -0000
@@ -13,7 +13,7 @@
'\n' + \
'/* include any extra headers needed here */\n' + \
'\n' + \
-'void %(prefix)s_register_classes(PyObject *d);\n' + \
+'void G_GNUC_INTERNAL %(prefix)s_register_classes(PyObject *d);\n' + \
'extern PyMethodDef %(prefix)s_functions[];\n' + \
'\n' + \
'DL_EXPORT(void)\n' + \
@@ -28,7 +28,7 @@
'\n' + \
' init_pygtk();\n' + \
'\n' + \
-' %(prefix)s_register_classes(d);\n' + \
+' G_GNUC_INTERNAL %(prefix)s_register_classes(d);\n' + \
'\n' + \
' /* add anything else to the module dictionary (such as constants) */\n' +\
'\n' + \
Index: gtk/gtkmodule.c
===================================================================
RCS file: /cvs/gnome/pygtk/gtk/gtkmodule.c,v
retrieving revision 1.69
diff -u -r1.69 gtkmodule.c
--- gtk/gtkmodule.c 13 Jul 2006 17:43:03 -0000 1.69
+++ gtk/gtkmodule.c 18 Jul 2006 18:23:13 -0000
@@ -35,8 +35,8 @@
#endif
void _pygtk_register_boxed_types(PyObject *moddict);
-void pygtk_register_classes(PyObject *d);
-void pygdk_register_classes(PyObject *d);
+void G_GNUC_INTERNAL pygtk_register_classes(PyObject *d);
+void G_GNUC_INTERNAL pygdk_register_classes(PyObject *d);
void pygtk_add_constants(PyObject *module, const gchar *strip_prefix);
void pygdk_add_constants(PyObject *module, const gchar *strip_prefix);
Index: gtk/gtkunixprintmodule.c
===================================================================
RCS file: /cvs/gnome/pygtk/gtk/gtkunixprintmodule.c,v
retrieving revision 1.3
diff -u -r1.3 gtkunixprintmodule.c
--- gtk/gtkunixprintmodule.c 14 Jul 2006 00:56:48 -0000 1.3
+++ gtk/gtkunixprintmodule.c 18 Jul 2006 18:23:13 -0000
@@ -35,7 +35,7 @@
# include <pycairo.h>
Pycairo_CAPI_t *Pycairo_CAPI;
-void pygtkunixprint_register_classes(PyObject *d);
+void G_GNUC_INTERNAL pygtkunixprint_register_classes(PyObject *d);
void pygtkunixprint_add_constants(PyObject *module, const gchar *strip_prefix);
extern PyMethodDef pygtkunixprint_functions[];
Index: gtk/libglademodule.c
===================================================================
RCS file: /cvs/gnome/pygtk/gtk/libglademodule.c,v
retrieving revision 1.9
diff -u -r1.9 libglademodule.c
--- gtk/libglademodule.c 13 Jul 2006 17:43:03 -0000 1.9
+++ gtk/libglademodule.c 18 Jul 2006 18:23:13 -0000
@@ -28,7 +28,7 @@
#include "pygtk.h"
#include <glade/glade.h>
-void pylibglade_register_classes(PyObject *d);
+void G_GNUC_INTERNAL pylibglade_register_classes(PyObject *d);
extern PyMethodDef pylibglade_functions[];
DL_EXPORT(void)
_______________________________________________
pygtk mailing list [email protected]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/