From 1577961aa2d8d8e37df82b2179e8b843f03cbf7d Mon Sep 17 00:00:00 2001 From: Přemysl Eric Janouch Date: Sat, 10 Jun 2023 11:52:11 +0200 Subject: Improve compatibility with older dependencies --- fiv-io-model.c | 4 ++++ fiv.c | 2 +- meson.build | 3 ++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/fiv-io-model.c b/fiv-io-model.c index 55ddd91..2f8b192 100644 --- a/fiv-io-model.c +++ b/fiv-io-model.c @@ -166,6 +166,10 @@ model_entry_array_new(void) (GDestroyNotify) fiv_io_model_entry_unref); } +#if !GLIB_CHECK_VERSION(2, 70, 0) +#define g_pattern_spec_match g_pattern_match +#endif + static gboolean model_supports(FivIoModel *self, const char *filename) { diff --git a/fiv.c b/fiv.c index 66a8d36..4b8440e 100644 --- a/fiv.c +++ b/fiv.c @@ -1352,7 +1352,7 @@ show_preferences(void) if (!g_spawn_async( NULL, argv, NULL, G_SPAWN_SEARCH_PATH, NULL, NULL, NULL, &error)) { if (g_error_matches(error, G_SPAWN_ERROR, G_SPAWN_ERROR_NOENT)) - g_prefix_error_literal(&error, + g_prefix_error(&error, "%s", "Please install dconf-editor, or use the gsettings utility.\n"); show_error_dialog(error); } diff --git a/meson.build b/meson.build index 8699c9f..4b578fd 100644 --- a/meson.build +++ b/meson.build @@ -154,7 +154,8 @@ gresources = gnome.compile_resources('resources', tiff_tables = custom_target('tiff-tables.h', output : 'tiff-tables.h', input : 'tiff-tables.db', - command : ['tiff-tables.awk', '@INPUT@'], + # Meson 0.56 chokes on files() as well as on a relative path. + command : [meson.current_source_dir() / 'tiff-tables.awk', '@INPUT@'], capture : true, ) -- cgit v1.2.3-70-g09d2