aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/proxy-libintl
diff options
context:
space:
mode:
authorDenys Dmytriyenko <denis@denix.org>2009-03-17 14:32:59 -0400
committerDenys Dmytriyenko <denis@denix.org>2009-03-17 14:32:59 -0400
commit709c4d66e0b107ca606941b988bad717c0b45d9b (patch)
tree37ee08b1eb308f3b2b6426d5793545c38396b838 /recipes/proxy-libintl
parentfa6cd5a3b993f16c27de4ff82b42684516d433ba (diff)
downloadopenembedded-709c4d66e0b107ca606941b988bad717c0b45d9b.tar.gz
openembedded-709c4d66e0b107ca606941b988bad717c0b45d9b.tar.bz2
openembedded-709c4d66e0b107ca606941b988bad717c0b45d9b.zip
rename packages/ to recipes/ per earlier agreement
See links below for more details: http://thread.gmane.org/gmane.comp.handhelds.openembedded/21326 http://thread.gmane.org/gmane.comp.handhelds.openembedded/21816 Signed-off-by: Denys Dmytriyenko <denis@denix.org> Acked-by: Mike Westerhof <mwester@dls.net> Acked-by: Philip Balister <philip@balister.org> Acked-by: Khem Raj <raj.khem@gmail.com> Acked-by: Marcin Juszkiewicz <hrw@openembedded.org> Acked-by: Koen Kooi <koen@openembedded.org> Acked-by: Frans Meulenbroeks <fransmeulenbroeks@gmail.com>
Diffstat (limited to 'recipes/proxy-libintl')
-rw-r--r--recipes/proxy-libintl/proxy-libintl-20080418/stub-only.patch72
-rw-r--r--recipes/proxy-libintl/proxy-libintl_20080418.bb46
2 files changed, 118 insertions, 0 deletions
diff --git a/recipes/proxy-libintl/proxy-libintl-20080418/stub-only.patch b/recipes/proxy-libintl/proxy-libintl-20080418/stub-only.patch
new file mode 100644
index 0000000000..7186b13c06
--- /dev/null
+++ b/recipes/proxy-libintl/proxy-libintl-20080418/stub-only.patch
@@ -0,0 +1,72 @@
+Index: proxy-libintl/src/proxy-libintl/libintl.c
+===================================================================
+--- proxy-libintl.orig/src/proxy-libintl/libintl.c
++++ proxy-libintl/src/proxy-libintl/libintl.c
+@@ -18,9 +18,12 @@
+ */
+
+ #ifdef _WIN32
+-#include <windows.h>
++# include <windows.h>
+ #else
+-#include <dlfcn.h>
++# include <stddef.h>
++# if !STUB_ONLY
++# include <dlfcn.h>
++# endif
+ typedef void* HMODULE;
+ #endif
+
+@@ -65,11 +68,13 @@ static char * (*p_bind_textdomain_codese
+ static int
+ use_intl_dll (HMODULE dll)
+ {
+-#ifdef _WIN32
+-#define LOOKUP(fn) p_##fn = (void *) GetProcAddress (dll, #fn); if (p_##fn == NULL) return 0
+-#else
+-#define LOOKUP(fn) p_##fn = (void *) dlsym (dll, #fn); if (p_##fn == NULL) return 0
+-#endif
++#if !STUB_ONLY
++# ifdef _WIN32
++# define LOOKUP(fn) p_##fn = (void *) GetProcAddress (dll, #fn); if (p_##fn == NULL) return 0
++# else
++# define LOOKUP(fn) p_##fn = (void *) dlsym (dll, #fn); if (p_##fn == NULL) return 0
++# endif /* _WIN32 */
++
+
+ LOOKUP (gettext);
+ LOOKUP (dgettext);
+@@ -82,7 +87,7 @@ use_intl_dll (HMODULE dll)
+ LOOKUP (bind_textdomain_codeset);
+
+ #undef LOOKUP
+-
++#endif /* !STUB_ONLY */
+ return 1;
+ }
+
+@@ -171,13 +176,17 @@ setup (void)
+
+ if (!beenhere)
+ {
+-#ifdef _WIN32
+- HMODULE intl_dll = LoadLibrary ("intl.dll");
+-#elif defined(__APPLE__) && defined(__MACH__)
+- HMODULE intl_dll = dlopen ("libintl.dylib", RTLD_LAZY);
+-#else
+- HMODULE intl_dll = dlopen ("libintl.so", RTLD_LAZY);
+-#endif
++#if !STUB_ONLY
++# ifdef _WIN32
++ HMODULE intl_dll = LoadLibrary ("intl.dll");
++# elif defined(__APPLE__) && defined(__MACH__)
++ HMODULE intl_dll = dlopen ("libintl.dylib", RTLD_LAZY);
++# else
++ HMODULE intl_dll = dlopen ("libintl.so", RTLD_LAZY);
++# endif
++#else /* !STUB_ONLY */
++ HMODULE intl_dll = NULL;
++#endif /* STUB_ONLY */
+
+ if (intl_dll != NULL &&
+ use_intl_dll (intl_dll))
diff --git a/recipes/proxy-libintl/proxy-libintl_20080418.bb b/recipes/proxy-libintl/proxy-libintl_20080418.bb
new file mode 100644
index 0000000000..dbe7b92c7e
--- /dev/null
+++ b/recipes/proxy-libintl/proxy-libintl_20080418.bb
@@ -0,0 +1,46 @@
+DESCRIPTION = "Proxy libintl"
+HOMEPAGE = "http://ftp.gnome.org/pub/GNOME/binaries/win32/dependencies/"
+SECTION = "libs"
+LICENSE = "LGPL"
+
+PR = "r1"
+PROVIDES = "virtual/libintl"
+
+
+SRC_URI = " \
+ http://ftp.gnome.org/pub/GNOME/binaries/win32/dependencies/${PN}-${PV}.zip \
+ file://stub-only.patch;patch=1 \
+"
+
+
+S = "${WORKDIR}"
+FILES_${PN}-dev = "${includedir} ${libdir}"
+
+
+CFLAGS_append = " -Wall -I ../../include ${@['-DSTUB_ONLY', ''][bb.data.getVar('USE_NLS', d, 1) != 'no']}"
+
+do_compile() {
+ cd ${WORKDIR}/src/proxy-libintl
+ oe_runmake
+}
+
+
+
+
+do_install() {
+ install -d ${D}/usr/include
+ install -d ${D}/usr/lib
+
+ install -m 0644 ${WORKDIR}/include/libintl.h ${D}/${includedir}
+ install -m 0644 ${WORKDIR}/lib/libintl.a ${D}/${libdir}
+}
+
+
+
+do_stage() {
+ install -m 0644 ${WORKDIR}/include/libintl.h ${STAGING_INCDIR}/
+ oe_libinstall -a -C lib libintl ${STAGING_LIBDIR}/
+}
+
+
+