mirror of
https://github.com/godotengine/godot.git
synced 2024-12-03 17:42:12 +00:00
SCons: Use colored output if available, change "colored"->"verbose"
(cherry picked from commit 2bf4553fe0
)
This commit is contained in:
parent
dcd4b80c13
commit
85a7105345
@ -66,6 +66,8 @@ elif (os.name=="nt"):
|
||||
custom_tools=['mingw']
|
||||
|
||||
env_base=Environment(tools=custom_tools);
|
||||
if 'TERM' in os.environ:
|
||||
env_base['ENV']['TERM'] = os.environ['TERM']
|
||||
env_base.AppendENVPath('PATH', os.getenv('PATH'))
|
||||
env_base.AppendENVPath('PKG_CONFIG_PATH', os.getenv('PKG_CONFIG_PATH'))
|
||||
env_base.global_defaults=global_defaults
|
||||
@ -146,7 +148,7 @@ opts.Add("LINKFLAGS", "Custom flags for the linker");
|
||||
opts.Add('unix_global_settings_path', 'unix-specific path to system-wide settings. Currently only used by templates.','')
|
||||
opts.Add('disable_3d', 'Disable 3D nodes for smaller executable (yes/no)', "no")
|
||||
opts.Add('disable_advanced_gui', 'Disable advance 3D gui nodes and behaviors (yes/no)', "no")
|
||||
opts.Add('colored', 'Enable colored output for the compilation (yes/no)', 'no')
|
||||
opts.Add('verbose', 'Enable verbose output for the compilation (yes/no)', 'yes')
|
||||
opts.Add('deprecated','Enable deprecated features (yes/no)','yes')
|
||||
opts.Add('extra_suffix', 'Custom extra suffix added to the base filename of all generated binary files.', '')
|
||||
opts.Add('vsproj', 'Generate Visual Studio Project. (yes/no)', 'no')
|
||||
@ -335,8 +337,8 @@ if selected_platform in platform_list:
|
||||
if (env['xml']=='yes'):
|
||||
env.Append(CPPFLAGS=['-DXML_ENABLED'])
|
||||
|
||||
if (env['colored']=='yes'):
|
||||
methods.colored(sys,env)
|
||||
if (env['verbose']=='no'):
|
||||
methods.no_verbose(sys,env)
|
||||
|
||||
Export('env')
|
||||
|
||||
|
@ -1414,7 +1414,7 @@ def save_active_platforms(apnames,ap):
|
||||
logow.write(str)
|
||||
|
||||
|
||||
def colored(sys,env):
|
||||
def no_verbose(sys,env):
|
||||
|
||||
#If the output is not a terminal, do nothing
|
||||
if not sys.stdout.isatty():
|
||||
|
@ -91,9 +91,6 @@ def configure(env):
|
||||
env.Append(CPPFLAGS=['-DTYPED_METHOD_BIND'])
|
||||
env["CC"]="clang"
|
||||
env["LD"]="clang++"
|
||||
if (env["colored"]=="yes"):
|
||||
if sys.stdout.isatty():
|
||||
env.Append(CPPFLAGS=["-fcolor-diagnostics"])
|
||||
|
||||
import methods
|
||||
|
||||
|
@ -38,9 +38,6 @@ def configure(env):
|
||||
env["CC"]="clang"
|
||||
env["CXX"]="clang++"
|
||||
env["LD"]="clang++"
|
||||
if (env["colored"]=="yes"):
|
||||
if sys.stdout.isatty():
|
||||
env.Append(CXXFLAGS=["-fcolor-diagnostics"])
|
||||
|
||||
is64=sys.maxsize > 2**32
|
||||
|
||||
|
@ -94,10 +94,6 @@ def configure(env):
|
||||
env.Append(CPPFLAGS=['-DTYPED_METHOD_BIND'])
|
||||
env.extra_suffix=".llvm"
|
||||
|
||||
if (env["colored"]=="yes"):
|
||||
if sys.stdout.isatty():
|
||||
env.Append(CXXFLAGS=["-fcolor-diagnostics"])
|
||||
|
||||
if (env["use_sanitizer"]=="yes"):
|
||||
env.Append(CXXFLAGS=['-fsanitize=address','-fno-omit-frame-pointer'])
|
||||
env.Append(LINKFLAGS=['-fsanitize=address'])
|
||||
|
Loading…
Reference in New Issue
Block a user