meson: use .enable_if for intel tools dependency on expat
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35840>
This commit is contained in:
Dylan Baker 2025-06-30 17:01:40 +00:00 committed by Marge Bot
parent 66a30385fe
commit 2e2826d121

View file

@ -1585,7 +1585,8 @@ if dep_thread.found()
endif
with_expat = get_option('expat') \
.disable_auto_if(with_platform_android or with_platform_windows)
.disable_auto_if(with_platform_android or with_platform_windows) \
.enable_if(with_intel_tools, error_message : 'Intel tools require expat')
if host_machine.system() == 'darwin'
dep_expat = meson.get_compiler('c').find_library('expat', required : with_expat)
@ -1594,11 +1595,6 @@ else
required : with_expat)
endif
# TODO: with Meson 1.1.0 this can be replaced with with_expat.enable_if(with_intel_tools)
if with_intel_tools and not dep_expat.found()
error('Intel tools require expat')
endif
# We don't require expat on Android or Windows
use_xmlconfig = get_option('xmlconfig') \
.require(not (with_platform_android or with_platform_windows),