# Copyright (C) 2017 The Android Open Source Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

import("//build_overrides/build.gni")
import("wasm_vars.gni")

# Summary of our typical build configurations:

# 1. Standalone builds
#    build_with_chromium = false
#    is_perfetto_build_generator = false
#    perfetto_build_standalone = true
#    perfetto_build_with_android = false
#    perfetto_build_with_embedder = false

# 2. Android tree builds
#    build_with_chromium = false
#    is_perfetto_build_generator = true
#    perfetto_build_standalone = false
#    perfetto_build_with_android = true
#    perfetto_build_with_embedder = false

# 3. Chromium tree builds
#    build_with_chromium = true
#    is_perfetto_build_generator = false
#    perfetto_build_standalone = false
#    perfetto_build_with_android = false
#    perfetto_build_with_embedder = true

# 4. Builds in other embedder trees (e.g. V8 standalone)
#    build_with_chromium = false
#    is_perfetto_build_generator = false
#    perfetto_build_standalone = false
#    perfetto_build_with_android = false
#    perfetto_build_with_embedder = true

# 5. Amalgamated sources (Client library)
#    build_with_chromium = false
#    is_perfetto_build_generator = true
#    perfetto_build_standalone = false
#    perfetto_build_with_android = false
#    perfetto_build_with_embedder = true

# +----------------------------------------------------------------------------+
# | Toolchain / environment related configuration                              |
# +----------------------------------------------------------------------------+
# This section contains a bunch of variables that are related with the toolchain
# and the build environment. Only tools/gen_xxx should customize them.

# Note that |build_with_chromium| is a global convention used by several
# projects, set outside of our control.

# Chromium sets this to true in its //build_overrides/build.gni.
if (!defined(build_with_chromium)) {
  build_with_chromium = false
}

if (!defined(is_nacl)) {
  is_nacl = false
}

if (!defined(is_gcc)) {
  is_gcc = !is_clang && !is_win
}

declare_args() {
  # The Android blueprint file generator set this to true (as well as
  # is_perfetto_build_generator). This is just about being built in the
  # Android tree (AOSP and internal) and is NOT related with the target OS.
  # In standalone Android builds and Chromium Android builds, this is false.
  perfetto_build_with_android = false

  # All the tools/gen_* scripts set this to true. This is mainly used to locate
  # .gni files from //gn rather than //build.
  is_perfetto_build_generator = false

  # This is for override via `gn args` (e.g. for tools/gen_xxx). Embedders
  # based on GN (e.g. v8) should NOT set this and instead directly sets
  # perfetto_build_with_embedder=true in their GN files.
  is_perfetto_embedder = false
}

# This can be overridden by embedders (e.g. v8) in their .gn(i) files. This must
# be different from the GN args flag (is_perfetto_embedder) because of the way
# GN works.
if (!defined(perfetto_build_with_embedder)) {
  perfetto_build_with_embedder = build_with_chromium || is_perfetto_embedder
}

perfetto_build_standalone =
    !perfetto_build_with_android && !build_with_chromium &&
    !perfetto_build_with_embedder

# Only relevant for GN builds. Sets the path where perfetto lives. This is //
# for standalone builds and //third_party/perfetto/ in embedders. The embedder
# can override it in its GN files.
if (perfetto_build_standalone || is_perfetto_build_generator) {
  perfetto_root_path = "//"
  import("//gn/standalone/android.gni")  # For android_api_level
  import("//gn/standalone/sanitizers/vars.gni")  # For is_fuzzer
} else if (!defined(perfetto_root_path)) {
  perfetto_root_path = "//third_party/perfetto/"
  import("//build/config/android/config.gni")  # For android_api_level
}

# Whether the ftrace producer and the service should be started
# by the integration test or assumed to be running.
# If we're building in the Android tree, we expect that the testing infra
# will start the binaries in the system image before the tests are run.
# In all other cases (i.e. when true), a temporary in-process instance will be
# brought up by our own integrationtest harness.
start_daemons_for_testing = !perfetto_build_with_android

# +----------------------------------------------------------------------------+
# | Tunable build variables for embedders                                      |
# +----------------------------------------------------------------------------+
# The variables in this section allow embedders to enable/disable features
# at the build-system level. This allows to opt-in into the various services
# and tools.

perfetto_force_dlog_default = ""
if (build_with_chromium) {
  perfetto_force_dlog_default = "off"
}

declare_args() {
  # Enables build of platform-wide tracing services (traced, traced_probes)
  # and executables (perfetto_cmd, trigger_perfetto).
  # When disabled, only the client library and other auxiliary tools can be
  # built (for Chromium and other GN embedders).
  # Note that traced_probes is further conditioned by the GN variable
  # enable_perfetto_traced_probes, in the declare_args() section below.
  enable_perfetto_platform_services =
      perfetto_build_standalone || perfetto_build_with_android

  # Allow the embedder to use the IPC layer. In turn this allows to use the
  # system backend in the client library.
  # This includes building things that rely on POSIX sockets, this places
  # limitations on the supported operating systems.
  # For now the IPC layer is conservatively not enabled on Chromium+Windows
  # builds.
  enable_perfetto_ipc =
      !is_nacl && (perfetto_build_standalone || perfetto_build_with_android ||
                   (build_with_chromium && !is_win) || is_fuchsia)

  # Makes the heap profiling daemon target reachable. It works only on Android,
  # but is built on Linux as well for test/compiler coverage.
  # On Android, it requires API level 26 due to libunwindstack.
  enable_perfetto_heapprofd =
      perfetto_build_with_android ||
      (perfetto_build_standalone && is_clang &&
       (is_linux || (is_android && android_api_level >= 26)))

  # Build the perf event profiler (traced_perf).
  # TODO(rsavitski): figure out how to make the android-core dependencies build
  # under gcc (_Atomic and other issues).
  enable_perfetto_traced_perf =
      perfetto_build_with_android ||
      (perfetto_build_standalone && is_clang &&
       (is_linux || (is_android && android_api_level >= 29)))

  # The Trace Processor: offline analytical engine to process traces and compute
  # metrics using a SQL engine.
  if (!defined(enable_perfetto_trace_processor)) {
    enable_perfetto_trace_processor =
        perfetto_build_standalone || build_with_chromium ||
        is_perfetto_build_generator
  }

  # Enables base::Watchdog. Is supported only on Linux-based platforms in
  # standalone GN builds (NOT in bazel/blaze).
  # gn/BUILD.gn further restricts this to OS_LINUX || OS_ANDROID when generating
  # the perfetto_build_flags.h header.
  enable_perfetto_watchdog =
      perfetto_build_with_android ||
      (perfetto_build_standalone && !is_perfetto_build_generator)

  # Misc host executable under tools/.
  enable_perfetto_tools =
      perfetto_build_standalone || perfetto_build_with_android

  enable_perfetto_unittests = perfetto_build_standalone ||
                              build_with_chromium || perfetto_build_with_android

  enable_perfetto_integration_tests =
      perfetto_build_standalone || perfetto_build_with_android

  enable_perfetto_benchmarks = perfetto_build_standalone && !is_win

  enable_perfetto_fuzzers =
      perfetto_build_standalone && defined(is_fuzzer) && is_fuzzer

  # Enables the write_version_header.py tool that generates a .h that contains a
  # macro with the current git revision and latest release version from
  # CHANGELOG. If false base/version.h will return "unknown".
  enable_perfetto_version_gen =
      perfetto_build_standalone || is_perfetto_build_generator ||
      perfetto_build_with_android

  # Only for local development. When true the binaries (perfetto, traced, ...)
  # are monolithic and don't use a common shared library. This is mainly to
  # avoid LD_LIBRARY_PATH dances when testing locally.
  # On Windows we default to monolithic executables, because pairing
  # dllexport/import adds extra complexity for little benefit. Te only reason
  # for monolithic_binaries=false is saving binary size, which matters mainly on
  # Android. See also comments on PERFETTO_EXPORT_ENTRYPOINT in compiler.h.
  monolithic_binaries = !perfetto_build_with_android && (is_win || is_mac)

  # Whether DLOG should be enabled on debug builds (""), all builds ("on"), or
  # none ("off"). We disable it by default for embedders to avoid spamming their
  # console.
  perfetto_force_dlog = perfetto_force_dlog_default

  # Whether DCHECKs should be enabled or not. Values: "on" | "off" | "".
  # By default ("") DCHECKs are enabled only:
  # - If DCHECK_ALWAYS_ON is defined (which is mainly a Chromium-ism).
  # - On debug builds (i.e. if NDEBUG is NOT defined) but only in Chromium,
  #   Android and standalone builds.
  # - On all other builds (e.g., SDK) it's off regardless of NDEBUG (unless
  #   DCHECK_ALWAYS_ON is defined).
  # See base/logging.h for the implementation of all this.
  perfetto_force_dcheck = ""

  # Installs a signal handler for the most common crash signals which unwinds
  # the stack and prints the stack trace on stderr. Requires a dependency on
  # libbacktrace when enabled.
  enable_perfetto_stderr_crash_dump =
      is_debug && perfetto_build_standalone && !is_wasm && !is_win

  # Enables more aggressive compiler flags that assume recent Intel CPUs.
  # Runtime checks during initialization will print an error message and exit
  # if the CPU doesn't support those flags.
  # Don't enable by default for MacOS. Old Intel Macs as used in CIs
  # etc don't have the fancy CPU instructions (i.e. AVX2) this implies.
  enable_perfetto_x64_cpu_opt =
      current_cpu == "x64" && is_linux && !is_wasm &&
      perfetto_build_standalone && !is_perfetto_build_generator
}

declare_args() {
  # When false, it disables system backend consumer support in the Perfetto SDK.
  # Saves ~300KB binary size.
  if (!defined(enable_perfetto_system_consumer)) {
    enable_perfetto_system_consumer = enable_perfetto_ipc
  }
}

declare_args() {
  perfetto_enable_git_rev_version_header =
      enable_perfetto_version_gen && perfetto_build_standalone &&
      !is_perfetto_build_generator

  # The traced_probes daemon is very Linux-specific, as it depends on ftrace and
  # various /proc interfaces. There is no point making its code platform-neutral
  # as it won't do anything useful on Windows.
  # The only reason why we still build it on Mac OS is to be able to run the
  # unittests there and making dev on mac less cumbersome. The traced_probes
  # code happens to build cleanly and for now the mainteinance cost on Mac is
  # extremely low.
  enable_perfetto_traced_probes = enable_perfetto_platform_services && !is_win

  # The relay service is enabled when platform services are enabled.
  # TODO(chinglinyu) check if we can enable on Windows.
  enable_perfetto_traced_relay = enable_perfetto_platform_services && !is_win

  # Whether info-level logging is enabled.
  perfetto_verbose_logs_enabled =
      !build_with_chromium || perfetto_force_dlog == "on"

  # Enables the SQL query layer of trace processor.
  enable_perfetto_trace_processor_sqlite =
      enable_perfetto_trace_processor &&
      (build_with_chromium || !perfetto_build_with_embedder)

  # Enables the optional SQLite percentile module.
  enable_perfetto_trace_processor_percentile =
      enable_perfetto_trace_processor &&
      (perfetto_build_standalone || perfetto_build_with_android)

  # Enables the REPL interactive prompt in the trace processor.
  enable_perfetto_trace_processor_linenoise =
      perfetto_build_standalone && enable_perfetto_trace_processor &&
      (is_linux || is_android || is_mac)

  # Enables JSON support in the trace processor. Required for JSON trace import
  # and export.
  enable_perfetto_trace_processor_json =
      enable_perfetto_trace_processor && !perfetto_build_with_android

  # Enables the support for importing profiles from the MacOS Instruments app.
  # Requires a dependency on libexpat for XML parsing.
  # Disabled in chromium due to some fuzzer related build failure (b/363347029).
  enable_perfetto_trace_processor_mac_instruments =
      enable_perfetto_trace_processor &&
      (perfetto_build_standalone || perfetto_build_with_android ||
       is_perfetto_build_generator)

  # Enables httpd RPC support in the trace processor.
  # Further per-OS conditionals are applied in gn/BUILD.gn.
  # Chromium+Win: httpd support depends on enable_perfetto_ipc, which is not
  # enabled on Chromium+Win for now (see a comment there).
  enable_perfetto_trace_processor_httpd =
      enable_perfetto_trace_processor &&
      (perfetto_build_standalone || perfetto_build_with_android ||
       (build_with_chromium && !is_win))

  # Enables Zlib support. This is used to compress traces (by the tracing
  # service and by the "perfetto" cmdline client) and to decompress traces (by
  # trace_processor).
  enable_perfetto_zlib =
      enable_perfetto_trace_processor || enable_perfetto_platform_services

  # Enables function name demangling using sources from llvm. Otherwise
  # trace_processor falls back onto using the c++ runtime demangler, which
  # typically handles only itanium mangling.
  # llvm-demangle is incompatible with GCC and can be used only when building
  # with clang.
  enable_perfetto_llvm_demangle =
      is_clang && enable_perfetto_trace_processor && perfetto_build_standalone

  # Enables gRPC in the Perfetto codebase. gRPC significantly increases build
  # times and the general footprint of Perfetto. As it only required for
  # BigTrace and even then only to build the final ready-to-ship binary, don't
  # enable this by default.
  enable_perfetto_grpc = false
}

declare_args() {
  # Enables the traceconv tool.
  enable_perfetto_traceconv =
      enable_perfetto_tools && enable_perfetto_trace_processor_sqlite

  # Allows to build the UI (TypeScript/ HTML / WASM)
  enable_perfetto_ui =
      perfetto_build_standalone && enable_perfetto_trace_processor_sqlite &&
      host_os != "win"

  # Allows to build the perfetto.dev website.
  # WARNING: if this flag is enabled, the build performs globbing at generation
  # time. Incremental builds that add/remove files will not be supported without
  # rerunning gn.
  enable_perfetto_site = false

  # Check that the merged perfetto_trace.proto can be translated to a C++ lite
  # proto and compiled. This is disabled by default because it's expensive (it
  # can take a couple of minutes).
  enable_perfetto_merged_protos_check = false

  # Skip buildtools dependency checks (needed for ChromeOS).
  skip_buildtools_check = false

  # Used by CrOS builds. Uses pkg-config to determine the appropriate flags
  # for including and linking system libraries.
  #   set `host_pkg_config` to the `BUILD_PKG_CONFIG` and
  #   set `pkg_config` to the target `PKG_CONFIG`.
  # Note: that if this is enabled `perfetto_use_system_protobuf` should be also.
  perfetto_use_pkgconfig = false

  # Used by CrOS system builds. Uses the system version of protobuf
  # from /usr/include instead of the hermetic one.
  perfetto_use_system_protobuf = false

  # Used by CrOS system builds. Uses the system version of sqlite
  # from /usr/include instead of the hermetic one.
  perfetto_use_system_sqlite = false

  perfetto_use_system_zlib = false
}

if (is_win) {
  # clang-cl
  perfetto_isystem_cflag = "/I"
} else {
  perfetto_isystem_cflag = "-isystem"
}

# +---------------------------------------------------------------------------+
# | Cross-checks                                                              |
# +---------------------------------------------------------------------------+

# Exactly one between build_with_android, build_standalone and
# build_with_embedder must be true.
assert(perfetto_build_standalone || perfetto_build_with_android ||
       perfetto_build_with_embedder)
assert(!(perfetto_build_with_android && perfetto_build_standalone))
assert(!(perfetto_build_with_embedder && perfetto_build_standalone))
assert(!(perfetto_build_with_android && perfetto_build_with_embedder))

# If |build_with_chromium| is true then also |perfetto_build_with_embedder|
# must be true
assert(!build_with_chromium || perfetto_build_with_embedder)

# If |perfetto_build_with_android| is true then also
# |is_perfetto_build_generator| must be true.
assert(!perfetto_build_with_android || is_perfetto_build_generator)

# We should never end up in a state where is_perfetto_embedder=true but
# perfetto_build_with_embedder=false.
assert(!is_perfetto_embedder || perfetto_build_with_embedder)

# The monolithic binaries is not supported when building in the Android tree.
assert(!monolithic_binaries || !perfetto_build_with_android)

# Watchdog must be on in Android builds.
assert(enable_perfetto_watchdog || !perfetto_build_with_android)

assert(perfetto_force_dlog == "" || perfetto_force_dlog == "on" ||
       perfetto_force_dlog == "off")

# If enable_perfetto_traced_probes is set, enable_perfetto_platform_services
# must be set as well. Doesn't make sense to build traced_probes without the
# rest. traced_probes integration tests depend on traced.
assert(!enable_perfetto_traced_probes || enable_perfetto_platform_services)

# |perfetto_use_pkgconfig| changes the behavior of
# |perfetto_use_system_protobuf|, so if perfetto_use_pkgconfig is set,
# |perfetto_use_system_protobuf| must be set.
assert(!perfetto_use_pkgconfig || perfetto_use_system_protobuf,
       "perfetto_use_pkgconfig requires perfetto_use_system_protobuf")
