third_party.pigweed.src/targets/docs/target_config.gni
Alexei Frolov 4737349f12 Update docs target to only use ARM size reports
This change removes the host gcc and clang toolchains from the docs
target's toolchain size reports and switches the default toolchain to
ARM GCC for traditional size report targets.

Fixed: 122

Change-Id: Iafe7cedb160d16eea6f3d9d4f64671814bb73b80
2020-03-04 01:13:34 +00:00

46 lines
1.6 KiB
Plaintext

# Copyright 2020 The Pigweed Authors
#
# 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
#
# https://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("$dir_pigweed/pw_vars_default.gni")
_arm_bloaty_config = "$dir_pw_boot_armv7m/bloaty_config.bloaty"
# Targets are required to set a default toolchain. Use the Cortex M4 ARM
# toolchain for old pw_size_report targets.
pw_target_toolchain = "$dir_pw_toolchain:arm_gcc_cortex_m4_og"
pw_executable_config.bloaty_config_file = _arm_bloaty_config
# Special upstream build variable to indicate that this is a docs-only target.
pw_is_docs_target = true
# Toolchains to compare in documentation size reports.
pw_size_report_toolchains = [
{
name = "arm-none-eabi-gcc -Og -mcpu=cortex-m4"
target = "$dir_pw_toolchain:arm_gcc_cortex_m4_og"
bloaty_config = _arm_bloaty_config
},
{
name = "arm-none-eabi-gcc -Os -mcpu=cortex-m4"
target = "$dir_pw_toolchain:arm_gcc_cortex_m4_os"
bloaty_config = _arm_bloaty_config
},
{
name = "arm-none-eabi-gcc -O2 -mcpu=cortex-m4"
target = "$dir_pw_toolchain:arm_gcc_cortex_m4_o2"
bloaty_config = _arm_bloaty_config
},
]