diff options
author | Wim Taymans <wim.taymans@gmail.com> | 2003-02-10 20:32:32 +0000 |
---|---|---|
committer | Wim Taymans <wim.taymans@gmail.com> | 2003-02-10 20:32:32 +0000 |
commit | b030b5cef270a7498c62d734d853012bb84e062b (patch) | |
tree | 8363b479c9a9d2860e7ce4945833f28476a3d910 /tools | |
parent | 136e5d254e37ac2854d396ef724d1f1344fe7134 (diff) |
- Add more --disable options
Original commit message from CVS:
- Add more --disable options
- fix makefiles to only compile non-disabled features
- some compile fixes.
- removed extratypes, added gsturitype
- make get/set clock on a bin overridable
- some portability fixes for GUINT64
- separate pools from gstregistry.[ch] into gstregistrypool.[ch]
- make gstobject size fixed, even if we disabled load/save
- don't use 'new' as a variable as it is not a valib C++ variable
Diffstat (limited to 'tools')
-rw-r--r-- | tools/Makefile.am | 16 | ||||
-rw-r--r-- | tools/gst-inspect.c | 24 | ||||
-rw-r--r-- | tools/gst-launch.c | 10 |
3 files changed, 38 insertions, 12 deletions
diff --git a/tools/Makefile.am b/tools/Makefile.am index 1e38f1d45..0c658b5e3 100644 --- a/tools/Makefile.am +++ b/tools/Makefile.am @@ -7,15 +7,15 @@ endif if GST_DISABLE_LOADSAVE GST_LOADSAVE_SRC = else -GST_LOADSAVE_SRC = gst-compprep gst-xmllaunch +GST_LOADSAVE_SRC = gst-compprep gst-xmllaunch gst-complete endif bin_PROGRAMS = gst-launch \ $(GST_REGISTRY_SRC) \ gst-inspect \ $(GST_LOADSAVE_SRC) \ - gst-md5sum \ - gst-complete + gst-md5sum + bin_SCRIPTS = gst-feedback man_MANS = gst-launch.1 gst-md5sum.1 gst-register.1 gst-inspect.1 \ @@ -30,21 +30,19 @@ gst_md5sum_LDADD = $(GST_LIBS) #-lefence gst_md5sum_CFLAGS = $(GST_CFLAGS) -DGST_CONFIG_DIR=\"$(GST_CONFIG_DIR)\" \ -DGST_CACHE_DIR=\""$(GST_CACHE_DIR)"\" +gst_inspect_LDADD = $(GST_LIBS) ../libs/gst/control/libgstcontrol-@GST_MAJORMINOR@.la +gst_inspect_CFLAGS = $(GST_CFLAGS) -DGST_CONFIG_DIR=\"$(GST_CONFIG_DIR)\" \ + -DGST_CACHE_DIR=\""$(GST_CACHE_DIR)"\" + if !GST_DISABLE_REGISTRY gst_register_LDADD = $(GST_LIBS) gst_register_CFLAGS = $(GST_CFLAGS) -DGST_CONFIG_DIR=\"$(GST_CONFIG_DIR)\" \ -DGST_CACHE_DIR=\""$(GST_CACHE_DIR)"\" -endif - -gst_inspect_LDADD = $(GST_LIBS) ../libs/gst/control/libgstcontrol-@GST_MAJORMINOR@.la -gst_inspect_CFLAGS = $(GST_CFLAGS) -DGST_CONFIG_DIR=\"$(GST_CONFIG_DIR)\" \ - -DGST_CACHE_DIR=\""$(GST_CACHE_DIR)"\" gst_complete_LDADD = $(GST_LIBS) gst_complete_CFLAGS = $(GST_CFLAGS) -DGST_CONFIG_DIR=\"$(GST_CONFIG_DIR)\" \ -DGST_CACHE_DIR=\""$(GST_CACHE_DIR)"\" -if !GST_DISABLE_LOADSAVE gst_compprep_LDADD = $(GST_LIBS) gst_compprep_CFLAGS = $(GST_CFLAGS) -DGST_CONFIG_DIR=\"$(GST_CONFIG_DIR)\" \ -DGST_CACHE_DIR=\""$(GST_CACHE_DIR)"\" diff --git a/tools/gst-inspect.c b/tools/gst-inspect.c index 89990f274..3dc38bce1 100644 --- a/tools/gst-inspect.c +++ b/tools/gst-inspect.c @@ -170,6 +170,7 @@ print_query_types (const GstQueryType *types) static void print_event_masks (const GstEventMask *masks) { +#ifndef GST_DISABLE_ENUMTYPES GType event_type; GEnumClass *klass; GType event_flags; @@ -213,6 +214,7 @@ print_event_masks (const GstEventMask *masks) masks++; } +#endif } static void @@ -342,8 +344,8 @@ print_element_properties (GstElement *element) break; } default: - if (param->value_type == GST_TYPE_FILENAME) { - g_print("%-23.23s Filename", ""); + if (param->value_type == GST_TYPE_URI) { + g_print("%-23.23s URI", ""); } if (param->value_type == GST_TYPE_CAPS) { GstCaps *caps = g_value_peek_pointer (&value); @@ -586,6 +588,7 @@ print_element_info (GstElementFactory *factory) g_print (" none\n"); } +#ifndef GST_DISABLE_INDEX g_print ("\nIndexing capabilities:\n"); if (gst_element_is_indexable (element)) { g_print (" element can do indexing\n"); @@ -593,6 +596,7 @@ print_element_info (GstElementFactory *factory) else { g_print (" none\n"); } +#endif g_print ("\nPads:\n"); if (element->numpads) { @@ -807,6 +811,7 @@ print_element_list (void) g_print ("%s: %s: %s\n", plugin->name, GST_PLUGIN_FEATURE_NAME (factory) ,factory->details->longname); } +#ifndef GST_DISABLE_AUTOPLUG else if (GST_IS_AUTOPLUG_FACTORY (feature)) { GstAutoplugFactory *factory; @@ -814,6 +819,8 @@ print_element_list (void) g_print ("%s: %s: %s\n", plugin->name, GST_PLUGIN_FEATURE_NAME (factory), factory->longdesc); } +#endif +#ifndef GST_DISABLE_INDEX else if (GST_IS_INDEX_FACTORY (feature)) { GstIndexFactory *factory; @@ -821,6 +828,7 @@ print_element_list (void) g_print ("%s: %s: %s\n", plugin->name, GST_PLUGIN_FEATURE_NAME (factory), factory->longdesc); } +#endif else if (GST_IS_TYPE_FACTORY (feature)) { GstTypeFactory *factory; @@ -839,6 +847,7 @@ print_element_list (void) g_print ("%s: %s: %s\n", plugin->name, GST_PLUGIN_FEATURE_NAME (factory), factory->longdesc); } +#ifndef GST_DISABLE_URI else if (GST_IS_URI_HANDLER (feature)) { GstURIHandler *handler; @@ -847,6 +856,7 @@ print_element_list (void) GST_PLUGIN_FEATURE_NAME (handler), handler->uri, handler->longdesc, handler->element, handler->property); } +#endif else { g_print ("%s: %s (%s)\n", plugin->name, GST_PLUGIN_FEATURE_NAME (feature), @@ -891,6 +901,7 @@ print_plugin_info (GstPlugin *plugin) factory->details->longname); num_elements++; } +#ifndef GST_DISABLE_AUTOPLUG else if (GST_IS_AUTOPLUG_FACTORY (feature)) { GstAutoplugFactory *factory; @@ -898,6 +909,8 @@ print_plugin_info (GstPlugin *plugin) g_print (" %s: %s\n", GST_OBJECT_NAME (factory), factory->longdesc); num_autoplug++; } +#endif +#ifndef GST_DISABLE_INDEX else if (GST_IS_INDEX_FACTORY (feature)) { GstIndexFactory *factory; @@ -905,6 +918,7 @@ print_plugin_info (GstPlugin *plugin) g_print (" %s: %s\n", GST_OBJECT_NAME (factory), factory->longdesc); num_indexes++; } +#endif else if (GST_IS_TYPE_FACTORY (feature)) { GstTypeFactory *factory; @@ -997,26 +1011,32 @@ main (int argc, char *argv[]) g_print ("%s: a scheduler\n", argv[1]); return 0; } +#ifndef GST_DISABLE_INDEX feature = gst_registry_pool_find_feature (argv[1], GST_TYPE_INDEX_FACTORY); if (feature) { g_print ("%s: an index\n", argv[1]); return 0; } +#endif +#ifndef GST_DISABLE_AUTOPLUG feature = gst_registry_pool_find_feature (argv[1], GST_TYPE_AUTOPLUG_FACTORY); if (feature) { g_print ("%s: an autoplugger\n", argv[1]); return 0; } +#endif feature = gst_registry_pool_find_feature (argv[1], GST_TYPE_TYPE_FACTORY); if (feature) { g_print ("%s: an type\n", argv[1]); return 0; } +#ifndef GST_DISABLE_URI feature = gst_registry_pool_find_feature (argv[1], GST_TYPE_URI_HANDLER); if (feature) { g_print ("%s: an uri handler\n", argv[1]); return 0; } +#endif } } else { /* strip the .so */ diff --git a/tools/gst-launch.c b/tools/gst-launch.c index 6a551770f..d237f2a34 100644 --- a/tools/gst-launch.c +++ b/tools/gst-launch.c @@ -42,6 +42,7 @@ idle_func (gpointer data) return busy; } +#ifndef GST_DISABLE_LOADSAVE static GstElement* xmllaunch_parse_cmdline (const gchar **argv) { @@ -105,6 +106,7 @@ xmllaunch_parse_cmdline (const gchar **argv) else return l->data; } +#endif extern volatile gboolean glib_on_error_halt; static void fault_restore(void); @@ -191,8 +193,10 @@ main(int argc, char *argv[]) "output status information and property notifications", NULL}, {"exclude", 'X', POPT_ARG_STRING|POPT_ARGFLAG_STRIP, &exclude_args, 0, "do not output status information of TYPE", "TYPE1,TYPE2,..."}, +#ifndef GST_DISABLE_LOADSAVE {"output", 'o', POPT_ARG_STRING|POPT_ARGFLAG_STRIP, &savefile, 0, "save xml representation of pipeline to FILE and exit", "FILE"}, +#endif {"no_fault", 'f', POPT_ARG_NONE|POPT_ARGFLAG_STRIP, &no_fault, 0, "Do not install a fault handler", NULL}, {"trace", 't', POPT_ARG_NONE|POPT_ARGFLAG_STRIP, &trace, 0, @@ -224,9 +228,13 @@ main(int argc, char *argv[]) /* make a null-terminated version of argv */ argvn = g_new0 (char*, argc); memcpy (argvn, argv+1, sizeof (char*) * (argc-1)); +#ifndef GST_DISABLE_LOADSAVE if (strstr (argv[0], "gst-xmllaunch")) { pipeline = xmllaunch_parse_cmdline ((const gchar**)argvn); - } else { + } + else +#endif + { pipeline = (GstElement*) gst_parse_launchv ((const gchar**)argvn, &error); } g_free (argvn); |