<pre style='margin:0'>
Christopher Nielsen (mascguy) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/a9bce4f091b3d87b5b031bc5437c068e6214e78a">https://github.com/macports/macports-ports/commit/a9bce4f091b3d87b5b031bc5437c068e6214e78a</a></p>
<pre style="white-space: pre; background: #F8F8F8"><span style='display:block; white-space:pre;color:#808000;'>commit a9bce4f091b3d87b5b031bc5437c068e6214e78a
</span>Author: Christopher Nielsen <mascguy@github.com>
AuthorDate: Wed Apr 24 14:51:12 2024 -0400
<span style='display:block; white-space:pre;color:#404040;'> gtk2-devel: patch source issues
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> - Drop experimental variant 'bit_depth_1'
</span><span style='display:block; white-space:pre;color:#404040;'> - Disable silent rules
</span><span style='display:block; white-space:pre;color:#404040;'> - Reduce warnings
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> See: https://trac.macports.org/ticket/69471
</span>---
gnome/gtk2-devel/Portfile | 21 +--
.../files/patch-gtk2-bit_depth-gdkimage.diff | 167 ---------------------
.../gtk2-devel/files/patch-gtkscale-bad-cast.diff | 18 +++
gnome/gtk2-devel/files/patch-tests-menubars.diff | 41 +++++
4 files changed, 71 insertions(+), 176 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/gnome/gtk2-devel/Portfile b/gnome/gtk2-devel/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index e0817c536ba..f5dad16109d 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/gnome/gtk2-devel/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/gnome/gtk2-devel/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -10,7 +10,7 @@ name gtk2-devel
</span> conflicts gtk2
set my_name gtk2
version 2.24.33
<span style='display:block; white-space:pre;background:#ffe0e0;'>-revision 3
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+revision 4
</span> epoch 0
categories gnome x11
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -62,12 +62,18 @@ depends_run-append \
</span> patchfiles-append patch-aliases.diff
patchfiles-append patch-gtk-builder-convert.diff
<span style='display:block; white-space:pre;background:#e0ffe0;'>+# Minor source fixes, only applicable to gtk2; fixed/removed for gtk3 and later.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# See: https://trac.macports.org/ticket/69471
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+patchfiles-append patch-gtkscale-bad-cast.diff
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+patchfiles-append patch-tests-menubars.diff
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> # autoreconf to deal with stupid issues during install (install: .libs/libferret.lai: No such file or directory)
use_autoreconf yes
autoreconf.args -fvi
configure.args-append \
--disable-glibtest \
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ --disable-silent-rules \
</span> --enable-introspection \
--enable-static \
gio_can_sniff=yes
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -77,7 +83,11 @@ configure.cppflags-append \
</span> -DX_LOCALE \
-D_IPP_PRIVATE_STRUCTURES=1
configure.cflags-append \
<span style='display:block; white-space:pre;background:#ffe0e0;'>- -fstrict-aliasing
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -fstrict-aliasing \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -Wno-deprecated-declarations \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -Wno-enum-conversion \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -Wno-unknown-warning-option \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -Wno-error=unknown-warning-option
</span>
# gobject-introspection uses g-ir-scanner, which uses $CC from env
if {${universal_possible} && [variant_isset universal]} {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -269,13 +279,6 @@ variant bundle requires quartz description {Support including into a bundle} {
</span> notes "You have enabled 'bundle' variant which breaks GTK2 when used outside of application bundle!"
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>-variant bit_depth_1 requires quartz description {Enable experimental 1-bit image support} {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- # Experimental upstream patch for 1-bit image support
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- # https://gitlab.gnome.org/GNOME/gtk/-/issues/580
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- # https://gitlab.gnome.org/GNOME/gtk/uploads/2a194d81de8e8346a81816870264b3bf/gdkimage.patch
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- patchfiles-append patch-gtk2-bit_depth-gdkimage.diff
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-}
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span> livecheck.type regex
livecheck.url https://download.gnome.org/sources/${proj_name}/${branch}/
livecheck.regex "LATEST-IS-(${port_ver_major}\\.\\d*\[02468\](?:\\.\\d+)*)"
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/gnome/gtk2-devel/files/patch-gtk2-bit_depth-gdkimage.diff b/gnome/gtk2-devel/files/patch-gtk2-bit_depth-gdkimage.diff
</span>deleted file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 48dcf7d7449..00000000000
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/gnome/gtk2-devel/files/patch-gtk2-bit_depth-gdkimage.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,167 +0,0 @@
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-#==================================================================================================
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-# From 98a5cf03578b8bb81e5222549851cd865754f658 Mon Sep 17 00:00:00 2001
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-# From: Emmanuel Stapf <manuseiffel@users.noreply.github.com>
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-# Date: Mon, 11 Jul 2016 07:42:11 +0900
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-# Subject: [PATCH 1/1] Add support for 1-bpp images
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-#
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-# https://gitlab.gnome.org/GNOME/gtk/-/issues/580
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-# https://gitlab.gnome.org/GNOME/gtk/uploads/2a194d81de8e8346a81816870264b3bf/gdkimage.patch
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-#==================================================================================================
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>----
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- gdk/quartz/gdkimage-quartz.c | 66 +++++++++++++++++++++++++++++---------------
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- 1 file changed, 43 insertions(+), 23 deletions(-)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-diff --git a/gdk/quartz/gdkimage-quartz.c b/gdk/quartz/gdkimage-quartz.c
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-index 493efba..d96b70c 100644
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>---- gdk/quartz/gdkimage-quartz.c
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+++ gdk/quartz/gdkimage-quartz.c
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -37,15 +37,16 @@ _gdk_quartz_image_copy_to_image (GdkDrawable *drawable,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- gint height)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- GdkScreen *screen;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ int depth;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- g_return_val_if_fail (GDK_IS_DRAWABLE_IMPL_QUARTZ (drawable), NULL);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- g_return_val_if_fail (image != NULL || (dest_x == 0 && dest_y == 0), NULL);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- screen = gdk_drawable_get_screen (drawable);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ depth = gdk_drawable_get_depth (drawable);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- if (!image)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- image = _gdk_image_new_for_depth (screen, GDK_IMAGE_FASTEST, NULL,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- width, height,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- gdk_drawable_get_depth (drawable));
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ width, height, depth);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- if (GDK_IS_PIXMAP_IMPL_QUARTZ (drawable))
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -63,7 +64,7 @@ _gdk_quartz_image_copy_to_image (GdkDrawable *drawable,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- return image;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- switch (gdk_drawable_get_depth (drawable))
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ switch (depth)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- case 24:
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- bytes_per_row = pix_impl->width * 4;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -112,7 +113,7 @@ _gdk_quartz_image_copy_to_image (GdkDrawable *drawable,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- for (x = 0; x < width; x++)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- gint32 pixel;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- /* 8 bits */
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- pixel = src[0];
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- src++;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -123,7 +124,7 @@ _gdk_quartz_image_copy_to_image (GdkDrawable *drawable,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- break;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- default:
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- g_warning ("Unsupported bit depth %d\n", gdk_drawable_get_depth (drawable));
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ g_warning ("Unsupported bit depth %d\n", depth);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- return image;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -146,7 +147,7 @@ _gdk_quartz_image_copy_to_image (GdkDrawable *drawable,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- if (GDK_WINDOW_IMPL_QUARTZ (drawable) == GDK_WINDOW_IMPL_QUARTZ (GDK_WINDOW_OBJECT (_gdk_root)->impl))
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- /* Special case for the root window. */
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- CGRect rect = CGRectMake (src_x, src_y, width, height);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ CGRect rect = CGRectMake (src_x, src_y, width, height);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- CGImageRef root_image_ref = CGWindowListCreateImage (rect,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- kCGWindowListOptionOnScreenOnly,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- kCGNullWindowID,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -173,7 +174,7 @@ _gdk_quartz_image_copy_to_image (GdkDrawable *drawable,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- else
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- NSRect rect = NSMakeRect (src_x, src_y, width, height);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ NSRect rect = NSMakeRect (src_x, src_y, width, height);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- view = GDK_WINDOW_IMPL_QUARTZ (drawable)->view;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- /* We return the image even if we can't copy to it. */
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -322,7 +323,7 @@ _gdk_image_new_for_depth (GdkScreen *screen,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- if (visual)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- depth = visual->depth;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- g_assert (depth == 24 || depth == 32);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ g_assert((depth == 1) || (depth == 24) || (depth == 32));
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- image = g_object_new (gdk_image_get_type (), NULL);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- image->type = type;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -333,11 +334,16 @@ _gdk_image_new_for_depth (GdkScreen *screen,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- image->byte_order = (G_BYTE_ORDER == G_LITTLE_ENDIAN) ? GDK_LSB_FIRST : GDK_MSB_FIRST;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- /* We only support images with bpp 4 */
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- image->bpp = 4;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- image->bpl = image->width * image->bpp;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- image->bits_per_pixel = image->bpp * 8;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ if (depth == 1) {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ image->bpp = 1;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ image->bpl = (image->width >> 3) + 1;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ image->bits_per_pixel = 1;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ } else {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ image->bpp = 4;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ image->bpl = image->width * image->bpp;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ image->bits_per_pixel = image->bpp * 8;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- image->mem = g_malloc (image->bpl * image->height);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- memset (image->mem, 0x00, image->bpl * image->height);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -355,9 +361,14 @@ gdk_image_get_pixel (GdkImage *image,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- g_return_val_if_fail (x >= 0 && x < image->width, 0);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- g_return_val_if_fail (y >= 0 && y < image->height, 0);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- ptr = image->mem + y * image->bpl + x * image->bpp;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- return *(guint32 *)ptr;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ ptr = image->mem + y * image->bpl;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ if (image->depth == 1) {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ guchar data = (image->byte_order == GDK_MSB_FIRST ? (0x80 >> (x & 7)) : (1 << (x & 7)));
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ return (ptr[x >> 3] & data) ? 0x1 : 0x0;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ } else {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ ptr += x * image->bpp;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ return *(guint32 *)ptr;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- void
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -366,18 +377,27 @@ gdk_image_put_pixel (GdkImage *image,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- gint y,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- guint32 pixel)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- guchar *ptr;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- ptr = image->mem + y * image->bpl + x * image->bpp;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- *(guint32 *)ptr = pixel;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ guchar *ptr = image->mem + y * image->bpl;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ if (image->depth == 1) {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ guchar data = (image->byte_order == GDK_MSB_FIRST ? (0x80 >> (x & 7)) : (1 << (x & 7)));
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ if (pixel) {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ ptr[x >> 3] |= data;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ } else {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ ptr[x >> 3] &= ~data;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ } else {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ ptr += x * image->bpp;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ *(guint32 *)ptr = pixel;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- gint
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- _gdk_windowing_get_bits_for_depth (GdkDisplay *display,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- gint depth)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ gint depth)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- if (depth == 24 || depth == 32)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ if (depth == 1)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ return 1;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ else if (depth == 24 || depth == 32)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- return 32;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- else
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- g_assert_not_reached ();
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>---
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-2.9.0.windows.1
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/gnome/gtk2-devel/files/patch-gtkscale-bad-cast.diff b/gnome/gtk2-devel/files/patch-gtkscale-bad-cast.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 00000000000..253f19c01f3
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/gnome/gtk2-devel/files/patch-gtkscale-bad-cast.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,18 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+#==================================================================================================
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# Upstream bug fix, removing invalid cast to GCompareFunc. Fixed in gtk3 and later, but never
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# backported to gtk2.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+#
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# Date: 2024-04-24
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# See: https://trac.macports.org/ticket/69471
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+#==================================================================================================
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- gtk/gtkscale.c.orig 2024-04-24 14:08:36.000000000 -0400
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ gtk/gtkscale.c 2024-04-24 14:09:30.000000000 -0400
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -1471,7 +1471,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ mark->position = position;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ priv->marks = g_slist_insert_sorted_with_data (priv->marks, mark,
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- (GCompareFunc) compare_marks,
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ compare_marks,
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ GINT_TO_POINTER (
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ gtk_range_get_inverted (GTK_RANGE (scale))
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ));
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/gnome/gtk2-devel/files/patch-tests-menubars.diff b/gnome/gtk2-devel/files/patch-tests-menubars.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 00000000000..676a2068858
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/gnome/gtk2-devel/files/patch-tests-menubars.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,41 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+#==================================================================================================
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# Upstream bug fix, for a few fundamental issues with this source file. Removed in gtk3 and
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# later, so only applicable to gtk2.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+#
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# Date: 2024-04-25
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# See: https://trac.macports.org/ticket/69471
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+#==================================================================================================
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- tests/testmenubars.c.orig 2024-04-24 14:14:19.000000000 -0400
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ tests/testmenubars.c 2024-04-24 14:17:42.000000000 -0400
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -21,7 +21,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include <gtk/gtk.h>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ static GtkWidget *
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-create_menu (depth)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++create_menu (int depth)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ GtkWidget *menu;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ GtkWidget *menuitem;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -70,19 +70,19 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ menuitem = gtk_image_menu_item_new_from_stock (GTK_STOCK_HOME, NULL);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ gtk_menu_shell_append (GTK_MENU_SHELL (menubar), menuitem);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ gtk_label_set_angle (GTK_LABEL (GTK_BIN (menuitem)->child), angle);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- menu = create_menu (2, TRUE);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ menu = create_menu (2);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ gtk_menu_item_set_submenu (GTK_MENU_ITEM (menuitem), menu);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ menuitem = gtk_menu_item_new_with_label ("foo");
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ gtk_menu_shell_append (GTK_MENU_SHELL (menubar), menuitem);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ gtk_label_set_angle (GTK_LABEL (GTK_BIN (menuitem)->child), angle);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- menu = create_menu (2, TRUE);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ menu = create_menu (2);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ gtk_menu_item_set_submenu (GTK_MENU_ITEM (menuitem), menu);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ menuitem = gtk_menu_item_new_with_label ("bar");
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ gtk_menu_shell_append (GTK_MENU_SHELL (menubar), menuitem);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ gtk_label_set_angle (GTK_LABEL (GTK_BIN (menuitem)->child), angle);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- menu = create_menu (2, TRUE);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ menu = create_menu (2);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ gtk_menu_item_set_submenu (GTK_MENU_ITEM (menuitem), menu);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ return menubar;
</span></pre><pre style='margin:0'>
</pre>