commit 411412c6e9a4fd993962e400ce7f7f3745fcbf35
Author: Johannes Berg <johannes@sipsolutions.net>
Date:   Fri Aug 21 16:09:41 2009 +0200

    Use a common class id/key. Fixes #590348.
    
    Inspired by discussion on IRC between Alessandro Decina,
    some others and myself.

diff --git a/gst/Makefile.am b/gst/Makefile.am
index db8d91c..9d77a75 100644
--- a/gst/Makefile.am
+++ b/gst/Makefile.am
@@ -48,13 +48,15 @@ GEN_FILES = arg-types.py gst-types.defs libs.defs base.defs pbutils.defs
 # GStreamer bindings
 _gst_la_CFLAGS = $(common_cflags)
 _gst_la_LIBADD = $(common_libadd) $(GST_BASE_LIBS)
-_gst_la_LDFLAGS = $(common_ldflags) -export-symbols-regex "^(init_gst|_PyGObject_API).*" \
+_gst_la_LDFLAGS = $(common_ldflags) \
+	-export-symbols-regex "^(init_gst|_PyGObject_API|pygstminiobject_class_).*" \
 	$(GST_BASE_LIBS) $(GST_CONTROLLER_LIBS) $(GST_NET_LIBS) $(GST_DP_LIBS)
 _gst_la_SOURCES = 		\
 	gst-argtypes.c 		\
 	gstmodule.c 		\
 	pygstiterator.c		\
 	pygstminiobject.c 	\
+	pygstminiobjclass.c	\
 	pygstvalue.c 		\
 	pygstexception.c
 
diff --git a/gst/pygstminiobjclass.c b/gst/pygstminiobjclass.c
new file mode 100644
index 0000000..9851c11
--- /dev/null
+++ b/gst/pygstminiobjclass.c
@@ -0,0 +1,25 @@
+/* -*- Mode: C; c-basic-offset: 4 -*-
+ * pygtk- Python bindings for the GTK toolkit.
+ * Copyright (C) 1998-2003  James Henstridge
+ * Copyright (C) 2009       Johannes Berg <johannes@sipsolutions.net>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ * USA
+ */
+#include "pygstminiobject.h"
+
+const gchar _pygstminiobject_class_id[] = "PyGstMiniObject::class";
+const gchar *pygstminiobject_class_id = _pygstminiobject_class_id;
+GQuark pygstminiobject_class_key = 0;
diff --git a/gst/pygstminiobject.c b/gst/pygstminiobject.c
index dcd4ded..1c79f93 100644
--- a/gst/pygstminiobject.c
+++ b/gst/pygstminiobject.c
@@ -24,8 +24,6 @@
 #include "pygstminiobject.h"
 #include <gst/gst.h>
 
-static const gchar pygstminiobject_class_id[]     = "PyGstMiniObject::class";
-static GQuark      pygstminiobject_class_key    = 0;
 /* static const gchar pygstminiobject_wrapper_id[]   = "PyGstMiniObject::wrapper"; */
 /* static GQuark      pygstminiobject_wrapper_key  = 0; */
 
diff --git a/gst/pygstminiobject.h b/gst/pygstminiobject.h
index 8551603..016198e 100644
--- a/gst/pygstminiobject.h
+++ b/gst/pygstminiobject.h
@@ -12,6 +12,9 @@
 
 G_BEGIN_DECLS
 
+extern const gchar *pygstminiobject_class_id;
+extern GQuark      pygstminiobject_class_key;
+
 /* Work around bugs in PyGILState api fixed in 2.4.0a4 */
 #undef PYGIL_API_IS_BUGGY
 #if PY_VERSION_HEX < 0x020400A4
