From ee2dd1acc79ee1e4c45e297dd9a313e8a11868d4 Mon Sep 17 00:00:00 2001 From: Chun-wei Fan Date: Wed, 5 Jan 2022 17:50:29 +0800 Subject: [PATCH] gtk/meson.build: Fix builds without PangoFT2 We aren't really using PangoFT2 for [language|script]-names.c, and are always using items from them, so make sure they are being built. Also always include the pangoft2 dependency in gtk_dep if it is found. --- gtk/meson.build | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/gtk/meson.build b/gtk/meson.build index 09a6e0bc84..9e01201522 100644 --- a/gtk/meson.build +++ b/gtk/meson.build @@ -1072,6 +1072,10 @@ gtk_gen_headers = [ gtkversion, ] +font_script_language_sources = files([ + 'language-names.c', +]) + gtk_sources += [ gtk_a11y_src, gtk_dbus_src, @@ -1081,6 +1085,7 @@ gtk_sources += [ gtkmarshalers, gtkprivatetypebuiltins, gtktypebuiltins, + font_script_language_sources, ] gtk_deps = [ @@ -1097,13 +1102,6 @@ gtk_deps = [ graphene_dep, ] -if harfbuzz_dep.found() and pangoft_dep.found() - gtk_deps += [ harfbuzz_dep, pangoft_dep ] - gtk_sources += files([ - 'language-names.c', - ]) -endif - if x11_enabled x11_data_prefix = dependency('x11').get_variable(pkgconfig: 'prefix') @@ -1151,6 +1149,9 @@ endif # So we don't add these twice if x11_enabled or wayland_enabled gtk_sources += gtk_use_wayland_or_x11_c_sources +endif + +if pangoft_dep.found() gtk_deps += pangoft_dep endif