1 # Copyright 2020 The Pigweed Authors
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
7 # https://www.apache.org/licenses/LICENSE-2.0
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
15 import("//build_overrides/pigweed.gni")
17 import("$dir_pw_toolchain/universal_tools.gni")
19 # A dummy toolchain which is set as the default for Pigweed. This is never used;
20 # the top-level BUILD.gn enumerates the toolchains for each build.
23 forward_variables_from(pw_universal_stamp, "*")
27 forward_variables_from(pw_universal_copy, "*")
30 # If the user tries to build a target with the default toolchain, run a script
31 # printing out the error.
32 _bad_toolchain_command =
34 rebase_path("$dir_pw_toolchain/py/pw_toolchain/bad_toolchain.py")
37 command = _bad_toolchain_command
39 [ "{{source_out_dir}}/{{target_output_name}}.{{source_file_part}}.o" ]
43 command = _bad_toolchain_command
45 [ "{{source_out_dir}}/{{target_output_name}}.{{source_file_part}}.o" ]
49 command = _bad_toolchain_command
51 [ "{{source_out_dir}}/{{target_output_name}}.{{source_file_part}}.o" ]
55 command = _bad_toolchain_command
56 outputs = [ "{{output_dir}}/{{target_output_name}}{{output_extension}}" ]
60 command = _bad_toolchain_command
61 outputs = [ "{{output_dir}}/{{target_output_name}}{{output_extension}}" ]
65 command = _bad_toolchain_command
66 outputs = [ "{{output_dir}}/{{target_output_name}}{{output_extension}}" ]