• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright 2020 The Pigweed Authors
2#
3# Licensed under the Apache License, Version 2.0 (the "License"); you may not
4# use this file except in compliance with the License. You may obtain a copy of
5# the License at
6#
7#     https://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
11# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
12# License for the specific language governing permissions and limitations under
13# the License.
14
15buildconfig = "//BUILDCONFIG.gn"
16import("//build_overrides/pigweed_environment.gni")
17
18# Generate a compilation database for all targets.
19export_compile_commands = [ ":*" ]
20
21default_args = {
22  # Default all upstream Pigweed toolchains to enable pw::span asserts.
23  pw_span_ENABLE_ASSERTS = true
24
25  pw_build_PIP_CONSTRAINTS =
26      [ "//pw_env_setup/py/pw_env_setup/virtualenv_setup/constraint.list" ]
27
28  pw_build_PIP_REQUIREMENTS = [ "//pw_env_setup/py/pw_env_setup/virtualenv_setup/pigweed_upstream_requirements.txt" ]
29
30  # TODO(b/292098416): This should stay false until a cross-platform constraint
31  # file workflow is implemented.
32  pw_build_PYTHON_PIP_INSTALL_REQUIRE_HASHES = false
33
34  pw_build_PYTHON_PIP_INSTALL_FIND_LINKS =
35      [ "${pw_env_setup_CIPD_MSRV_PYTHON}/pip_cache" ]
36
37  pw_toolchain_STATIC_ANALYSIS_SKIP_SOURCES_RES = [
38    # Exclude third party CHRE headers that were downloaded from static analysis.
39    "environment/packages/chre/.*",
40
41    # Exclude third-party headers from static analysis.
42    "third_party/.*",
43
44    # Exclude GoogleTest, which fails some clang-tidy checks.
45    ".*/googletest/src/.*",
46    ".*/googlemock/src/.*",
47
48    # Exclude Boringssl, which fails some clang-tidy checks.
49    ".*/boringssl/src/.*",
50
51    # Exclude mbedtls, which fails some clang-tidy checks.
52    ".*/mbedtls/library/.*",
53
54    "pw_bluetooth_sapphire/.*",
55    "../pw_bluetooth_sapphire/.*",
56  ]
57
58  pw_toolchain_STATIC_ANALYSIS_SKIP_INCLUDE_PATHS = [
59    # Exclude third party CHRE code from static analysis.
60    "../environment/packages/chre/.*",
61
62    # Code generated by third-party tool.
63    "pw_tls_client/generate_test_data",
64
65    # Exclude GoogleTest, which fails some clang-tidy checks.
66    ".*/googletest/include.*",
67    ".*/googlemock/include.*",
68
69    # Exclude Boringssl, which fails some clang-tidy checks.
70    ".*/boringssl/src/include.*",
71
72    # Exclude mbedtls, which fails some clang-tidy checks.
73    ".*/mbedtls/include.*",
74
75    "../pw_bluetooth_sapphire/.*",
76  ]
77}
78