[dia/wip/jtojnar/mac-integration: 3/3] build: Re-add Mac GTK integration



commit b6ad980f20aa49b833797f784a3598def32a4ee8
Author: Jan Tojnar <jtojnar gmail com>
Date:   Tue Apr 7 22:54:43 2020 +0200

    build: Re-add Mac GTK integration
    
    This was forgotten during Meson port

 app/meson.build |  2 +-
 meson.build     | 11 +++++++++++
 2 files changed, 12 insertions(+), 1 deletion(-)
---
diff --git a/app/meson.build b/app/meson.build
index 6690a247..c113bfaa 100644
--- a/app/meson.build
+++ b/app/meson.build
@@ -95,7 +95,7 @@ resources = gnome.compile_resources('dia-resources', 'dia.gresource.xml',
 
 diaapp_lib = both_libraries('diaapp',
                             dia_sources + [diamarshal_h, config_h],
-                            dependencies: [libgtk_dep, libxml_dep, libm_dep, libdia_dep],
+                            dependencies: [libgtk_dep, libxml_dep, libm_dep, libdia_dep, gtk_mac_dep],
                             link_args: dia_link_args,
                             export_dynamic: true,  # some plugins require this.
                             include_directories: [configuration_inc])
diff --git a/meson.build b/meson.build
index 3bf55e75..05c68fd1 100644
--- a/meson.build
+++ b/meson.build
@@ -33,6 +33,17 @@ conf.set('HAVE_OGDF', libogdf_dep.found())
 libxslt_dep = dependency('libxslt', required: false)
 conf.set('HAVE_XSLT', libxslt_dep.found())
 
+libgdk_dep  = dependency('gdk-2.0')
+gdk_target = libgdk_dep.get_pkgconfig_variable('target')
+
+if gdk_target == 'quartz'
+    gtk_mac_dep = dependency('gtk-mac-integration')
+    conf.set('HAVE_MAC_INTEGRATION', true)
+else
+    # non-dependency
+    gtk_mac_dep = dependency('', required: false)
+endif
+
 prefix = get_option('prefix')
 datadir = prefix / get_option('datadir')
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]