mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-23 18:21:04 +00:00
configure.ac: Bump requirements to released versions (core and base 0.10.13).
Original commit message from CVS: * configure.ac: Bump requirements to released versions (core and base 0.10.13). * gst/icydemux/gsticydemux.c: (gst_icydemux_unicodify): Use gst_tag_utf8_from_freeform_string() from libgsttag instead of own implementation.
This commit is contained in:
parent
e99b73973b
commit
63fc719540
3 changed files with 13 additions and 80 deletions
|
@ -1,3 +1,12 @@
|
|||
2007-06-05 Tim-Philipp Müller <tim at centricular dot net>
|
||||
|
||||
* configure.ac:
|
||||
Bump requirements to released versions (core and base 0.10.13).
|
||||
|
||||
* gst/icydemux/gsticydemux.c: (gst_icydemux_unicodify):
|
||||
Use gst_tag_utf8_from_freeform_string() from libgsttag instead of
|
||||
own implementation.
|
||||
|
||||
2007-06-05 Andy Wingo <wingo@pobox.com>
|
||||
|
||||
* sys/v4l2/gstv4l2src.c (gst_v4l2src_start, gst_v4l2src_stop): Add
|
||||
|
|
|
@ -46,8 +46,8 @@ dnl AS_LIBTOOL_TAGS
|
|||
AM_PROG_LIBTOOL
|
||||
|
||||
dnl *** required versions of GStreamer stuff ***
|
||||
GST_REQ=0.10.11.1
|
||||
GSTPB_REQ=0.10.12.1
|
||||
GST_REQ=0.10.13
|
||||
GSTPB_REQ=0.10.13
|
||||
|
||||
dnl *** autotools stuff ****
|
||||
|
||||
|
|
|
@ -48,6 +48,7 @@
|
|||
#endif
|
||||
#include <gst/gst.h>
|
||||
#include <gst/gst-i18n-plugin.h>
|
||||
#include <gst/tag/tag.h>
|
||||
|
||||
#include "gsticydemux.h"
|
||||
|
||||
|
@ -291,83 +292,6 @@ gst_icydemux_remove_srcpad (GstICYDemux * icydemux)
|
|||
return res;
|
||||
};
|
||||
|
||||
/* FIXME: remove this once we depend on gst-plugins-base >= 0.10.12.1 */
|
||||
static gchar *
|
||||
notgst_tag_freeform_string_to_utf8 (const gchar * data, gint size,
|
||||
const gchar ** env_vars)
|
||||
{
|
||||
const gchar *cur_loc = NULL;
|
||||
gsize bytes_read;
|
||||
gchar *utf8 = NULL;
|
||||
|
||||
g_return_val_if_fail (data != NULL, NULL);
|
||||
|
||||
if (size < 0)
|
||||
size = strlen (data);
|
||||
|
||||
/* Should we try the charsets specified
|
||||
* via environment variables FIRST ? */
|
||||
if (g_utf8_validate (data, size, NULL))
|
||||
return g_strndup (data, size);
|
||||
|
||||
while (env_vars != NULL && *env_vars != NULL) {
|
||||
const gchar *env = NULL;
|
||||
|
||||
/* Try charsets specified via the environment */
|
||||
env = g_getenv (*env_vars);
|
||||
if (env != NULL && *env != '\0') {
|
||||
gchar **c, **csets;
|
||||
|
||||
csets = g_strsplit (env, G_SEARCHPATH_SEPARATOR_S, -1);
|
||||
|
||||
for (c = csets; c && *c; ++c) {
|
||||
if ((utf8 =
|
||||
g_convert (data, size, "UTF-8", *c, &bytes_read, NULL, NULL))) {
|
||||
if (bytes_read == size) {
|
||||
g_strfreev (csets);
|
||||
goto beach;
|
||||
}
|
||||
g_free (utf8);
|
||||
utf8 = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
g_strfreev (csets);
|
||||
}
|
||||
|
||||
++env_vars;
|
||||
}
|
||||
|
||||
/* Try current locale (if not UTF-8) */
|
||||
if (!g_get_charset (&cur_loc)) {
|
||||
if ((utf8 = g_locale_to_utf8 (data, size, &bytes_read, NULL, NULL))) {
|
||||
if (bytes_read == size) {
|
||||
goto beach;
|
||||
}
|
||||
g_free (utf8);
|
||||
utf8 = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
/* Try ISO-8859-1 */
|
||||
utf8 = g_convert (data, size, "UTF-8", "ISO-8859-1", &bytes_read, NULL, NULL);
|
||||
if (utf8 != NULL && bytes_read == size) {
|
||||
goto beach;
|
||||
}
|
||||
|
||||
g_free (utf8);
|
||||
return NULL;
|
||||
|
||||
beach:
|
||||
|
||||
g_strchomp (utf8);
|
||||
if (utf8 && utf8[0] != '\0')
|
||||
return utf8;
|
||||
|
||||
g_free (utf8);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static gchar *
|
||||
gst_icydemux_unicodify (const gchar * str)
|
||||
{
|
||||
|
@ -375,7 +299,7 @@ gst_icydemux_unicodify (const gchar * str)
|
|||
"GST_TAG_ENCODING", NULL
|
||||
};
|
||||
|
||||
return notgst_tag_freeform_string_to_utf8 (str, -1, env_vars);
|
||||
return gst_tag_freeform_string_to_utf8 (str, -1, env_vars);
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
Loading…
Reference in a new issue