From: Jose Fonseca Date: Fri, 25 Oct 2019 21:09:34 +0000 (+0100) Subject: scons: Fix force_scons parsing. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=ace5138548c9833dacad14482ecadaa672884611;p=mesa.git scons: Fix force_scons parsing. - Use parsed options instead of using ARGUMENTS directly. - Handle the case of mingw cross compilation. Reviewed-by: Roland Scheidegger Closes: https://gitlab.freedesktop.org/mesa/mesa/issues/2003 --- diff --git a/SConstruct b/SConstruct index 61a915f7deb..f905189dd9e 100644 --- a/SConstruct +++ b/SConstruct @@ -71,9 +71,8 @@ Help(opts.GenerateHelpText(env)) ####################################################################### # Print a deprecation warning for using scons on non-windows -if common.host_platform != 'windows': - force = ARGUMENTS['force_scons'] - if force.lower() not in {'false', 'off', 'none', '0', 'n'}: +if common.host_platform != 'windows' and env['platform'] != 'windows': + if env['force_scons']: print("WARNING: Scons is deprecated for non-windows platforms (including cygwin) " "please use meson instead.", file=sys.stderr) else: