From 17b125e80fae938e43805171145c602e0c988072 Mon Sep 17 00:00:00 2001 From: Colomban Wendling Date: Wed, 21 Jan 2026 22:28:11 +0100 Subject: [PATCH 1/2] cfg: Add CAIRO_VERSION_ENCODE() Add CAIRO_VERSION_ENCODE() to fix undefined function-like macro error. --- cfg/cairo.cfg | 1 + test/cfg/cairo.c | 3 +++ 2 files changed, 4 insertions(+) diff --git a/cfg/cairo.cfg b/cfg/cairo.cfg index e077c2fc40d..d766abffc2e 100644 --- a/cfg/cairo.cfg +++ b/cfg/cairo.cfg @@ -21,6 +21,7 @@ + diff --git a/test/cfg/cairo.c b/test/cfg/cairo.c index a081a8fe52c..b8c518225a0 100644 --- a/test/cfg/cairo.c +++ b/test/cfg/cairo.c @@ -9,6 +9,9 @@ #include +#if CAIRO_VERSION >= CAIRO_VERSION_ENCODE(1, 2, 3) +#endif + void validCode(cairo_surface_t *target) { cairo_t * cairo1 = cairo_create(target); From 3bb73677db357b229a9ccfddea995907c3a4872f Mon Sep 17 00:00:00 2001 From: Colomban Wendling Date: Wed, 21 Jan 2026 22:35:52 +0100 Subject: [PATCH 2/2] cfg: Add version check macros for GLib, GTK and ATK Add GLIB_CHECK_VERSION(), GTK_CHECK_VERSION() and ATK_CHECK_VERSION() to fix undefined function-like macro error. --- cfg/gtk.cfg | 4 ++++ test/cfg/gtk.c | 8 ++++++++ 2 files changed, 12 insertions(+) diff --git a/cfg/gtk.cfg b/cfg/gtk.cfg index 722efb6b76b..4dd9700c62c 100644 --- a/cfg/gtk.cfg +++ b/cfg/gtk.cfg @@ -23079,4 +23079,8 @@ + + + + diff --git a/test/cfg/gtk.c b/test/cfg/gtk.c index 8d5e9dd801d..3e4e5b1cb06 100644 --- a/test/cfg/gtk.c +++ b/test/cfg/gtk.c @@ -11,8 +11,16 @@ #include #include #include +#include +#if GLIB_CHECK_VERSION(2, 3, 4) +#endif +#if GTK_CHECK_VERSION(4, 5, 6) +#endif +#if ATK_CHECK_VERSION(2, 3, 6) +#endif + void validCode(int argInt, GHashTableIter * hash_table_iter, GHashTable * hash_table) { g_assert_cmpint(4 + 1, >=, 5);