# Defines the configuration of siso (next-gen build system)

import("//build/config/gclient_args.gni")

# use_siso_default is default value of use_siso.
# need to match with autoninja's logic.
use_siso_default = false

_is_google_corp_machine = false
if (path_exists("/usr/bin/gcert") ||  # linux
    path_exists("/usr/local/bin/gcert") ||  # mac
    path_exists("/c:/gnubby/bin/gcert.exe")) {
  _is_google_corp_machine = true
}

_is_ninja_used = path_exists(rebase_path(".ninja_deps", root_build_dir))

if (path_exists("//build/config/siso/.sisoenv") &&
    defined(build_with_chromium) && build_with_chromium &&
    _is_google_corp_machine && !_is_ninja_used) {
  use_siso_default = true
}

declare_args() {
  # Placeholder to allow having use_siso in args.gn file.
  # Explicit `use_siso` in args.gn can override default.
  # This is used only for autoninja (to dispatch siso or ninja),
  # and for use_reclient's default.
  use_siso = use_siso_default
}
