gnome-shell/revert-gir-2.0-port.patch
2025-11-11 14:08:54 +01:00

200 lines
6.5 KiB
Diff

From 445bf69e9aafa8ad76e0b4bc70cd56359f717776 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
Date: Thu, 6 Nov 2025 15:20:15 +0100
Subject: [PATCH 1/3] Revert "build: Depend on GLib 2.86.0"
This reverts commit 02d9487c1992972a344cac5866f0aedd357827ee.
---
meson.build | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/meson.build b/meson.build
index 0cc6cceb94..ff5fc88734 100644
--- a/meson.build
+++ b/meson.build
@@ -21,7 +21,7 @@ libmutter_test_pc = 'libmutter-test-' + mutter_api_version
ecal_req = '>= 3.33.1'
eds_req = '>= 3.33.1'
gcr_req = '>= 3.90.0'
-gio_req = '>= 2.86.0'
+gio_req = '>= 2.85.1'
gjs_req = '>= 1.85.90'
gtk_req = '>= 4.0'
mutter_req = '>= 49.0'
--
2.51.1
From f4a4ce8a0608d8fb8c39cf7b81c828a22e305e63 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
Date: Thu, 6 Nov 2025 15:21:29 +0100
Subject: [PATCH 2/3] Revert "build: Depend on gjs 1.85.90"
This reverts commit 08563fae7cd392527b0712c583750add21ac97d7.
---
meson.build | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/meson.build b/meson.build
index ff5fc88734..5bc23778ef 100644
--- a/meson.build
+++ b/meson.build
@@ -22,7 +22,7 @@ ecal_req = '>= 3.33.1'
eds_req = '>= 3.33.1'
gcr_req = '>= 3.90.0'
gio_req = '>= 2.85.1'
-gjs_req = '>= 1.85.90'
+gjs_req = '>= 1.85.1'
gtk_req = '>= 4.0'
mutter_req = '>= 49.0'
polkit_req = '>= 0.100'
--
2.51.1
From 6f94c04657a9013dd9ca2e5366e6118d8cb96b20 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
Date: Thu, 6 Nov 2025 15:27:19 +0100
Subject: [PATCH 3/3] Revert "Port to gjs-1.85/girepository-2.0"
This reverts commit c8e28918aa96c53333ea7019eb24642b7878b548.
---
meson.build | 7 ++++---
src/main.c | 23 ++++++++++-------------
src/run-js-test.c | 9 +++------
3 files changed, 17 insertions(+), 22 deletions(-)
diff --git a/meson.build b/meson.build
index 5bc23778ef..ddd7d2c6e4 100644
--- a/meson.build
+++ b/meson.build
@@ -21,8 +21,9 @@ libmutter_test_pc = 'libmutter-test-' + mutter_api_version
ecal_req = '>= 3.33.1'
eds_req = '>= 3.33.1'
gcr_req = '>= 3.90.0'
-gio_req = '>= 2.85.1'
-gjs_req = '>= 1.85.1'
+gio_req = '>= 2.79.2'
+gi_req = '>= 1.49.1'
+gjs_req = '>= 1.81.2'
gtk_req = '>= 4.0'
mutter_req = '>= 49.0'
polkit_req = '>= 0.100'
@@ -72,7 +73,7 @@ ecal_dep = dependency('libecal-2.0', version: ecal_req)
eds_dep = dependency('libedataserver-1.2', version: eds_req)
gcr_dep = dependency('gcr-4', version: gcr_req)
gdk_pixbuf_dep = dependency('gdk-pixbuf-2.0')
-gi_dep = dependency('girepository-2.0', version: gio_req)
+gi_dep = dependency('gobject-introspection-1.0', version: gi_req)
gio_dep = dependency('gio-2.0', version: gio_req)
gio_unix_dep = dependency('gio-unix-2.0', version: gio_req)
gjs_dep = dependency('gjs-1.0', version: gjs_req)
diff --git a/src/main.c b/src/main.c
index 99eca3e3c9..af4fa8597e 100644
--- a/src/main.c
+++ b/src/main.c
@@ -13,7 +13,7 @@
#include <clutter/clutter.h>
#include <glib-unix.h>
#include <glib/gi18n-lib.h>
-#include <girepository/girepository.h>
+#include <girepository.h>
#include <meta/meta-context.h>
#include <meta/meta-plugin.h>
#include <meta/prefs.h>
@@ -133,7 +133,7 @@ shell_dbus_init (gboolean replace)
#ifdef HAVE_EXE_INTROSPECTION
static void
-maybe_add_rpath_introspection_paths (GIRepository *repo)
+maybe_add_rpath_introspection_paths (void)
{
ElfW (Dyn) *dyn;
ElfW (Dyn) *rpath = NULL;
@@ -210,8 +210,8 @@ maybe_add_rpath_introspection_paths (GIRepository *repo)
g_debug ("Prepending RPATH directory '%s' "
"to introsepciton library search path",
rpath_dir->str);
- gi_repository_prepend_search_path (repo, rpath_dir->str);
- gi_repository_prepend_library_path (repo, rpath_dir->str);
+ g_irepository_prepend_search_path (rpath_dir->str);
+ g_irepository_prepend_library_path (rpath_dir->str);
}
}
#endif /* HAVE_EXE_INTROSPECTION */
@@ -219,23 +219,20 @@ maybe_add_rpath_introspection_paths (GIRepository *repo)
static void
shell_introspection_init (void)
{
- g_autoptr (GIRepository) repo = NULL;
- repo = gi_repository_dup_default ();
-
- gi_repository_prepend_search_path (repo, MUTTER_TYPELIB_DIR);
- gi_repository_prepend_search_path (repo, SHELL_TYPELIB_DIR);
+ g_irepository_prepend_search_path (MUTTER_TYPELIB_DIR);
+ g_irepository_prepend_search_path (SHELL_TYPELIB_DIR);
/* We need to explicitly add the directories where the private libraries are
* installed to the GIR's library path, so that they can be found at runtime
* when linking using DT_RUNPATH (instead of DT_RPATH), which is the default
* for some linkers (e.g. gold) and in some distros (e.g. Debian).
*/
- gi_repository_prepend_library_path (repo, MUTTER_TYPELIB_DIR);
- gi_repository_prepend_library_path (repo, GNOME_SHELL_PKGLIBDIR);
+ g_irepository_prepend_library_path (MUTTER_TYPELIB_DIR);
+ g_irepository_prepend_library_path (GNOME_SHELL_PKGLIBDIR);
#ifdef HAVE_EXE_INTROSPECTION
- maybe_add_rpath_introspection_paths (repo);
+ maybe_add_rpath_introspection_paths ();
#endif
}
@@ -614,7 +611,7 @@ main (int argc, char **argv)
context = meta_create_context (WM_NAME);
meta_context_add_option_entries (context, gnome_shell_options,
GETTEXT_PACKAGE);
- meta_context_add_option_group (context, gi_repository_get_option_group ());
+ meta_context_add_option_group (context, g_irepository_get_option_group ());
session_mode = (char *) g_getenv ("GNOME_SHELL_SESSION_MODE");
diff --git a/src/run-js-test.c b/src/run-js-test.c
index 7a539d3a23..4f795252c2 100644
--- a/src/run-js-test.c
+++ b/src/run-js-test.c
@@ -30,7 +30,7 @@
#include <stdlib.h>
#include <string.h>
-#include <girepository/girepository.h>
+#include <girepository.h>
#include <gjs/gjs.h>
#include "shell-global.h"
@@ -64,7 +64,6 @@ int
main (int argc, char **argv)
{
GOptionContext *context;
- g_autoptr (GIRepository) repo = NULL;
g_autoptr (GError) error = NULL;
ShellGlobal *global;
GjsContext *js_context;
@@ -86,10 +85,8 @@ main (int argc, char **argv)
global = shell_global_get ();
js_context = _shell_global_get_gjs_context (global);
- repo = gi_repository_dup_default ();
-
- gi_repository_prepend_search_path (repo, MUTTER_TYPELIB_DIR);
- gi_repository_prepend_search_path (repo, SHELL_TYPELIB_DIR);
+ g_irepository_prepend_search_path (MUTTER_TYPELIB_DIR);
+ g_irepository_prepend_search_path (SHELL_TYPELIB_DIR);
if (argc < 2)
{
--
2.51.1