mirror of
https://github.com/godotengine/godot.git
synced 2024-11-21 11:32:13 +00:00
Merge pull request #95504 from mihe/ninja-options
Expose more Ninja-related build options
This commit is contained in:
commit
7ce65f54be
@ -234,6 +234,8 @@ opts.Add(BoolVariable("dev_mode", "Alias for dev options: verbose=yes warnings=e
|
||||
opts.Add(BoolVariable("tests", "Build the unit tests", False))
|
||||
opts.Add(BoolVariable("fast_unsafe", "Enable unsafe options for faster rebuilds", False))
|
||||
opts.Add(BoolVariable("ninja", "Use the ninja backend for faster rebuilds", False))
|
||||
opts.Add(BoolVariable("ninja_auto_run", "Run ninja automatically after generating the ninja file", True))
|
||||
opts.Add("ninja_file", "Path to the generated ninja file", "build.ninja")
|
||||
opts.Add(BoolVariable("compiledb", "Generate compilation DB (`compile_commands.json`) for external tools", False))
|
||||
opts.Add(BoolVariable("verbose", "Enable verbose output for the compilation", False))
|
||||
opts.Add(BoolVariable("progress", "Show a progress indicator during compilation", True))
|
||||
@ -1031,13 +1033,10 @@ if env["ninja"]:
|
||||
Exit(255)
|
||||
|
||||
SetOption("experimental", "ninja")
|
||||
env["NINJA_FILE_NAME"] = env["ninja_file"]
|
||||
env["NINJA_DISABLE_AUTO_RUN"] = not env["ninja_auto_run"]
|
||||
env.Tool("ninja")
|
||||
|
||||
# By setting this we allow the user to run ninja by themselves with all
|
||||
# the flags they need, as apparently automatically running from scons
|
||||
# is way slower.
|
||||
SetOption("disable_execute_ninja", True)
|
||||
|
||||
# Threads
|
||||
if env["threads"]:
|
||||
env.Append(CPPDEFINES=["THREADS_ENABLED"])
|
||||
|
Loading…
Reference in New Issue
Block a user