summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph Reiter <reiter.christoph@gmail.com>2023-03-25 17:40:11 +0100
committerChristoph Reiter <reiter.christoph@gmail.com>2023-03-25 17:42:29 +0100
commitc3e2e480cf7e8587be26fd1174672c295b3f2f9c (patch)
treeaa4d31f77024f69dd8b5912eda1a09535c228b0f
parentd1e2d39b5a936f71595a2b9b372cafe9d884483e (diff)
downloadat-spi2-core-c3e2e480cf7e8587be26fd1174672c295b3f2f9c.tar.gz
meson: don't require dlopen for atk only builds
atk doesn't need it. This allows building atk alone on Windows
-rw-r--r--meson.build14
1 files changed, 8 insertions, 6 deletions
diff --git a/meson.build b/meson.build
index 944c36b0..84d872d7 100644
--- a/meson.build
+++ b/meson.build
@@ -134,12 +134,14 @@ endif
glib_dep = dependency('glib-2.0', version: glib_req_version)
gobject_dep = dependency('gobject-2.0', version: gobject_req_version)
gio_dep = dependency('gio-2.0', version: gio_req_version)
-if cc.has_function('dlopen')
- dl_dep = []
-elif cc.has_function('dlopen', args: '-ldl')
- dl_dep = cc.find_library('dl')
-else
- error('Could not find a library with the dlopen function')
+if not get_option('atk_only')
+ if cc.has_function('dlopen')
+ dl_dep = []
+ elif cc.has_function('dlopen', args: '-ldl')
+ dl_dep = cc.find_library('dl')
+ else
+ error('Could not find a library with the dlopen function')
+ endif
endif
gmodule_dep = dependency('gmodule-2.0', version: gmodule_req_version)
libxml_dep = dependency('libxml-2.0', version: libxml_req_version)