diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2018-07-21 23:17:03 +0200 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2018-07-21 23:17:36 +0200 |
commit | 0aa7fcd41042f4ba96b259c438e5ea3d220c6cc9 (patch) | |
tree | 89cbce9a2464b78f5993efb8bc518b1d82565f34 /SConstruct | |
parent | 92415365c8586dd0c91b0566d7c00753e0687273 (diff) |
SCons: Prevent using disable_3d or disable_advanced_gui with tools=yes
Those make no sense for tools build, as the editor uses advanced GUI
features heavily, and adding checks for 3D/physics features everywhere
in the editor would be cumbersome (and error-prone).
Fixes #1701.
Diffstat (limited to 'SConstruct')
-rw-r--r-- | SConstruct | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/SConstruct b/SConstruct index 50fb5bc48c..08c5b6d34f 100644 --- a/SConstruct +++ b/SConstruct @@ -417,11 +417,19 @@ if selected_platform in platform_list: if env['tools']: env.Append(CPPDEFINES=['TOOLS_ENABLED']) if env['disable_3d']: - env.Append(CPPDEFINES=['_3D_DISABLED']) + if env['tools']: + print("Build option 'disable_3d=yes' cannot be used with 'tools=yes' (editor), only with 'tools=no' (export template).") + sys.exit(255) + else: + env.Append(CPPDEFINES=['_3D_DISABLED']) if env['gdscript']: env.Append(CPPDEFINES=['GDSCRIPT_ENABLED']) if env['disable_advanced_gui']: - env.Append(CPPDEFINES=['ADVANCED_GUI_DISABLED']) + if env['tools']: + print("Build option 'disable_advanced_gui=yes' cannot be used with 'tools=yes' (editor), only with 'tools=no' (export template).") + sys.exit(255) + else: + env.Append(CPPDEFINES=['ADVANCED_GUI_DISABLED']) if env['minizip']: env.Append(CPPDEFINES=['MINIZIP_ENABLED']) if env['xml']: |