+2001-12-13 Michael Meeks <michael@ximian.com>
+
+ * plugins/xvideosink/Makefile.am: add $(X_LIBS)
+
+ * examples/typefind/typefind.c (type_found): upd.
+ xml code.
+
+ * plugins/mikmod/gstmikmod.c
+ (gst_mikmod_set_property): same memory bug here -
+ unfixed.
+
+ * plugins/oss/gstosssrc.c
+ (gst_osssrc_set_property): fix memory issue.
+ (gst_osssrc_init): dup the string - argh; quit here -
+ such code should be stuck in a common base class not
+ cut and pasted.
+
+ * plugins/oss/gstosssink.c
+ (gst_osssink_init): manage the device allocation.
+ (gst_osssink_finalize): impl.
+ (gst_osssink_class_init): upd.
+ (gst_osssink_set_property): upd.
+
+ * acconfig.h: cover HAVE_LIBXML2
+
+ * configure.ac: update libxml checks.
+
2001-12-11 22:10 thomasvs
* lots of build fixes for 0.3.0 release
#undef HAVE_STPCPY
#undef USE_GLIB2
+#undef HAVE_LIBXML2
#undef PLUGINS_DIR
#undef PLUGINS_BUILDDIR
}
# now remove the cache, because it can be considered dangerous in this case
-echo "+ removing config.cache ... "
-rm -f config.cache
+#echo "+ removing config.cache ... "
+#rm -f config.cache
CONFIGURE_OPT='--enable-maintainer-mode --enable-plugin-builddir --enable-debug --enable-DEBUG'
AC_SUBST(GTK_LIBS)
AC_SUBST(GTK_CFLAGS)
+if test x$USE_GLIB2 = xno; then
+ LIBXML_PKG='libxml >= 1.8.1'
+else
+ LIBXML_PKG='libxml-2.0'
+ AC_DEFINE(HAVE_LIBXML2)
+fi
+AC_SUBST(LIBXML_PKG)
+
dnl Check for libxml
dnl Thomas tries to convert this to pkg-config
-PKG_CHECK_MODULES(XML, libxml >= 1.8.1, XML_CONFIG=yes, XML_CONFIG=no)
+PKG_CHECK_MODULES(XML, $LIBXML_PKG, XML_CONFIG=yes, XML_CONFIG=no)
dnl AC_PATH_PROG(XML_CONFIG, xml-config, no)
if test x$XML_CONFIG = xno; then
- AC_MSG_ERROR(Couldn't find xml-config)
+ AC_MSG_ERROR(Couldn't find $LIBXML_PKG)
fi
-dnl XML_LIBS="`xml-config --libs`"
-dnl XML_CFLAGS="`xml-config --cflags`"
-dnl AC_CHECK_LIB(xml, xmlDocGetRootElement, :,
-dnl [ AC_MSG_ERROR(Need version 1.8.1 or better of libxml) ],
-dnl $XML_LIBS)
AC_SUBST(XML_LIBS)
AC_SUBST(XML_CFLAGS)
{
int i, j;
int num_channels;
- gboolean done;
char buffer[20];
/* First, include the header file for the plugin, to bring in the
* object definition and other useful things.
*/
+#include <string.h>
#include "example.h"
/* The ElementDetails structure gives a human-readable description
xmlNodePtr parent;
doc = xmlNewDoc ("1.0");
- doc->root = xmlNewDocNode (doc, NULL, "Capabilities", NULL);
+ doc->xmlRootNode = xmlNewDocNode (doc, NULL, "Capabilities", NULL);
- parent = xmlNewChild (doc->root, NULL, "Caps1", NULL);
+ parent = xmlNewChild (doc->xmlRootNode, NULL, "Caps1", NULL);
gst_caps_save_thyself (caps, parent);
xmlDocDump (stdout, doc);
gst_bin_add(GST_BIN(bin), typefind);
g_signal_connect (G_OBJECT (typefind), "have_type",
- type_found, NULL);
+ G_CALLBACK (type_found), NULL);
gst_pad_connect(gst_element_get_pad(disksrc,"src"),
gst_element_get_pad(typefind,"sink"));
//thread = gst_thread_new("thread");
thread = gst_elementfactory_make("thread", "thread");
g_assert(thread != NULL);
- g_signal_connect (G_OBJECT (thread), "object_saved", object_saved, g_strdup ("decoder thread"));
+ g_signal_connect (G_OBJECT (thread), "object_saved",
+ G_CALLBACK (object_saved),
+ g_strdup ("decoder thread"));
thread2 = gst_elementfactory_make("thread", "thread2");
//thread2 = gst_thread_new("thread2");
g_assert(thread2 != NULL);
- g_signal_connect (G_OBJECT (thread2), "object_saved", object_saved, g_strdup ("render thread"));
+ g_signal_connect (G_OBJECT (thread2), "object_saved",
+ G_CALLBACK (object_saved),
+ g_strdup ("render thread"));
/* create a new bin to hold the elements */
bin = gst_bin_new("bin");
+#include <string.h>
#include <stdlib.h>
#include <gst/gst.h>
xml = gst_xml_new ();
- g_signal_connect (G_OBJECT (xml), "object_loaded", xml_loaded, xml);
+ g_signal_connect (G_OBJECT (xml), "object_loaded",
+ G_CALLBACK (xml_loaded), xml);
ret = gst_xml_parse_file(xml, "xmlTest.gst", NULL);
g_assert (ret == TRUE);
/***** Deal with XML stuff, we have to handle both loadsave and registry *****/
#if (! (defined(GST_DISABLE_LOADSAVE) && defined(GST_DISABLE_REGISTRY)) )
+#ifdef HAVE_LIBXML2
+ #include <libxml/parser.h>
+#else /* impossibly broken header namespacing */
#include <parser.h>
+#endif
// Include compatability defines: if libxml hasn't already defined these,
// we have an old version 1.x
gst_bin_add(GST_BIN(pipeline),GST_ELEMENT(src));
gst_bin_add(GST_BIN(pipeline),GST_ELEMENT(parse));
- g_signal_connect(G_OBJECT(parse),"new_pad",mp2tomp1, pipeline);
+ g_signal_connect(G_OBJECT(parse),"new_pad",G_CALLBACK(mp2tomp1), pipeline);
g_signal_connect(G_OBJECT(src),"eos",G_CALLBACK(eof),NULL);
gst_bin_add (GST_BIN (pipeline), GST_ELEMENT (mux));
gst_bin_add (GST_BIN (pipeline), GST_ELEMENT (fdsink));
- g_signal_connect (G_OBJECT (parse), "new_pad", mp2tomp1_new_pad, pipeline);
+ g_signal_connect (G_OBJECT (parse), "new_pad",
+ G_CALLBACK (mp2tomp1_new_pad), pipeline);
- g_signal_connect (G_OBJECT (src), "eos", eof, NULL);
+ g_signal_connect (G_OBJECT (src), "eos",
+ G_CALLBACK (eof), NULL);
gst_element_connect (src, "src", parse, "sink");
gst_element_connect (mux, "src", fdsink, "sink");
gst_bin_add(GST_BIN(pipeline),GST_ELEMENT(parse));
- g_signal_connect(G_OBJECT(parse),"new_pad",mp2tomp1, pipeline);
+ g_signal_connect(G_OBJECT(parse),"new_pad",
+ G_CALLBACK (mp2tomp1), pipeline);
g_signal_connect(G_OBJECT(src),"eos",G_CALLBACK(eof),NULL);
{
int i, j;
int num_channels;
- gboolean done;
char buffer[20];
/* First, include the header file for the plugin, to bring in the
* object definition and other useful things.
*/
+#include <string.h>
#include "example.h"
/* The ElementDetails structure gives a human-readable description
xmlNodePtr parent;
doc = xmlNewDoc ("1.0");
- doc->root = xmlNewDocNode (doc, NULL, "Capabilities", NULL);
+ doc->xmlRootNode = xmlNewDocNode (doc, NULL, "Capabilities", NULL);
- parent = xmlNewChild (doc->root, NULL, "Caps1", NULL);
+ parent = xmlNewChild (doc->xmlRootNode, NULL, "Caps1", NULL);
gst_caps_save_thyself (caps, parent);
xmlDocDump (stdout, doc);
gst_bin_add(GST_BIN(bin), typefind);
g_signal_connect (G_OBJECT (typefind), "have_type",
- type_found, NULL);
+ G_CALLBACK (type_found), NULL);
gst_pad_connect(gst_element_get_pad(disksrc,"src"),
gst_element_get_pad(typefind,"sink"));
//thread = gst_thread_new("thread");
thread = gst_elementfactory_make("thread", "thread");
g_assert(thread != NULL);
- g_signal_connect (G_OBJECT (thread), "object_saved", object_saved, g_strdup ("decoder thread"));
+ g_signal_connect (G_OBJECT (thread), "object_saved",
+ G_CALLBACK (object_saved),
+ g_strdup ("decoder thread"));
thread2 = gst_elementfactory_make("thread", "thread2");
//thread2 = gst_thread_new("thread2");
g_assert(thread2 != NULL);
- g_signal_connect (G_OBJECT (thread2), "object_saved", object_saved, g_strdup ("render thread"));
+ g_signal_connect (G_OBJECT (thread2), "object_saved",
+ G_CALLBACK (object_saved),
+ g_strdup ("render thread"));
/* create a new bin to hold the elements */
bin = gst_bin_new("bin");
+#include <string.h>
#include <stdlib.h>
#include <gst/gst.h>
xml = gst_xml_new ();
- g_signal_connect (G_OBJECT (xml), "object_loaded", xml_loaded, xml);
+ g_signal_connect (G_OBJECT (xml), "object_loaded",
+ G_CALLBACK (xml_loaded), xml);
ret = gst_xml_parse_file(xml, "xmlTest.gst", NULL);
g_assert (ret == TRUE);
#include <stdio.h>
#include <string.h>
-#include <parser.h> // NOTE: this is xml-config's fault
-// Include compatability defines: if libxml hasn't already defined these,
-// we have an old version 1.x
-#ifndef xmlChildrenNode
-#define xmlChildrenNode childs
-#define xmlRootNode root
-#endif
+#include <gst/gstconfig.h>
#include <glib.h>
-#include "config.h"
typedef struct {
gchar *name;