diff options
Diffstat (limited to 'meta/recipes-core/glib-2.0/files/relocate-modules.patch')
-rw-r--r-- | meta/recipes-core/glib-2.0/files/relocate-modules.patch | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/meta/recipes-core/glib-2.0/files/relocate-modules.patch b/meta/recipes-core/glib-2.0/files/relocate-modules.patch new file mode 100644 index 0000000000..a1ff198aa6 --- /dev/null +++ b/meta/recipes-core/glib-2.0/files/relocate-modules.patch | |||
@@ -0,0 +1,44 @@ | |||
1 | From 0133aeabd37a9137722abd86039d7d0797b5896f Mon Sep 17 00:00:00 2001 | ||
2 | From: Ross Burton <ross.burton@intel.com> | ||
3 | Date: Fri, 11 Mar 2016 15:35:55 +0000 | ||
4 | Subject: [PATCH] glib-2.0: relocate the GIO module directory for native builds | ||
5 | |||
6 | Instead of hard-coding GIO_MODULE_PATH when glib is built, use dladdr() to | ||
7 | determine where libglib.so is and use that path to calculate GIO_MODULES_DIR. | ||
8 | |||
9 | This solves relocation problems with GIOModule for native builds of glib. | ||
10 | |||
11 | Upstream-Status: Inappropriate | ||
12 | Signed-off-by: Ross Burton <ross.burton@intel.com> | ||
13 | |||
14 | Port patch to 2.48 | ||
15 | Signed-off-by: Jussi Kukkonen <jussi.kukkonen@intel.com> | ||
16 | --- | ||
17 | gio/giomodule.c | 7 ------- | ||
18 | 1 file changed, 7 deletions(-) | ||
19 | |||
20 | diff --git a/gio/giomodule.c b/gio/giomodule.c | ||
21 | index 1e14955..3c09bb5 100644 | ||
22 | --- a/gio/giomodule.c | ||
23 | +++ b/gio/giomodule.c | ||
24 | @@ -1259,11 +1259,6 @@ get_gio_module_dir (void) | ||
25 | g_free (install_dir); | ||
26 | #else | ||
27 | module_dir = g_strdup (GIO_MODULE_DIR); | ||
28 | -#ifdef __APPLE__ | ||
29 | -#include "TargetConditionals.h" | ||
30 | -/* Only auto-relocate on macOS, not watchOS etc; older macOS SDKs only define TARGET_OS_MAC */ | ||
31 | -#if (defined (TARGET_OS_OSX) && TARGET_OS_OSX) || \ | ||
32 | - (!defined (TARGET_OS_OSX) && defined (TARGET_OS_MAC) && TARGET_OS_MAC) | ||
33 | #include <dlfcn.h> | ||
34 | { | ||
35 | g_autofree gchar *path = NULL; | ||
36 | @@ -1282,8 +1277,6 @@ get_gio_module_dir (void) | ||
37 | } | ||
38 | } | ||
39 | } | ||
40 | -#endif | ||
41 | -#endif | ||
42 | #endif | ||
43 | } | ||
44 | |||