Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1025)

Side by Side Diff: third_party/yasm/yasm_assemble.gni

Issue 375873006: Rename source_prereqs to inputs in the GN build. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « third_party/yasm/BUILD.gn ('k') | tools/gn/target_generator.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2014 The Chromium Authors. All rights reserved. 1 # Copyright 2014 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 # This provides the yasm_assemble() template which uses YASM to assemble 5 # This provides the yasm_assemble() template which uses YASM to assemble
6 # assembly files. 6 # assembly files.
7 # 7 #
8 # Files to be assembled with YASM should have an extension of .asm. 8 # Files to be assembled with YASM should have an extension of .asm.
9 # 9 #
10 # Parameters 10 # Parameters
(...skipping 11 matching lines...) Expand all
22 # source root and the root generated file dir is always added, just like 22 # source root and the root generated file dir is always added, just like
23 # our C++ build sets up. 23 # our C++ build sets up.
24 # 24 #
25 # Example: include_dirs = [ "//some/other/path", target_gen_dir ] 25 # Example: include_dirs = [ "//some/other/path", target_gen_dir ]
26 # 26 #
27 # defines (optional) 27 # defines (optional)
28 # [list of strings] List of defines, as with the native code defines. 28 # [list of strings] List of defines, as with the native code defines.
29 # 29 #
30 # Example: defines = [ "FOO", "BAR=1" ] 30 # Example: defines = [ "FOO", "BAR=1" ]
31 # 31 #
32 # source_prereqs, deps, visibility (optional) 32 # inputs, deps, visibility (optional)
33 # These have the same meaning as in an action. 33 # These have the same meaning as in an action.
34 # 34 #
35 # Example 35 # Example
36 # 36 #
37 # yasm_assemble("my_yasm_target") { 37 # yasm_assemble("my_yasm_target") {
38 # sources = [ 38 # sources = [
39 # "ultra_optimized_awesome.asm", 39 # "ultra_optimized_awesome.asm",
40 # ] 40 # ]
41 # include_dirs = [ "assembly_include" ] 41 # include_dirs = [ "assembly_include" ]
42 # } 42 # }
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
108 108
109 action_name = "${target_name}_action" 109 action_name = "${target_name}_action"
110 source_set_name = target_name 110 source_set_name = target_name
111 111
112 action_foreach(action_name) { 112 action_foreach(action_name) {
113 visibility = ":$source_set_name" # Only the source set can depend on this. 113 visibility = ":$source_set_name" # Only the source set can depend on this.
114 114
115 script = "//third_party/yasm/run_yasm.py" 115 script = "//third_party/yasm/run_yasm.py"
116 sources = invoker.sources 116 sources = invoker.sources
117 117
118 if (defined(invoker.source_prereqs)) { 118 if (defined(invoker.inputs)) {
119 source_prereqs = invoker.source_prereqs 119 inputs = invoker.inputs
120 } 120 }
121 121
122 # Executable (first in the args). The binary might be in the root build dir 122 # Executable (first in the args). The binary might be in the root build dir
123 # (no cross-compiling) or in a toolchain-specific subdirectory of that 123 # (no cross-compiling) or in a toolchain-specific subdirectory of that
124 # (when cross-compiling). 124 # (when cross-compiling).
125 yasm_label = "//third_party/yasm($host_toolchain)" 125 yasm_label = "//third_party/yasm($host_toolchain)"
126 args = [ "./" + # Force current dir. 126 args = [ "./" + # Force current dir.
127 rebase_path(get_label_info(yasm_label, "root_out_dir") + "/yasm", 127 rebase_path(get_label_info(yasm_label, "root_out_dir") + "/yasm",
128 root_build_dir) 128 root_build_dir)
129 ] 129 ]
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 source_set(source_set_name) { 178 source_set(source_set_name) {
179 if (defined(invoker.visibility)) { 179 if (defined(invoker.visibility)) {
180 visibility = invoker.visibility 180 visibility = invoker.visibility
181 } 181 }
182 182
183 sources = get_target_outputs(":$action_name") 183 sources = get_target_outputs(":$action_name")
184 184
185 deps = [ ":$action_name" ] 185 deps = [ ":$action_name" ]
186 } 186 }
187 } 187 }
OLDNEW
« no previous file with comments | « third_party/yasm/BUILD.gn ('k') | tools/gn/target_generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698