summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/glib-2.0/glib-2.0/no-iconv.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-core/glib-2.0/glib-2.0/no-iconv.patch')
-rw-r--r--meta/recipes-core/glib-2.0/glib-2.0/no-iconv.patch106
1 files changed, 0 insertions, 106 deletions
diff --git a/meta/recipes-core/glib-2.0/glib-2.0/no-iconv.patch b/meta/recipes-core/glib-2.0/glib-2.0/no-iconv.patch
deleted file mode 100644
index 9c06fe600e..0000000000
--- a/meta/recipes-core/glib-2.0/glib-2.0/no-iconv.patch
+++ /dev/null
@@ -1,106 +0,0 @@
1Upstream-Status: Inappropriate [embedded specific]
2
3We provide dummy implementation of iconv functionality if it does not find
4iconv which will be case with uclibc. We remove the check for iconv in configure
5
6This is needed when libintl and libiconv is not available. It wont have any
7impact on case when they are available.
8
9Signed-off-by: Khem Raj <raj.khem@gmail.com>
10
11
12Index: glib-2.26.1/glib/gconvert.c
13===================================================================
14--- glib-2.26.1.orig/glib/gconvert.c
15+++ glib-2.26.1/glib/gconvert.c
16@@ -23,7 +23,7 @@
17 #include "config.h"
18 #include "glibconfig.h"
19
20-#ifndef G_OS_WIN32
21+#if !defined G_OS_WIN32 && defined HAVE_ICONV_H
22 #include <iconv.h>
23 #endif
24 #include <errno.h>
25@@ -65,6 +65,28 @@
26 #error GNU libiconv not in use but included iconv.h is from libiconv
27 #endif
28
29+#ifndef HAVE_ICONV_H
30+typedef void *iconv_t;
31+
32+iconv_t iconv_open(const char *tocode, const char *fromcode)
33+{
34+ return (iconv_t)(-1);
35+}
36+
37+int iconv_close(iconv_t cd)
38+{
39+ free(cd);
40+
41+ return 0;
42+}
43+size_t iconv (iconv_t __cd, char **__inbuf,
44+ size_t *__inbytesleft,
45+ char **__outbuf,
46+ size_t *__outbytesleft)
47+{
48+ return 0;
49+}
50+#endif
51
52 /**
53 * SECTION:conversions
54Index: glib-2.26.1/configure.ac
55===================================================================
56--- glib-2.26.1.orig/configure.ac
57+++ glib-2.26.1/configure.ac
58@@ -373,46 +373,8 @@ dnl *** Tests for iconv ***
59 dnl ***********************
60 dnl
61 dnl We do this before the gettext checks, to avoid distortion
62-
63-dnl On Windows we use a native implementation
64-
65-if test x"$glib_native_win32" = xyes; then
66- with_libiconv=native
67-else
68- AC_ARG_WITH(libiconv,
69- [AC_HELP_STRING([--with-libiconv=@<:@no/gnu/native@:>@],
70- [use the libiconv library])],,
71- [with_libiconv=maybe])
72-
73- found_iconv=no
74- case $with_libiconv in
75- maybe)
76- # Check in the C library first
77- AC_CHECK_FUNC(iconv_open, [with_libiconv=no; found_iconv=yes])
78- # Check if we have GNU libiconv
79- if test $found_iconv = "no"; then
80- AC_CHECK_LIB(iconv, libiconv_open, [with_libiconv=gnu; found_iconv=yes])
81- fi
82- # Check if we have a iconv in -liconv, possibly from vendor
83- if test $found_iconv = "no"; then
84- AC_CHECK_LIB(iconv, iconv_open, [with_libiconv=native; found_iconv=yes])
85- fi
86- ;;
87- no)
88- AC_CHECK_FUNC(iconv_open, [with_libiconv=no; found_iconv=yes])
89- ;;
90- gnu|yes)
91- AC_CHECK_LIB(iconv, libiconv_open, [with_libiconv=gnu; found_iconv=yes])
92- ;;
93- native)
94- AC_CHECK_LIB(iconv, iconv_open, [with_libiconv=native; found_iconv=yes])
95- ;;
96- esac
97-
98- if test "x$found_iconv" = "xno" ; then
99- AC_MSG_ERROR([*** No iconv() implementation found in C library or libiconv])
100- fi
101-fi
102+found_iconv=yes
103+with_libiconv=no
104
105 gl_GLIBC21
106 AC_ARG_ENABLE(iconv-cache,