Description: Adapt girepository usage back to the 1.0 API to fix build failure
 The build environment provides the GIRepository 1.0 API headers
 (gobject-introspection-1.0) but not the 2.0 API headers, so including
 <girepository/girepository.h> fails. Revert the girepository-2.0 API usage
 (gi_repository_*) to the 1.0 API (g_irepository_*) to fix the FTBFS.
Author: tangxiaofeng <tangxiaofeng@kylinos.cn>
Origin: other
Forwarded: not-needed
Last-Update: 2026-09-01

--- eog-49.1.orig/src/eog-plugin-engine.c
+++ eog-49.1/src/eog-plugin-engine.c
@@ -34,7 +34,7 @@
 #include <glib/gi18n.h>
 #include <glib.h>
 #include <gio/gio.h>
-#include <girepository/girepository.h>
+#include <girepository.h>
 
 #define EOG_PLUGIN_DATA_DIR EOG_DATA_DIR G_DIR_SEPARATOR_S "plugins"
 
@@ -89,7 +89,7 @@ eog_plugin_engine_new (void)
 					"girepository-1.0", NULL);
 
 	/* This should be moved to libpeas */
-	if (gi_repository_require (gi_repository_dup_default (),
+	if (g_irepository_require (g_irepository_get_default (),
 				   "Peas", "1.0", 0, &error) == NULL)
 	{
 		g_warning ("Error loading Peas typelib: %s\n",
@@ -98,7 +98,7 @@ eog_plugin_engine_new (void)
 	}
 
 
-	if (gi_repository_require (gi_repository_dup_default (),
+	if (g_irepository_require (g_irepository_get_default (),
 				   "PeasGtk", "1.0", 0, &error) == NULL)
 	{
 		g_warning ("Error loading PeasGtk typelib: %s\n",
@@ -107,7 +107,7 @@ eog_plugin_engine_new (void)
 	}
 
 
-	if (gi_repository_require_private (gi_repository_dup_default (),
+	if (g_irepository_require_private (g_irepository_get_default (),
 					   private_path, "Eog", "3.0", 0,
 					   &error) == NULL)
 	{
--- eog-49.1.orig/src/main.c
+++ eog-49.1/src/main.c
@@ -27,7 +27,7 @@
 #include "config.h"
 #endif
 #ifdef HAVE_INTROSPECTION
-#include <girepository/girepository.h>
+#include <girepository.h>
 #endif
 
 #include "eog-application.h"
@@ -102,7 +102,7 @@ main (int argc, char **argv)
 	 * Using gtk_get_option_group here initializes gtk during parsing */
 	g_option_context_add_group (ctx, gtk_get_option_group (FALSE));
 #ifdef HAVE_INTROSPECTION
-	g_option_context_add_group (ctx, gi_repository_get_option_group ());
+	g_option_context_add_group (ctx, g_irepository_get_option_group ());
 #endif
 
 	if (!g_option_context_parse (ctx, &argc, &argv, &error)) {
