From de3e5be2350e988053c0b76d5be7e6a1633b9713 Mon Sep 17 00:00:00 2001 From: Nirbheek Chauhan Date: Sat, 7 Jul 2018 00:19:57 +0530 Subject: [PATCH 1/4] meson: Add a fallback for the harfbuzz dependency This meson port is not upstream yet, so a wrap file is not included. Upstream has expressed interest but the port hasn't been tested on all platforms yet. Will be added when it gets upstreamed. Link to WIP port: https://github.com/centricular/harfbuzz --- meson.build | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/meson.build b/meson.build index 713877808f..5e48265cd4 100644 --- a/meson.build +++ b/meson.build @@ -373,7 +373,8 @@ pixbuf_dep = dependency('gdk-pixbuf-2.0', version: gdk_pixbuf_req, epoxy_dep = dependency('epoxy', version: epoxy_req, fallback: ['libepoxy', 'libepoxy_dep']) atk_dep = dependency('atk', version: atk_req) -harfbuzz_dep = dependency('harfbuzz', version: '>= 0.9', required: false) +harfbuzz_dep = dependency('harfbuzz', version: '>= 0.9', required: false, + fallback: ['harfbuzz', 'libharfbuzz_dep']) xkbdep = dependency('xkbcommon', version: xkbcommon_req, required: wayland_enabled) graphene_dep = dependency('graphene-gobject-1.0', version: graphene_req, fallback: ['graphene', 'graphene_dep']) From 00c29e1fbe231a6bcb0041fa14298e539963f258 Mon Sep 17 00:00:00 2001 From: Nirbheek Chauhan Date: Sat, 7 Jul 2018 00:20:41 +0530 Subject: [PATCH 2/4] meson: Use proxy-libintl subproject when needed and available Such as on Windows with MSVC. --- meson.build | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/meson.build b/meson.build index 5e48265cd4..1483353cfa 100644 --- a/meson.build +++ b/meson.build @@ -591,9 +591,24 @@ endif # Check for bind_textdomain_codeset, including -lintl if GLib brings it in by # doing the same check as glib. We can't check that by linking to glib because # it might be a subproject and hence not built yet. -libintl_dep = cc.find_library('intl', required : false) -if cc.has_function('bind_textdomain_codeset', dependencies: libintl_dep) +if cc.has_function('ngettext') + libintl_dep = [] cdata.set('HAVE_BIND_TEXTDOMAIN_CODESET', 1) +else + libintl_dep = cc.find_library('intl', required : false) + if cc.has_function('bind_textdomain_codeset', dependencies: libintl_dep) + cdata.set('HAVE_BIND_TEXTDOMAIN_CODESET', 1) + else + # Don't use subproject('proxy-libintl').get_variable('intl_dep') because that + # makes the dependency unconditional. This way, people have the option of + # either not providing the subproject or disabling it entirely with + # --wrap-mode=nodownload or nofallback. + libintl_dep = dependency('', required : false, + fallback: ['proxy-libintl', 'intl_dep']) + if libintl_dep.found() + cdata.set('HAVE_BIND_TEXTDOMAIN_CODESET', 1) + endif + endif endif if os_unix From b98f5a0823b178f0ba0506b38bc954e3ce5453df Mon Sep 17 00:00:00 2001 From: Nirbheek Chauhan Date: Mon, 23 Jul 2018 14:55:25 +0530 Subject: [PATCH 3/4] meson: Always fetch pangoft2_dep from the pango subproject This ensures that we will use pangoft2 if it is available, and not if it is not available. See: https://gitlab.gnome.org/GNOME/pango/merge_requests/6 --- meson.build | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/meson.build b/meson.build index 1483353cfa..53504f9279 100644 --- a/meson.build +++ b/meson.build @@ -327,12 +327,8 @@ pango_dep = dependency('pango', version: pango_req, # Require PangoFT2 if on X11 or wayland require_pangoft2 = wayland_enabled or x11_enabled - -if require_pangoft2 - pangoft_dep = dependency('pangoft2', fallback : ['pango', 'libpangoft2_dep']) -else - pangoft_dep = dependency('pangoft2', required: false) -endif +pangoft_dep = dependency('pangoft2', required: require_pangoft2, + fallback : ['pango', 'libpangoft2_dep']) if pangoft_dep.found() # Need at least 2.7.1 for FT_Get_Var_Design_Coordinates() From 4bae7fb0fd6ba3d1c84e329fc43f729fdcaeabc5 Mon Sep 17 00:00:00 2001 From: Nirbheek Chauhan Date: Fri, 12 Oct 2018 14:23:53 +0530 Subject: [PATCH 4/4] .gitignore: Ignore all subdirs in the subprojects dir --- .gitignore | 1 + 1 file changed, 1 insertion(+) create mode 100644 .gitignore diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000000..025c6c9c02 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/subprojects/*/