OLD | NEW |
1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 # ============================================================================= | 5 # ============================================================================= |
6 # PLATFORM SELECTION | 6 # PLATFORM SELECTION |
7 # ============================================================================= | 7 # ============================================================================= |
8 # | 8 # |
9 # There are two main things to set: "os" and "cpu". The "toolchain" is the name | 9 # There are two main things to set: "os" and "cpu". The "toolchain" is the name |
10 # of the GN thing that encodes combinations of these things. | 10 # of the GN thing that encodes combinations of these things. |
(...skipping 586 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
597 # on multiple platforms, but this whole block of code (how we define | 597 # on multiple platforms, but this whole block of code (how we define |
598 # host_toolchain) needs to be reworked regardless to key off of host_os | 598 # host_toolchain) needs to be reworked regardless to key off of host_os |
599 # and host_cpu rather than the is_* variables. | 599 # and host_cpu rather than the is_* variables. |
600 host_toolchain = "//build/toolchain/linux:clang_x64" | 600 host_toolchain = "//build/toolchain/linux:clang_x64" |
601 } | 601 } |
602 | 602 |
603 # ============================================================================== | 603 # ============================================================================== |
604 # COMPONENT SETUP | 604 # COMPONENT SETUP |
605 # ============================================================================== | 605 # ============================================================================== |
606 | 606 |
607 # TODO(brettw): Convert component_mode to being a non-exported variable | |
608 # ("_component_mode" instead) once ICU's BUILD.gn file is updated to use | |
609 # is_component_build instead. | |
610 if (is_component_build) { | 607 if (is_component_build) { |
611 component_mode = "shared_library" | 608 _component_mode = "shared_library" |
612 } else { | 609 } else { |
613 component_mode = "source_set" | 610 _component_mode = "source_set" |
614 } | 611 } |
615 | |
616 template("component") { | 612 template("component") { |
617 target(component_mode, target_name) { | 613 target(_component_mode, target_name) { |
618 forward_variables_from(invoker, "*") | 614 forward_variables_from(invoker, "*") |
619 | 615 |
620 # All shared libraries must have the sanitizer deps to properly link in | 616 # All shared libraries must have the sanitizer deps to properly link in |
621 # asan mode (this target will be empty in other cases). | 617 # asan mode (this target will be empty in other cases). |
622 if (!defined(deps)) { | 618 if (!defined(deps)) { |
623 deps = [] | 619 deps = [] |
624 } | 620 } |
625 deps += [ "//build/config/sanitizers:deps" ] | 621 deps += [ "//build/config/sanitizers:deps" ] |
626 } | 622 } |
627 } | 623 } |
OLD | NEW |