meson/mesa/wide: define WIN32_LEAN_AND_MEAN with pre_args

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18425>
This commit is contained in:
Yonggang Luo
2022-09-06 17:32:29 +08:00
committed by Marge Bot
parent 2f140c564f
commit b6e4aa6f31
11 changed files with 5 additions and 24 deletions

View File

@@ -1617,6 +1617,10 @@ elif host_machine.system() != 'windows'
else
dep_expat = null_dep
endif
# Predefined macros for windows
if host_machine.system() == 'windows'
pre_args += '-DWIN32_LEAN_AND_MEAN' # http://msdn2.microsoft.com/en-us/library/6dwk3a1z.aspx
endif
# this only exists on linux so either this is linux and it will be found, or
# it's not linux and wont
dep_m = cc.find_library('m', required : false)