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
3 # found in the LICENSE file.
5 import("//testing/test.gni")
7 defines = [ "GN_BUILD" ]
9 static_library("gn_lib") {
11 "action_target_generator.cc",
12 "action_target_generator.h",
17 "binary_target_generator.cc",
18 "binary_target_generator.h",
25 "c_include_iterator.cc",
26 "c_include_iterator.h",
42 "config_values_extractors.cc",
43 "config_values_extractors.h",
44 "config_values_generator.cc",
45 "config_values_generator.h",
46 "copy_target_generator.cc",
47 "copy_target_generator.h",
56 "filesystem_utils.cc",
58 "function_exec_script.cc",
59 "function_foreach.cc",
60 "function_get_label_info.cc",
61 "function_get_path_info.cc",
62 "function_get_target_outputs.cc",
63 "function_process_file_template.cc",
64 "function_read_file.cc",
65 "function_rebase_path.cc",
66 "function_set_default_toolchain.cc",
67 "function_set_defaults.cc",
68 "function_template.cc",
69 "function_toolchain.cc",
70 "function_write_file.cc",
73 "functions_target.cc",
74 "group_target_generator.cc",
75 "group_target_generator.h",
80 "inherited_libraries.cc",
81 "inherited_libraries.h",
82 "input_conversion.cc",
86 "input_file_manager.cc",
87 "input_file_manager.h",
99 "ninja_action_target_writer.cc",
100 "ninja_action_target_writer.h",
101 "ninja_binary_target_writer.cc",
102 "ninja_binary_target_writer.h",
103 "ninja_build_writer.cc",
104 "ninja_build_writer.h",
105 "ninja_copy_target_writer.cc",
106 "ninja_copy_target_writer.h",
107 "ninja_group_target_writer.cc",
108 "ninja_group_target_writer.h",
109 "ninja_target_writer.cc",
110 "ninja_target_writer.h",
111 "ninja_toolchain_writer.cc",
112 "ninja_toolchain_writer.h",
133 "scope_per_file_provider.cc",
134 "scope_per_file_provider.h",
143 "source_file_type.cc",
144 "source_file_type.h",
149 "substitution_list.cc",
150 "substitution_list.h",
151 "substitution_pattern.cc",
152 "substitution_pattern.h",
153 "substitution_type.cc",
154 "substitution_type.h",
155 "substitution_writer.cc",
156 "substitution_writer.h",
161 "target_generator.cc",
162 "target_generator.h",
178 "value_extractors.cc",
179 "value_extractors.h",
188 "//base/third_party/dynamic_annotations",
192 action("last_commit_position") {
193 script = "last_commit_position.py"
195 # This dependency forces a re-run when the code is synced.
197 "//build/util/LASTCHANGE",
200 outfile = "$target_gen_dir/last_commit_position.h"
206 rebase_path("//", root_build_dir),
207 rebase_path(outfile, root_build_dir),
208 "TOOLS_GN_LAST_COMMIT_POSITION_H_",
219 ":last_commit_position",
224 test("gn_unittests") {
226 "action_target_generator_unittest.cc",
228 "builder_unittest.cc",
229 "c_include_iterator_unittest.cc",
230 "command_format_unittest.cc",
231 "config_values_extractors_unittest.cc",
232 "escape_unittest.cc",
233 "exec_process_unittest.cc",
234 "filesystem_utils_unittest.cc",
235 "function_foreach_unittest.cc",
236 "function_get_label_info_unittest.cc",
237 "function_get_path_info_unittest.cc",
238 "function_get_target_outputs_unittest.cc",
239 "function_process_file_template_unittest.cc",
240 "function_rebase_path_unittest.cc",
241 "function_write_file_unittest.cc",
242 "functions_target_unittest.cc",
243 "functions_unittest.cc",
244 "header_checker_unittest.cc",
245 "inherited_libraries_unittest.cc",
246 "input_conversion_unittest.cc",
247 "label_pattern_unittest.cc",
249 "loader_unittest.cc",
250 "ninja_action_target_writer_unittest.cc",
251 "ninja_binary_target_writer_unittest.cc",
252 "ninja_copy_target_writer_unittest.cc",
253 "ninja_group_target_writer_unittest.cc",
254 "ninja_target_writer_unittest.cc",
255 "ninja_toolchain_writer_unittest.cc",
256 "operators_unittest.cc",
257 "parse_tree_unittest.cc",
258 "parser_unittest.cc",
259 "path_output_unittest.cc",
260 "pattern_unittest.cc",
261 "scope_per_file_provider_unittest.cc",
263 "source_dir_unittest.cc",
264 "string_utils_unittest.cc",
265 "substitution_pattern_unittest.cc",
266 "substitution_writer_unittest.cc",
267 "target_generator_unittest.cc",
268 "target_unittest.cc",
269 "template_unittest.cc",
270 "test_with_scope.cc",
272 "tokenizer_unittest.cc",
273 "unique_vector_unittest.cc",
275 "visibility_unittest.cc",
279 "//base/test:run_all_unittests",
280 "//base/test:test_support",
285 executable("generate_test_gn_data") {
287 "generate_test_gn_data.cc",