Files
poky/meta/recipes-gnome/gtk+/gtk+3_3.24.51.bb
Jörg Sommer 78a280af44 gtk+3: Update 3.24.43 -> 3.24.51
According to https://www.gtk.org/docs/installations/linux/#gtk-v3x the new
place for downloads is download.gnome.org aka $GNOME_MIRROR (ftp.g.o
redirects to this). And new versions are without `+`.

Update opengl.patch, handle new `is_gl_context_current`.

Overview of Changes in GTK+ 3.24.51, 29-09-2025
===============================================

* Wayland:
 - Force window titles to be valid utf8
 - Flush tablet events when neccessary

* X11:
 - Avoid a use-after-free with threads

* Windows:
 - Avoid min/max buttons for dialogs

* Images:
 - Replace a few calls to gdk_pixbuf_get_pixels
   with read_pixels to avoid thread-safety issues

* GL:
 - Try harder to keep the GL context current

* Input:
 - Make compose file parsing more robust

* Translation updates:
 Catalan
 Esperanto
 Persian

Overview of Changes in GTK+ 3.24.50, 07-08-2025
===============================================

* Themes:
 - Add a progress-working-symbolic icon
 - Support strokes in symbolic icons
 - Update theme CSS
 - Remove hardcoded Cantarell font

* GtkShortcutsWindow:
 - Differentiate all keypad symbols visually

* GtkApplication:
 - Register unsandboxed apps with the portals

* macOS:
 - Remove redundant NSView calls
 - Fix some memory leaks
 - Don't try to use the file transfer portal

* Windows:
 - Always mark windows as minimizable

* X11
 - Fix problems with gtk_window_get_geometry

* Wayland:
 - Fix a crash

* Input:
 - Make compose sequence visuals configurable

* Printing:
 - Fix the build with libcups 3
 - Support gnome-papers as previewer

* Translation updates
 Nepali
 Persian
 Uzbek (Latin)

Overview of Changes in GTK+ 3.24.49, 05-03-2025
===============================================

* Fix a crash in GtkIMContext

* Fix crashes in DND with GtkPlug/GtkSocket

* Wayland:
 - Fix erroneous crossing events, causing menus to malfunction
 - Support the cursor-shape protocol

* X11:
 - Enforce size limits on windows, preventing lockups

* macOS:
 - Fix pen tilt handling

* Translation updates
 Bulgarian
 Thai

Overview of Changes in GTK+ 3.24.48, 25-02-2025
===============================================

* Switch to the new ci-based release process

Overview of Changes in GTK+ 3.24.44, 24-01-2025
===============================================

* GtkFileChooser:
 - Stop replacing : (colon) with U+2236 (ratio)

* GtkEmojiChooser:
 - Update to Unicode 16 / CLDR 46

* GtkSpinButton:
 - Use semantically appropriate icon names
 - Make numeric spin buttons always LTR

* GtkEntry:
 - Stop guessing text direction from keyboard layout
 - Add a shortcut and context menu item to change text direction

* GtkEventControllerMotion:
 - Make enter and leave signals work

* Accessibility:
 - Use message dialog titles as names

* GDK:
 - Fix portal handling of gvfs files

* Wayland:
 - Support the xdg_foreign_v2 protocol
 - Try to fix monitor geometry on sway
 - Improve font setting fallback
 - Use a better default cursor size
 - Fix a crash during DND

* macOS:
 - Fix a UI hang

* Translation updates:
 Bulgarian
 Farsi
 Hindi
 Hungarian
 Icelandic
 Latvian
 Serbian

(From OE-Core rev: 7f370c3b9c10e723324ea8f924011c5f570749d4)

Signed-off-by: Jörg Sommer <joerg.sommer@navimatix.de>
Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com>
Signed-off-by: Ross Burton <ross.burton@arm.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2025-10-27 11:37:43 +00:00

169 lines
7.3 KiB
BlitzBasic

SUMMARY = "Multi-platform toolkit for creating GUIs"
DESCRIPTION = "GTK+ is a multi-platform toolkit for creating graphical user interfaces. Offering a complete \
set of widgets, GTK+ is suitable for projects ranging from small one-off projects to complete application suites."
HOMEPAGE = "http://www.gtk.org"
BUGTRACKER = "https://gitlab.gnome.org/GNOME/gtk/-/issues/"
SECTION = "libs"
LIC_FILES_CHKSUM = "file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2 \
file://gtk/gtk.h;endline=25;md5=1d8dc0fccdbfa26287a271dce88af737 \
file://gdk/gdk.h;endline=25;md5=c920ce39dc88c6f06d3e7c50e08086f2 \
file://tests/testgtk.c;endline=25;md5=cb732daee1d82af7a2bf953cf3cf26f1"
CVE_PRODUCT = "gnome:gtk gtk:gtk\+"
DEPENDS = "glib-2.0 cairo pango atk jpeg libpng gdk-pixbuf gdk-pixbuf-native"
LICENSE = "LGPL-2.0-only & LGPL-2.0-or-later & LGPL-2.1-or-later"
inherit meson gettext pkgconfig gtk-doc update-alternatives gtk-immodules-cache gsettings features_check gobject-introspection
MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}"
SRC_URI = "${GNOME_MIRROR}/gtk/${MAJ_VER}/gtk-${PV}.tar.xz \
file://opengl.patch \
"
SRC_URI[sha256sum] = "0013877c6bd23c2dbe42ad7c70a053d0e449be66736574e37867c49c5f905a4f"
S = "${UNPACKDIR}/gtk-${PV}"
BBCLASSEXTEND = "native nativesdk"
GSETTINGS_PACKAGE:class-native = ""
# versions >= 3.90 are development versions, otherwise like upstream-version-is-even
UPSTREAM_CHECK_REGEX = "[^\d\.](?P<pver>3\.([1-8]?[02468])+(\.\d+)+)\.tar"
ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
do_configure:prepend() {
# These files are generated by wayland-scanner but will race over modification
# time between the copies in the sysroot from wayland-protocols and the copy
# in the source tree. Solve the race by deleting so they need to be regenerated.
rm -f ${S}/modules/input/*-text-input-*.[ch]
}
GTKDOC_MESON_OPTION = 'gtk_doc'
EXTRA_OEMESON = "-Dxinerama=no -Dtests=false"
EXTRA_OEMESON:append:class-native = " -Ddemos=false -Dexamples=false"
PACKAGECONFIG ??= " \
${@bb.utils.filter('DISTRO_FEATURES', 'opengl x11', d)} \
${@bb.utils.contains('DISTRO_FEATURES', 'opengl wayland', 'wayland', '', d)} \
"
PACKAGECONFIG:class-native = "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}"
PACKAGECONFIG:class-nativesdk = "${@bb.utils.filter('DISTRO_FEATURES', 'x11', d)}"
PACKAGECONFIG[x11] = "-Dx11_backend=true,-Dx11_backend=false,at-spi2-atk fontconfig libx11 libxext libxcursor libxi libxdamage libxrandr libxrender libxcomposite libxfixes"
# this is provided by oe-core patch that removes epoxy/gl dependency from a X11 build
PACKAGECONFIG[opengl] = "-Dopengl=true,-Dopengl=false,libepoxy"
PACKAGECONFIG[wayland] = "-Dwayland_backend=true,-Dwayland_backend=false,wayland wayland-protocols libxkbcommon virtual/egl virtual/libgles2 wayland-native"
PACKAGECONFIG[cups] = ",,cups,cups gtk3-printbackend-cups"
PACKAGECONFIG[colord] = "-Dcolord=yes,-Dcolord=no,colord"
PACKAGECONFIG[cloudproviders] = "-Dcloudproviders=true,-Dcloudproviders=false,libcloudproviders"
PACKAGECONFIG[tracker3] = "-Dtracker3=true,-Dtracker3=false,tinysparql,localsearch"
prepare_gtk_scripts() {
mv ${D}${bindir}/gtk-update-icon-cache ${D}${bindir}/gtk-update-icon-cache-3.0
# duplicate gtk-query-immodules for post install script update_gtk_immodules_cache
mkdir -p ${D}${libexecdir}
ln ${D}${bindir}/gtk-query-immodules-3.0 ${D}${libexecdir}/${MLPREFIX}gtk-query-immodules-3.0
}
do_install:append:class-target() {
prepare_gtk_scripts
}
do_install:append:class-nativesdk() {
prepare_gtk_scripts
}
do_install:append:class-native() {
create_wrapper ${D}/${bindir}/gtk-update-icon-cache \
GDK_PIXBUF_MODULE_FILE=${STAGING_LIBDIR_NATIVE}/gdk-pixbuf-2.0/2.10.0/loaders.cache
create_wrapper ${D}/${bindir}/gtk-encode-symbolic-svg \
GDK_PIXBUF_MODULE_FILE=${STAGING_LIBDIR_NATIVE}/gdk-pixbuf-2.0/2.10.0/loaders.cache
}
PROVIDES += "gtk-icon-utils"
PACKAGES =+ "${PN}-demo"
LIBV = "3.0.0"
FILES:${PN}-demo = "${bindir}/gtk3-demo \
${bindir}/gtk3-demo-application \
${bindir}/gtk3-icon-browser \
${bindir}/gtk3-widget-factory \
${datadir}/gtk-3.0/demo \
${datadir}/applications/gtk3-demo.desktop \
${datadir}/applications/gtk3-icon-browser.desktop \
${datadir}/applications/gtk3-widget-factory.desktop \
${datadir}/icons/hicolor/*/apps/gtk3-demo*.png \
${datadir}/icons/hicolor/*/apps/gtk3-widget-factory*.png"
FILES:${PN}:append = " ${bindir}/gtk-update-icon-cache-3.0 \
${bindir}/gtk-query-immodules-3.0 \
${bindir}/gtk-launch \
${datadir}/themes ${datadir}/gtk-3.0/emoji \
${sysconfdir} ${datadir}/glib-2.0/schemas/ \
${libdir}/gtk-3.0/${LIBV}/engines/libpixmap.so \
${libdir}/gtk-3.0/modules/*.so"
FILES:${PN}-dev += " \
${datadir}/gtk-3.0/gtkbuilder.rng \
${datadir}/gtk-3.0/include \
${datadir}/gtk-3.0/valgrind \
${datadir}/gettext/its \
${libdir}/gtk-3.0/include \
${libdir}/gtk-3.0/${LIBV}/loaders/*.la \
${libdir}/gtk-3.0/${LIBV}/immodules/*.la \
${libdir}/gtk-3.0/3.0.0/printbackends/*.la \
${libdir}/gtk-3.0/${LIBV}/engines/*.la \
${libdir}/gtk-3.0/modules/*.la \
${bindir}/gtk-builder-convert \
${bindir}/gtk-encode-symbolic-svg \
${bindir}/gtk-builder-tool \
${bindir}/gtk-query-settings \
"
GTKBASE_RRECOMMENDS ?= "liberation-fonts \
gdk-pixbuf-loader-png \
gdk-pixbuf-loader-jpeg \
gdk-pixbuf-loader-gif \
gdk-pixbuf-loader-xpm \
shared-mime-info \
adwaita-icon-theme-symbolic \
"
GTKBASE_RRECOMMENDS:class-native ?= "\
"
GTKGLIBC_RRECOMMENDS ?= "${GTKBASE_RRECOMMENDS} glibc-gconv-iso8859-1"
RRECOMMENDS:${PN} = "${GTKBASE_RRECOMMENDS}"
RRECOMMENDS:${PN}:libc-glibc = "${GTKGLIBC_RRECOMMENDS}"
RDEPENDS:${PN}-dev += "${@bb.utils.contains("PACKAGECONFIG", "wayland", "wayland-protocols", "", d)}"
RDEPENDS:${PN}-demo += "librsvg-gtk"
PACKAGES_DYNAMIC += "^gtk3-immodule-.* ^gtk3-printbackend-.*"
ALTERNATIVE:${PN} = "gtk-update-icon-cache"
ALTERNATIVE_TARGET[gtk-update-icon-cache] = "${bindir}/gtk-update-icon-cache-3.0"
ALTERNATIVE_PRIORITY = "30"
python populate_packages:prepend () {
import os.path
gtk_libdir = d.expand('${libdir}/gtk-3.0/${LIBV}')
immodules_root = os.path.join(gtk_libdir, 'immodules')
printmodules_root = os.path.join(gtk_libdir, 'printbackends');
immodules = do_split_packages(d, immodules_root, r'^im-(.*)\.so$', 'gtk3-immodule-%s', 'GTK input module for %s')
if immodules:
d.setVar("GTKIMMODULES_PACKAGES", " ".join(immodules))
do_split_packages(d, printmodules_root, r'^libprintbackend-(.*)\.so$', 'gtk3-printbackend-%s', 'GTK printbackend module for %s')
if (d.getVar('DEBIAN_NAMES')):
d.setVar(d.expand('PKG:${PN}'), '${MLPREFIX}libgtk-3.0')
}