blob: 3cd4a1e5fff32fbfc42358f36df958cce1efd416 [file] [log] [blame]
Alexei Frolov1a82c142019-10-31 17:37:12 -07001# Copyright 2019 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
15import("modules.gni")
16
17# Default configs to use for all binary build targets.
18_default_common_binary_configs = [
19 "$dir_pw_build:reduced_size",
20 "$dir_pw_build:strict_warnings",
21]
22
23set_defaults("executable") {
24 configs = _default_common_binary_configs
25}
26
27set_defaults("static_library") {
28 configs = _default_common_binary_configs
29}
30
31set_defaults("shared_library") {
32 configs = _default_common_binary_configs
33}
34
35set_defaults("source_set") {
36 configs = _default_common_binary_configs
37}
38
39declare_args() {
40 # The name of the GN template used to build Pigweed executables.
41 pw_executable_target_type = "executable"
42
43 # Path to the .gni file in which the pw_executable_target_type template is
44 # defined. Empty string if using a GN primitive.
45 pw_executable_target_path = ""
46}
47
48set_default_toolchain("$dir_pw_toolchain:arm_gcc_cortex_m4_og")