tree: ea7db2e3e72b161fe405dd7c17c1fa0bd975b7d4 [path history] [tgz]
  1. bin/
  2. bootstrap/
  3. docs/
  4. example/
  5. format_test_data/
  6. misc/
  7. tutorial/
  8. action_target_generator.cc
  9. action_target_generator.h
  10. action_target_generator_unittest.cc
  11. action_values.cc
  12. action_values.h
  13. analyzer.cc
  14. analyzer.h
  15. analyzer_unittest.cc
  16. args.cc
  17. args.h
  18. args_unittest.cc
  19. binary_target_generator.cc
  20. binary_target_generator.h
  21. BUILD.gn
  22. build_settings.cc
  23. build_settings.h
  24. builder.cc
  25. builder.h
  26. builder_record.cc
  27. builder_record.h
  28. builder_unittest.cc
  29. bundle_data.cc
  30. bundle_data.h
  31. bundle_data_target_generator.cc
  32. bundle_data_target_generator.h
  33. bundle_file_rule.cc
  34. bundle_file_rule.h
  35. c_include_iterator.cc
  36. c_include_iterator.h
  37. c_include_iterator_unittest.cc
  38. command_analyze.cc
  39. command_args.cc
  40. command_check.cc
  41. command_clean.cc
  42. command_desc.cc
  43. command_format.cc
  44. command_format.h
  45. command_format_unittest.cc
  46. command_gen.cc
  47. command_help.cc
  48. command_ls.cc
  49. command_path.cc
  50. command_refs.cc
  51. commands.cc
  52. commands.h
  53. config.cc
  54. config.h
  55. config_unittest.cc
  56. config_values.cc
  57. config_values.h
  58. config_values_extractors.cc
  59. config_values_extractors.h
  60. config_values_extractors_unittest.cc
  61. config_values_generator.cc
  62. config_values_generator.h
  63. copy_target_generator.cc
  64. copy_target_generator.h
  65. create_bundle_target_generator.cc
  66. create_bundle_target_generator.h
  67. DEPS
  68. deps_iterator.cc
  69. deps_iterator.h
  70. desc_builder.cc
  71. desc_builder.h
  72. eclipse_writer.cc
  73. eclipse_writer.h
  74. err.cc
  75. err.h
  76. escape.cc
  77. escape.h
  78. escape_unittest.cc
  79. exec_process.cc
  80. exec_process.h
  81. exec_process_unittest.cc
  82. filesystem_utils.cc
  83. filesystem_utils.h
  84. filesystem_utils_unittest.cc
  85. function_exec_script.cc
  86. function_foreach.cc
  87. function_foreach_unittest.cc
  88. function_forward_variables_from.cc
  89. function_forward_variables_from_unittest.cc
  90. function_get_label_info.cc
  91. function_get_label_info_unittest.cc
  92. function_get_path_info.cc
  93. function_get_path_info_unittest.cc
  94. function_get_target_outputs.cc
  95. function_get_target_outputs_unittest.cc
  96. function_process_file_template.cc
  97. function_process_file_template_unittest.cc
  98. function_read_file.cc
  99. function_rebase_path.cc
  100. function_rebase_path_unittest.cc
  101. function_set_default_toolchain.cc
  102. function_set_defaults.cc
  103. function_template.cc
  104. function_template_unittest.cc
  105. function_toolchain.cc
  106. function_toolchain_unittest.cc
  107. function_write_file.cc
  108. function_write_file_unittest.cc
  109. functions.cc
  110. functions.h
  111. functions_target.cc
  112. functions_target_unittest.cc
  113. functions_unittest.cc
  114. gn_main.cc
  115. group_target_generator.cc
  116. group_target_generator.h
  117. header_checker.cc
  118. header_checker.h
  119. header_checker_unittest.cc
  120. import_manager.cc
  121. import_manager.h
  122. inherited_libraries.cc
  123. inherited_libraries.h
  124. inherited_libraries_unittest.cc
  125. input_conversion.cc
  126. input_conversion.h
  127. input_conversion_unittest.cc
  128. input_file.cc
  129. input_file.h
  130. input_file_manager.cc
  131. input_file_manager.h
  132. item.cc
  133. item.h
  134. json_project_writer.cc
  135. json_project_writer.h
  136. label.cc
  137. label.h
  138. label_pattern.cc
  139. label_pattern.h
  140. label_pattern_unittest.cc
  141. label_ptr.h
  142. label_unittest.cc
  143. last_commit_position.py
  144. lib_file.cc
  145. lib_file.h
  146. loader.cc
  147. loader.h
  148. loader_unittest.cc
  149. location.cc
  150. location.h
  151. ninja_action_target_writer.cc
  152. ninja_action_target_writer.h
  153. ninja_action_target_writer_unittest.cc
  154. ninja_binary_target_writer.cc
  155. ninja_binary_target_writer.h
  156. ninja_binary_target_writer_unittest.cc
  157. ninja_build_writer.cc
  158. ninja_build_writer.h
  159. ninja_build_writer_unittest.cc
  160. ninja_bundle_data_target_writer.cc
  161. ninja_bundle_data_target_writer.h
  162. ninja_bundle_data_target_writer_unittest.cc
  163. ninja_copy_target_writer.cc
  164. ninja_copy_target_writer.h
  165. ninja_copy_target_writer_unittest.cc
  166. ninja_create_bundle_target_writer.cc
  167. ninja_create_bundle_target_writer.h
  168. ninja_create_bundle_target_writer_unittest.cc
  169. ninja_group_target_writer.cc
  170. ninja_group_target_writer.h
  171. ninja_group_target_writer_unittest.cc
  172. ninja_target_writer.cc
  173. ninja_target_writer.h
  174. ninja_target_writer_unittest.cc
  175. ninja_toolchain_writer.cc
  176. ninja_toolchain_writer.h
  177. ninja_toolchain_writer_unittest.cc
  178. ninja_utils.cc
  179. ninja_utils.h
  180. ninja_writer.cc
  181. ninja_writer.h
  182. operators.cc
  183. operators.h
  184. operators_unittest.cc
  185. ordered_set.h
  186. output_file.cc
  187. output_file.h
  188. OWNERS
  189. parse_node_value_adapter.cc
  190. parse_node_value_adapter.h
  191. parse_tree.cc
  192. parse_tree.h
  193. parse_tree_unittest.cc
  194. parser.cc
  195. parser.h
  196. parser_fuzzer.cc
  197. parser_unittest.cc
  198. path_output.cc
  199. path_output.h
  200. path_output_unittest.cc
  201. pattern.cc
  202. pattern.h
  203. pattern_unittest.cc
  204. pool.cc
  205. pool.h
  206. qt_creator_writer.cc
  207. qt_creator_writer.h
  208. README.md
  209. runtime_deps.cc
  210. runtime_deps.h
  211. runtime_deps_unittest.cc
  212. scheduler.cc
  213. scheduler.h
  214. scope.cc
  215. scope.h
  216. scope_per_file_provider.cc
  217. scope_per_file_provider.h
  218. scope_per_file_provider_unittest.cc
  219. scope_unittest.cc
  220. settings.cc
  221. settings.h
  222. setup.cc
  223. setup.h
  224. source_dir.cc
  225. source_dir.h
  226. source_dir_unittest.cc
  227. source_file.cc
  228. source_file.h
  229. source_file_type.cc
  230. source_file_type.h
  231. source_file_unittest.cc
  232. standard_out.cc
  233. standard_out.h
  234. string_utils.cc
  235. string_utils.h
  236. string_utils_unittest.cc
  237. substitution_list.cc
  238. substitution_list.h
  239. substitution_pattern.cc
  240. substitution_pattern.h
  241. substitution_pattern_unittest.cc
  242. substitution_type.cc
  243. substitution_type.h
  244. substitution_writer.cc
  245. substitution_writer.h
  246. substitution_writer_unittest.cc
  247. switches.cc
  248. switches.h
  249. target.cc
  250. target.h
  251. target_generator.cc
  252. target_generator.h
  253. target_unittest.cc
  254. template.cc
  255. template.h
  256. template_unittest.cc
  257. test_with_scope.cc
  258. test_with_scope.h
  259. token.cc
  260. token.h
  261. tokenizer.cc
  262. tokenizer.h
  263. tokenizer_unittest.cc
  264. tool.cc
  265. tool.h
  266. toolchain.cc
  267. toolchain.h
  268. trace.cc
  269. trace.h
  270. unique_vector.h
  271. unique_vector_unittest.cc
  272. value.cc
  273. value.h
  274. value_extractors.cc
  275. value_extractors.h
  276. value_unittest.cc
  277. variables.cc
  278. variables.h
  279. visibility.cc
  280. visibility.h
  281. visibility_unittest.cc
  282. visual_studio_utils.cc
  283. visual_studio_utils.h
  284. visual_studio_utils_unittest.cc
  285. visual_studio_writer.cc
  286. visual_studio_writer.h
  287. visual_studio_writer_unittest.cc
  288. xcode_object.cc
  289. xcode_object.h
  290. xcode_object_unittest.cc
  291. xcode_writer.cc
  292. xcode_writer.h
  293. xml_element_writer.cc
  294. xml_element_writer.h
  295. xml_element_writer_unittest.cc
tools/gn/README.md

What is GN?

GN is a meta-build system that generates Ninja build files so that you can build Chromium with Ninja.

Why did you switch from GYP?

  1. We believe GN files are more readable and more maintainable than GYP files.
  2. GN is fast:
  • GN is 20x faster than GYP.
  • GN supports automatically re-running itself as needed by Ninja as part of the build. This eliminates the need to remember to re-run GN when you change a build file.
  1. GN gives us better tools for enforcing dependencies (see gn check and the visibility, public_deps, and data_deps options for some examples).
  2. GN gives us tools for querying the build graph; you can ask “what does X depend on” and “who depends on Y”, for example.

What's the status of the GYP->GN migration for Chromium?

As of Oct 2016:

  • All of the Chromium builds have been switched over.
  • Nearly all of the GYP files have been deleted from the Chromium repos.
  • You can no longer build with GYP as a result.
  • There are still some GYP files in place for the “Closure Compilation” builders that need to be converted over.
  • Some related projects (e.g., V8, Skia) may still support GYP for their own reasons.
  • We're still cleaning up some odds and ends like making gclient not still use GYP_DEFINES.

I want more info on GN!

Read these links: