summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2022-08-01 10:31:46 +0200
committerGitHub <noreply@github.com>2022-08-01 10:31:46 +0200
commitdd238cb0384d87368cd85972bfeff0cc11a91eaa (patch)
treecd74955173150eb381629a0149bcc5a8a2452ac8
parent90dae713a1d3785b61607c98995c05238b574ac1 (diff)
parent89847dc6e34e1caf589a03fdcc3aecd193d9bd1f (diff)
Merge pull request #63722 from akien-mga/scons-4.4.0-vs-solution
SCons: Fix creating VS solution with SCons 4.4.0
-rw-r--r--methods.py12
1 files changed, 11 insertions, 1 deletions
diff --git a/methods.py b/methods.py
index 571b134c8a..b719395ae0 100644
--- a/methods.py
+++ b/methods.py
@@ -607,8 +607,18 @@ def find_visual_c_batch_file(env):
find_batch_file,
)
+ # Syntax changed in SCons 4.4.0.
+ from SCons import __version__ as scons_raw_version
+
+ scons_ver = env._get_major_minor_revision(scons_raw_version)
+
version = get_default_version(env)
- (host_platform, target_platform, _) = get_host_target(env)
+
+ if scons_ver >= (4, 4, 0):
+ (host_platform, target_platform, _) = get_host_target(env, version)
+ else:
+ (host_platform, target_platform, _) = get_host_target(env)
+
return find_batch_file(env, version, host_platform, target_platform)[0]