$OpenBSD: patch-plugin_gstpythonplugin_c,v 1.1 2012/02/21 15:26:58 ajacoutot Exp $

Needed for loading libgstpython.so:
/usr/local/lib/libpythonX.Y.so.X.Y: undefined symbol 'forkpty'

--- plugin/gstpythonplugin.c.orig	Tue Feb 21 16:02:27 2012
+++ plugin/gstpythonplugin.c	Tue Feb 21 16:00:32 2012
@@ -346,7 +348,7 @@ plugin_init (GstPlugin * plugin)
   PyGILState_STATE state;
   PyObject *gst, *dict, *pyplugin;
   gboolean we_initialized = FALSE;
-  GModule *libpython;
+  GModule *libpython, *libutil;
   gpointer has_python = NULL;
 
   GST_DEBUG_CATEGORY_INIT (pyplugindebug, "pyplugin", 0,
@@ -364,6 +366,13 @@ plugin_init (GstPlugin * plugin)
   if (has_python) {
     GST_LOG ("libpython is already loaded");
   } else {
+    GST_LOG ("loading libutil");
+    libutil = g_module_open ("libutil.so", 0);
+    if (!libutil) {
+      GST_WARNING ("Couldn't g_module_open libutil. Reason: %s",
+          g_module_error ());
+      return FALSE;
+    }
     GST_LOG ("loading libpython");
     libpython =
         g_module_open (PY_LIB_LOC "/libpython" PYTHON_VERSION "."
