-
Notifications
You must be signed in to change notification settings - Fork 165
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1279 from wingtk/weekly-2024.3.14
GTK 4.14.1 and other updates
- Loading branch information
Showing
28 changed files
with
733 additions
and
176 deletions.
There are no files selected for viewing
25 changes: 0 additions & 25 deletions
25
gvsbuild/patches/adwaita-icon-theme/001-fix-relative-cursor-path.patch
This file was deleted.
Oops, something went wrong.
59 changes: 59 additions & 0 deletions
59
gvsbuild/patches/glib-base/001-glib-package-installation-directory.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
From 03ad717497c4669970a8f335961272af449d277c Mon Sep 17 00:00:00 2001 | ||
From: TingPing <tingping@tingping.se> | ||
Date: Sun, 9 Nov 2014 00:11:13 -0500 | ||
Subject: [PATCH] Fix g_win32_get_package_installation_directory_of_module() | ||
handling some paths containing bin/lib | ||
|
||
--- | ||
glib/gwin32.c | 30 +++++++++--------------------- | ||
1 file changed, 9 insertions(+), 21 deletions(-) | ||
|
||
diff --git a/glib/gwin32.c b/glib/gwin32.c | ||
index ffc5fe2..f495bee 100644 | ||
--- a/glib/gwin32.c | ||
+++ b/glib/gwin32.c | ||
@@ -249,32 +249,20 @@ g_win32_get_package_installation_directory_of_module (gpointer hmodule) | ||
|
||
filename = g_utf16_to_utf8 (wc_fn, -1, NULL, NULL, NULL); | ||
|
||
+ /* Strip off trailing module/executable */ | ||
if ((p = strrchr (filename, G_DIR_SEPARATOR)) != NULL) | ||
*p = '\0'; | ||
|
||
- retval = g_strdup (filename); | ||
- | ||
- do | ||
- { | ||
- p = strrchr (retval, G_DIR_SEPARATOR); | ||
- if (p == NULL) | ||
- break; | ||
- | ||
+ /* Strip off trailing bin/lib */ | ||
+ if ((p = strrchr (filename, G_DIR_SEPARATOR)) != NULL) | ||
+ { | ||
+ if (g_ascii_strcasecmp (p + 1, "bin") == 0 || | ||
+ g_ascii_strcasecmp (p + 1, "lib") == 0) | ||
*p = '\0'; | ||
+ } | ||
|
||
- if (g_ascii_strcasecmp (p + 1, "bin") == 0 || | ||
- g_ascii_strcasecmp (p + 1, "lib") == 0) | ||
- break; | ||
- } | ||
- while (p != NULL); | ||
- | ||
- if (p == NULL) | ||
- { | ||
- g_free (retval); | ||
- retval = filename; | ||
- } | ||
- else | ||
- g_free (filename); | ||
+ retval = g_strdup (filename); | ||
+ g_free (filename); | ||
|
||
#ifdef G_WITH_CYGWIN | ||
/* In Cygwin we need to have POSIX paths */ | ||
-- | ||
2.1.0 | ||
|
80 changes: 80 additions & 0 deletions
80
gvsbuild/patches/glib-base/002-gir-scanner-dll-not-found.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,80 @@ | ||
From 8954e300e6d6433454d05bf5cf925d2141a516c9 Mon Sep 17 00:00:00 2001 | ||
From: Chun-wei Fan <fanchunwei@src.gnome.org> | ||
Date: Thu, 28 Mar 2024 18:36:41 +0800 | ||
Subject: [PATCH] Introspection: Fix running g-ir-scanner 1.80.x+ on Windows | ||
|
||
Since we are now building GLib, so we want to make sure that we indeed | ||
load the freshly-built DLLs when running g-ir-scanner, so we add the | ||
various needed subdirs (and if needed, subprojects), to set the | ||
GI_EXTRA_BASE_DLL_DIRS envvar so that g-ir-scanner will look for the | ||
newly-built GLib DLLs. | ||
|
||
This will also fix the g-ir-scanner not running when there is no | ||
pre-existing GLib on the system, so that the needed DLLs are found. | ||
|
||
Related issue: https://gitlab.gnome.org/GNOME/gobject-introspection/-/issues/499 | ||
--- | ||
girepository/introspection/meson.build | 35 ++++++++++++++++++++++++++ | ||
1 file changed, 35 insertions(+) | ||
|
||
diff --git a/girepository/introspection/meson.build b/girepository/introspection/meson.build | ||
index 9405686c18..cc70ddf50a 100644 | ||
--- a/girepository/introspection/meson.build | ||
+++ b/girepository/introspection/meson.build | ||
@@ -14,6 +14,34 @@ if get_option('b_sanitize') != '' | ||
'ASAN_OPTIONS', 'verify_asan_link_order=0', separator: ',') | ||
endif | ||
|
||
+if host_system == 'windows' | ||
+ build_root = meson.project_build_root() | ||
+ gi_scanner_dll_paths = [ | ||
+ build_root / 'glib', | ||
+ build_root / 'gobject', | ||
+ build_root / 'gio', | ||
+ build_root / 'gmodule' | ||
+ ] | ||
+ | ||
+ # Check whether ZLib, libffi and proxy-intl and PCRE are indeed built as subprojects, else os.add_dll_directory() | ||
+ # will complain | ||
+ # Keep in sync with GLib's subprojects settings | ||
+ sub_build_root = build_root / 'subprojects' | ||
+ foreach dep: ['proxy-intl', 'libffi', 'zlib-1.2.11', 'pcre2-10.42'] | ||
+ dep_dir = sub_build_root / dep | ||
+ if fs.exists(dep_dir) and fs.is_dir(dep_dir) | ||
+ gi_scanner_dll_paths += [dep_dir] | ||
+ endif | ||
+ endforeach | ||
+ | ||
+ # Also assume the installation bindir to be considered for DLLs | ||
+ message('Ensure that all of GLib\'s dependent non-system DLLs that are not built') | ||
+ message('alongside with GLib can be found in \'@0@\''.format(get_option('prefix') / get_option('bindir'))) | ||
+ message('Check this if building .gir files fail due to \'ImportError: DLL load failed while importing _giscanner\'') | ||
+ gi_scanner_dll_paths += get_option('prefix') / get_option('bindir') | ||
+ gi_gen_env_variables.set('GI_EXTRA_BASE_DLL_DIRS', gi_scanner_dll_paths) | ||
+endif | ||
+ | ||
# GLib | ||
glib_gir_sources = [ | ||
gi_gen_shared_sources, | ||
@@ -304,6 +332,12 @@ libgirepository_gir_args = [ | ||
'--identifier-prefix=GI', | ||
] | ||
|
||
+gi_libgirepository_gen_env_variables = environment() | ||
+ | ||
+if host_system == 'windows' | ||
+ gi_libgirepository_gen_env_variables.set('GI_EXTRA_BASE_DLL_DIRS', gi_scanner_dll_paths) | ||
+endif | ||
+ | ||
girepository_gir = gnome.generate_gir(libgirepository, | ||
sources: libgirepository_gir_sources, | ||
namespace: 'GIRepository', | ||
@@ -316,5 +350,6 @@ girepository_gir = gnome.generate_gir(libgirepository, | ||
install: true, | ||
dependencies: [ libglib_dep, libgobject_dep, libgmodule_dep, libgio_dep ], | ||
extra_args: gir_args + libgirepository_gir_args, | ||
+ env: gi_libgirepository_gen_env_variables, | ||
) | ||
|
||
-- | ||
GitLab |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,80 @@ | ||
From 8954e300e6d6433454d05bf5cf925d2141a516c9 Mon Sep 17 00:00:00 2001 | ||
From: Chun-wei Fan <fanchunwei@src.gnome.org> | ||
Date: Thu, 28 Mar 2024 18:36:41 +0800 | ||
Subject: [PATCH] Introspection: Fix running g-ir-scanner 1.80.x+ on Windows | ||
|
||
Since we are now building GLib, so we want to make sure that we indeed | ||
load the freshly-built DLLs when running g-ir-scanner, so we add the | ||
various needed subdirs (and if needed, subprojects), to set the | ||
GI_EXTRA_BASE_DLL_DIRS envvar so that g-ir-scanner will look for the | ||
newly-built GLib DLLs. | ||
|
||
This will also fix the g-ir-scanner not running when there is no | ||
pre-existing GLib on the system, so that the needed DLLs are found. | ||
|
||
Related issue: https://gitlab.gnome.org/GNOME/gobject-introspection/-/issues/499 | ||
--- | ||
girepository/introspection/meson.build | 35 ++++++++++++++++++++++++++ | ||
1 file changed, 35 insertions(+) | ||
|
||
diff --git a/girepository/introspection/meson.build b/girepository/introspection/meson.build | ||
index 9405686c18..cc70ddf50a 100644 | ||
--- a/girepository/introspection/meson.build | ||
+++ b/girepository/introspection/meson.build | ||
@@ -14,6 +14,34 @@ if get_option('b_sanitize') != '' | ||
'ASAN_OPTIONS', 'verify_asan_link_order=0', separator: ',') | ||
endif | ||
|
||
+if host_system == 'windows' | ||
+ build_root = meson.project_build_root() | ||
+ gi_scanner_dll_paths = [ | ||
+ build_root / 'glib', | ||
+ build_root / 'gobject', | ||
+ build_root / 'gio', | ||
+ build_root / 'gmodule' | ||
+ ] | ||
+ | ||
+ # Check whether ZLib, libffi and proxy-intl and PCRE are indeed built as subprojects, else os.add_dll_directory() | ||
+ # will complain | ||
+ # Keep in sync with GLib's subprojects settings | ||
+ sub_build_root = build_root / 'subprojects' | ||
+ foreach dep: ['proxy-intl', 'libffi', 'zlib-1.2.11', 'pcre2-10.42'] | ||
+ dep_dir = sub_build_root / dep | ||
+ if fs.exists(dep_dir) and fs.is_dir(dep_dir) | ||
+ gi_scanner_dll_paths += [dep_dir] | ||
+ endif | ||
+ endforeach | ||
+ | ||
+ # Also assume the installation bindir to be considered for DLLs | ||
+ message('Ensure that all of GLib\'s dependent non-system DLLs that are not built') | ||
+ message('alongside with GLib can be found in \'@0@\''.format(get_option('prefix') / get_option('bindir'))) | ||
+ message('Check this if building .gir files fail due to \'ImportError: DLL load failed while importing _giscanner\'') | ||
+ gi_scanner_dll_paths += get_option('prefix') / get_option('bindir') | ||
+ gi_gen_env_variables.set('GI_EXTRA_BASE_DLL_DIRS', gi_scanner_dll_paths) | ||
+endif | ||
+ | ||
# GLib | ||
glib_gir_sources = [ | ||
gi_gen_shared_sources, | ||
@@ -304,6 +332,12 @@ libgirepository_gir_args = [ | ||
'--identifier-prefix=GI', | ||
] | ||
|
||
+gi_libgirepository_gen_env_variables = environment() | ||
+ | ||
+if host_system == 'windows' | ||
+ gi_libgirepository_gen_env_variables.set('GI_EXTRA_BASE_DLL_DIRS', gi_scanner_dll_paths) | ||
+endif | ||
+ | ||
girepository_gir = gnome.generate_gir(libgirepository, | ||
sources: libgirepository_gir_sources, | ||
namespace: 'GIRepository', | ||
@@ -316,5 +350,6 @@ girepository_gir = gnome.generate_gir(libgirepository, | ||
install: true, | ||
dependencies: [ libglib_dep, libgobject_dep, libgmodule_dep, libgio_dep ], | ||
extra_args: gir_args + libgirepository_gir_args, | ||
+ env: gi_libgirepository_gen_env_variables, | ||
) | ||
|
||
-- | ||
GitLab |
25 changes: 0 additions & 25 deletions
25
gvsbuild/patches/glib/002-python-312-distutils-to-packaging.patch
This file was deleted.
Oops, something went wrong.
File renamed without changes.
44 changes: 44 additions & 0 deletions
44
gvsbuild/patches/gtk4/001-fix-pangoft2-file-not-found.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
From f0f3ea1b3e4743d8e468a92ebd2c2f8c8610e711 Mon Sep 17 00:00:00 2001 | ||
From: Matthias Clasen <mclasen@redhat.com> | ||
Date: Sun, 31 Mar 2024 09:52:36 +0200 | ||
Subject: [PATCH] Fix build without fontconfig | ||
|
||
We were missing some ifdefs for Windows builds. | ||
|
||
Fixes: #6591 | ||
--- | ||
gsk/gskprivate.c | 6 ++++++ | ||
1 file changed, 6 insertions(+) | ||
|
||
diff --git a/gsk/gskprivate.c b/gsk/gskprivate.c | ||
index 2d89f66daf0..0353830e12e 100644 | ||
--- a/gsk/gskprivate.c | ||
+++ b/gsk/gskprivate.c | ||
@@ -1,9 +1,13 @@ | ||
+#include "config.h" | ||
+ | ||
#include "gskresources.h" | ||
#include "gskprivate.h" | ||
|
||
#include <cairo.h> | ||
#include <pango/pangocairo.h> | ||
+#ifdef HAVE_PANGOFT | ||
#include <pango/pangoft2.h> | ||
+#endif | ||
#include <math.h> | ||
|
||
static gpointer | ||
@@ -119,9 +123,11 @@ gsk_reload_font (PangoFont *font, | ||
last_result = pango_font_map_reload_font (pango_font_get_font_map (font), font, scale, context, NULL); | ||
#else | ||
|
||
+#ifdef HAVE_PANGOFT | ||
pattern = pango_fc_font_get_pattern (PANGO_FC_FONT (font)); | ||
if (FcPatternGetDouble (pattern, FC_DPI, 0, &dpi) == FcResultMatch) | ||
pango_cairo_context_set_resolution (context, dpi); | ||
+#endif | ||
|
||
desc = pango_font_describe_with_absolute_size (font); | ||
size = pango_font_description_get_size (desc); | ||
-- | ||
GitLab |
38 changes: 38 additions & 0 deletions
38
gvsbuild/patches/gtksourceview5/001-fix-fontconfig-availability-check.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
From e114e12aae3aeb06b8ed96c0317d4f85bdff5f57 Mon Sep 17 00:00:00 2001 | ||
From: gwillems <g.willems.dev@laposte.net> | ||
Date: Tue, 2 Apr 2024 19:44:08 +0000 | ||
Subject: [PATCH] utils: fix fontconfig availability check | ||
|
||
Macro `ENABLE_FONT_CONFIG` is always defined, either 0 or 1, by meson's `config_h.set10()`, | ||
so `#ifdef` will always be true. | ||
Use `#if` instead. | ||
|
||
Fixes #360 | ||
--- | ||
gtksourceview/gtksourceutils.c | 4 ++-- | ||
1 file changed, 2 insertions(+), 2 deletions(-) | ||
|
||
diff --git a/gtksourceview/gtksourceutils.c b/gtksourceview/gtksourceutils.c | ||
index dd68f46a3..122b305c2 100644 | ||
--- a/gtksourceview/gtksourceutils.c | ||
+++ b/gtksourceview/gtksourceutils.c | ||
@@ -73,7 +73,7 @@ | ||
# endif | ||
#endif | ||
|
||
-#ifdef ENABLE_FONT_CONFIG | ||
+#if ENABLE_FONT_CONFIG | ||
# include <fontconfig/fontconfig.h> | ||
# include <pango/pangocairo.h> | ||
# include <pango/pangofc-fontmap.h> | ||
@@ -967,7 +967,7 @@ _gtk_source_utils_aligned_free (gpointer data) | ||
aligned_free (data); | ||
} | ||
|
||
-#ifdef ENABLE_FONT_CONFIG | ||
+#if ENABLE_FONT_CONFIG | ||
static PangoFontMap * | ||
load_override_font_fc (void) | ||
{ | ||
-- | ||
GitLab |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.