third_party.pigweed.src/targets/host/host_common.gni
Armando Montanez fb3d3fba79 Don't declare pigweed variables as globals
Require targets to explicitly import pigweed variable definitions. This
moves out some necessary logic from the BUILDCONFIG.gn file.

Change-Id: If9c9fe5a680cc9d897a0e8a55889873be618ed84
2020-06-16 09:50:59 -07:00

40 lines
1.2 KiB
Plaintext

# Copyright 2019 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("//build_overrides/pigweed.gni")
import("$dir_pigweed/pw_vars_default.gni")
declare_args() {
pw_build_host_tools = false
dir_third_party_nanopb = ""
}
# Allow nanopb to be toggled via a build arg on host for easy testing.
if (dir_third_party_nanopb != "") {
pw_protobuf_generators += [ "nanopb" ]
}
# Use logging-based test output on host.
pw_unit_test_main = "$dir_pw_unit_test:logging_main"
# Configure backend for assert facade.
dir_pw_assert_backend = "$dir_pw_assert_basic"
# Configure backend for logging facade.
dir_pw_log_backend = "$dir_pw_log_basic"
# Configure backend for pw_sys_io facade.
dir_pw_sys_io_backend = "$dir_pw_sys_io_stdio"