mt-libuv 4.1.01 → 4.1.02

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2091) hide show
  1. checksums.yaml +4 -4
  2. data/ext/gyp/.gitignore +1 -0
  3. data/ext/gyp/AUTHORS +17 -0
  4. data/ext/gyp/DEPS +23 -0
  5. data/ext/gyp/LICENSE +27 -0
  6. data/ext/gyp/OWNERS +1 -0
  7. data/ext/gyp/PRESUBMIT.py +125 -0
  8. data/ext/gyp/README.md +5 -0
  9. data/ext/gyp/buildbot/buildbot_run.py +138 -0
  10. data/ext/gyp/buildbot/commit_queue/OWNERS +6 -0
  11. data/ext/gyp/buildbot/commit_queue/README +3 -0
  12. data/ext/gyp/buildbot/commit_queue/cq_config.json +15 -0
  13. data/ext/gyp/buildbot/travis-checkout.sh +27 -0
  14. data/ext/gyp/buildbot/travis-test.sh +12 -0
  15. data/ext/gyp/codereview.settings +6 -0
  16. data/ext/gyp/data/win/large-pdb-shim.cc +12 -0
  17. data/ext/gyp/gyp +8 -0
  18. data/ext/gyp/gyp.bat +5 -0
  19. data/ext/gyp/gyp_main.py +16 -0
  20. data/ext/gyp/gyptest.py +243 -0
  21. data/ext/gyp/pylib/gyp/MSVSNew.py +353 -0
  22. data/ext/gyp/pylib/gyp/MSVSProject.py +208 -0
  23. data/ext/gyp/pylib/gyp/MSVSSettings.py +1106 -0
  24. data/ext/gyp/pylib/gyp/MSVSSettings_test.py +1486 -0
  25. data/ext/gyp/pylib/gyp/MSVSToolFile.py +58 -0
  26. data/ext/gyp/pylib/gyp/MSVSUserFile.py +147 -0
  27. data/ext/gyp/pylib/gyp/MSVSUtil.py +271 -0
  28. data/ext/gyp/pylib/gyp/MSVSVersion.py +504 -0
  29. data/ext/gyp/pylib/gyp/__init__.py +555 -0
  30. data/ext/gyp/pylib/gyp/common.py +619 -0
  31. data/ext/gyp/pylib/gyp/common_test.py +73 -0
  32. data/ext/gyp/pylib/gyp/easy_xml.py +170 -0
  33. data/ext/gyp/pylib/gyp/easy_xml_test.py +106 -0
  34. data/ext/gyp/pylib/gyp/flock_tool.py +54 -0
  35. data/ext/gyp/pylib/gyp/generator/__init__.py +0 -0
  36. data/ext/gyp/pylib/gyp/generator/analyzer.py +744 -0
  37. data/ext/gyp/pylib/gyp/generator/cmake.py +1256 -0
  38. data/ext/gyp/pylib/gyp/generator/dump_dependency_json.py +101 -0
  39. data/ext/gyp/pylib/gyp/generator/eclipse.py +425 -0
  40. data/ext/gyp/pylib/gyp/generator/gypd.py +94 -0
  41. data/ext/gyp/pylib/gyp/generator/gypsh.py +56 -0
  42. data/ext/gyp/pylib/gyp/generator/make.py +2260 -0
  43. data/ext/gyp/pylib/gyp/generator/msvs.py +3537 -0
  44. data/ext/gyp/pylib/gyp/generator/msvs_test.py +40 -0
  45. data/ext/gyp/pylib/gyp/generator/ninja.py +2500 -0
  46. data/ext/gyp/pylib/gyp/generator/ninja_test.py +46 -0
  47. data/ext/gyp/pylib/gyp/generator/xcode.py +1302 -0
  48. data/ext/gyp/pylib/gyp/generator/xcode_test.py +23 -0
  49. data/ext/gyp/pylib/gyp/input.py +2908 -0
  50. data/ext/gyp/pylib/gyp/input_test.py +90 -0
  51. data/ext/gyp/pylib/gyp/mac_tool.py +721 -0
  52. data/ext/gyp/pylib/gyp/msvs_emulation.py +1112 -0
  53. data/ext/gyp/pylib/gyp/ninja_syntax.py +168 -0
  54. data/ext/gyp/pylib/gyp/simple_copy.py +57 -0
  55. data/ext/gyp/pylib/gyp/win_tool.py +326 -0
  56. data/ext/gyp/pylib/gyp/xcode_emulation.py +1800 -0
  57. data/ext/gyp/pylib/gyp/xcode_ninja.py +289 -0
  58. data/ext/gyp/pylib/gyp/xcodeproj_file.py +2995 -0
  59. data/ext/gyp/pylib/gyp/xml_fix.py +68 -0
  60. data/ext/gyp/samples/samples +83 -0
  61. data/ext/gyp/samples/samples.bat +5 -0
  62. data/ext/gyp/setup.py +19 -0
  63. data/ext/gyp/test/actions/generated-header/action.py +11 -0
  64. data/ext/gyp/test/actions/generated-header/main.cc +7 -0
  65. data/ext/gyp/test/actions/generated-header/test.gyp +34 -0
  66. data/ext/gyp/test/actions/gyptest-all.py +101 -0
  67. data/ext/gyp/test/actions/gyptest-default.py +68 -0
  68. data/ext/gyp/test/actions/gyptest-errors.py +24 -0
  69. data/ext/gyp/test/actions/gyptest-generated-header.py +38 -0
  70. data/ext/gyp/test/actions/src/action_missing_name.gyp +24 -0
  71. data/ext/gyp/test/actions/src/actions.gyp +114 -0
  72. data/ext/gyp/test/actions/src/confirm-dep-files.py +21 -0
  73. data/ext/gyp/test/actions/src/subdir1/counter.py +44 -0
  74. data/ext/gyp/test/actions/src/subdir1/executable.gyp +74 -0
  75. data/ext/gyp/test/actions/src/subdir1/make-prog1.py +20 -0
  76. data/ext/gyp/test/actions/src/subdir1/make-prog2.py +20 -0
  77. data/ext/gyp/test/actions/src/subdir1/program.c +12 -0
  78. data/ext/gyp/test/actions/src/subdir2/make-file.py +11 -0
  79. data/ext/gyp/test/actions/src/subdir2/none.gyp +33 -0
  80. data/ext/gyp/test/actions/src/subdir3/generate_main.py +21 -0
  81. data/ext/gyp/test/actions/src/subdir3/null_input.gyp +29 -0
  82. data/ext/gyp/test/actions-bare/gyptest-bare.py +24 -0
  83. data/ext/gyp/test/actions-bare/src/bare.gyp +25 -0
  84. data/ext/gyp/test/actions-bare/src/bare.py +11 -0
  85. data/ext/gyp/test/actions-depfile/depfile.gyp +42 -0
  86. data/ext/gyp/test/actions-depfile/gyptest-all.py +30 -0
  87. data/ext/gyp/test/actions-depfile/input.txt +1 -0
  88. data/ext/gyp/test/actions-depfile/touch.py +18 -0
  89. data/ext/gyp/test/actions-multiple/gyptest-all.py +72 -0
  90. data/ext/gyp/test/actions-multiple/src/actions.gyp +226 -0
  91. data/ext/gyp/test/actions-multiple/src/copyfile.py +9 -0
  92. data/ext/gyp/test/actions-multiple/src/filter.py +12 -0
  93. data/ext/gyp/test/actions-multiple/src/foo.c +11 -0
  94. data/ext/gyp/test/actions-multiple/src/input.txt +1 -0
  95. data/ext/gyp/test/actions-multiple/src/main.c +22 -0
  96. data/ext/gyp/test/actions-multiple-outputs/gyptest-multiple-outputs.py +45 -0
  97. data/ext/gyp/test/actions-multiple-outputs/src/multiple-outputs.gyp +23 -0
  98. data/ext/gyp/test/actions-multiple-outputs/src/touch.py +16 -0
  99. data/ext/gyp/test/actions-multiple-outputs-with-dependencies/gyptest-action.py +45 -0
  100. data/ext/gyp/test/actions-multiple-outputs-with-dependencies/src/action.gyp +28 -0
  101. data/ext/gyp/test/actions-multiple-outputs-with-dependencies/src/rcopy.py +20 -0
  102. data/ext/gyp/test/actions-none/gyptest-none.py +24 -0
  103. data/ext/gyp/test/actions-none/src/fake_cross.py +12 -0
  104. data/ext/gyp/test/actions-none/src/foo.cc +1 -0
  105. data/ext/gyp/test/actions-none/src/none_with_source_files.gyp +35 -0
  106. data/ext/gyp/test/actions-subdir/gyptest-action.py +26 -0
  107. data/ext/gyp/test/actions-subdir/src/make-file.py +11 -0
  108. data/ext/gyp/test/actions-subdir/src/none.gyp +31 -0
  109. data/ext/gyp/test/actions-subdir/src/subdir/make-subdir-file.py +11 -0
  110. data/ext/gyp/test/actions-subdir/src/subdir/subdir.gyp +28 -0
  111. data/ext/gyp/test/additional-targets/gyptest-additional.py +63 -0
  112. data/ext/gyp/test/additional-targets/src/all.gyp +13 -0
  113. data/ext/gyp/test/additional-targets/src/dir1/actions.gyp +56 -0
  114. data/ext/gyp/test/additional-targets/src/dir1/emit.py +11 -0
  115. data/ext/gyp/test/additional-targets/src/dir1/lib1.c +6 -0
  116. data/ext/gyp/test/analyzer/common.gypi +6 -0
  117. data/ext/gyp/test/analyzer/gyptest-analyzer.py +427 -0
  118. data/ext/gyp/test/analyzer/static_library_test.gyp +34 -0
  119. data/ext/gyp/test/analyzer/subdir/subdir.gyp +36 -0
  120. data/ext/gyp/test/analyzer/subdir/subdir2/subdir2.gyp +15 -0
  121. data/ext/gyp/test/analyzer/subdir2/subdir.gyp +18 -0
  122. data/ext/gyp/test/analyzer/subdir2/subdir.includes.gypi +9 -0
  123. data/ext/gyp/test/analyzer/test.gyp +114 -0
  124. data/ext/gyp/test/analyzer/test2.gyp +25 -0
  125. data/ext/gyp/test/analyzer/test2.includes.gypi +13 -0
  126. data/ext/gyp/test/analyzer/test2.includes.includes.gypi +9 -0
  127. data/ext/gyp/test/analyzer/test2.toplevel_includes.gypi +15 -0
  128. data/ext/gyp/test/analyzer/test3.gyp +77 -0
  129. data/ext/gyp/test/analyzer/test4.gyp +80 -0
  130. data/ext/gyp/test/analyzer/test5.gyp +25 -0
  131. data/ext/gyp/test/arflags/gyptest-arflags.py +26 -0
  132. data/ext/gyp/test/arflags/lib.cc +0 -0
  133. data/ext/gyp/test/arflags/test.gyp +10 -0
  134. data/ext/gyp/test/assembly/gyptest-assembly.py +31 -0
  135. data/ext/gyp/test/assembly/gyptest-override.py +24 -0
  136. data/ext/gyp/test/assembly/src/as.bat +4 -0
  137. data/ext/gyp/test/assembly/src/assembly.gyp +62 -0
  138. data/ext/gyp/test/assembly/src/lib1.S +15 -0
  139. data/ext/gyp/test/assembly/src/lib1.c +3 -0
  140. data/ext/gyp/test/assembly/src/override.gyp +34 -0
  141. data/ext/gyp/test/assembly/src/override_asm.asm +8 -0
  142. data/ext/gyp/test/assembly/src/program.c +12 -0
  143. data/ext/gyp/test/build-option/gyptest-build.py +27 -0
  144. data/ext/gyp/test/build-option/hello.c +13 -0
  145. data/ext/gyp/test/build-option/hello.gyp +15 -0
  146. data/ext/gyp/test/builddir/gyptest-all.py +85 -0
  147. data/ext/gyp/test/builddir/gyptest-default.py +85 -0
  148. data/ext/gyp/test/builddir/src/builddir.gypi +18 -0
  149. data/ext/gyp/test/builddir/src/func1.c +6 -0
  150. data/ext/gyp/test/builddir/src/func2.c +6 -0
  151. data/ext/gyp/test/builddir/src/func3.c +6 -0
  152. data/ext/gyp/test/builddir/src/func4.c +6 -0
  153. data/ext/gyp/test/builddir/src/func5.c +6 -0
  154. data/ext/gyp/test/builddir/src/prog1.c +10 -0
  155. data/ext/gyp/test/builddir/src/prog1.gyp +30 -0
  156. data/ext/gyp/test/builddir/src/subdir2/prog2.c +10 -0
  157. data/ext/gyp/test/builddir/src/subdir2/prog2.gyp +19 -0
  158. data/ext/gyp/test/builddir/src/subdir2/subdir3/prog3.c +10 -0
  159. data/ext/gyp/test/builddir/src/subdir2/subdir3/prog3.gyp +19 -0
  160. data/ext/gyp/test/builddir/src/subdir2/subdir3/subdir4/prog4.c +10 -0
  161. data/ext/gyp/test/builddir/src/subdir2/subdir3/subdir4/prog4.gyp +19 -0
  162. data/ext/gyp/test/builddir/src/subdir2/subdir3/subdir4/subdir5/prog5.c +10 -0
  163. data/ext/gyp/test/builddir/src/subdir2/subdir3/subdir4/subdir5/prog5.gyp +19 -0
  164. data/ext/gyp/test/cflags/cflags.c +15 -0
  165. data/ext/gyp/test/cflags/cflags.gyp +23 -0
  166. data/ext/gyp/test/cflags/gyptest-cflags.py +75 -0
  167. data/ext/gyp/test/compilable/gyptest-headers.py +29 -0
  168. data/ext/gyp/test/compilable/src/headers.gyp +26 -0
  169. data/ext/gyp/test/compilable/src/lib1.cpp +7 -0
  170. data/ext/gyp/test/compilable/src/lib1.hpp +6 -0
  171. data/ext/gyp/test/compilable/src/program.cpp +9 -0
  172. data/ext/gyp/test/compiler-override/compiler-exe.gyp +16 -0
  173. data/ext/gyp/test/compiler-override/compiler-global-settings.gyp.in +34 -0
  174. data/ext/gyp/test/compiler-override/compiler-host.gyp +17 -0
  175. data/ext/gyp/test/compiler-override/compiler-shared-lib.gyp +16 -0
  176. data/ext/gyp/test/compiler-override/cxxtest.cc +7 -0
  177. data/ext/gyp/test/compiler-override/gyptest-compiler-env-toolchain.py +78 -0
  178. data/ext/gyp/test/compiler-override/gyptest-compiler-env.py +110 -0
  179. data/ext/gyp/test/compiler-override/gyptest-compiler-global-settings.py +82 -0
  180. data/ext/gyp/test/compiler-override/my_cc.py +7 -0
  181. data/ext/gyp/test/compiler-override/my_cxx.py +7 -0
  182. data/ext/gyp/test/compiler-override/my_ld.py +7 -0
  183. data/ext/gyp/test/compiler-override/my_nm.py +9 -0
  184. data/ext/gyp/test/compiler-override/my_readelf.py +9 -0
  185. data/ext/gyp/test/compiler-override/test.c +7 -0
  186. data/ext/gyp/test/conditions/elseif/elseif.gyp +43 -0
  187. data/ext/gyp/test/conditions/elseif/elseif_bad1.gyp +20 -0
  188. data/ext/gyp/test/conditions/elseif/elseif_bad2.gyp +22 -0
  189. data/ext/gyp/test/conditions/elseif/elseif_bad3.gyp +23 -0
  190. data/ext/gyp/test/conditions/elseif/elseif_conditions.gypi +15 -0
  191. data/ext/gyp/test/conditions/elseif/gyptest_elseif.py +33 -0
  192. data/ext/gyp/test/conditions/elseif/program.cc +10 -0
  193. data/ext/gyp/test/configurations/basics/configurations.c +15 -0
  194. data/ext/gyp/test/configurations/basics/configurations.gyp +32 -0
  195. data/ext/gyp/test/configurations/basics/gyptest-configurations.py +29 -0
  196. data/ext/gyp/test/configurations/inheritance/configurations.c +21 -0
  197. data/ext/gyp/test/configurations/inheritance/configurations.gyp +40 -0
  198. data/ext/gyp/test/configurations/inheritance/duplicates.gyp +27 -0
  199. data/ext/gyp/test/configurations/inheritance/duplicates.gypd.golden +12 -0
  200. data/ext/gyp/test/configurations/inheritance/gyptest-duplicates.py +36 -0
  201. data/ext/gyp/test/configurations/inheritance/gyptest-inheritance.py +33 -0
  202. data/ext/gyp/test/configurations/invalid/actions.gyp +18 -0
  203. data/ext/gyp/test/configurations/invalid/all_dependent_settings.gyp +18 -0
  204. data/ext/gyp/test/configurations/invalid/configurations.gyp +18 -0
  205. data/ext/gyp/test/configurations/invalid/dependencies.gyp +18 -0
  206. data/ext/gyp/test/configurations/invalid/direct_dependent_settings.gyp +18 -0
  207. data/ext/gyp/test/configurations/invalid/gyptest-configurations.py +36 -0
  208. data/ext/gyp/test/configurations/invalid/libraries.gyp +18 -0
  209. data/ext/gyp/test/configurations/invalid/link_settings.gyp +18 -0
  210. data/ext/gyp/test/configurations/invalid/sources.gyp +18 -0
  211. data/ext/gyp/test/configurations/invalid/standalone_static_library.gyp +17 -0
  212. data/ext/gyp/test/configurations/invalid/target_name.gyp +18 -0
  213. data/ext/gyp/test/configurations/invalid/type.gyp +18 -0
  214. data/ext/gyp/test/configurations/target_platform/configurations.gyp +58 -0
  215. data/ext/gyp/test/configurations/target_platform/front.c +8 -0
  216. data/ext/gyp/test/configurations/target_platform/gyptest-target_platform.py +40 -0
  217. data/ext/gyp/test/configurations/target_platform/left.c +3 -0
  218. data/ext/gyp/test/configurations/target_platform/right.c +3 -0
  219. data/ext/gyp/test/configurations/x64/configurations.c +12 -0
  220. data/ext/gyp/test/configurations/x64/configurations.gyp +38 -0
  221. data/ext/gyp/test/configurations/x64/gyptest-x86.py +31 -0
  222. data/ext/gyp/test/copies/gyptest-all.py +42 -0
  223. data/ext/gyp/test/copies/gyptest-attribs.py +41 -0
  224. data/ext/gyp/test/copies/gyptest-default.py +42 -0
  225. data/ext/gyp/test/copies/gyptest-samedir.py +28 -0
  226. data/ext/gyp/test/copies/gyptest-slash.py +39 -0
  227. data/ext/gyp/test/copies/gyptest-sourceless-shared-lib.py +20 -0
  228. data/ext/gyp/test/copies/gyptest-updir.py +32 -0
  229. data/ext/gyp/test/copies/src/copies-attribs.gyp +20 -0
  230. data/ext/gyp/test/copies/src/copies-samedir.gyp +37 -0
  231. data/ext/gyp/test/copies/src/copies-slash.gyp +36 -0
  232. data/ext/gyp/test/copies/src/copies-sourceless-shared-lib.gyp +27 -0
  233. data/ext/gyp/test/copies/src/copies-updir.gyp +21 -0
  234. data/ext/gyp/test/copies/src/copies.gyp +70 -0
  235. data/ext/gyp/test/copies/src/directory/file3 +1 -0
  236. data/ext/gyp/test/copies/src/directory/file4 +1 -0
  237. data/ext/gyp/test/copies/src/directory/subdir/file5 +1 -0
  238. data/ext/gyp/test/copies/src/executable-file.sh +3 -0
  239. data/ext/gyp/test/copies/src/file1 +1 -0
  240. data/ext/gyp/test/copies/src/file2 +1 -0
  241. data/ext/gyp/test/copies/src/foo.c +13 -0
  242. data/ext/gyp/test/copies/src/parentdir/subdir/file6 +1 -0
  243. data/ext/gyp/test/custom-generator/gyptest-custom-generator.py +18 -0
  244. data/ext/gyp/test/custom-generator/mygenerator.py +14 -0
  245. data/ext/gyp/test/custom-generator/test.gyp +15 -0
  246. data/ext/gyp/test/cxxflags/cxxflags.cc +15 -0
  247. data/ext/gyp/test/cxxflags/cxxflags.gyp +15 -0
  248. data/ext/gyp/test/cxxflags/gyptest-cxxflags.py +45 -0
  249. data/ext/gyp/test/defines/defines-env.gyp +22 -0
  250. data/ext/gyp/test/defines/defines.c +23 -0
  251. data/ext/gyp/test/defines/defines.gyp +38 -0
  252. data/ext/gyp/test/defines/gyptest-define-override.py +43 -0
  253. data/ext/gyp/test/defines/gyptest-defines-env-regyp.py +51 -0
  254. data/ext/gyp/test/defines/gyptest-defines-env.py +85 -0
  255. data/ext/gyp/test/defines/gyptest-defines.py +39 -0
  256. data/ext/gyp/test/defines-escaping/defines-escaping.c +11 -0
  257. data/ext/gyp/test/defines-escaping/defines-escaping.gyp +19 -0
  258. data/ext/gyp/test/defines-escaping/gyptest-defines-escaping.py +184 -0
  259. data/ext/gyp/test/dependencies/a.c +9 -0
  260. data/ext/gyp/test/dependencies/adso/all_dependent_settings_order.gyp +45 -0
  261. data/ext/gyp/test/dependencies/adso/write_args.py +11 -0
  262. data/ext/gyp/test/dependencies/b/b.c +3 -0
  263. data/ext/gyp/test/dependencies/b/b.gyp +22 -0
  264. data/ext/gyp/test/dependencies/b/b3.c +9 -0
  265. data/ext/gyp/test/dependencies/c/c.c +4 -0
  266. data/ext/gyp/test/dependencies/c/c.gyp +22 -0
  267. data/ext/gyp/test/dependencies/c/d.c +3 -0
  268. data/ext/gyp/test/dependencies/double_dependency.gyp +23 -0
  269. data/ext/gyp/test/dependencies/double_dependent.gyp +12 -0
  270. data/ext/gyp/test/dependencies/extra_targets.gyp +18 -0
  271. data/ext/gyp/test/dependencies/gyptest-all-dependent-settings-order.py +19 -0
  272. data/ext/gyp/test/dependencies/gyptest-double-dependency.py +19 -0
  273. data/ext/gyp/test/dependencies/gyptest-extra-targets.py +22 -0
  274. data/ext/gyp/test/dependencies/gyptest-indirect-module-dependency.py +22 -0
  275. data/ext/gyp/test/dependencies/gyptest-lib-only.py +39 -0
  276. data/ext/gyp/test/dependencies/gyptest-none-traversal.py +25 -0
  277. data/ext/gyp/test/dependencies/gyptest-sharedlib-linksettings.py +21 -0
  278. data/ext/gyp/test/dependencies/lib_only.gyp +16 -0
  279. data/ext/gyp/test/dependencies/main.c +14 -0
  280. data/ext/gyp/test/dependencies/module-dep/a.cc +7 -0
  281. data/ext/gyp/test/dependencies/module-dep/dll.cc +9 -0
  282. data/ext/gyp/test/dependencies/module-dep/exe.cc +7 -0
  283. data/ext/gyp/test/dependencies/module-dep/indirect-module-dependency.gyp +37 -0
  284. data/ext/gyp/test/dependencies/none_traversal.gyp +46 -0
  285. data/ext/gyp/test/dependencies/sharedlib-linksettings/program.c +25 -0
  286. data/ext/gyp/test/dependencies/sharedlib-linksettings/sharedlib.c +16 -0
  287. data/ext/gyp/test/dependencies/sharedlib-linksettings/staticlib.c +24 -0
  288. data/ext/gyp/test/dependencies/sharedlib-linksettings/test.gyp +37 -0
  289. data/ext/gyp/test/dependency-copy/gyptest-copy.py +26 -0
  290. data/ext/gyp/test/dependency-copy/src/copies.gyp +25 -0
  291. data/ext/gyp/test/dependency-copy/src/file1.c +7 -0
  292. data/ext/gyp/test/dependency-copy/src/file2.c +7 -0
  293. data/ext/gyp/test/dependent-settings/nested-dependent-settings/all-dependent-settings.gyp +19 -0
  294. data/ext/gyp/test/dependent-settings/nested-dependent-settings/direct-dependent-settings.gyp +19 -0
  295. data/ext/gyp/test/dependent-settings/nested-dependent-settings/gyptest-nested-dependent-settings.py +18 -0
  296. data/ext/gyp/test/determinism/determinism.gyp +59 -0
  297. data/ext/gyp/test/determinism/empty-targets.gyp +32 -0
  298. data/ext/gyp/test/determinism/gyptest-determinism.py +30 -0
  299. data/ext/gyp/test/determinism/gyptest-empty-target-names.py +30 -0
  300. data/ext/gyp/test/determinism/gyptest-needed-variables.py +30 -0
  301. data/ext/gyp/test/determinism/gyptest-solibs.py +37 -0
  302. data/ext/gyp/test/determinism/main.cc +5 -0
  303. data/ext/gyp/test/determinism/needed-variables.gyp +33 -0
  304. data/ext/gyp/test/determinism/rule.py +8 -0
  305. data/ext/gyp/test/determinism/solib.cc +8 -0
  306. data/ext/gyp/test/determinism/solibs.gyp +32 -0
  307. data/ext/gyp/test/empty-target/empty-target.gyp +12 -0
  308. data/ext/gyp/test/empty-target/gyptest-empty-target.py +18 -0
  309. data/ext/gyp/test/errors/dependency_cycle.gyp +23 -0
  310. data/ext/gyp/test/errors/duplicate_basenames.gyp +13 -0
  311. data/ext/gyp/test/errors/duplicate_node.gyp +12 -0
  312. data/ext/gyp/test/errors/duplicate_rule.gyp +22 -0
  313. data/ext/gyp/test/errors/duplicate_targets.gyp +14 -0
  314. data/ext/gyp/test/errors/error_command.gyp +12 -0
  315. data/ext/gyp/test/errors/file_cycle0.gyp +17 -0
  316. data/ext/gyp/test/errors/file_cycle1.gyp +13 -0
  317. data/ext/gyp/test/errors/gyptest-errors.py +80 -0
  318. data/ext/gyp/test/errors/missing_command.gyp +12 -0
  319. data/ext/gyp/test/errors/missing_dep.gyp +15 -0
  320. data/ext/gyp/test/errors/missing_targets.gyp +8 -0
  321. data/ext/gyp/test/escaping/colon/test.gyp +21 -0
  322. data/ext/gyp/test/escaping/gyptest-colon.py +51 -0
  323. data/ext/gyp/test/exclusion/exclusion.gyp +23 -0
  324. data/ext/gyp/test/exclusion/gyptest-exclusion.py +22 -0
  325. data/ext/gyp/test/exclusion/hello.c +15 -0
  326. data/ext/gyp/test/external-cross-compile/gyptest-cross.py +31 -0
  327. data/ext/gyp/test/external-cross-compile/src/bogus1.cc +1 -0
  328. data/ext/gyp/test/external-cross-compile/src/bogus2.c +1 -0
  329. data/ext/gyp/test/external-cross-compile/src/cross.gyp +83 -0
  330. data/ext/gyp/test/external-cross-compile/src/cross_compile.gypi +23 -0
  331. data/ext/gyp/test/external-cross-compile/src/fake_cross.py +18 -0
  332. data/ext/gyp/test/external-cross-compile/src/program.cc +16 -0
  333. data/ext/gyp/test/external-cross-compile/src/test1.cc +1 -0
  334. data/ext/gyp/test/external-cross-compile/src/test2.c +1 -0
  335. data/ext/gyp/test/external-cross-compile/src/test3.cc +1 -0
  336. data/ext/gyp/test/external-cross-compile/src/test4.c +1 -0
  337. data/ext/gyp/test/external-cross-compile/src/tochar.py +13 -0
  338. data/ext/gyp/test/generator-output/actions/actions.gyp +16 -0
  339. data/ext/gyp/test/generator-output/actions/build/README.txt +4 -0
  340. data/ext/gyp/test/generator-output/actions/subdir1/actions-out/README.txt +4 -0
  341. data/ext/gyp/test/generator-output/actions/subdir1/build/README.txt +4 -0
  342. data/ext/gyp/test/generator-output/actions/subdir1/executable.gyp +44 -0
  343. data/ext/gyp/test/generator-output/actions/subdir1/make-prog1.py +20 -0
  344. data/ext/gyp/test/generator-output/actions/subdir1/make-prog2.py +20 -0
  345. data/ext/gyp/test/generator-output/actions/subdir1/program.c +12 -0
  346. data/ext/gyp/test/generator-output/actions/subdir2/actions-out/README.txt +4 -0
  347. data/ext/gyp/test/generator-output/actions/subdir2/build/README.txt +4 -0
  348. data/ext/gyp/test/generator-output/actions/subdir2/make-file.py +11 -0
  349. data/ext/gyp/test/generator-output/actions/subdir2/none.gyp +31 -0
  350. data/ext/gyp/test/generator-output/copies/build/README.txt +4 -0
  351. data/ext/gyp/test/generator-output/copies/copies-out/README.txt +4 -0
  352. data/ext/gyp/test/generator-output/copies/copies.gyp +50 -0
  353. data/ext/gyp/test/generator-output/copies/file1 +1 -0
  354. data/ext/gyp/test/generator-output/copies/file2 +1 -0
  355. data/ext/gyp/test/generator-output/copies/subdir/build/README.txt +4 -0
  356. data/ext/gyp/test/generator-output/copies/subdir/copies-out/README.txt +4 -0
  357. data/ext/gyp/test/generator-output/copies/subdir/file3 +1 -0
  358. data/ext/gyp/test/generator-output/copies/subdir/file4 +1 -0
  359. data/ext/gyp/test/generator-output/copies/subdir/subdir.gyp +32 -0
  360. data/ext/gyp/test/generator-output/gyptest-actions.py +57 -0
  361. data/ext/gyp/test/generator-output/gyptest-copies.py +59 -0
  362. data/ext/gyp/test/generator-output/gyptest-depth.py +58 -0
  363. data/ext/gyp/test/generator-output/gyptest-mac-bundle.py +33 -0
  364. data/ext/gyp/test/generator-output/gyptest-relocate.py +59 -0
  365. data/ext/gyp/test/generator-output/gyptest-rules.py +58 -0
  366. data/ext/gyp/test/generator-output/gyptest-subdir2-deep.py +36 -0
  367. data/ext/gyp/test/generator-output/gyptest-symlink.py +44 -0
  368. data/ext/gyp/test/generator-output/gyptest-top-all.py +53 -0
  369. data/ext/gyp/test/generator-output/mac-bundle/Info.plist +32 -0
  370. data/ext/gyp/test/generator-output/mac-bundle/app.order +1 -0
  371. data/ext/gyp/test/generator-output/mac-bundle/header.h +1 -0
  372. data/ext/gyp/test/generator-output/mac-bundle/main.c +1 -0
  373. data/ext/gyp/test/generator-output/mac-bundle/resource.sb +1 -0
  374. data/ext/gyp/test/generator-output/mac-bundle/test.gyp +25 -0
  375. data/ext/gyp/test/generator-output/rules/build/README.txt +4 -0
  376. data/ext/gyp/test/generator-output/rules/copy-file.py +12 -0
  377. data/ext/gyp/test/generator-output/rules/rules.gyp +16 -0
  378. data/ext/gyp/test/generator-output/rules/subdir1/build/README.txt +4 -0
  379. data/ext/gyp/test/generator-output/rules/subdir1/define3.in0 +1 -0
  380. data/ext/gyp/test/generator-output/rules/subdir1/define4.in0 +1 -0
  381. data/ext/gyp/test/generator-output/rules/subdir1/executable.gyp +59 -0
  382. data/ext/gyp/test/generator-output/rules/subdir1/function1.in1 +6 -0
  383. data/ext/gyp/test/generator-output/rules/subdir1/function2.in1 +6 -0
  384. data/ext/gyp/test/generator-output/rules/subdir1/program.c +18 -0
  385. data/ext/gyp/test/generator-output/rules/subdir2/build/README.txt +4 -0
  386. data/ext/gyp/test/generator-output/rules/subdir2/file1.in0 +1 -0
  387. data/ext/gyp/test/generator-output/rules/subdir2/file2.in0 +1 -0
  388. data/ext/gyp/test/generator-output/rules/subdir2/file3.in1 +1 -0
  389. data/ext/gyp/test/generator-output/rules/subdir2/file4.in1 +1 -0
  390. data/ext/gyp/test/generator-output/rules/subdir2/none.gyp +49 -0
  391. data/ext/gyp/test/generator-output/rules/subdir2/rules-out/README.txt +4 -0
  392. data/ext/gyp/test/generator-output/src/build/README.txt +4 -0
  393. data/ext/gyp/test/generator-output/src/inc.h +1 -0
  394. data/ext/gyp/test/generator-output/src/inc1/include1.h +1 -0
  395. data/ext/gyp/test/generator-output/src/prog1.c +18 -0
  396. data/ext/gyp/test/generator-output/src/prog1.gyp +28 -0
  397. data/ext/gyp/test/generator-output/src/subdir2/build/README.txt +4 -0
  398. data/ext/gyp/test/generator-output/src/subdir2/deeper/build/README.txt +4 -0
  399. data/ext/gyp/test/generator-output/src/subdir2/deeper/deeper.c +7 -0
  400. data/ext/gyp/test/generator-output/src/subdir2/deeper/deeper.gyp +18 -0
  401. data/ext/gyp/test/generator-output/src/subdir2/deeper/deeper.h +1 -0
  402. data/ext/gyp/test/generator-output/src/subdir2/inc2/include2.h +1 -0
  403. data/ext/gyp/test/generator-output/src/subdir2/prog2.c +18 -0
  404. data/ext/gyp/test/generator-output/src/subdir2/prog2.gyp +28 -0
  405. data/ext/gyp/test/generator-output/src/subdir3/build/README.txt +4 -0
  406. data/ext/gyp/test/generator-output/src/subdir3/inc3/include3.h +1 -0
  407. data/ext/gyp/test/generator-output/src/subdir3/prog3.c +18 -0
  408. data/ext/gyp/test/generator-output/src/subdir3/prog3.gyp +25 -0
  409. data/ext/gyp/test/generator-output/src/symroot.gypi +16 -0
  410. data/ext/gyp/test/gyp-defines/defines.gyp +26 -0
  411. data/ext/gyp/test/gyp-defines/echo.py +11 -0
  412. data/ext/gyp/test/gyp-defines/gyptest-multiple-values.py +36 -0
  413. data/ext/gyp/test/gyp-defines/gyptest-regyp.py +40 -0
  414. data/ext/gyp/test/hard_dependency/gyptest-exported-hard-dependency.py +37 -0
  415. data/ext/gyp/test/hard_dependency/gyptest-no-exported-hard-dependency.py +36 -0
  416. data/ext/gyp/test/hard_dependency/src/a.c +9 -0
  417. data/ext/gyp/test/hard_dependency/src/a.h +12 -0
  418. data/ext/gyp/test/hard_dependency/src/b.c +9 -0
  419. data/ext/gyp/test/hard_dependency/src/b.h +12 -0
  420. data/ext/gyp/test/hard_dependency/src/c.c +10 -0
  421. data/ext/gyp/test/hard_dependency/src/c.h +10 -0
  422. data/ext/gyp/test/hard_dependency/src/d.c +9 -0
  423. data/ext/gyp/test/hard_dependency/src/emit.py +11 -0
  424. data/ext/gyp/test/hard_dependency/src/hard_dependency.gyp +78 -0
  425. data/ext/gyp/test/hello/gyptest-all.py +24 -0
  426. data/ext/gyp/test/hello/gyptest-default.py +24 -0
  427. data/ext/gyp/test/hello/gyptest-disable-regyp.py +32 -0
  428. data/ext/gyp/test/hello/gyptest-regyp-output.py +36 -0
  429. data/ext/gyp/test/hello/gyptest-regyp.py +32 -0
  430. data/ext/gyp/test/hello/gyptest-target.py +24 -0
  431. data/ext/gyp/test/hello/hello.c +11 -0
  432. data/ext/gyp/test/hello/hello.gyp +15 -0
  433. data/ext/gyp/test/hello/hello2.c +11 -0
  434. data/ext/gyp/test/hello/hello2.gyp +15 -0
  435. data/ext/gyp/test/home_dot_gyp/gyptest-home-includes-config-arg.py +31 -0
  436. data/ext/gyp/test/home_dot_gyp/gyptest-home-includes-config-env.py +33 -0
  437. data/ext/gyp/test/home_dot_gyp/gyptest-home-includes-regyp.py +44 -0
  438. data/ext/gyp/test/home_dot_gyp/gyptest-home-includes.py +30 -0
  439. data/ext/gyp/test/home_dot_gyp/home/.gyp/include.gypi +5 -0
  440. data/ext/gyp/test/home_dot_gyp/home2/.gyp/include.gypi +5 -0
  441. data/ext/gyp/test/home_dot_gyp/home2/.gyp_new/include.gypi +5 -0
  442. data/ext/gyp/test/home_dot_gyp/src/all.gyp +22 -0
  443. data/ext/gyp/test/home_dot_gyp/src/printfoo.c +7 -0
  444. data/ext/gyp/test/include_dirs/gyptest-all.py +43 -0
  445. data/ext/gyp/test/include_dirs/gyptest-default.py +43 -0
  446. data/ext/gyp/test/include_dirs/src/inc.h +1 -0
  447. data/ext/gyp/test/include_dirs/src/inc1/include1.h +1 -0
  448. data/ext/gyp/test/include_dirs/src/includes.c +19 -0
  449. data/ext/gyp/test/include_dirs/src/includes.gyp +27 -0
  450. data/ext/gyp/test/include_dirs/src/shadow1/shadow.h +1 -0
  451. data/ext/gyp/test/include_dirs/src/shadow2/shadow.h +1 -0
  452. data/ext/gyp/test/include_dirs/src/subdir/inc.h +1 -0
  453. data/ext/gyp/test/include_dirs/src/subdir/inc2/include2.h +1 -0
  454. data/ext/gyp/test/include_dirs/src/subdir/subdir_includes.c +14 -0
  455. data/ext/gyp/test/include_dirs/src/subdir/subdir_includes.gyp +20 -0
  456. data/ext/gyp/test/intermediate_dir/gyptest-intermediate-dir.py +44 -0
  457. data/ext/gyp/test/intermediate_dir/src/script.py +22 -0
  458. data/ext/gyp/test/intermediate_dir/src/shared_infile.txt +1 -0
  459. data/ext/gyp/test/intermediate_dir/src/test.gyp +42 -0
  460. data/ext/gyp/test/intermediate_dir/src/test2.gyp +42 -0
  461. data/ext/gyp/test/ios/app-bundle/TestApp/English.lproj/InfoPlist-error.strings +3 -0
  462. data/ext/gyp/test/ios/app-bundle/TestApp/English.lproj/InfoPlist.strings +3 -0
  463. data/ext/gyp/test/ios/app-bundle/TestApp/English.lproj/LanguageMap.plist +8 -0
  464. data/ext/gyp/test/ios/app-bundle/TestApp/English.lproj/MainMenu.xib +17 -0
  465. data/ext/gyp/test/ios/app-bundle/TestApp/English.lproj/Main_iPhone.storyboard +27 -0
  466. data/ext/gyp/test/ios/app-bundle/TestApp/Images.xcassets/AppIcon.appiconset/Contents.json +58 -0
  467. data/ext/gyp/test/ios/app-bundle/TestApp/Images.xcassets/image.imageset/Contents.json +23 -0
  468. data/ext/gyp/test/ios/app-bundle/TestApp/Images.xcassets/image.imageset/super_sylvain.png +0 -0
  469. data/ext/gyp/test/ios/app-bundle/TestApp/Images.xcassets/image.imageset/super_sylvain@2x.png +0 -0
  470. data/ext/gyp/test/ios/app-bundle/TestApp/Images.xcassets/image.imageset/super_sylvain@3x.png +0 -0
  471. data/ext/gyp/test/ios/app-bundle/TestApp/TestApp-Info.plist +28 -0
  472. data/ext/gyp/test/ios/app-bundle/TestApp/check_no_signature.py +13 -0
  473. data/ext/gyp/test/ios/app-bundle/TestApp/main.m +13 -0
  474. data/ext/gyp/test/ios/app-bundle/TestApp/only-compile-in-32-bits.m +7 -0
  475. data/ext/gyp/test/ios/app-bundle/TestApp/only-compile-in-64-bits.m +7 -0
  476. data/ext/gyp/test/ios/app-bundle/test-archs.gyp +109 -0
  477. data/ext/gyp/test/ios/app-bundle/test-assets-catalog.gyp +45 -0
  478. data/ext/gyp/test/ios/app-bundle/test-crosscompile.gyp +47 -0
  479. data/ext/gyp/test/ios/app-bundle/test-device.gyp +109 -0
  480. data/ext/gyp/test/ios/app-bundle/test.gyp +75 -0
  481. data/ext/gyp/test/ios/app-bundle/tool_main.cc +7 -0
  482. data/ext/gyp/test/ios/copies-with-xcode-envvars/Info.plist +24 -0
  483. data/ext/gyp/test/ios/copies-with-xcode-envvars/copies-with-xcode-envvars.gyp +97 -0
  484. data/ext/gyp/test/ios/copies-with-xcode-envvars/empty.c +1 -0
  485. data/ext/gyp/test/ios/copies-with-xcode-envvars/file0 +1 -0
  486. data/ext/gyp/test/ios/copies-with-xcode-envvars/file1 +1 -0
  487. data/ext/gyp/test/ios/copies-with-xcode-envvars/file10 +1 -0
  488. data/ext/gyp/test/ios/copies-with-xcode-envvars/file11 +1 -0
  489. data/ext/gyp/test/ios/copies-with-xcode-envvars/file2 +1 -0
  490. data/ext/gyp/test/ios/copies-with-xcode-envvars/file3 +1 -0
  491. data/ext/gyp/test/ios/copies-with-xcode-envvars/file4 +1 -0
  492. data/ext/gyp/test/ios/copies-with-xcode-envvars/file5 +1 -0
  493. data/ext/gyp/test/ios/copies-with-xcode-envvars/file6 +1 -0
  494. data/ext/gyp/test/ios/copies-with-xcode-envvars/file7 +1 -0
  495. data/ext/gyp/test/ios/copies-with-xcode-envvars/file8 +1 -0
  496. data/ext/gyp/test/ios/copies-with-xcode-envvars/file9 +1 -0
  497. data/ext/gyp/test/ios/deployment-target/check-version-min.c +33 -0
  498. data/ext/gyp/test/ios/deployment-target/deployment-target.gyp +34 -0
  499. data/ext/gyp/test/ios/extension/ActionExtension/ActionViewController.h +9 -0
  500. data/ext/gyp/test/ios/extension/ActionExtension/ActionViewController.m +31 -0
  501. data/ext/gyp/test/ios/extension/ActionExtension/Info.plist +42 -0
  502. data/ext/gyp/test/ios/extension/ActionExtension/MainInterface.storyboard +63 -0
  503. data/ext/gyp/test/ios/extension/ExtensionContainer/AppDelegate.h +12 -0
  504. data/ext/gyp/test/ios/extension/ExtensionContainer/AppDelegate.m +19 -0
  505. data/ext/gyp/test/ios/extension/ExtensionContainer/Base.lproj/Main.storyboard +25 -0
  506. data/ext/gyp/test/ios/extension/ExtensionContainer/Images.xcassets/AppIcon.appiconset/Contents.json +53 -0
  507. data/ext/gyp/test/ios/extension/ExtensionContainer/Images.xcassets/LaunchImage.launchimage/Contents.json +51 -0
  508. data/ext/gyp/test/ios/extension/ExtensionContainer/Info.plist +32 -0
  509. data/ext/gyp/test/ios/extension/ExtensionContainer/ViewController.h +11 -0
  510. data/ext/gyp/test/ios/extension/ExtensionContainer/ViewController.m +24 -0
  511. data/ext/gyp/test/ios/extension/ExtensionContainer/main.m +13 -0
  512. data/ext/gyp/test/ios/extension/extension.gyp +91 -0
  513. data/ext/gyp/test/ios/framework/framework.gyp +43 -0
  514. data/ext/gyp/test/ios/framework/iOSFramework/Info.plist +26 -0
  515. data/ext/gyp/test/ios/framework/iOSFramework/Thing.h +10 -0
  516. data/ext/gyp/test/ios/framework/iOSFramework/Thing.m +22 -0
  517. data/ext/gyp/test/ios/framework/iOSFramework/iOSFramework.h +9 -0
  518. data/ext/gyp/test/ios/gyptest-app-ios-assets-catalog.py +57 -0
  519. data/ext/gyp/test/ios/gyptest-app-ios.py +76 -0
  520. data/ext/gyp/test/ios/gyptest-archs.py +62 -0
  521. data/ext/gyp/test/ios/gyptest-copies-with-xcode-envvars.py +65 -0
  522. data/ext/gyp/test/ios/gyptest-crosscompile.py +34 -0
  523. data/ext/gyp/test/ios/gyptest-deployment-target.py +23 -0
  524. data/ext/gyp/test/ios/gyptest-extension.py +51 -0
  525. data/ext/gyp/test/ios/gyptest-framework.py +37 -0
  526. data/ext/gyp/test/ios/gyptest-per-config-settings.py +190 -0
  527. data/ext/gyp/test/ios/gyptest-watch.py +44 -0
  528. data/ext/gyp/test/ios/gyptest-xcode-ninja.py +25 -0
  529. data/ext/gyp/test/ios/watch/WatchApp/Images.xcassets/AppIcon.appiconset/Contents.json +62 -0
  530. data/ext/gyp/test/ios/watch/WatchApp/Images.xcassets/LaunchImage.launchimage/Contents.json +24 -0
  531. data/ext/gyp/test/ios/watch/WatchApp/Info.plist +35 -0
  532. data/ext/gyp/test/ios/watch/WatchApp/Interface.storyboard +15 -0
  533. data/ext/gyp/test/ios/watch/WatchContainer/AppDelegate.h +12 -0
  534. data/ext/gyp/test/ios/watch/WatchContainer/AppDelegate.m +19 -0
  535. data/ext/gyp/test/ios/watch/WatchContainer/Base.lproj/Main.storyboard +25 -0
  536. data/ext/gyp/test/ios/watch/WatchContainer/Images.xcassets/AppIcon.appiconset/Contents.json +53 -0
  537. data/ext/gyp/test/ios/watch/WatchContainer/Images.xcassets/LaunchImage.launchimage/Contents.json +51 -0
  538. data/ext/gyp/test/ios/watch/WatchContainer/Info.plist +32 -0
  539. data/ext/gyp/test/ios/watch/WatchContainer/ViewController.h +11 -0
  540. data/ext/gyp/test/ios/watch/WatchContainer/ViewController.m +24 -0
  541. data/ext/gyp/test/ios/watch/WatchContainer/main.m +13 -0
  542. data/ext/gyp/test/ios/watch/WatchKitExtension/Images.xcassets/MyImage.imageset/Contents.json +20 -0
  543. data/ext/gyp/test/ios/watch/WatchKitExtension/Info.plist +38 -0
  544. data/ext/gyp/test/ios/watch/WatchKitExtension/InterfaceController.h +10 -0
  545. data/ext/gyp/test/ios/watch/WatchKitExtension/InterfaceController.m +25 -0
  546. data/ext/gyp/test/ios/watch/WatchKitExtension/MainInterface.storyboard +63 -0
  547. data/ext/gyp/test/ios/watch/watch.gyp +105 -0
  548. data/ext/gyp/test/ios/xctests/App/AppDelegate.h +11 -0
  549. data/ext/gyp/test/ios/xctests/App/AppDelegate.m +18 -0
  550. data/ext/gyp/test/ios/xctests/App/Base.lproj/LaunchScreen.xib +41 -0
  551. data/ext/gyp/test/ios/xctests/App/Base.lproj/Main.storyboard +25 -0
  552. data/ext/gyp/test/ios/xctests/App/Images.xcassets/AppIcon.appiconset/Contents.json +68 -0
  553. data/ext/gyp/test/ios/xctests/App/Info.plist +47 -0
  554. data/ext/gyp/test/ios/xctests/App/ViewController.h +9 -0
  555. data/ext/gyp/test/ios/xctests/App/ViewController.m +21 -0
  556. data/ext/gyp/test/ios/xctests/App/main.m +13 -0
  557. data/ext/gyp/test/ios/xctests/AppTests/AppTests.m +31 -0
  558. data/ext/gyp/test/ios/xctests/AppTests/Info.plist +24 -0
  559. data/ext/gyp/test/ios/xctests/gyptest-xctests.py +49 -0
  560. data/ext/gyp/test/ios/xctests/xctests.gyp +74 -0
  561. data/ext/gyp/test/lib/README.txt +17 -0
  562. data/ext/gyp/test/lib/TestCmd.py +1597 -0
  563. data/ext/gyp/test/lib/TestCommon.py +591 -0
  564. data/ext/gyp/test/lib/TestGyp.py +1259 -0
  565. data/ext/gyp/test/lib/TestMac.py +76 -0
  566. data/ext/gyp/test/lib/TestWin.py +101 -0
  567. data/ext/gyp/test/library/gyptest-shared-obj-install-path.py +39 -0
  568. data/ext/gyp/test/library/gyptest-shared.py +84 -0
  569. data/ext/gyp/test/library/gyptest-static.py +84 -0
  570. data/ext/gyp/test/library/src/lib1.c +10 -0
  571. data/ext/gyp/test/library/src/lib1_moveable.c +10 -0
  572. data/ext/gyp/test/library/src/lib2.c +10 -0
  573. data/ext/gyp/test/library/src/lib2_moveable.c +10 -0
  574. data/ext/gyp/test/library/src/library.gyp +58 -0
  575. data/ext/gyp/test/library/src/program.c +15 -0
  576. data/ext/gyp/test/library/src/shared_dependency.gyp +33 -0
  577. data/ext/gyp/test/library_dirs/gyptest-library-dirs.py +50 -0
  578. data/ext/gyp/test/library_dirs/subdir/README.txt +1 -0
  579. data/ext/gyp/test/library_dirs/subdir/hello.cc +11 -0
  580. data/ext/gyp/test/library_dirs/subdir/mylib.cc +9 -0
  581. data/ext/gyp/test/library_dirs/subdir/mylib.h +12 -0
  582. data/ext/gyp/test/library_dirs/subdir/test-win.gyp +60 -0
  583. data/ext/gyp/test/library_dirs/subdir/test.gyp +68 -0
  584. data/ext/gyp/test/link-dependency/gyptest-link-dependency.py +23 -0
  585. data/ext/gyp/test/link-dependency/main.c +7 -0
  586. data/ext/gyp/test/link-dependency/mymalloc.c +12 -0
  587. data/ext/gyp/test/link-dependency/test.gyp +37 -0
  588. data/ext/gyp/test/link-objects/base.c +6 -0
  589. data/ext/gyp/test/link-objects/extra.c +5 -0
  590. data/ext/gyp/test/link-objects/gyptest-all.py +28 -0
  591. data/ext/gyp/test/link-objects/link-objects.gyp +24 -0
  592. data/ext/gyp/test/linux/gyptest-implicit-rpath.py +48 -0
  593. data/ext/gyp/test/linux/gyptest-ldflags-duplicates.py +22 -0
  594. data/ext/gyp/test/linux/gyptest-ldflags-from-environment.py +45 -0
  595. data/ext/gyp/test/linux/gyptest-target-rpath.py +43 -0
  596. data/ext/gyp/test/linux/implicit-rpath/file.c +1 -0
  597. data/ext/gyp/test/linux/implicit-rpath/main.c +1 -0
  598. data/ext/gyp/test/linux/implicit-rpath/test.gyp +47 -0
  599. data/ext/gyp/test/linux/ldflags-duplicates/check-ldflags.py +28 -0
  600. data/ext/gyp/test/linux/ldflags-duplicates/lib1.c +6 -0
  601. data/ext/gyp/test/linux/ldflags-duplicates/lib2.c +6 -0
  602. data/ext/gyp/test/linux/ldflags-duplicates/main.c +7 -0
  603. data/ext/gyp/test/linux/ldflags-duplicates/test.gyp +45 -0
  604. data/ext/gyp/test/linux/ldflags-from-environment/main.c +7 -0
  605. data/ext/gyp/test/linux/ldflags-from-environment/test.gyp +23 -0
  606. data/ext/gyp/test/linux/target-rpath/file.c +1 -0
  607. data/ext/gyp/test/linux/target-rpath/main.c +1 -0
  608. data/ext/gyp/test/linux/target-rpath/test.gyp +47 -0
  609. data/ext/gyp/test/mac/action-envvars/action/action.gyp +34 -0
  610. data/ext/gyp/test/mac/action-envvars/action/action.sh +8 -0
  611. data/ext/gyp/test/mac/app-bundle/TestApp/English.lproj/InfoPlist-error.strings +3 -0
  612. data/ext/gyp/test/mac/app-bundle/TestApp/English.lproj/InfoPlist.strings +3 -0
  613. data/ext/gyp/test/mac/app-bundle/TestApp/English.lproj/MainMenu.xib +4119 -0
  614. data/ext/gyp/test/mac/app-bundle/TestApp/English.lproj/utf-16be.strings +0 -0
  615. data/ext/gyp/test/mac/app-bundle/TestApp/English.lproj/utf-16le.strings +0 -0
  616. data/ext/gyp/test/mac/app-bundle/TestApp/Images.xcassets/AppIcon.appiconset/Contents.json +58 -0
  617. data/ext/gyp/test/mac/app-bundle/TestApp/Images.xcassets/image.imageset/Contents.json +23 -0
  618. data/ext/gyp/test/mac/app-bundle/TestApp/Images.xcassets/image.imageset/super_sylvain.png +0 -0
  619. data/ext/gyp/test/mac/app-bundle/TestApp/Images.xcassets/image.imageset/super_sylvain@2x.png +0 -0
  620. data/ext/gyp/test/mac/app-bundle/TestApp/Images.xcassets/image.imageset/super_sylvain@3x.png +0 -0
  621. data/ext/gyp/test/mac/app-bundle/TestApp/TestApp-Info.plist +34 -0
  622. data/ext/gyp/test/mac/app-bundle/TestApp/TestAppAppDelegate.h +13 -0
  623. data/ext/gyp/test/mac/app-bundle/TestApp/TestAppAppDelegate.m +15 -0
  624. data/ext/gyp/test/mac/app-bundle/TestApp/main.m +10 -0
  625. data/ext/gyp/test/mac/app-bundle/empty.c +0 -0
  626. data/ext/gyp/test/mac/app-bundle/test-assets-catalog.gyp +43 -0
  627. data/ext/gyp/test/mac/app-bundle/test-error.gyp +31 -0
  628. data/ext/gyp/test/mac/app-bundle/test.gyp +41 -0
  629. data/ext/gyp/test/mac/archs/empty_main.cc +1 -0
  630. data/ext/gyp/test/mac/archs/file.mm +1 -0
  631. data/ext/gyp/test/mac/archs/file_a.cc +8 -0
  632. data/ext/gyp/test/mac/archs/file_a.h +10 -0
  633. data/ext/gyp/test/mac/archs/file_b.cc +8 -0
  634. data/ext/gyp/test/mac/archs/file_b.h +10 -0
  635. data/ext/gyp/test/mac/archs/file_c.cc +11 -0
  636. data/ext/gyp/test/mac/archs/file_d.cc +11 -0
  637. data/ext/gyp/test/mac/archs/header.h +1 -0
  638. data/ext/gyp/test/mac/archs/my_file.cc +4 -0
  639. data/ext/gyp/test/mac/archs/my_main_file.cc +9 -0
  640. data/ext/gyp/test/mac/archs/test-archs-multiarch.gyp +92 -0
  641. data/ext/gyp/test/mac/archs/test-archs-x86_64.gyp +27 -0
  642. data/ext/gyp/test/mac/archs/test-dependencies.gyp +92 -0
  643. data/ext/gyp/test/mac/archs/test-no-archs.gyp +21 -0
  644. data/ext/gyp/test/mac/archs/test-valid-archs.gyp +28 -0
  645. data/ext/gyp/test/mac/bundle-resources/change.sh +3 -0
  646. data/ext/gyp/test/mac/bundle-resources/executable-file.sh +3 -0
  647. data/ext/gyp/test/mac/bundle-resources/secret.txt +1 -0
  648. data/ext/gyp/test/mac/bundle-resources/test.gyp +59 -0
  649. data/ext/gyp/test/mac/cflags/ccfile.cc +7 -0
  650. data/ext/gyp/test/mac/cflags/ccfile_withcflags.cc +7 -0
  651. data/ext/gyp/test/mac/cflags/cfile.c +7 -0
  652. data/ext/gyp/test/mac/cflags/cppfile.cpp +7 -0
  653. data/ext/gyp/test/mac/cflags/cppfile_withcflags.cpp +7 -0
  654. data/ext/gyp/test/mac/cflags/cxxfile.cxx +7 -0
  655. data/ext/gyp/test/mac/cflags/cxxfile_withcflags.cxx +7 -0
  656. data/ext/gyp/test/mac/cflags/mfile.m +7 -0
  657. data/ext/gyp/test/mac/cflags/mmfile.mm +7 -0
  658. data/ext/gyp/test/mac/cflags/mmfile_withcflags.mm +7 -0
  659. data/ext/gyp/test/mac/cflags/test.gyp +132 -0
  660. data/ext/gyp/test/mac/clang-cxx-language-standard/c++11.cc +8 -0
  661. data/ext/gyp/test/mac/clang-cxx-language-standard/c++98.cc +24 -0
  662. data/ext/gyp/test/mac/clang-cxx-language-standard/clang-cxx-language-standard.gyp +30 -0
  663. data/ext/gyp/test/mac/clang-cxx-library/clang-cxx-library.gyp +32 -0
  664. data/ext/gyp/test/mac/clang-cxx-library/libc++.cc +11 -0
  665. data/ext/gyp/test/mac/clang-cxx-library/libstdc++.cc +11 -0
  666. data/ext/gyp/test/mac/copies-with-xcode-envvars/copies-with-xcode-envvars.gyp +87 -0
  667. data/ext/gyp/test/mac/copies-with-xcode-envvars/empty.c +1 -0
  668. data/ext/gyp/test/mac/copies-with-xcode-envvars/file0 +1 -0
  669. data/ext/gyp/test/mac/copies-with-xcode-envvars/file1 +1 -0
  670. data/ext/gyp/test/mac/copies-with-xcode-envvars/file10 +1 -0
  671. data/ext/gyp/test/mac/copies-with-xcode-envvars/file11 +1 -0
  672. data/ext/gyp/test/mac/copies-with-xcode-envvars/file2 +1 -0
  673. data/ext/gyp/test/mac/copies-with-xcode-envvars/file3 +1 -0
  674. data/ext/gyp/test/mac/copies-with-xcode-envvars/file4 +1 -0
  675. data/ext/gyp/test/mac/copies-with-xcode-envvars/file5 +1 -0
  676. data/ext/gyp/test/mac/copies-with-xcode-envvars/file6 +1 -0
  677. data/ext/gyp/test/mac/copies-with-xcode-envvars/file7 +1 -0
  678. data/ext/gyp/test/mac/copies-with-xcode-envvars/file8 +1 -0
  679. data/ext/gyp/test/mac/copies-with-xcode-envvars/file9 +1 -0
  680. data/ext/gyp/test/mac/copy-dylib/empty.c +1 -0
  681. data/ext/gyp/test/mac/copy-dylib/test.gyp +31 -0
  682. data/ext/gyp/test/mac/debuginfo/file.c +6 -0
  683. data/ext/gyp/test/mac/debuginfo/test.gyp +82 -0
  684. data/ext/gyp/test/mac/depend-on-bundle/English.lproj/InfoPlist.strings +1 -0
  685. data/ext/gyp/test/mac/depend-on-bundle/Info.plist +28 -0
  686. data/ext/gyp/test/mac/depend-on-bundle/bundle.c +1 -0
  687. data/ext/gyp/test/mac/depend-on-bundle/executable.c +4 -0
  688. data/ext/gyp/test/mac/depend-on-bundle/test.gyp +28 -0
  689. data/ext/gyp/test/mac/deployment-target/check-version-min.c +33 -0
  690. data/ext/gyp/test/mac/deployment-target/deployment-target.gyp +28 -0
  691. data/ext/gyp/test/mac/framework/TestFramework/English.lproj/InfoPlist.strings +2 -0
  692. data/ext/gyp/test/mac/framework/TestFramework/Info.plist +28 -0
  693. data/ext/gyp/test/mac/framework/TestFramework/ObjCVector.h +28 -0
  694. data/ext/gyp/test/mac/framework/TestFramework/ObjCVector.mm +63 -0
  695. data/ext/gyp/test/mac/framework/TestFramework/ObjCVectorInternal.h +9 -0
  696. data/ext/gyp/test/mac/framework/TestFramework/TestFramework_Prefix.pch +7 -0
  697. data/ext/gyp/test/mac/framework/empty.c +0 -0
  698. data/ext/gyp/test/mac/framework/framework.gyp +108 -0
  699. data/ext/gyp/test/mac/framework-dirs/calculate.c +15 -0
  700. data/ext/gyp/test/mac/framework-dirs/framework-dirs.gyp +21 -0
  701. data/ext/gyp/test/mac/framework-headers/myframework.h +8 -0
  702. data/ext/gyp/test/mac/framework-headers/myframework.m +8 -0
  703. data/ext/gyp/test/mac/framework-headers/test.gyp +44 -0
  704. data/ext/gyp/test/mac/global-settings/src/dir1/dir1.gyp +11 -0
  705. data/ext/gyp/test/mac/global-settings/src/dir2/dir2.gyp +22 -0
  706. data/ext/gyp/test/mac/global-settings/src/dir2/file.txt +1 -0
  707. data/ext/gyp/test/mac/gyptest-action-envvars.py +36 -0
  708. data/ext/gyp/test/mac/gyptest-app-assets-catalog.py +125 -0
  709. data/ext/gyp/test/mac/gyptest-app-error.py +49 -0
  710. data/ext/gyp/test/mac/gyptest-app.py +122 -0
  711. data/ext/gyp/test/mac/gyptest-archs.py +96 -0
  712. data/ext/gyp/test/mac/gyptest-bundle-resources.py +64 -0
  713. data/ext/gyp/test/mac/gyptest-cflags.py +21 -0
  714. data/ext/gyp/test/mac/gyptest-clang-cxx-language-standard.py +25 -0
  715. data/ext/gyp/test/mac/gyptest-clang-cxx-library.py +32 -0
  716. data/ext/gyp/test/mac/gyptest-copies-with-xcode-envvars.py +65 -0
  717. data/ext/gyp/test/mac/gyptest-copies.py +62 -0
  718. data/ext/gyp/test/mac/gyptest-copy-dylib.py +25 -0
  719. data/ext/gyp/test/mac/gyptest-debuginfo.py +36 -0
  720. data/ext/gyp/test/mac/gyptest-depend-on-bundle.py +45 -0
  721. data/ext/gyp/test/mac/gyptest-deployment-target.py +27 -0
  722. data/ext/gyp/test/mac/gyptest-framework-dirs.py +23 -0
  723. data/ext/gyp/test/mac/gyptest-framework-headers.py +38 -0
  724. data/ext/gyp/test/mac/gyptest-framework.py +80 -0
  725. data/ext/gyp/test/mac/gyptest-global-settings.py +33 -0
  726. data/ext/gyp/test/mac/gyptest-identical-name.py +45 -0
  727. data/ext/gyp/test/mac/gyptest-infoplist-process.py +56 -0
  728. data/ext/gyp/test/mac/gyptest-installname.py +85 -0
  729. data/ext/gyp/test/mac/gyptest-kext.py +27 -0
  730. data/ext/gyp/test/mac/gyptest-ldflags-passed-to-libtool.py +37 -0
  731. data/ext/gyp/test/mac/gyptest-ldflags.py +74 -0
  732. data/ext/gyp/test/mac/gyptest-libraries.py +30 -0
  733. data/ext/gyp/test/mac/gyptest-libtool-zero.py +26 -0
  734. data/ext/gyp/test/mac/gyptest-loadable-module-bundle-product-extension.py +31 -0
  735. data/ext/gyp/test/mac/gyptest-loadable-module.py +54 -0
  736. data/ext/gyp/test/mac/gyptest-lto.py +66 -0
  737. data/ext/gyp/test/mac/gyptest-missing-cfbundlesignature.py +34 -0
  738. data/ext/gyp/test/mac/gyptest-non-strs-flattened-to-env.py +38 -0
  739. data/ext/gyp/test/mac/gyptest-objc-arc.py +27 -0
  740. data/ext/gyp/test/mac/gyptest-objc-gc.py +51 -0
  741. data/ext/gyp/test/mac/gyptest-postbuild-copy-bundle.py +75 -0
  742. data/ext/gyp/test/mac/gyptest-postbuild-defaults.py +34 -0
  743. data/ext/gyp/test/mac/gyptest-postbuild-fail.py +71 -0
  744. data/ext/gyp/test/mac/gyptest-postbuild-multiple-configurations.py +26 -0
  745. data/ext/gyp/test/mac/gyptest-postbuild-static-library.py +28 -0
  746. data/ext/gyp/test/mac/gyptest-postbuild.py +53 -0
  747. data/ext/gyp/test/mac/gyptest-prefixheader.py +20 -0
  748. data/ext/gyp/test/mac/gyptest-rebuild.py +46 -0
  749. data/ext/gyp/test/mac/gyptest-rpath.py +50 -0
  750. data/ext/gyp/test/mac/gyptest-sdkroot.py +56 -0
  751. data/ext/gyp/test/mac/gyptest-sourceless-module.py +77 -0
  752. data/ext/gyp/test/mac/gyptest-strip-default.py +97 -0
  753. data/ext/gyp/test/mac/gyptest-strip.py +66 -0
  754. data/ext/gyp/test/mac/gyptest-swift-library.py +67 -0
  755. data/ext/gyp/test/mac/gyptest-type-envvars.py +26 -0
  756. data/ext/gyp/test/mac/gyptest-unicode-settings.py +20 -0
  757. data/ext/gyp/test/mac/gyptest-xcode-env-order.py +95 -0
  758. data/ext/gyp/test/mac/gyptest-xcode-gcc-clang.py +40 -0
  759. data/ext/gyp/test/mac/gyptest-xcode-gcc.py +60 -0
  760. data/ext/gyp/test/mac/gyptest-xcode-support-actions.py +25 -0
  761. data/ext/gyp/test/mac/gyptest-xctest.py +41 -0
  762. data/ext/gyp/test/mac/gyptest-xcuitest.py +39 -0
  763. data/ext/gyp/test/mac/identical-name/proxy/proxy.cc +2 -0
  764. data/ext/gyp/test/mac/identical-name/proxy/proxy.gyp +9 -0
  765. data/ext/gyp/test/mac/identical-name/proxy/testlib/testlib.cc +2 -0
  766. data/ext/gyp/test/mac/identical-name/proxy/testlib/testlib.gyp +8 -0
  767. data/ext/gyp/test/mac/identical-name/test-should-fail.gyp +10 -0
  768. data/ext/gyp/test/mac/identical-name/test.gyp +11 -0
  769. data/ext/gyp/test/mac/identical-name/test.gypi +7 -0
  770. data/ext/gyp/test/mac/identical-name/testlib/main.cc +3 -0
  771. data/ext/gyp/test/mac/identical-name/testlib/testlib.gyp +14 -0
  772. data/ext/gyp/test/mac/identical-name/testlib/void.cc +2 -0
  773. data/ext/gyp/test/mac/infoplist-process/Info.plist +36 -0
  774. data/ext/gyp/test/mac/infoplist-process/main.c +7 -0
  775. data/ext/gyp/test/mac/infoplist-process/test1.gyp +25 -0
  776. data/ext/gyp/test/mac/infoplist-process/test2.gyp +25 -0
  777. data/ext/gyp/test/mac/infoplist-process/test3.gyp +25 -0
  778. data/ext/gyp/test/mac/installname/Info.plist +28 -0
  779. data/ext/gyp/test/mac/installname/file.c +1 -0
  780. data/ext/gyp/test/mac/installname/main.c +1 -0
  781. data/ext/gyp/test/mac/installname/test.gyp +93 -0
  782. data/ext/gyp/test/mac/kext/GypKext/GypKext-Info.plist +35 -0
  783. data/ext/gyp/test/mac/kext/GypKext/GypKext.c +16 -0
  784. data/ext/gyp/test/mac/kext/kext.gyp +18 -0
  785. data/ext/gyp/test/mac/ldflags/subdirectory/Info.plist +8 -0
  786. data/ext/gyp/test/mac/ldflags/subdirectory/file.c +2 -0
  787. data/ext/gyp/test/mac/ldflags/subdirectory/symbol_list.def +1 -0
  788. data/ext/gyp/test/mac/ldflags/subdirectory/test.gyp +66 -0
  789. data/ext/gyp/test/mac/ldflags-libtool/file.c +1 -0
  790. data/ext/gyp/test/mac/ldflags-libtool/test.gyp +17 -0
  791. data/ext/gyp/test/mac/libraries/subdir/README.txt +1 -0
  792. data/ext/gyp/test/mac/libraries/subdir/hello.cc +10 -0
  793. data/ext/gyp/test/mac/libraries/subdir/mylib.c +7 -0
  794. data/ext/gyp/test/mac/libraries/subdir/test.gyp +65 -0
  795. data/ext/gyp/test/mac/libtool-zero/mylib.c +7 -0
  796. data/ext/gyp/test/mac/libtool-zero/test.gyp +18 -0
  797. data/ext/gyp/test/mac/loadable-module/Info.plist +26 -0
  798. data/ext/gyp/test/mac/loadable-module/module.c +11 -0
  799. data/ext/gyp/test/mac/loadable-module/test.gyp +18 -0
  800. data/ext/gyp/test/mac/loadable-module-bundle-product-extension/src.cc +7 -0
  801. data/ext/gyp/test/mac/loadable-module-bundle-product-extension/test.gyp +24 -0
  802. data/ext/gyp/test/mac/lto/asmfile.S +2 -0
  803. data/ext/gyp/test/mac/lto/ccfile.cc +1 -0
  804. data/ext/gyp/test/mac/lto/cfile.c +1 -0
  805. data/ext/gyp/test/mac/lto/mfile.m +1 -0
  806. data/ext/gyp/test/mac/lto/mmfile.mm +1 -0
  807. data/ext/gyp/test/mac/lto/test.gyp +35 -0
  808. data/ext/gyp/test/mac/missing-cfbundlesignature/Info.plist +10 -0
  809. data/ext/gyp/test/mac/missing-cfbundlesignature/Other-Info.plist +12 -0
  810. data/ext/gyp/test/mac/missing-cfbundlesignature/Third-Info.plist +12 -0
  811. data/ext/gyp/test/mac/missing-cfbundlesignature/file.c +1 -0
  812. data/ext/gyp/test/mac/missing-cfbundlesignature/test.gyp +34 -0
  813. data/ext/gyp/test/mac/non-strs-flattened-to-env/Info.plist +15 -0
  814. data/ext/gyp/test/mac/non-strs-flattened-to-env/main.c +7 -0
  815. data/ext/gyp/test/mac/non-strs-flattened-to-env/test.gyp +27 -0
  816. data/ext/gyp/test/mac/objc-arc/c-file.c +5 -0
  817. data/ext/gyp/test/mac/objc-arc/cc-file.cc +5 -0
  818. data/ext/gyp/test/mac/objc-arc/m-file-arc-weak.m +9 -0
  819. data/ext/gyp/test/mac/objc-arc/m-file-no-arc.m +9 -0
  820. data/ext/gyp/test/mac/objc-arc/m-file.m +9 -0
  821. data/ext/gyp/test/mac/objc-arc/mm-file-arc-weak.mm +9 -0
  822. data/ext/gyp/test/mac/objc-arc/mm-file-no-arc.mm +9 -0
  823. data/ext/gyp/test/mac/objc-arc/mm-file.mm +9 -0
  824. data/ext/gyp/test/mac/objc-arc/test.gyp +53 -0
  825. data/ext/gyp/test/mac/objc-gc/c-file.c +1 -0
  826. data/ext/gyp/test/mac/objc-gc/cc-file.cc +1 -0
  827. data/ext/gyp/test/mac/objc-gc/main.m +6 -0
  828. data/ext/gyp/test/mac/objc-gc/needs-gc-mm.mm +1 -0
  829. data/ext/gyp/test/mac/objc-gc/needs-gc.m +1 -0
  830. data/ext/gyp/test/mac/objc-gc/test.gyp +102 -0
  831. data/ext/gyp/test/mac/postbuild-copy-bundle/Framework-Info.plist +30 -0
  832. data/ext/gyp/test/mac/postbuild-copy-bundle/TestApp-Info.plist +32 -0
  833. data/ext/gyp/test/mac/postbuild-copy-bundle/copied.txt +1 -0
  834. data/ext/gyp/test/mac/postbuild-copy-bundle/empty.c +0 -0
  835. data/ext/gyp/test/mac/postbuild-copy-bundle/main.c +4 -0
  836. data/ext/gyp/test/mac/postbuild-copy-bundle/postbuild-copy-framework.sh +9 -0
  837. data/ext/gyp/test/mac/postbuild-copy-bundle/resource_file.sb +1 -0
  838. data/ext/gyp/test/mac/postbuild-copy-bundle/test.gyp +49 -0
  839. data/ext/gyp/test/mac/postbuild-defaults/Info.plist +13 -0
  840. data/ext/gyp/test/mac/postbuild-defaults/main.c +7 -0
  841. data/ext/gyp/test/mac/postbuild-defaults/postbuild-defaults.sh +15 -0
  842. data/ext/gyp/test/mac/postbuild-defaults/test.gyp +26 -0
  843. data/ext/gyp/test/mac/postbuild-fail/file.c +6 -0
  844. data/ext/gyp/test/mac/postbuild-fail/postbuild-fail.sh +6 -0
  845. data/ext/gyp/test/mac/postbuild-fail/test.gyp +38 -0
  846. data/ext/gyp/test/mac/postbuild-fail/touch-dynamic.sh +7 -0
  847. data/ext/gyp/test/mac/postbuild-fail/touch-static.sh +7 -0
  848. data/ext/gyp/test/mac/postbuild-multiple-configurations/main.c +4 -0
  849. data/ext/gyp/test/mac/postbuild-multiple-configurations/postbuild-touch-file.sh +7 -0
  850. data/ext/gyp/test/mac/postbuild-multiple-configurations/test.gyp +26 -0
  851. data/ext/gyp/test/mac/postbuild-static-library/empty.c +4 -0
  852. data/ext/gyp/test/mac/postbuild-static-library/postbuild-touch-file.sh +7 -0
  853. data/ext/gyp/test/mac/postbuild-static-library/test.gyp +34 -0
  854. data/ext/gyp/test/mac/postbuilds/copy.sh +3 -0
  855. data/ext/gyp/test/mac/postbuilds/file.c +4 -0
  856. data/ext/gyp/test/mac/postbuilds/file_g.c +4 -0
  857. data/ext/gyp/test/mac/postbuilds/file_h.c +4 -0
  858. data/ext/gyp/test/mac/postbuilds/script/shared_library_postbuild.sh +23 -0
  859. data/ext/gyp/test/mac/postbuilds/script/static_library_postbuild.sh +23 -0
  860. data/ext/gyp/test/mac/postbuilds/subdirectory/copied_file.txt +1 -0
  861. data/ext/gyp/test/mac/postbuilds/subdirectory/nested_target.gyp +53 -0
  862. data/ext/gyp/test/mac/postbuilds/test.gyp +93 -0
  863. data/ext/gyp/test/mac/prefixheader/file.c +1 -0
  864. data/ext/gyp/test/mac/prefixheader/file.cc +1 -0
  865. data/ext/gyp/test/mac/prefixheader/file.m +1 -0
  866. data/ext/gyp/test/mac/prefixheader/file.mm +1 -0
  867. data/ext/gyp/test/mac/prefixheader/header.h +1 -0
  868. data/ext/gyp/test/mac/prefixheader/test.gyp +82 -0
  869. data/ext/gyp/test/mac/rebuild/TestApp-Info.plist +32 -0
  870. data/ext/gyp/test/mac/rebuild/delay-touch.sh +6 -0
  871. data/ext/gyp/test/mac/rebuild/empty.c +0 -0
  872. data/ext/gyp/test/mac/rebuild/main.c +1 -0
  873. data/ext/gyp/test/mac/rebuild/test.gyp +56 -0
  874. data/ext/gyp/test/mac/rpath/file.c +1 -0
  875. data/ext/gyp/test/mac/rpath/main.c +1 -0
  876. data/ext/gyp/test/mac/rpath/test.gyp +48 -0
  877. data/ext/gyp/test/mac/sdkroot/file.cc +5 -0
  878. data/ext/gyp/test/mac/sdkroot/test.gyp +35 -0
  879. data/ext/gyp/test/mac/sdkroot/test_shorthand.sh +20 -0
  880. data/ext/gyp/test/mac/sourceless-module/empty.c +1 -0
  881. data/ext/gyp/test/mac/sourceless-module/empty.txt +2 -0
  882. data/ext/gyp/test/mac/sourceless-module/fun.c +1 -0
  883. data/ext/gyp/test/mac/sourceless-module/test.gyp +96 -0
  884. data/ext/gyp/test/mac/strip/file.c +22 -0
  885. data/ext/gyp/test/mac/strip/main.c +25 -0
  886. data/ext/gyp/test/mac/strip/strip.saves +5 -0
  887. data/ext/gyp/test/mac/strip/subdirectory/nested_file.c +1 -0
  888. data/ext/gyp/test/mac/strip/subdirectory/nested_strip.saves +5 -0
  889. data/ext/gyp/test/mac/strip/subdirectory/subdirectory.gyp +38 -0
  890. data/ext/gyp/test/mac/strip/subdirectory/test_reading_save_file_from_postbuild.sh +5 -0
  891. data/ext/gyp/test/mac/strip/test-defaults.gyp +51 -0
  892. data/ext/gyp/test/mac/strip/test.gyp +119 -0
  893. data/ext/gyp/test/mac/swift-library/Info.plist +28 -0
  894. data/ext/gyp/test/mac/swift-library/file.swift +9 -0
  895. data/ext/gyp/test/mac/swift-library/test.gyp +21 -0
  896. data/ext/gyp/test/mac/type_envvars/file.c +6 -0
  897. data/ext/gyp/test/mac/type_envvars/test.gyp +100 -0
  898. data/ext/gyp/test/mac/type_envvars/test_bundle_executable.sh +30 -0
  899. data/ext/gyp/test/mac/type_envvars/test_bundle_loadable_module.sh +35 -0
  900. data/ext/gyp/test/mac/type_envvars/test_bundle_shared_library.sh +38 -0
  901. data/ext/gyp/test/mac/type_envvars/test_check_sdkroot.sh +47 -0
  902. data/ext/gyp/test/mac/type_envvars/test_nonbundle_executable.sh +33 -0
  903. data/ext/gyp/test/mac/type_envvars/test_nonbundle_loadable_module.sh +31 -0
  904. data/ext/gyp/test/mac/type_envvars/test_nonbundle_none.sh +32 -0
  905. data/ext/gyp/test/mac/type_envvars/test_nonbundle_shared_library.sh +31 -0
  906. data/ext/gyp/test/mac/type_envvars/test_nonbundle_static_library.sh +31 -0
  907. data/ext/gyp/test/mac/unicode-settings/file.cc +2 -0
  908. data/ext/gyp/test/mac/unicode-settings/test.gyp +23 -0
  909. data/ext/gyp/test/mac/unicode-settings/test_bundle_display_name.sh +7 -0
  910. data/ext/gyp/test/mac/xcode-env-order/Info.plist +56 -0
  911. data/ext/gyp/test/mac/xcode-env-order/file.ext1 +0 -0
  912. data/ext/gyp/test/mac/xcode-env-order/file.ext2 +0 -0
  913. data/ext/gyp/test/mac/xcode-env-order/file.ext3 +0 -0
  914. data/ext/gyp/test/mac/xcode-env-order/main.c +7 -0
  915. data/ext/gyp/test/mac/xcode-env-order/test.gyp +121 -0
  916. data/ext/gyp/test/mac/xcode-gcc/aliasing.cc +13 -0
  917. data/ext/gyp/test/mac/xcode-gcc/test-clang.gyp +42 -0
  918. data/ext/gyp/test/mac/xcode-gcc/test.gyp +60 -0
  919. data/ext/gyp/test/mac/xcode-gcc/valid_c.c +8 -0
  920. data/ext/gyp/test/mac/xcode-gcc/valid_cc.cc +8 -0
  921. data/ext/gyp/test/mac/xcode-gcc/valid_m.m +8 -0
  922. data/ext/gyp/test/mac/xcode-gcc/valid_mm.mm +8 -0
  923. data/ext/gyp/test/mac/xcode-gcc/warn_about_invalid_offsetof_macro.cc +15 -0
  924. data/ext/gyp/test/mac/xcode-gcc/warn_about_missing_newline.c +8 -0
  925. data/ext/gyp/test/mac/xcode-support-actions/source.c +0 -0
  926. data/ext/gyp/test/mac/xcode-support-actions/test.gyp +26 -0
  927. data/ext/gyp/test/mac/xctest/MyClass.h +8 -0
  928. data/ext/gyp/test/mac/xctest/MyClass.m +8 -0
  929. data/ext/gyp/test/mac/xctest/TestCase.m +16 -0
  930. data/ext/gyp/test/mac/xctest/resource.txt +1 -0
  931. data/ext/gyp/test/mac/xctest/test.gyp +47 -0
  932. data/ext/gyp/test/mac/xctest/test.xcodeproj/xcshareddata/xcschemes/classes.xcscheme +69 -0
  933. data/ext/gyp/test/mac/xcuitest/Info.plist +28 -0
  934. data/ext/gyp/test/mac/xcuitest/MyAppDelegate.h +8 -0
  935. data/ext/gyp/test/mac/xcuitest/MyAppDelegate.m +19 -0
  936. data/ext/gyp/test/mac/xcuitest/TestCase.m +15 -0
  937. data/ext/gyp/test/mac/xcuitest/main.m +15 -0
  938. data/ext/gyp/test/mac/xcuitest/resource.txt +1 -0
  939. data/ext/gyp/test/mac/xcuitest/test.gyp +69 -0
  940. data/ext/gyp/test/make/dependencies.gyp +15 -0
  941. data/ext/gyp/test/make/gyptest-dependencies.py +26 -0
  942. data/ext/gyp/test/make/gyptest-noload.py +57 -0
  943. data/ext/gyp/test/make/main.cc +12 -0
  944. data/ext/gyp/test/make/main.h +0 -0
  945. data/ext/gyp/test/make/noload/all.gyp +18 -0
  946. data/ext/gyp/test/make/noload/lib/shared.c +3 -0
  947. data/ext/gyp/test/make/noload/lib/shared.gyp +16 -0
  948. data/ext/gyp/test/make/noload/lib/shared.h +1 -0
  949. data/ext/gyp/test/make/noload/main.c +9 -0
  950. data/ext/gyp/test/make_global_settings/ar/gyptest-make_global_settings_ar.py +126 -0
  951. data/ext/gyp/test/make_global_settings/ar/make_global_settings_ar.gyp +29 -0
  952. data/ext/gyp/test/make_global_settings/basics/gyptest-make_global_settings.py +51 -0
  953. data/ext/gyp/test/make_global_settings/basics/make_global_settings.gyp +17 -0
  954. data/ext/gyp/test/make_global_settings/env-wrapper/gyptest-wrapper.py +51 -0
  955. data/ext/gyp/test/make_global_settings/env-wrapper/wrapper.gyp +17 -0
  956. data/ext/gyp/test/make_global_settings/full-toolchain/bar.cc +1 -0
  957. data/ext/gyp/test/make_global_settings/full-toolchain/foo.c +1 -0
  958. data/ext/gyp/test/make_global_settings/full-toolchain/gyptest-make_global_settings.py +53 -0
  959. data/ext/gyp/test/make_global_settings/full-toolchain/make_global_settings.gyp +22 -0
  960. data/ext/gyp/test/make_global_settings/full-toolchain/my_nm.py +9 -0
  961. data/ext/gyp/test/make_global_settings/full-toolchain/my_readelf.py +9 -0
  962. data/ext/gyp/test/make_global_settings/ld/gyptest-make_global_settings_ld.py +130 -0
  963. data/ext/gyp/test/make_global_settings/ld/make_global_settings_ld.gyp +29 -0
  964. data/ext/gyp/test/make_global_settings/wrapper/gyptest-wrapper.py +52 -0
  965. data/ext/gyp/test/make_global_settings/wrapper/wrapper.gyp +21 -0
  966. data/ext/gyp/test/many-actions/file0 +0 -0
  967. data/ext/gyp/test/many-actions/file1 +0 -0
  968. data/ext/gyp/test/many-actions/file2 +0 -0
  969. data/ext/gyp/test/many-actions/file3 +0 -0
  970. data/ext/gyp/test/many-actions/file4 +0 -0
  971. data/ext/gyp/test/many-actions/gyptest-many-actions-unsorted.py +43 -0
  972. data/ext/gyp/test/many-actions/gyptest-many-actions.py +29 -0
  973. data/ext/gyp/test/many-actions/many-actions-unsorted.gyp +154 -0
  974. data/ext/gyp/test/many-actions/many-actions.gyp +1817 -0
  975. data/ext/gyp/test/module/gyptest-default.py +28 -0
  976. data/ext/gyp/test/module/src/lib1.c +10 -0
  977. data/ext/gyp/test/module/src/lib2.c +10 -0
  978. data/ext/gyp/test/module/src/module.gyp +53 -0
  979. data/ext/gyp/test/module/src/program.c +111 -0
  980. data/ext/gyp/test/msvs/buildevents/buildevents.gyp +14 -0
  981. data/ext/gyp/test/msvs/buildevents/gyptest-msbuild-supports-prepostbuild.py +24 -0
  982. data/ext/gyp/test/msvs/buildevents/gyptest-ninja-warnings.py +29 -0
  983. data/ext/gyp/test/msvs/buildevents/main.cc +5 -0
  984. data/ext/gyp/test/msvs/config_attrs/gyptest-config_attrs.py +41 -0
  985. data/ext/gyp/test/msvs/config_attrs/hello.c +11 -0
  986. data/ext/gyp/test/msvs/config_attrs/hello.gyp +21 -0
  987. data/ext/gyp/test/msvs/express/base/base.gyp +22 -0
  988. data/ext/gyp/test/msvs/express/express.gyp +19 -0
  989. data/ext/gyp/test/msvs/express/gyptest-express.py +29 -0
  990. data/ext/gyp/test/msvs/external_builder/external.gyp +68 -0
  991. data/ext/gyp/test/msvs/external_builder/external_builder.py +9 -0
  992. data/ext/gyp/test/msvs/external_builder/gyptest-all.py +59 -0
  993. data/ext/gyp/test/msvs/external_builder/hello.cpp +10 -0
  994. data/ext/gyp/test/msvs/external_builder/hello.z +6 -0
  995. data/ext/gyp/test/msvs/external_builder/msbuild_action.py +9 -0
  996. data/ext/gyp/test/msvs/external_builder/msbuild_rule.py +11 -0
  997. data/ext/gyp/test/msvs/filters/filters.gyp +47 -0
  998. data/ext/gyp/test/msvs/filters/gyptest-filters-2008.py +68 -0
  999. data/ext/gyp/test/msvs/filters/gyptest-filters-2010.py +57 -0
  1000. data/ext/gyp/test/msvs/list_excluded/gyptest-all.py +51 -0
  1001. data/ext/gyp/test/msvs/list_excluded/hello.cpp +10 -0
  1002. data/ext/gyp/test/msvs/list_excluded/hello_exclude.gyp +19 -0
  1003. data/ext/gyp/test/msvs/list_excluded/hello_mac.cpp +10 -0
  1004. data/ext/gyp/test/msvs/missing_sources/gyptest-missing.py +43 -0
  1005. data/ext/gyp/test/msvs/missing_sources/hello_missing.gyp +15 -0
  1006. data/ext/gyp/test/msvs/multiple_actions_error_handling/action_fail.py +7 -0
  1007. data/ext/gyp/test/msvs/multiple_actions_error_handling/action_succeed.py +7 -0
  1008. data/ext/gyp/test/msvs/multiple_actions_error_handling/actions.gyp +40 -0
  1009. data/ext/gyp/test/msvs/multiple_actions_error_handling/gyptest.py +26 -0
  1010. data/ext/gyp/test/msvs/props/AppName.props +14 -0
  1011. data/ext/gyp/test/msvs/props/AppName.vsprops +11 -0
  1012. data/ext/gyp/test/msvs/props/gyptest-props.py +22 -0
  1013. data/ext/gyp/test/msvs/props/hello.c +11 -0
  1014. data/ext/gyp/test/msvs/props/hello.gyp +22 -0
  1015. data/ext/gyp/test/msvs/rules_stdout_stderr/dummy.bar +5 -0
  1016. data/ext/gyp/test/msvs/rules_stdout_stderr/dummy.foo +5 -0
  1017. data/ext/gyp/test/msvs/rules_stdout_stderr/gyptest-rules-stdout-stderr.py +29 -0
  1018. data/ext/gyp/test/msvs/rules_stdout_stderr/rule_stderr.py +8 -0
  1019. data/ext/gyp/test/msvs/rules_stdout_stderr/rule_stdout.py +7 -0
  1020. data/ext/gyp/test/msvs/rules_stdout_stderr/rules-stdout-stderr.gyp +52 -0
  1021. data/ext/gyp/test/msvs/shared_output/common.gypi +17 -0
  1022. data/ext/gyp/test/msvs/shared_output/gyptest-shared_output.py +41 -0
  1023. data/ext/gyp/test/msvs/shared_output/hello.c +12 -0
  1024. data/ext/gyp/test/msvs/shared_output/hello.gyp +21 -0
  1025. data/ext/gyp/test/msvs/shared_output/there/there.c +12 -0
  1026. data/ext/gyp/test/msvs/shared_output/there/there.gyp +16 -0
  1027. data/ext/gyp/test/msvs/uldi2010/gyptest-all.py +20 -0
  1028. data/ext/gyp/test/msvs/uldi2010/hello.c +13 -0
  1029. data/ext/gyp/test/msvs/uldi2010/hello.gyp +26 -0
  1030. data/ext/gyp/test/msvs/uldi2010/hello2.c +10 -0
  1031. data/ext/gyp/test/multiple-targets/gyptest-all.py +30 -0
  1032. data/ext/gyp/test/multiple-targets/gyptest-default.py +30 -0
  1033. data/ext/gyp/test/multiple-targets/src/common.c +7 -0
  1034. data/ext/gyp/test/multiple-targets/src/multiple.gyp +24 -0
  1035. data/ext/gyp/test/multiple-targets/src/prog1.c +10 -0
  1036. data/ext/gyp/test/multiple-targets/src/prog2.c +10 -0
  1037. data/ext/gyp/test/ninja/action-rule-hash/gyptest-action-rule-hash.py +32 -0
  1038. data/ext/gyp/test/ninja/action-rule-hash/subdir/action-rule-hash.gyp +29 -0
  1039. data/ext/gyp/test/ninja/action-rule-hash/subdir/emit.py +13 -0
  1040. data/ext/gyp/test/ninja/action_dependencies/gyptest-action-dependencies.py +64 -0
  1041. data/ext/gyp/test/ninja/action_dependencies/src/a.c +10 -0
  1042. data/ext/gyp/test/ninja/action_dependencies/src/a.h +13 -0
  1043. data/ext/gyp/test/ninja/action_dependencies/src/action_dependencies.gyp +88 -0
  1044. data/ext/gyp/test/ninja/action_dependencies/src/b.c +18 -0
  1045. data/ext/gyp/test/ninja/action_dependencies/src/b.h +13 -0
  1046. data/ext/gyp/test/ninja/action_dependencies/src/c.c +10 -0
  1047. data/ext/gyp/test/ninja/action_dependencies/src/c.h +13 -0
  1048. data/ext/gyp/test/ninja/action_dependencies/src/emit.py +11 -0
  1049. data/ext/gyp/test/ninja/chained-dependency/chained-dependency.gyp +53 -0
  1050. data/ext/gyp/test/ninja/chained-dependency/chained.c +5 -0
  1051. data/ext/gyp/test/ninja/chained-dependency/gyptest-chained-dependency.py +30 -0
  1052. data/ext/gyp/test/ninja/empty-and-non-empty-duplicate-name/gyptest-empty-and-non-empty-duplicate-name.py +23 -0
  1053. data/ext/gyp/test/ninja/empty-and-non-empty-duplicate-name/subdir/included.gyp +19 -0
  1054. data/ext/gyp/test/ninja/empty-and-non-empty-duplicate-name/test.gyp +19 -0
  1055. data/ext/gyp/test/ninja/normalize-paths-win/gyptest-normalize-paths.py +46 -0
  1056. data/ext/gyp/test/ninja/normalize-paths-win/hello.cc +7 -0
  1057. data/ext/gyp/test/ninja/normalize-paths-win/normalize-paths.gyp +68 -0
  1058. data/ext/gyp/test/ninja/s-needs-no-depfiles/empty.s +1 -0
  1059. data/ext/gyp/test/ninja/s-needs-no-depfiles/gyptest-s-needs-no-depfiles.py +42 -0
  1060. data/ext/gyp/test/ninja/s-needs-no-depfiles/s-needs-no-depfiles.gyp +13 -0
  1061. data/ext/gyp/test/ninja/solibs_avoid_relinking/gyptest-solibs-avoid-relinking.py +48 -0
  1062. data/ext/gyp/test/ninja/solibs_avoid_relinking/main.cc +5 -0
  1063. data/ext/gyp/test/ninja/solibs_avoid_relinking/solib.cc +8 -0
  1064. data/ext/gyp/test/ninja/solibs_avoid_relinking/solibs_avoid_relinking.gyp +38 -0
  1065. data/ext/gyp/test/ninja/use-console/foo.bar +5 -0
  1066. data/ext/gyp/test/ninja/use-console/gyptest-use-console.py +29 -0
  1067. data/ext/gyp/test/ninja/use-console/use-console.gyp +60 -0
  1068. data/ext/gyp/test/ninja/use-custom-environment-files/gyptest-use-custom-environment-files.py +28 -0
  1069. data/ext/gyp/test/ninja/use-custom-environment-files/use-custom-environment-files.cc +7 -0
  1070. data/ext/gyp/test/ninja/use-custom-environment-files/use-custom-environment-files.gyp +15 -0
  1071. data/ext/gyp/test/no-cpp/gyptest-no-cpp.py +53 -0
  1072. data/ext/gyp/test/no-cpp/src/call-f-main.c +2 -0
  1073. data/ext/gyp/test/no-cpp/src/empty-main.c +1 -0
  1074. data/ext/gyp/test/no-cpp/src/f.cc +3 -0
  1075. data/ext/gyp/test/no-cpp/src/test.gyp +25 -0
  1076. data/ext/gyp/test/no-output/gyptest-no-output.py +21 -0
  1077. data/ext/gyp/test/no-output/src/nooutput.gyp +17 -0
  1078. data/ext/gyp/test/product/gyptest-product.py +43 -0
  1079. data/ext/gyp/test/product/hello.c +15 -0
  1080. data/ext/gyp/test/product/product.gyp +128 -0
  1081. data/ext/gyp/test/prune_targets/gyptest-prune-targets.py +66 -0
  1082. data/ext/gyp/test/prune_targets/lib1.cc +6 -0
  1083. data/ext/gyp/test/prune_targets/lib2.cc +6 -0
  1084. data/ext/gyp/test/prune_targets/lib3.cc +6 -0
  1085. data/ext/gyp/test/prune_targets/lib_indirect.cc +6 -0
  1086. data/ext/gyp/test/prune_targets/program.cc +7 -0
  1087. data/ext/gyp/test/prune_targets/test1.gyp +26 -0
  1088. data/ext/gyp/test/prune_targets/test2.gyp +30 -0
  1089. data/ext/gyp/test/relative/foo/a/a.cc +9 -0
  1090. data/ext/gyp/test/relative/foo/a/a.gyp +13 -0
  1091. data/ext/gyp/test/relative/foo/a/c/c.cc +9 -0
  1092. data/ext/gyp/test/relative/foo/a/c/c.gyp +12 -0
  1093. data/ext/gyp/test/relative/foo/b/b.cc +9 -0
  1094. data/ext/gyp/test/relative/foo/b/b.gyp +9 -0
  1095. data/ext/gyp/test/relative/gyptest-default.py +25 -0
  1096. data/ext/gyp/test/rename/filecase/file.c +1 -0
  1097. data/ext/gyp/test/rename/filecase/test-casesensitive.gyp +15 -0
  1098. data/ext/gyp/test/rename/filecase/test.gyp +14 -0
  1099. data/ext/gyp/test/rename/gyptest-filecase.py +35 -0
  1100. data/ext/gyp/test/restat/gyptest-restat.py +31 -0
  1101. data/ext/gyp/test/restat/src/create_intermediate.py +17 -0
  1102. data/ext/gyp/test/restat/src/restat.gyp +50 -0
  1103. data/ext/gyp/test/restat/src/touch.py +16 -0
  1104. data/ext/gyp/test/rules/gyptest-all.py +84 -0
  1105. data/ext/gyp/test/rules/gyptest-default.py +70 -0
  1106. data/ext/gyp/test/rules/gyptest-input-root.py +26 -0
  1107. data/ext/gyp/test/rules/gyptest-special-variables.py +18 -0
  1108. data/ext/gyp/test/rules/src/actions.gyp +23 -0
  1109. data/ext/gyp/test/rules/src/an_asm.S +6 -0
  1110. data/ext/gyp/test/rules/src/as.bat +7 -0
  1111. data/ext/gyp/test/rules/src/copy-file.py +11 -0
  1112. data/ext/gyp/test/rules/src/external/external.gyp +66 -0
  1113. data/ext/gyp/test/rules/src/external/file1.in +1 -0
  1114. data/ext/gyp/test/rules/src/external/file2.in +1 -0
  1115. data/ext/gyp/test/rules/src/input-root.gyp +24 -0
  1116. data/ext/gyp/test/rules/src/noaction/file1.in +1 -0
  1117. data/ext/gyp/test/rules/src/noaction/no_action_with_rules_fails.gyp +37 -0
  1118. data/ext/gyp/test/rules/src/rule.py +17 -0
  1119. data/ext/gyp/test/rules/src/somefile.ext +0 -0
  1120. data/ext/gyp/test/rules/src/special-variables.gyp +34 -0
  1121. data/ext/gyp/test/rules/src/subdir1/executable.gyp +37 -0
  1122. data/ext/gyp/test/rules/src/subdir1/function1.in +6 -0
  1123. data/ext/gyp/test/rules/src/subdir1/function2.in +6 -0
  1124. data/ext/gyp/test/rules/src/subdir1/program.c +12 -0
  1125. data/ext/gyp/test/rules/src/subdir2/both_rule_and_action_input.gyp +50 -0
  1126. data/ext/gyp/test/rules/src/subdir2/file1.in +1 -0
  1127. data/ext/gyp/test/rules/src/subdir2/file2.in +1 -0
  1128. data/ext/gyp/test/rules/src/subdir2/never_used.gyp +31 -0
  1129. data/ext/gyp/test/rules/src/subdir2/no_action.gyp +38 -0
  1130. data/ext/gyp/test/rules/src/subdir2/no_inputs.gyp +32 -0
  1131. data/ext/gyp/test/rules/src/subdir2/none.gyp +33 -0
  1132. data/ext/gyp/test/rules/src/subdir2/program.c +12 -0
  1133. data/ext/gyp/test/rules/src/subdir3/executable2.gyp +37 -0
  1134. data/ext/gyp/test/rules/src/subdir3/function3.in +6 -0
  1135. data/ext/gyp/test/rules/src/subdir3/program.c +10 -0
  1136. data/ext/gyp/test/rules/src/subdir4/asm-function.assem +10 -0
  1137. data/ext/gyp/test/rules/src/subdir4/build-asm.gyp +49 -0
  1138. data/ext/gyp/test/rules/src/subdir4/program.c +19 -0
  1139. data/ext/gyp/test/rules-dirname/gyptest-dirname.py +57 -0
  1140. data/ext/gyp/test/rules-dirname/src/actions.gyp +15 -0
  1141. data/ext/gyp/test/rules-dirname/src/copy-file.py +11 -0
  1142. data/ext/gyp/test/rules-dirname/src/subdir/a/b/c.gencc +8 -0
  1143. data/ext/gyp/test/rules-dirname/src/subdir/a/b/c.printvars +1 -0
  1144. data/ext/gyp/test/rules-dirname/src/subdir/foo/bar/baz.gencc +8 -0
  1145. data/ext/gyp/test/rules-dirname/src/subdir/foo/bar/baz.printvars +1 -0
  1146. data/ext/gyp/test/rules-dirname/src/subdir/input-rule-dirname.gyp +140 -0
  1147. data/ext/gyp/test/rules-dirname/src/subdir/main.cc +14 -0
  1148. data/ext/gyp/test/rules-dirname/src/subdir/nodir.gencc +8 -0
  1149. data/ext/gyp/test/rules-dirname/src/subdir/printvars.py +14 -0
  1150. data/ext/gyp/test/rules-rebuild/gyptest-all.py +70 -0
  1151. data/ext/gyp/test/rules-rebuild/gyptest-default.py +91 -0
  1152. data/ext/gyp/test/rules-rebuild/src/main.c +12 -0
  1153. data/ext/gyp/test/rules-rebuild/src/make-sources.py +19 -0
  1154. data/ext/gyp/test/rules-rebuild/src/prog1.in +7 -0
  1155. data/ext/gyp/test/rules-rebuild/src/prog2.in +7 -0
  1156. data/ext/gyp/test/rules-rebuild/src/same_target.gyp +31 -0
  1157. data/ext/gyp/test/rules-use-built-dependencies/gyptest-use-built-dependencies.py +23 -0
  1158. data/ext/gyp/test/rules-use-built-dependencies/src/main.cc +17 -0
  1159. data/ext/gyp/test/rules-use-built-dependencies/src/use-built-dependencies-rule.gyp +42 -0
  1160. data/ext/gyp/test/rules-variables/gyptest-rules-variables.py +35 -0
  1161. data/ext/gyp/test/rules-variables/src/input_ext.c +9 -0
  1162. data/ext/gyp/test/rules-variables/src/input_name/test.c +9 -0
  1163. data/ext/gyp/test/rules-variables/src/input_path/subdir/test.c +9 -0
  1164. data/ext/gyp/test/rules-variables/src/subdir/input_dirname.c +9 -0
  1165. data/ext/gyp/test/rules-variables/src/subdir/test.c +18 -0
  1166. data/ext/gyp/test/rules-variables/src/test.input_root.c +9 -0
  1167. data/ext/gyp/test/rules-variables/src/variables.gyp +40 -0
  1168. data/ext/gyp/test/same-gyp-name/gyptest-all.py +38 -0
  1169. data/ext/gyp/test/same-gyp-name/gyptest-default.py +38 -0
  1170. data/ext/gyp/test/same-gyp-name/gyptest-library.py +20 -0
  1171. data/ext/gyp/test/same-gyp-name/library/one/sub.gyp +11 -0
  1172. data/ext/gyp/test/same-gyp-name/library/test.gyp +15 -0
  1173. data/ext/gyp/test/same-gyp-name/library/two/sub.gyp +11 -0
  1174. data/ext/gyp/test/same-gyp-name/src/all.gyp +16 -0
  1175. data/ext/gyp/test/same-gyp-name/src/subdir1/executable.gyp +15 -0
  1176. data/ext/gyp/test/same-gyp-name/src/subdir1/main1.cc +6 -0
  1177. data/ext/gyp/test/same-gyp-name/src/subdir2/executable.gyp +15 -0
  1178. data/ext/gyp/test/same-gyp-name/src/subdir2/main2.cc +6 -0
  1179. data/ext/gyp/test/same-rule-output-file-name/gyptest-all.py +23 -0
  1180. data/ext/gyp/test/same-rule-output-file-name/src/subdir1/subdir1.gyp +30 -0
  1181. data/ext/gyp/test/same-rule-output-file-name/src/subdir2/subdir2.gyp +30 -0
  1182. data/ext/gyp/test/same-rule-output-file-name/src/subdirs.gyp +16 -0
  1183. data/ext/gyp/test/same-rule-output-file-name/src/touch.py +11 -0
  1184. data/ext/gyp/test/same-source-file-name/gyptest-all.py +34 -0
  1185. data/ext/gyp/test/same-source-file-name/gyptest-default.py +34 -0
  1186. data/ext/gyp/test/same-source-file-name/gyptest-pass-executable.py +33 -0
  1187. data/ext/gyp/test/same-source-file-name/gyptest-pass-shared.py +18 -0
  1188. data/ext/gyp/test/same-source-file-name/gyptest-static.py +34 -0
  1189. data/ext/gyp/test/same-source-file-name/src/all.gyp +30 -0
  1190. data/ext/gyp/test/same-source-file-name/src/double-executable.gyp +21 -0
  1191. data/ext/gyp/test/same-source-file-name/src/double-shared.gyp +27 -0
  1192. data/ext/gyp/test/same-source-file-name/src/double-static.gyp +22 -0
  1193. data/ext/gyp/test/same-source-file-name/src/func.c +6 -0
  1194. data/ext/gyp/test/same-source-file-name/src/prog1.c +16 -0
  1195. data/ext/gyp/test/same-source-file-name/src/prog2.c +16 -0
  1196. data/ext/gyp/test/same-source-file-name/src/prog3.c +18 -0
  1197. data/ext/gyp/test/same-source-file-name/src/subdir1/func.c +6 -0
  1198. data/ext/gyp/test/same-source-file-name/src/subdir2/func.c +6 -0
  1199. data/ext/gyp/test/same-target-name/gyptest-same-target-name.py +18 -0
  1200. data/ext/gyp/test/same-target-name/src/all.gyp +16 -0
  1201. data/ext/gyp/test/same-target-name/src/executable1.gyp +15 -0
  1202. data/ext/gyp/test/same-target-name/src/executable2.gyp +15 -0
  1203. data/ext/gyp/test/same-target-name-different-directory/gyptest-all.py +41 -0
  1204. data/ext/gyp/test/same-target-name-different-directory/src/subdir1/subdir1.gyp +66 -0
  1205. data/ext/gyp/test/same-target-name-different-directory/src/subdir2/subdir2.gyp +66 -0
  1206. data/ext/gyp/test/same-target-name-different-directory/src/subdirs.gyp +16 -0
  1207. data/ext/gyp/test/same-target-name-different-directory/src/touch.py +11 -0
  1208. data/ext/gyp/test/sanitize-rule-names/blah.S +0 -0
  1209. data/ext/gyp/test/sanitize-rule-names/gyptest-sanitize-rule-names.py +17 -0
  1210. data/ext/gyp/test/sanitize-rule-names/hello.cc +7 -0
  1211. data/ext/gyp/test/sanitize-rule-names/sanitize-rule-names.gyp +27 -0
  1212. data/ext/gyp/test/sanitize-rule-names/script.py +10 -0
  1213. data/ext/gyp/test/self-dependency/common.gypi +13 -0
  1214. data/ext/gyp/test/self-dependency/dep.gyp +23 -0
  1215. data/ext/gyp/test/self-dependency/gyptest-self-dependency.py +19 -0
  1216. data/ext/gyp/test/self-dependency/self_dependency.gyp +15 -0
  1217. data/ext/gyp/test/sibling/gyptest-all.py +42 -0
  1218. data/ext/gyp/test/sibling/gyptest-relocate.py +44 -0
  1219. data/ext/gyp/test/sibling/src/build/all.gyp +16 -0
  1220. data/ext/gyp/test/sibling/src/prog1/prog1.c +7 -0
  1221. data/ext/gyp/test/sibling/src/prog1/prog1.gyp +15 -0
  1222. data/ext/gyp/test/sibling/src/prog2/prog2.c +7 -0
  1223. data/ext/gyp/test/sibling/src/prog2/prog2.gyp +15 -0
  1224. data/ext/gyp/test/small/gyptest-small.py +56 -0
  1225. data/ext/gyp/test/standalone/gyptest-standalone.py +35 -0
  1226. data/ext/gyp/test/standalone/standalone.gyp +12 -0
  1227. data/ext/gyp/test/standalone-static-library/gyptest-standalone-static-library.py +50 -0
  1228. data/ext/gyp/test/standalone-static-library/invalid.gyp +16 -0
  1229. data/ext/gyp/test/standalone-static-library/mylib.c +7 -0
  1230. data/ext/gyp/test/standalone-static-library/mylib.gyp +26 -0
  1231. data/ext/gyp/test/standalone-static-library/prog.c +7 -0
  1232. data/ext/gyp/test/subdirectory/gyptest-SYMROOT-all.py +36 -0
  1233. data/ext/gyp/test/subdirectory/gyptest-SYMROOT-default.py +37 -0
  1234. data/ext/gyp/test/subdirectory/gyptest-subdir-all.py +34 -0
  1235. data/ext/gyp/test/subdirectory/gyptest-subdir-default.py +34 -0
  1236. data/ext/gyp/test/subdirectory/gyptest-subdir2-deep.py +25 -0
  1237. data/ext/gyp/test/subdirectory/gyptest-top-all.py +43 -0
  1238. data/ext/gyp/test/subdirectory/gyptest-top-default.py +43 -0
  1239. data/ext/gyp/test/subdirectory/src/prog1.c +7 -0
  1240. data/ext/gyp/test/subdirectory/src/prog1.gyp +21 -0
  1241. data/ext/gyp/test/subdirectory/src/subdir/prog2.c +7 -0
  1242. data/ext/gyp/test/subdirectory/src/subdir/prog2.gyp +18 -0
  1243. data/ext/gyp/test/subdirectory/src/subdir/subdir2/prog3.c +7 -0
  1244. data/ext/gyp/test/subdirectory/src/subdir/subdir2/prog3.gyp +18 -0
  1245. data/ext/gyp/test/subdirectory/src/symroot.gypi +16 -0
  1246. data/ext/gyp/test/symlinks/gyptest-symlinks.py +66 -0
  1247. data/ext/gyp/test/symlinks/hello.c +12 -0
  1248. data/ext/gyp/test/symlinks/hello.gyp +15 -0
  1249. data/ext/gyp/test/target/gyptest-target.py +37 -0
  1250. data/ext/gyp/test/target/hello.c +7 -0
  1251. data/ext/gyp/test/target/target.gyp +24 -0
  1252. data/ext/gyp/test/toolsets/gyptest-toolsets.py +31 -0
  1253. data/ext/gyp/test/toolsets/main.cc +13 -0
  1254. data/ext/gyp/test/toolsets/toolsets.cc +11 -0
  1255. data/ext/gyp/test/toolsets/toolsets.gyp +62 -0
  1256. data/ext/gyp/test/toolsets/toolsets_shared.cc +11 -0
  1257. data/ext/gyp/test/toplevel-dir/gyptest-toplevel-dir.py +31 -0
  1258. data/ext/gyp/test/toplevel-dir/src/sub1/main.gyp +18 -0
  1259. data/ext/gyp/test/toplevel-dir/src/sub1/prog1.c +7 -0
  1260. data/ext/gyp/test/toplevel-dir/src/sub2/prog2.c +7 -0
  1261. data/ext/gyp/test/toplevel-dir/src/sub2/prog2.gyp +15 -0
  1262. data/ext/gyp/test/variables/commands/commands-repeated.gyp +128 -0
  1263. data/ext/gyp/test/variables/commands/commands-repeated.gyp.stdout +136 -0
  1264. data/ext/gyp/test/variables/commands/commands-repeated.gypd.golden +77 -0
  1265. data/ext/gyp/test/variables/commands/commands.gyp +91 -0
  1266. data/ext/gyp/test/variables/commands/commands.gyp.ignore-env.stdout +96 -0
  1267. data/ext/gyp/test/variables/commands/commands.gyp.stdout +96 -0
  1268. data/ext/gyp/test/variables/commands/commands.gypd.golden +66 -0
  1269. data/ext/gyp/test/variables/commands/commands.gypi +23 -0
  1270. data/ext/gyp/test/variables/commands/gyptest-commands-ignore-env.py +47 -0
  1271. data/ext/gyp/test/variables/commands/gyptest-commands-repeated-multidir.py +23 -0
  1272. data/ext/gyp/test/variables/commands/gyptest-commands-repeated.py +40 -0
  1273. data/ext/gyp/test/variables/commands/gyptest-commands.py +40 -0
  1274. data/ext/gyp/test/variables/commands/repeated_multidir/dir_1/test_1.gyp +13 -0
  1275. data/ext/gyp/test/variables/commands/repeated_multidir/dir_2/test_2.gyp +13 -0
  1276. data/ext/gyp/test/variables/commands/repeated_multidir/main.gyp +16 -0
  1277. data/ext/gyp/test/variables/commands/repeated_multidir/print_cwd_basename.py +11 -0
  1278. data/ext/gyp/test/variables/commands/repeated_multidir/repeated_command_common.gypi +25 -0
  1279. data/ext/gyp/test/variables/commands/test.py +7 -0
  1280. data/ext/gyp/test/variables/commands/update_golden +11 -0
  1281. data/ext/gyp/test/variables/empty/empty.gyp +13 -0
  1282. data/ext/gyp/test/variables/empty/empty.gypi +9 -0
  1283. data/ext/gyp/test/variables/empty/gyptest-empty.py +19 -0
  1284. data/ext/gyp/test/variables/filelist/filelist.gyp.stdout +26 -0
  1285. data/ext/gyp/test/variables/filelist/filelist.gypd.golden +43 -0
  1286. data/ext/gyp/test/variables/filelist/gyptest-filelist-golden.py +53 -0
  1287. data/ext/gyp/test/variables/filelist/gyptest-filelist.py +29 -0
  1288. data/ext/gyp/test/variables/filelist/src/dummy.py +5 -0
  1289. data/ext/gyp/test/variables/filelist/src/filelist.gyp +93 -0
  1290. data/ext/gyp/test/variables/filelist/src/filelist2.gyp +40 -0
  1291. data/ext/gyp/test/variables/filelist/update_golden +8 -0
  1292. data/ext/gyp/test/variables/latelate/gyptest-latelate.py +25 -0
  1293. data/ext/gyp/test/variables/latelate/src/latelate.gyp +34 -0
  1294. data/ext/gyp/test/variables/latelate/src/program.cc +13 -0
  1295. data/ext/gyp/test/variables/variable-in-path/C1/hello.cc +7 -0
  1296. data/ext/gyp/test/variables/variable-in-path/gyptest-variable-in-path.py +23 -0
  1297. data/ext/gyp/test/variables/variable-in-path/variable-in-path.gyp +31 -0
  1298. data/ext/gyp/test/win/asm-files/asm-files.gyp +17 -0
  1299. data/ext/gyp/test/win/asm-files/b.s +0 -0
  1300. data/ext/gyp/test/win/asm-files/c.S +0 -0
  1301. data/ext/gyp/test/win/asm-files/hello.cc +7 -0
  1302. data/ext/gyp/test/win/batch-file-action/batch-file-action.gyp +21 -0
  1303. data/ext/gyp/test/win/batch-file-action/infile +1 -0
  1304. data/ext/gyp/test/win/batch-file-action/somecmd.bat +5 -0
  1305. data/ext/gyp/test/win/command-quote/a.S +0 -0
  1306. data/ext/gyp/test/win/command-quote/bat with spaces.bat +7 -0
  1307. data/ext/gyp/test/win/command-quote/command-quote.gyp +79 -0
  1308. data/ext/gyp/test/win/command-quote/go.bat +7 -0
  1309. data/ext/gyp/test/win/command-quote/subdir/and/another/in-subdir.gyp +27 -0
  1310. data/ext/gyp/test/win/compiler-flags/additional-include-dirs.cc +10 -0
  1311. data/ext/gyp/test/win/compiler-flags/additional-include-dirs.gyp +20 -0
  1312. data/ext/gyp/test/win/compiler-flags/additional-options.cc +10 -0
  1313. data/ext/gyp/test/win/compiler-flags/additional-options.gyp +31 -0
  1314. data/ext/gyp/test/win/compiler-flags/analysis.gyp +40 -0
  1315. data/ext/gyp/test/win/compiler-flags/buffer-security-check.gyp +51 -0
  1316. data/ext/gyp/test/win/compiler-flags/buffer-security.cc +12 -0
  1317. data/ext/gyp/test/win/compiler-flags/calling-convention-cdecl.def +6 -0
  1318. data/ext/gyp/test/win/compiler-flags/calling-convention-fastcall.def +6 -0
  1319. data/ext/gyp/test/win/compiler-flags/calling-convention-stdcall.def +6 -0
  1320. data/ext/gyp/test/win/compiler-flags/calling-convention-vectorcall.def +6 -0
  1321. data/ext/gyp/test/win/compiler-flags/calling-convention.cc +6 -0
  1322. data/ext/gyp/test/win/compiler-flags/calling-convention.gyp +66 -0
  1323. data/ext/gyp/test/win/compiler-flags/character-set-mbcs.cc +11 -0
  1324. data/ext/gyp/test/win/compiler-flags/character-set-unicode.cc +15 -0
  1325. data/ext/gyp/test/win/compiler-flags/character-set.gyp +35 -0
  1326. data/ext/gyp/test/win/compiler-flags/compile-as-managed.cc +9 -0
  1327. data/ext/gyp/test/win/compiler-flags/compile-as-managed.gyp +29 -0
  1328. data/ext/gyp/test/win/compiler-flags/compile-as-winrt.cc +12 -0
  1329. data/ext/gyp/test/win/compiler-flags/compile-as-winrt.gyp +20 -0
  1330. data/ext/gyp/test/win/compiler-flags/debug-format.gyp +48 -0
  1331. data/ext/gyp/test/win/compiler-flags/default-char-is-unsigned.cc +15 -0
  1332. data/ext/gyp/test/win/compiler-flags/default-char-is-unsigned.gyp +20 -0
  1333. data/ext/gyp/test/win/compiler-flags/disable-specific-warnings.cc +9 -0
  1334. data/ext/gyp/test/win/compiler-flags/disable-specific-warnings.gyp +29 -0
  1335. data/ext/gyp/test/win/compiler-flags/enable-enhanced-instruction-set.cc +28 -0
  1336. data/ext/gyp/test/win/compiler-flags/enable-enhanced-instruction-set.gyp +68 -0
  1337. data/ext/gyp/test/win/compiler-flags/exception-handling-on.cc +24 -0
  1338. data/ext/gyp/test/win/compiler-flags/exception-handling.gyp +46 -0
  1339. data/ext/gyp/test/win/compiler-flags/floating-point-model-fast.cc +19 -0
  1340. data/ext/gyp/test/win/compiler-flags/floating-point-model-precise.cc +19 -0
  1341. data/ext/gyp/test/win/compiler-flags/floating-point-model-strict.cc +19 -0
  1342. data/ext/gyp/test/win/compiler-flags/floating-point-model.gyp +43 -0
  1343. data/ext/gyp/test/win/compiler-flags/force-include-files-with-precompiled.cc +10 -0
  1344. data/ext/gyp/test/win/compiler-flags/force-include-files.cc +8 -0
  1345. data/ext/gyp/test/win/compiler-flags/force-include-files.gyp +36 -0
  1346. data/ext/gyp/test/win/compiler-flags/function-level-linking.cc +11 -0
  1347. data/ext/gyp/test/win/compiler-flags/function-level-linking.gyp +28 -0
  1348. data/ext/gyp/test/win/compiler-flags/hello.cc +7 -0
  1349. data/ext/gyp/test/win/compiler-flags/optimizations.gyp +207 -0
  1350. data/ext/gyp/test/win/compiler-flags/pdbname-override.gyp +26 -0
  1351. data/ext/gyp/test/win/compiler-flags/pdbname.cc +7 -0
  1352. data/ext/gyp/test/win/compiler-flags/pdbname.gyp +24 -0
  1353. data/ext/gyp/test/win/compiler-flags/precomp.cc +6 -0
  1354. data/ext/gyp/test/win/compiler-flags/rtti-on.cc +11 -0
  1355. data/ext/gyp/test/win/compiler-flags/rtti.gyp +37 -0
  1356. data/ext/gyp/test/win/compiler-flags/runtime-checks.cc +11 -0
  1357. data/ext/gyp/test/win/compiler-flags/runtime-checks.gyp +29 -0
  1358. data/ext/gyp/test/win/compiler-flags/runtime-library-md.cc +19 -0
  1359. data/ext/gyp/test/win/compiler-flags/runtime-library-mdd.cc +19 -0
  1360. data/ext/gyp/test/win/compiler-flags/runtime-library-mt.cc +19 -0
  1361. data/ext/gyp/test/win/compiler-flags/runtime-library-mtd.cc +19 -0
  1362. data/ext/gyp/test/win/compiler-flags/runtime-library.gyp +48 -0
  1363. data/ext/gyp/test/win/compiler-flags/subdir/header.h +0 -0
  1364. data/ext/gyp/test/win/compiler-flags/treat-wchar-t-as-built-in-type.gyp +33 -0
  1365. data/ext/gyp/test/win/compiler-flags/treat-wchar-t-as-built-in-type1.cc +11 -0
  1366. data/ext/gyp/test/win/compiler-flags/treat-wchar-t-as-built-in-type2.cc +11 -0
  1367. data/ext/gyp/test/win/compiler-flags/uninit.cc +13 -0
  1368. data/ext/gyp/test/win/compiler-flags/warning-as-error.cc +9 -0
  1369. data/ext/gyp/test/win/compiler-flags/warning-as-error.gyp +37 -0
  1370. data/ext/gyp/test/win/compiler-flags/warning-level.gyp +115 -0
  1371. data/ext/gyp/test/win/compiler-flags/warning-level1.cc +8 -0
  1372. data/ext/gyp/test/win/compiler-flags/warning-level2.cc +14 -0
  1373. data/ext/gyp/test/win/compiler-flags/warning-level3.cc +11 -0
  1374. data/ext/gyp/test/win/compiler-flags/warning-level4.cc +10 -0
  1375. data/ext/gyp/test/win/enable-winrt/dllmain.cc +30 -0
  1376. data/ext/gyp/test/win/enable-winrt/enable-winrt.gyp +39 -0
  1377. data/ext/gyp/test/win/generator-output-different-drive/gyptest-generator-output-different-drive.py +44 -0
  1378. data/ext/gyp/test/win/generator-output-different-drive/prog.c +10 -0
  1379. data/ext/gyp/test/win/generator-output-different-drive/prog.gyp +15 -0
  1380. data/ext/gyp/test/win/gyptest-asm-files.py +26 -0
  1381. data/ext/gyp/test/win/gyptest-cl-additional-include-dirs.py +22 -0
  1382. data/ext/gyp/test/win/gyptest-cl-additional-options.py +28 -0
  1383. data/ext/gyp/test/win/gyptest-cl-analysis.py +30 -0
  1384. data/ext/gyp/test/win/gyptest-cl-buffer-security-check.py +53 -0
  1385. data/ext/gyp/test/win/gyptest-cl-calling-convention.py +22 -0
  1386. data/ext/gyp/test/win/gyptest-cl-character-set.py +22 -0
  1387. data/ext/gyp/test/win/gyptest-cl-compile-as-managed.py +24 -0
  1388. data/ext/gyp/test/win/gyptest-cl-compile-as-winrt.py +20 -0
  1389. data/ext/gyp/test/win/gyptest-cl-debug-format.py +43 -0
  1390. data/ext/gyp/test/win/gyptest-cl-default-char-is-unsigned.py +22 -0
  1391. data/ext/gyp/test/win/gyptest-cl-disable-specific-warnings.py +32 -0
  1392. data/ext/gyp/test/win/gyptest-cl-enable-enhanced-instruction-set.py +49 -0
  1393. data/ext/gyp/test/win/gyptest-cl-exception-handling.py +33 -0
  1394. data/ext/gyp/test/win/gyptest-cl-floating-point-model.py +22 -0
  1395. data/ext/gyp/test/win/gyptest-cl-force-include-files.py +22 -0
  1396. data/ext/gyp/test/win/gyptest-cl-function-level-linking.py +54 -0
  1397. data/ext/gyp/test/win/gyptest-cl-optimizations.py +105 -0
  1398. data/ext/gyp/test/win/gyptest-cl-pdbname-override.py +27 -0
  1399. data/ext/gyp/test/win/gyptest-cl-pdbname.py +30 -0
  1400. data/ext/gyp/test/win/gyptest-cl-rtti.py +30 -0
  1401. data/ext/gyp/test/win/gyptest-cl-runtime-checks.py +30 -0
  1402. data/ext/gyp/test/win/gyptest-cl-runtime-library.py +22 -0
  1403. data/ext/gyp/test/win/gyptest-cl-treat-wchar-t-as-built-in-type.py +22 -0
  1404. data/ext/gyp/test/win/gyptest-cl-warning-as-error.py +30 -0
  1405. data/ext/gyp/test/win/gyptest-cl-warning-level.py +41 -0
  1406. data/ext/gyp/test/win/gyptest-command-quote.py +42 -0
  1407. data/ext/gyp/test/win/gyptest-crosscompile-ar.py +29 -0
  1408. data/ext/gyp/test/win/gyptest-lib-ltcg.py +22 -0
  1409. data/ext/gyp/test/win/gyptest-link-additional-deps.py +22 -0
  1410. data/ext/gyp/test/win/gyptest-link-additional-options.py +22 -0
  1411. data/ext/gyp/test/win/gyptest-link-aslr.py +35 -0
  1412. data/ext/gyp/test/win/gyptest-link-base-address.py +62 -0
  1413. data/ext/gyp/test/win/gyptest-link-debug-info.py +26 -0
  1414. data/ext/gyp/test/win/gyptest-link-default-libs.py +22 -0
  1415. data/ext/gyp/test/win/gyptest-link-deffile.py +43 -0
  1416. data/ext/gyp/test/win/gyptest-link-defrelink.py +56 -0
  1417. data/ext/gyp/test/win/gyptest-link-delay-load-dlls.py +35 -0
  1418. data/ext/gyp/test/win/gyptest-link-embed-manifest.py +100 -0
  1419. data/ext/gyp/test/win/gyptest-link-enable-uac.py +104 -0
  1420. data/ext/gyp/test/win/gyptest-link-enable-winrt-app-revision.py +43 -0
  1421. data/ext/gyp/test/win/gyptest-link-enable-winrt-target-platform-version.py +47 -0
  1422. data/ext/gyp/test/win/gyptest-link-enable-winrt.py +37 -0
  1423. data/ext/gyp/test/win/gyptest-link-entrypointsymbol.py +24 -0
  1424. data/ext/gyp/test/win/gyptest-link-fixed-base.py +40 -0
  1425. data/ext/gyp/test/win/gyptest-link-force-symbol-reference.py +26 -0
  1426. data/ext/gyp/test/win/gyptest-link-generate-manifest.py +127 -0
  1427. data/ext/gyp/test/win/gyptest-link-incremental.py +37 -0
  1428. data/ext/gyp/test/win/gyptest-link-large-address-aware.py +35 -0
  1429. data/ext/gyp/test/win/gyptest-link-large-pdb.py +76 -0
  1430. data/ext/gyp/test/win/gyptest-link-library-adjust.py +21 -0
  1431. data/ext/gyp/test/win/gyptest-link-library-directories.py +35 -0
  1432. data/ext/gyp/test/win/gyptest-link-ltcg.py +44 -0
  1433. data/ext/gyp/test/win/gyptest-link-mapfile.py +44 -0
  1434. data/ext/gyp/test/win/gyptest-link-nodefaultlib.py +24 -0
  1435. data/ext/gyp/test/win/gyptest-link-noimportlib.py +30 -0
  1436. data/ext/gyp/test/win/gyptest-link-nxcompat.py +37 -0
  1437. data/ext/gyp/test/win/gyptest-link-opt-icf.py +41 -0
  1438. data/ext/gyp/test/win/gyptest-link-opt-ref.py +40 -0
  1439. data/ext/gyp/test/win/gyptest-link-ordering.py +103 -0
  1440. data/ext/gyp/test/win/gyptest-link-outputfile.py +28 -0
  1441. data/ext/gyp/test/win/gyptest-link-pdb-no-output.py +25 -0
  1442. data/ext/gyp/test/win/gyptest-link-pdb-output.py +33 -0
  1443. data/ext/gyp/test/win/gyptest-link-pdb.py +35 -0
  1444. data/ext/gyp/test/win/gyptest-link-pgo.py +75 -0
  1445. data/ext/gyp/test/win/gyptest-link-profile.py +37 -0
  1446. data/ext/gyp/test/win/gyptest-link-restat-importlib.py +47 -0
  1447. data/ext/gyp/test/win/gyptest-link-safeseh.py +46 -0
  1448. data/ext/gyp/test/win/gyptest-link-shard.py +30 -0
  1449. data/ext/gyp/test/win/gyptest-link-stacksize.py +62 -0
  1450. data/ext/gyp/test/win/gyptest-link-subsystem.py +38 -0
  1451. data/ext/gyp/test/win/gyptest-link-target-machine.py +28 -0
  1452. data/ext/gyp/test/win/gyptest-link-tsaware.py +33 -0
  1453. data/ext/gyp/test/win/gyptest-link-uldi-depending-on-module.py +24 -0
  1454. data/ext/gyp/test/win/gyptest-link-uldi.py +28 -0
  1455. data/ext/gyp/test/win/gyptest-link-unsupported-manifest.py +27 -0
  1456. data/ext/gyp/test/win/gyptest-link-update-manifest.py +104 -0
  1457. data/ext/gyp/test/win/gyptest-link-warnings-as-errors.py +24 -0
  1458. data/ext/gyp/test/win/gyptest-long-command-line.py +23 -0
  1459. data/ext/gyp/test/win/gyptest-macro-projectname.py +24 -0
  1460. data/ext/gyp/test/win/gyptest-macro-targetext.py +26 -0
  1461. data/ext/gyp/test/win/gyptest-macro-targetfilename.py +37 -0
  1462. data/ext/gyp/test/win/gyptest-macro-targetname.py +29 -0
  1463. data/ext/gyp/test/win/gyptest-macro-targetpath.py +30 -0
  1464. data/ext/gyp/test/win/gyptest-macro-vcinstalldir.py +24 -0
  1465. data/ext/gyp/test/win/gyptest-macros-containing-gyp.py +21 -0
  1466. data/ext/gyp/test/win/gyptest-macros-in-inputs-and-outputs.py +27 -0
  1467. data/ext/gyp/test/win/gyptest-midl-excluded.py +22 -0
  1468. data/ext/gyp/test/win/gyptest-midl-includedirs.py +21 -0
  1469. data/ext/gyp/test/win/gyptest-midl-rules.py +28 -0
  1470. data/ext/gyp/test/win/gyptest-ml-safeseh.py +22 -0
  1471. data/ext/gyp/test/win/gyptest-quoting-commands.py +25 -0
  1472. data/ext/gyp/test/win/gyptest-rc-build.py +29 -0
  1473. data/ext/gyp/test/win/gyptest-sys.py +27 -0
  1474. data/ext/gyp/test/win/gyptest-system-include.py +21 -0
  1475. data/ext/gyp/test/win/idl-excluded/bad.idl +6 -0
  1476. data/ext/gyp/test/win/idl-excluded/copy-file.py +11 -0
  1477. data/ext/gyp/test/win/idl-excluded/idl-excluded.gyp +58 -0
  1478. data/ext/gyp/test/win/idl-excluded/program.cc +7 -0
  1479. data/ext/gyp/test/win/idl-includedirs/hello.cc +7 -0
  1480. data/ext/gyp/test/win/idl-includedirs/idl-includedirs.gyp +26 -0
  1481. data/ext/gyp/test/win/idl-includedirs/subdir/bar.idl +13 -0
  1482. data/ext/gyp/test/win/idl-includedirs/subdir/foo.idl +14 -0
  1483. data/ext/gyp/test/win/idl-rules/Window.idl +9 -0
  1484. data/ext/gyp/test/win/idl-rules/basic-idl.gyp +67 -0
  1485. data/ext/gyp/test/win/idl-rules/history_indexer.idl +17 -0
  1486. data/ext/gyp/test/win/idl-rules/history_indexer_user.cc +15 -0
  1487. data/ext/gyp/test/win/idl-rules/idl_compiler.py +17 -0
  1488. data/ext/gyp/test/win/importlib/dll_no_exports.cc +9 -0
  1489. data/ext/gyp/test/win/importlib/has-exports.cc +10 -0
  1490. data/ext/gyp/test/win/importlib/hello.cc +9 -0
  1491. data/ext/gyp/test/win/importlib/importlib.gyp +30 -0
  1492. data/ext/gyp/test/win/importlib/noimplib.gyp +16 -0
  1493. data/ext/gyp/test/win/large-pdb/dllmain.cc +9 -0
  1494. data/ext/gyp/test/win/large-pdb/large-pdb.gyp +98 -0
  1495. data/ext/gyp/test/win/large-pdb/main.cc +7 -0
  1496. data/ext/gyp/test/win/lib-crosscompile/answer.cc +9 -0
  1497. data/ext/gyp/test/win/lib-crosscompile/answer.h +5 -0
  1498. data/ext/gyp/test/win/lib-crosscompile/use_host_ar.gyp +17 -0
  1499. data/ext/gyp/test/win/lib-flags/answer.cc +9 -0
  1500. data/ext/gyp/test/win/lib-flags/answer.h +5 -0
  1501. data/ext/gyp/test/win/lib-flags/ltcg.gyp +21 -0
  1502. data/ext/gyp/test/win/linker-flags/a/x.cc +7 -0
  1503. data/ext/gyp/test/win/linker-flags/a/z.cc +7 -0
  1504. data/ext/gyp/test/win/linker-flags/additional-deps.cc +10 -0
  1505. data/ext/gyp/test/win/linker-flags/additional-deps.gyp +30 -0
  1506. data/ext/gyp/test/win/linker-flags/additional-options.gyp +29 -0
  1507. data/ext/gyp/test/win/linker-flags/aslr.gyp +35 -0
  1508. data/ext/gyp/test/win/linker-flags/b/y.cc +7 -0
  1509. data/ext/gyp/test/win/linker-flags/base-address.gyp +38 -0
  1510. data/ext/gyp/test/win/linker-flags/debug-info.gyp +28 -0
  1511. data/ext/gyp/test/win/linker-flags/deffile-multiple.gyp +17 -0
  1512. data/ext/gyp/test/win/linker-flags/deffile.cc +13 -0
  1513. data/ext/gyp/test/win/linker-flags/deffile.def +8 -0
  1514. data/ext/gyp/test/win/linker-flags/deffile.gyp +38 -0
  1515. data/ext/gyp/test/win/linker-flags/delay-load-dlls.gyp +35 -0
  1516. data/ext/gyp/test/win/linker-flags/delay-load.cc +10 -0
  1517. data/ext/gyp/test/win/linker-flags/embed-manifest.gyp +109 -0
  1518. data/ext/gyp/test/win/linker-flags/enable-uac.gyp +45 -0
  1519. data/ext/gyp/test/win/linker-flags/entrypointsymbol.cc +13 -0
  1520. data/ext/gyp/test/win/linker-flags/entrypointsymbol.gyp +28 -0
  1521. data/ext/gyp/test/win/linker-flags/extra.manifest +11 -0
  1522. data/ext/gyp/test/win/linker-flags/extra2.manifest +11 -0
  1523. data/ext/gyp/test/win/linker-flags/fixed-base.gyp +52 -0
  1524. data/ext/gyp/test/win/linker-flags/force-symbol-reference.gyp +39 -0
  1525. data/ext/gyp/test/win/linker-flags/generate-manifest.gyp +166 -0
  1526. data/ext/gyp/test/win/linker-flags/hello.cc +7 -0
  1527. data/ext/gyp/test/win/linker-flags/incremental.gyp +65 -0
  1528. data/ext/gyp/test/win/linker-flags/inline_test.cc +12 -0
  1529. data/ext/gyp/test/win/linker-flags/inline_test.h +5 -0
  1530. data/ext/gyp/test/win/linker-flags/inline_test_main.cc +15 -0
  1531. data/ext/gyp/test/win/linker-flags/large-address-aware.gyp +28 -0
  1532. data/ext/gyp/test/win/linker-flags/library-adjust.cc +10 -0
  1533. data/ext/gyp/test/win/linker-flags/library-adjust.gyp +16 -0
  1534. data/ext/gyp/test/win/linker-flags/library-directories-define.cc +7 -0
  1535. data/ext/gyp/test/win/linker-flags/library-directories-reference.cc +10 -0
  1536. data/ext/gyp/test/win/linker-flags/library-directories.gyp +42 -0
  1537. data/ext/gyp/test/win/linker-flags/link-ordering.gyp +95 -0
  1538. data/ext/gyp/test/win/linker-flags/link-warning.cc +10 -0
  1539. data/ext/gyp/test/win/linker-flags/ltcg.gyp +42 -0
  1540. data/ext/gyp/test/win/linker-flags/main-crt.c +8 -0
  1541. data/ext/gyp/test/win/linker-flags/manifest-in-comment.cc +13 -0
  1542. data/ext/gyp/test/win/linker-flags/mapfile.cc +12 -0
  1543. data/ext/gyp/test/win/linker-flags/mapfile.gyp +45 -0
  1544. data/ext/gyp/test/win/linker-flags/no-default-libs.cc +18 -0
  1545. data/ext/gyp/test/win/linker-flags/no-default-libs.gyp +13 -0
  1546. data/ext/gyp/test/win/linker-flags/nodefaultlib.cc +13 -0
  1547. data/ext/gyp/test/win/linker-flags/nodefaultlib.gyp +30 -0
  1548. data/ext/gyp/test/win/linker-flags/nxcompat.gyp +35 -0
  1549. data/ext/gyp/test/win/linker-flags/opt-icf.cc +29 -0
  1550. data/ext/gyp/test/win/linker-flags/opt-icf.gyp +63 -0
  1551. data/ext/gyp/test/win/linker-flags/opt-ref.cc +11 -0
  1552. data/ext/gyp/test/win/linker-flags/opt-ref.gyp +56 -0
  1553. data/ext/gyp/test/win/linker-flags/outputfile.gyp +58 -0
  1554. data/ext/gyp/test/win/linker-flags/pdb-output.gyp +49 -0
  1555. data/ext/gyp/test/win/linker-flags/pgo.gyp +143 -0
  1556. data/ext/gyp/test/win/linker-flags/profile.gyp +50 -0
  1557. data/ext/gyp/test/win/linker-flags/program-database.gyp +40 -0
  1558. data/ext/gyp/test/win/linker-flags/safeseh.gyp +79 -0
  1559. data/ext/gyp/test/win/linker-flags/safeseh_hello.cc +11 -0
  1560. data/ext/gyp/test/win/linker-flags/safeseh_zero.asm +10 -0
  1561. data/ext/gyp/test/win/linker-flags/safeseh_zero64.asm +9 -0
  1562. data/ext/gyp/test/win/linker-flags/stacksize.gyp +44 -0
  1563. data/ext/gyp/test/win/linker-flags/subdir/library.gyp +13 -0
  1564. data/ext/gyp/test/win/linker-flags/subsystem-windows.cc +9 -0
  1565. data/ext/gyp/test/win/linker-flags/subsystem.gyp +70 -0
  1566. data/ext/gyp/test/win/linker-flags/target-machine.gyp +48 -0
  1567. data/ext/gyp/test/win/linker-flags/tsaware.gyp +28 -0
  1568. data/ext/gyp/test/win/linker-flags/unsupported-manifest.gyp +13 -0
  1569. data/ext/gyp/test/win/linker-flags/update_pgd.py +35 -0
  1570. data/ext/gyp/test/win/linker-flags/warn-as-error.gyp +33 -0
  1571. data/ext/gyp/test/win/linker-flags/x.cc +7 -0
  1572. data/ext/gyp/test/win/linker-flags/y.cc +7 -0
  1573. data/ext/gyp/test/win/linker-flags/z.cc +7 -0
  1574. data/ext/gyp/test/win/long-command-line/function.cc +7 -0
  1575. data/ext/gyp/test/win/long-command-line/hello.cc +7 -0
  1576. data/ext/gyp/test/win/long-command-line/long-command-line.gyp +54 -0
  1577. data/ext/gyp/test/win/ml-safeseh/a.asm +10 -0
  1578. data/ext/gyp/test/win/ml-safeseh/hello.cc +11 -0
  1579. data/ext/gyp/test/win/ml-safeseh/ml-safeseh.gyp +24 -0
  1580. data/ext/gyp/test/win/precompiled/gyptest-all.py +21 -0
  1581. data/ext/gyp/test/win/precompiled/hello.c +14 -0
  1582. data/ext/gyp/test/win/precompiled/hello.gyp +28 -0
  1583. data/ext/gyp/test/win/precompiled/hello2.c +13 -0
  1584. data/ext/gyp/test/win/precompiled/precomp.c +8 -0
  1585. data/ext/gyp/test/win/rc-build/Resource.h +26 -0
  1586. data/ext/gyp/test/win/rc-build/hello.cpp +30 -0
  1587. data/ext/gyp/test/win/rc-build/hello.gyp +92 -0
  1588. data/ext/gyp/test/win/rc-build/hello.h +3 -0
  1589. data/ext/gyp/test/win/rc-build/hello.ico +0 -0
  1590. data/ext/gyp/test/win/rc-build/hello.rc +86 -0
  1591. data/ext/gyp/test/win/rc-build/hello3.rc +87 -0
  1592. data/ext/gyp/test/win/rc-build/small.ico +0 -0
  1593. data/ext/gyp/test/win/rc-build/subdir/hello2.rc +87 -0
  1594. data/ext/gyp/test/win/rc-build/subdir/include.h +1 -0
  1595. data/ext/gyp/test/win/rc-build/targetver.h +24 -0
  1596. data/ext/gyp/test/win/shard/hello.cc +7 -0
  1597. data/ext/gyp/test/win/shard/hello1.cc +7 -0
  1598. data/ext/gyp/test/win/shard/hello2.cc +7 -0
  1599. data/ext/gyp/test/win/shard/hello3.cc +7 -0
  1600. data/ext/gyp/test/win/shard/hello4.cc +7 -0
  1601. data/ext/gyp/test/win/shard/shard.gyp +31 -0
  1602. data/ext/gyp/test/win/shard/shard_ref.gyp +41 -0
  1603. data/ext/gyp/test/win/system-include/bar/header.h +0 -0
  1604. data/ext/gyp/test/win/system-include/common/commonheader.h +0 -0
  1605. data/ext/gyp/test/win/system-include/foo/header.h +0 -0
  1606. data/ext/gyp/test/win/system-include/main.cc +4 -0
  1607. data/ext/gyp/test/win/system-include/test.gyp +26 -0
  1608. data/ext/gyp/test/win/uldi/a.cc +7 -0
  1609. data/ext/gyp/test/win/uldi/b.cc +7 -0
  1610. data/ext/gyp/test/win/uldi/dll.cc +6 -0
  1611. data/ext/gyp/test/win/uldi/exe.cc +7 -0
  1612. data/ext/gyp/test/win/uldi/main.cc +10 -0
  1613. data/ext/gyp/test/win/uldi/uldi-depending-on-module.gyp +42 -0
  1614. data/ext/gyp/test/win/uldi/uldi.gyp +45 -0
  1615. data/ext/gyp/test/win/vs-macros/as.py +20 -0
  1616. data/ext/gyp/test/win/vs-macros/containing-gyp.gyp +39 -0
  1617. data/ext/gyp/test/win/vs-macros/do_stuff.py +8 -0
  1618. data/ext/gyp/test/win/vs-macros/hello.cc +7 -0
  1619. data/ext/gyp/test/win/vs-macros/input-output-macros.gyp +32 -0
  1620. data/ext/gyp/test/win/vs-macros/input.S +0 -0
  1621. data/ext/gyp/test/win/vs-macros/projectname.gyp +29 -0
  1622. data/ext/gyp/test/win/vs-macros/stuff.blah +1 -0
  1623. data/ext/gyp/test/win/vs-macros/targetext.gyp +59 -0
  1624. data/ext/gyp/test/win/vs-macros/targetfilename.gyp +59 -0
  1625. data/ext/gyp/test/win/vs-macros/targetname.gyp +52 -0
  1626. data/ext/gyp/test/win/vs-macros/targetpath.gyp +59 -0
  1627. data/ext/gyp/test/win/vs-macros/test_exists.py +10 -0
  1628. data/ext/gyp/test/win/vs-macros/vcinstalldir.gyp +41 -0
  1629. data/ext/gyp/test/win/win-driver-target-type/win-driver-target-type.c +10 -0
  1630. data/ext/gyp/test/win/win-driver-target-type/win-driver-target-type.gyp +32 -0
  1631. data/ext/gyp/test/win/win-driver-target-type/win-driver-target-type.h +13 -0
  1632. data/ext/gyp/test/win/win-driver-target-type/win-driver-target-type.rc +14 -0
  1633. data/ext/gyp/test/win/win-tool/copies_readonly_files.gyp +29 -0
  1634. data/ext/gyp/test/win/win-tool/gyptest-win-tool-handles-readonly-files.py +55 -0
  1635. data/ext/gyp/test/win/winrt-app-type-revision/dllmain.cc +30 -0
  1636. data/ext/gyp/test/win/winrt-app-type-revision/winrt-app-type-revison.gyp +43 -0
  1637. data/ext/gyp/test/win/winrt-target-platform-version/dllmain.cc +30 -0
  1638. data/ext/gyp/test/win/winrt-target-platform-version/winrt-target-platform-version.gyp +49 -0
  1639. data/ext/gyp/test/xcode-ninja/list_excluded/gyptest-all.py +49 -0
  1640. data/ext/gyp/test/xcode-ninja/list_excluded/hello.cpp +7 -0
  1641. data/ext/gyp/test/xcode-ninja/list_excluded/hello_exclude.gyp +19 -0
  1642. data/ext/gyp/test/xcode-ninja/list_excluded/hello_excluded.cpp +7 -0
  1643. data/ext/gyp/tools/README +15 -0
  1644. data/ext/gyp/tools/Xcode/README +5 -0
  1645. data/ext/gyp/tools/Xcode/Specifications/gyp.pbfilespec +27 -0
  1646. data/ext/gyp/tools/Xcode/Specifications/gyp.xclangspec +226 -0
  1647. data/ext/gyp/tools/emacs/README +12 -0
  1648. data/ext/gyp/tools/emacs/gyp-tests.el +63 -0
  1649. data/ext/gyp/tools/emacs/gyp.el +275 -0
  1650. data/ext/gyp/tools/emacs/run-unit-tests.sh +7 -0
  1651. data/ext/gyp/tools/emacs/testdata/media.gyp +1105 -0
  1652. data/ext/gyp/tools/emacs/testdata/media.gyp.fontified +1107 -0
  1653. data/ext/gyp/tools/graphviz.py +102 -0
  1654. data/ext/gyp/tools/pretty_gyp.py +156 -0
  1655. data/ext/gyp/tools/pretty_sln.py +171 -0
  1656. data/ext/gyp/tools/pretty_vcproj.py +337 -0
  1657. data/ext/libuv/.gitattributes +1 -0
  1658. data/ext/libuv/.github/ISSUE_TEMPLATE.md +13 -0
  1659. data/ext/libuv/.github/stale.yml +22 -0
  1660. data/ext/libuv/.gitignore +80 -0
  1661. data/ext/libuv/.mailmap +50 -0
  1662. data/ext/libuv/AUTHORS +415 -0
  1663. data/ext/libuv/CMakeLists.txt +430 -0
  1664. data/ext/libuv/CONTRIBUTING.md +172 -0
  1665. data/ext/libuv/ChangeLog +4548 -0
  1666. data/ext/libuv/LICENSE +70 -0
  1667. data/ext/libuv/LICENSE-docs +396 -0
  1668. data/ext/libuv/MAINTAINERS.md +48 -0
  1669. data/ext/libuv/Makefile.am +548 -0
  1670. data/ext/libuv/README.md +431 -0
  1671. data/ext/libuv/SUPPORTED_PLATFORMS.md +68 -0
  1672. data/ext/libuv/android-configure-arm +23 -0
  1673. data/ext/libuv/android-configure-arm64 +23 -0
  1674. data/ext/libuv/android-configure-x86 +23 -0
  1675. data/ext/libuv/android-configure-x86_64 +25 -0
  1676. data/ext/libuv/appveyor.yml +32 -0
  1677. data/ext/libuv/autogen.sh +46 -0
  1678. data/ext/libuv/common.gypi +213 -0
  1679. data/ext/libuv/configure.ac +82 -0
  1680. data/ext/libuv/docs/Makefile +183 -0
  1681. data/ext/libuv/docs/code/cgi/main.c +81 -0
  1682. data/ext/libuv/docs/code/cgi/tick.c +13 -0
  1683. data/ext/libuv/docs/code/detach/main.c +31 -0
  1684. data/ext/libuv/docs/code/dns/main.c +80 -0
  1685. data/ext/libuv/docs/code/helloworld/main.c +15 -0
  1686. data/ext/libuv/docs/code/idle-basic/main.c +24 -0
  1687. data/ext/libuv/docs/code/idle-compute/main.c +43 -0
  1688. data/ext/libuv/docs/code/interfaces/main.c +33 -0
  1689. data/ext/libuv/docs/code/locks/main.c +57 -0
  1690. data/ext/libuv/docs/code/multi-echo-server/hammer.js +20 -0
  1691. data/ext/libuv/docs/code/multi-echo-server/main.c +114 -0
  1692. data/ext/libuv/docs/code/multi-echo-server/worker.c +88 -0
  1693. data/ext/libuv/docs/code/onchange/main.c +44 -0
  1694. data/ext/libuv/docs/code/pipe-echo-server/main.c +94 -0
  1695. data/ext/libuv/docs/code/plugin/hello.c +5 -0
  1696. data/ext/libuv/docs/code/plugin/main.c +39 -0
  1697. data/ext/libuv/docs/code/plugin/plugin.h +7 -0
  1698. data/ext/libuv/docs/code/proc-streams/main.c +49 -0
  1699. data/ext/libuv/docs/code/proc-streams/test.c +8 -0
  1700. data/ext/libuv/docs/code/progress/main.c +47 -0
  1701. data/ext/libuv/docs/code/queue-cancel/main.c +59 -0
  1702. data/ext/libuv/docs/code/queue-work/main.c +44 -0
  1703. data/ext/libuv/docs/code/ref-timer/main.c +29 -0
  1704. data/ext/libuv/docs/code/signal/main.c +66 -0
  1705. data/ext/libuv/docs/code/spawn/main.c +36 -0
  1706. data/ext/libuv/docs/code/tcp-echo-server/main.c +87 -0
  1707. data/ext/libuv/docs/code/thread-create/main.c +36 -0
  1708. data/ext/libuv/docs/code/tty/main.c +29 -0
  1709. data/ext/libuv/docs/code/tty-gravity/main.c +48 -0
  1710. data/ext/libuv/docs/code/udp-dhcp/main.c +127 -0
  1711. data/ext/libuv/docs/code/uvcat/main.c +63 -0
  1712. data/ext/libuv/docs/code/uvstop/main.c +33 -0
  1713. data/ext/libuv/docs/code/uvtee/main.c +80 -0
  1714. data/ext/libuv/docs/code/uvwget/main.c +166 -0
  1715. data/ext/libuv/docs/make.bat +243 -0
  1716. data/ext/libuv/docs/src/api.rst +35 -0
  1717. data/ext/libuv/docs/src/async.rst +65 -0
  1718. data/ext/libuv/docs/src/check.rst +46 -0
  1719. data/ext/libuv/docs/src/conf.py +348 -0
  1720. data/ext/libuv/docs/src/design.rst +140 -0
  1721. data/ext/libuv/docs/src/dll.rst +44 -0
  1722. data/ext/libuv/docs/src/dns.rst +108 -0
  1723. data/ext/libuv/docs/src/errors.rst +365 -0
  1724. data/ext/libuv/docs/src/fs.rst +689 -0
  1725. data/ext/libuv/docs/src/fs_event.rst +132 -0
  1726. data/ext/libuv/docs/src/fs_poll.rst +77 -0
  1727. data/ext/libuv/docs/src/guide/about.rst +22 -0
  1728. data/ext/libuv/docs/src/guide/basics.rst +219 -0
  1729. data/ext/libuv/docs/src/guide/eventloops.rst +48 -0
  1730. data/ext/libuv/docs/src/guide/filesystem.rst +330 -0
  1731. data/ext/libuv/docs/src/guide/introduction.rst +75 -0
  1732. data/ext/libuv/docs/src/guide/networking.rst +250 -0
  1733. data/ext/libuv/docs/src/guide/processes.rst +406 -0
  1734. data/ext/libuv/docs/src/guide/threads.rst +385 -0
  1735. data/ext/libuv/docs/src/guide/utilities.rst +437 -0
  1736. data/ext/libuv/docs/src/guide.rst +22 -0
  1737. data/ext/libuv/docs/src/handle.rst +283 -0
  1738. data/ext/libuv/docs/src/idle.rst +54 -0
  1739. data/ext/libuv/docs/src/index.rst +62 -0
  1740. data/ext/libuv/docs/src/loop.rst +238 -0
  1741. data/ext/libuv/docs/src/migration_010_100.rst +244 -0
  1742. data/ext/libuv/docs/src/misc.rst +702 -0
  1743. data/ext/libuv/docs/src/pipe.rst +116 -0
  1744. data/ext/libuv/docs/src/poll.rst +121 -0
  1745. data/ext/libuv/docs/src/prepare.rst +46 -0
  1746. data/ext/libuv/docs/src/process.rst +250 -0
  1747. data/ext/libuv/docs/src/request.rst +116 -0
  1748. data/ext/libuv/docs/src/signal.rst +101 -0
  1749. data/ext/libuv/docs/src/sphinx-plugins/manpage.py +45 -0
  1750. data/ext/libuv/docs/src/static/architecture.png +0 -0
  1751. data/ext/libuv/docs/src/static/diagrams.key/Data/st0-311.jpg +0 -0
  1752. data/ext/libuv/docs/src/static/diagrams.key/Data/st1-475.jpg +0 -0
  1753. data/ext/libuv/docs/src/static/diagrams.key/Index.zip +0 -0
  1754. data/ext/libuv/docs/src/static/diagrams.key/Metadata/BuildVersionHistory.plist +8 -0
  1755. data/ext/libuv/docs/src/static/diagrams.key/Metadata/DocumentIdentifier +1 -0
  1756. data/ext/libuv/docs/src/static/diagrams.key/Metadata/Properties.plist +0 -0
  1757. data/ext/libuv/docs/src/static/diagrams.key/preview-micro.jpg +0 -0
  1758. data/ext/libuv/docs/src/static/diagrams.key/preview-web.jpg +0 -0
  1759. data/ext/libuv/docs/src/static/diagrams.key/preview.jpg +0 -0
  1760. data/ext/libuv/docs/src/static/favicon.ico +0 -0
  1761. data/ext/libuv/docs/src/static/logo.png +0 -0
  1762. data/ext/libuv/docs/src/static/loop_iteration.png +0 -0
  1763. data/ext/libuv/docs/src/stream.rst +237 -0
  1764. data/ext/libuv/docs/src/tcp.rst +125 -0
  1765. data/ext/libuv/docs/src/threading.rst +197 -0
  1766. data/ext/libuv/docs/src/threadpool.rst +69 -0
  1767. data/ext/libuv/docs/src/timer.rst +81 -0
  1768. data/ext/libuv/docs/src/tty.rst +139 -0
  1769. data/ext/libuv/docs/src/udp.rst +390 -0
  1770. data/ext/libuv/docs/src/upgrading.rst +11 -0
  1771. data/ext/libuv/docs/src/version.rst +60 -0
  1772. data/ext/libuv/gyp_uv.py +73 -0
  1773. data/ext/libuv/img/banner.png +0 -0
  1774. data/ext/libuv/img/logos.svg +152 -0
  1775. data/ext/libuv/include/uv/aix.h +32 -0
  1776. data/ext/libuv/include/uv/android-ifaddrs.h +54 -0
  1777. data/ext/libuv/include/uv/bsd.h +34 -0
  1778. data/ext/libuv/include/uv/darwin.h +61 -0
  1779. data/ext/libuv/include/uv/errno.h +448 -0
  1780. data/ext/libuv/include/uv/linux.h +34 -0
  1781. data/ext/libuv/include/uv/os390.h +33 -0
  1782. data/ext/libuv/include/uv/posix.h +31 -0
  1783. data/ext/libuv/include/uv/stdint-msvc2008.h +247 -0
  1784. data/ext/libuv/include/uv/sunos.h +44 -0
  1785. data/ext/libuv/include/uv/threadpool.h +37 -0
  1786. data/ext/libuv/include/uv/tree.h +768 -0
  1787. data/ext/libuv/include/uv/unix.h +505 -0
  1788. data/ext/libuv/include/uv/version.h +43 -0
  1789. data/ext/libuv/include/uv/win.h +691 -0
  1790. data/ext/libuv/include/uv.h +1782 -0
  1791. data/ext/libuv/libuv.pc.in +12 -0
  1792. data/ext/libuv/m4/.gitignore +4 -0
  1793. data/ext/libuv/m4/as_case.m4 +21 -0
  1794. data/ext/libuv/m4/libuv-check-flags.m4 +319 -0
  1795. data/ext/libuv/src/fs-poll.c +287 -0
  1796. data/ext/libuv/src/heap-inl.h +245 -0
  1797. data/ext/libuv/src/idna.c +291 -0
  1798. data/ext/libuv/src/idna.h +31 -0
  1799. data/ext/libuv/src/inet.c +302 -0
  1800. data/ext/libuv/src/queue.h +108 -0
  1801. data/ext/libuv/src/random.c +123 -0
  1802. data/ext/libuv/src/strscpy.c +17 -0
  1803. data/ext/libuv/src/strscpy.h +18 -0
  1804. data/ext/libuv/src/threadpool.c +388 -0
  1805. data/ext/libuv/src/timer.c +181 -0
  1806. data/ext/libuv/src/unix/aix-common.c +337 -0
  1807. data/ext/libuv/src/unix/aix.c +1066 -0
  1808. data/ext/libuv/src/unix/android-ifaddrs.c +712 -0
  1809. data/ext/libuv/src/unix/async.c +298 -0
  1810. data/ext/libuv/src/unix/atomic-ops.h +59 -0
  1811. data/ext/libuv/src/unix/bsd-ifaddrs.c +161 -0
  1812. data/ext/libuv/src/unix/bsd-proctitle.c +93 -0
  1813. data/ext/libuv/src/unix/core.c +1571 -0
  1814. data/ext/libuv/src/unix/cygwin.c +53 -0
  1815. data/ext/libuv/src/unix/darwin-proctitle.c +202 -0
  1816. data/ext/libuv/src/unix/darwin.c +225 -0
  1817. data/ext/libuv/src/unix/dl.c +80 -0
  1818. data/ext/libuv/src/unix/freebsd.c +290 -0
  1819. data/ext/libuv/src/unix/fs.c +2044 -0
  1820. data/ext/libuv/src/unix/fsevents.c +924 -0
  1821. data/ext/libuv/src/unix/getaddrinfo.c +255 -0
  1822. data/ext/libuv/src/unix/getnameinfo.c +121 -0
  1823. data/ext/libuv/src/unix/haiku.c +167 -0
  1824. data/ext/libuv/src/unix/ibmi.c +249 -0
  1825. data/ext/libuv/src/unix/internal.h +331 -0
  1826. data/ext/libuv/src/unix/kqueue.c +544 -0
  1827. data/ext/libuv/src/unix/linux-core.c +1091 -0
  1828. data/ext/libuv/src/unix/linux-inotify.c +354 -0
  1829. data/ext/libuv/src/unix/linux-syscalls.c +394 -0
  1830. data/ext/libuv/src/unix/linux-syscalls.h +153 -0
  1831. data/ext/libuv/src/unix/loop-watcher.c +68 -0
  1832. data/ext/libuv/src/unix/loop.c +194 -0
  1833. data/ext/libuv/src/unix/netbsd.c +259 -0
  1834. data/ext/libuv/src/unix/no-fsevents.c +42 -0
  1835. data/ext/libuv/src/unix/no-proctitle.c +42 -0
  1836. data/ext/libuv/src/unix/openbsd.c +244 -0
  1837. data/ext/libuv/src/unix/os390-syscalls.c +519 -0
  1838. data/ext/libuv/src/unix/os390-syscalls.h +68 -0
  1839. data/ext/libuv/src/unix/os390.c +1003 -0
  1840. data/ext/libuv/src/unix/pipe.c +377 -0
  1841. data/ext/libuv/src/unix/poll.c +150 -0
  1842. data/ext/libuv/src/unix/posix-hrtime.c +35 -0
  1843. data/ext/libuv/src/unix/posix-poll.c +336 -0
  1844. data/ext/libuv/src/unix/process.c +603 -0
  1845. data/ext/libuv/src/unix/procfs-exepath.c +45 -0
  1846. data/ext/libuv/src/unix/proctitle.c +132 -0
  1847. data/ext/libuv/src/unix/pthread-fixes.c +56 -0
  1848. data/ext/libuv/src/unix/random-devurandom.c +93 -0
  1849. data/ext/libuv/src/unix/random-getentropy.c +57 -0
  1850. data/ext/libuv/src/unix/random-getrandom.c +88 -0
  1851. data/ext/libuv/src/unix/random-sysctl-linux.c +99 -0
  1852. data/ext/libuv/src/unix/signal.c +577 -0
  1853. data/ext/libuv/src/unix/spinlock.h +53 -0
  1854. data/ext/libuv/src/unix/stream.c +1697 -0
  1855. data/ext/libuv/src/unix/sunos.c +836 -0
  1856. data/ext/libuv/src/unix/sysinfo-loadavg.c +36 -0
  1857. data/ext/libuv/src/unix/sysinfo-memory.c +42 -0
  1858. data/ext/libuv/src/unix/tcp.c +450 -0
  1859. data/ext/libuv/src/unix/thread.c +852 -0
  1860. data/ext/libuv/src/unix/tty.c +381 -0
  1861. data/ext/libuv/src/unix/udp.c +1136 -0
  1862. data/ext/libuv/src/uv-common.c +812 -0
  1863. data/ext/libuv/src/uv-common.h +326 -0
  1864. data/ext/libuv/src/uv-data-getter-setters.c +98 -0
  1865. data/ext/libuv/src/version.c +45 -0
  1866. data/ext/libuv/src/win/async.c +98 -0
  1867. data/ext/libuv/src/win/atomicops-inl.h +57 -0
  1868. data/ext/libuv/src/win/core.c +657 -0
  1869. data/ext/libuv/src/win/detect-wakeup.c +35 -0
  1870. data/ext/libuv/src/win/dl.c +136 -0
  1871. data/ext/libuv/src/win/error.c +172 -0
  1872. data/ext/libuv/src/win/fs-event.c +589 -0
  1873. data/ext/libuv/src/win/fs-fd-hash-inl.h +178 -0
  1874. data/ext/libuv/src/win/fs.c +3238 -0
  1875. data/ext/libuv/src/win/getaddrinfo.c +463 -0
  1876. data/ext/libuv/src/win/getnameinfo.c +157 -0
  1877. data/ext/libuv/src/win/handle-inl.h +180 -0
  1878. data/ext/libuv/src/win/handle.c +162 -0
  1879. data/ext/libuv/src/win/internal.h +344 -0
  1880. data/ext/libuv/src/win/loop-watcher.c +122 -0
  1881. data/ext/libuv/src/win/pipe.c +2386 -0
  1882. data/ext/libuv/src/win/poll.c +643 -0
  1883. data/ext/libuv/src/win/process-stdio.c +512 -0
  1884. data/ext/libuv/src/win/process.c +1282 -0
  1885. data/ext/libuv/src/win/req-inl.h +221 -0
  1886. data/ext/libuv/src/win/signal.c +277 -0
  1887. data/ext/libuv/src/win/snprintf.c +42 -0
  1888. data/ext/libuv/src/win/stream-inl.h +54 -0
  1889. data/ext/libuv/src/win/stream.c +243 -0
  1890. data/ext/libuv/src/win/tcp.c +1520 -0
  1891. data/ext/libuv/src/win/thread.c +520 -0
  1892. data/ext/libuv/src/win/tty.c +2348 -0
  1893. data/ext/libuv/src/win/udp.c +1185 -0
  1894. data/ext/libuv/src/win/util.c +1879 -0
  1895. data/ext/libuv/src/win/winapi.c +149 -0
  1896. data/ext/libuv/src/win/winapi.h +4751 -0
  1897. data/ext/libuv/src/win/winsock.c +575 -0
  1898. data/ext/libuv/src/win/winsock.h +201 -0
  1899. data/ext/libuv/test/benchmark-async-pummel.c +119 -0
  1900. data/ext/libuv/test/benchmark-async.c +141 -0
  1901. data/ext/libuv/test/benchmark-fs-stat.c +136 -0
  1902. data/ext/libuv/test/benchmark-getaddrinfo.c +92 -0
  1903. data/ext/libuv/test/benchmark-list.h +163 -0
  1904. data/ext/libuv/test/benchmark-loop-count.c +92 -0
  1905. data/ext/libuv/test/benchmark-million-async.c +112 -0
  1906. data/ext/libuv/test/benchmark-million-timers.c +86 -0
  1907. data/ext/libuv/test/benchmark-multi-accept.c +447 -0
  1908. data/ext/libuv/test/benchmark-ping-pongs.c +221 -0
  1909. data/ext/libuv/test/benchmark-pound.c +351 -0
  1910. data/ext/libuv/test/benchmark-pump.c +476 -0
  1911. data/ext/libuv/test/benchmark-sizes.c +46 -0
  1912. data/ext/libuv/test/benchmark-spawn.c +164 -0
  1913. data/ext/libuv/test/benchmark-tcp-write-batch.c +144 -0
  1914. data/ext/libuv/test/benchmark-thread.c +64 -0
  1915. data/ext/libuv/test/benchmark-udp-pummel.c +243 -0
  1916. data/ext/libuv/test/blackhole-server.c +121 -0
  1917. data/ext/libuv/test/dns-server.c +340 -0
  1918. data/ext/libuv/test/echo-server.c +382 -0
  1919. data/ext/libuv/test/fixtures/empty_file +0 -0
  1920. data/ext/libuv/test/fixtures/load_error.node +1 -0
  1921. data/ext/libuv/test/fixtures/lorem_ipsum.txt +1 -0
  1922. data/ext/libuv/test/run-benchmarks.c +65 -0
  1923. data/ext/libuv/test/run-tests.c +239 -0
  1924. data/ext/libuv/test/runner-unix.c +450 -0
  1925. data/ext/libuv/test/runner-unix.h +36 -0
  1926. data/ext/libuv/test/runner-win.c +357 -0
  1927. data/ext/libuv/test/runner-win.h +41 -0
  1928. data/ext/libuv/test/runner.c +431 -0
  1929. data/ext/libuv/test/runner.h +176 -0
  1930. data/ext/libuv/test/task.h +238 -0
  1931. data/ext/libuv/test/test-active.c +84 -0
  1932. data/ext/libuv/test/test-async-null-cb.c +64 -0
  1933. data/ext/libuv/test/test-async.c +134 -0
  1934. data/ext/libuv/test/test-barrier.c +148 -0
  1935. data/ext/libuv/test/test-callback-order.c +77 -0
  1936. data/ext/libuv/test/test-callback-stack.c +204 -0
  1937. data/ext/libuv/test/test-close-fd.c +80 -0
  1938. data/ext/libuv/test/test-close-order.c +80 -0
  1939. data/ext/libuv/test/test-condvar.c +267 -0
  1940. data/ext/libuv/test/test-connect-unspecified.c +63 -0
  1941. data/ext/libuv/test/test-connection-fail.c +151 -0
  1942. data/ext/libuv/test/test-cwd-and-chdir.c +58 -0
  1943. data/ext/libuv/test/test-default-loop-close.c +59 -0
  1944. data/ext/libuv/test/test-delayed-accept.c +189 -0
  1945. data/ext/libuv/test/test-dlerror.c +61 -0
  1946. data/ext/libuv/test/test-eintr-handling.c +94 -0
  1947. data/ext/libuv/test/test-embed.c +139 -0
  1948. data/ext/libuv/test/test-emfile.c +121 -0
  1949. data/ext/libuv/test/test-env-vars.c +140 -0
  1950. data/ext/libuv/test/test-error.c +79 -0
  1951. data/ext/libuv/test/test-fail-always.c +29 -0
  1952. data/ext/libuv/test/test-fork.c +683 -0
  1953. data/ext/libuv/test/test-fs-copyfile.c +209 -0
  1954. data/ext/libuv/test/test-fs-event.c +1165 -0
  1955. data/ext/libuv/test/test-fs-fd-hash.c +133 -0
  1956. data/ext/libuv/test/test-fs-open-flags.c +435 -0
  1957. data/ext/libuv/test/test-fs-poll.c +300 -0
  1958. data/ext/libuv/test/test-fs-readdir.c +462 -0
  1959. data/ext/libuv/test/test-fs.c +4238 -0
  1960. data/ext/libuv/test/test-get-currentexe.c +86 -0
  1961. data/ext/libuv/test/test-get-loadavg.c +35 -0
  1962. data/ext/libuv/test/test-get-memory.c +40 -0
  1963. data/ext/libuv/test/test-get-passwd.c +86 -0
  1964. data/ext/libuv/test/test-getaddrinfo.c +191 -0
  1965. data/ext/libuv/test/test-gethostname.c +58 -0
  1966. data/ext/libuv/test/test-getnameinfo.c +101 -0
  1967. data/ext/libuv/test/test-getsockname.c +361 -0
  1968. data/ext/libuv/test/test-getters-setters.c +88 -0
  1969. data/ext/libuv/test/test-gettimeofday.c +39 -0
  1970. data/ext/libuv/test/test-handle-fileno.c +125 -0
  1971. data/ext/libuv/test/test-homedir.c +72 -0
  1972. data/ext/libuv/test/test-hrtime.c +52 -0
  1973. data/ext/libuv/test/test-idle.c +99 -0
  1974. data/ext/libuv/test/test-idna.c +195 -0
  1975. data/ext/libuv/test/test-ip4-addr.c +55 -0
  1976. data/ext/libuv/test/test-ip6-addr.c +171 -0
  1977. data/ext/libuv/test/test-ipc-heavy-traffic-deadlock-bug.c +159 -0
  1978. data/ext/libuv/test/test-ipc-send-recv.c +429 -0
  1979. data/ext/libuv/test/test-ipc.c +974 -0
  1980. data/ext/libuv/test/test-list.h +1064 -0
  1981. data/ext/libuv/test/test-loop-alive.c +67 -0
  1982. data/ext/libuv/test/test-loop-close.c +75 -0
  1983. data/ext/libuv/test/test-loop-configure.c +38 -0
  1984. data/ext/libuv/test/test-loop-handles.c +337 -0
  1985. data/ext/libuv/test/test-loop-stop.c +71 -0
  1986. data/ext/libuv/test/test-loop-time.c +63 -0
  1987. data/ext/libuv/test/test-multiple-listen.c +109 -0
  1988. data/ext/libuv/test/test-mutexes.c +182 -0
  1989. data/ext/libuv/test/test-osx-select.c +140 -0
  1990. data/ext/libuv/test/test-pass-always.c +28 -0
  1991. data/ext/libuv/test/test-ping-pong.c +301 -0
  1992. data/ext/libuv/test/test-pipe-bind-error.c +139 -0
  1993. data/ext/libuv/test/test-pipe-close-stdout-read-stdin.c +112 -0
  1994. data/ext/libuv/test/test-pipe-connect-error.c +95 -0
  1995. data/ext/libuv/test/test-pipe-connect-multiple.c +107 -0
  1996. data/ext/libuv/test/test-pipe-connect-prepare.c +83 -0
  1997. data/ext/libuv/test/test-pipe-getsockname.c +266 -0
  1998. data/ext/libuv/test/test-pipe-pending-instances.c +59 -0
  1999. data/ext/libuv/test/test-pipe-sendmsg.c +172 -0
  2000. data/ext/libuv/test/test-pipe-server-close.c +94 -0
  2001. data/ext/libuv/test/test-pipe-set-fchmod.c +90 -0
  2002. data/ext/libuv/test/test-pipe-set-non-blocking.c +99 -0
  2003. data/ext/libuv/test/test-platform-output.c +170 -0
  2004. data/ext/libuv/test/test-poll-close-doesnt-corrupt-stack.c +114 -0
  2005. data/ext/libuv/test/test-poll-close.c +73 -0
  2006. data/ext/libuv/test/test-poll-closesocket.c +92 -0
  2007. data/ext/libuv/test/test-poll-oob.c +210 -0
  2008. data/ext/libuv/test/test-poll.c +668 -0
  2009. data/ext/libuv/test/test-process-priority.c +83 -0
  2010. data/ext/libuv/test/test-process-title-threadsafe.c +89 -0
  2011. data/ext/libuv/test/test-process-title.c +76 -0
  2012. data/ext/libuv/test/test-queue-foreach-delete.c +204 -0
  2013. data/ext/libuv/test/test-random.c +94 -0
  2014. data/ext/libuv/test/test-ref.c +445 -0
  2015. data/ext/libuv/test/test-run-nowait.c +45 -0
  2016. data/ext/libuv/test/test-run-once.c +48 -0
  2017. data/ext/libuv/test/test-semaphore.c +111 -0
  2018. data/ext/libuv/test/test-shutdown-close.c +108 -0
  2019. data/ext/libuv/test/test-shutdown-eof.c +182 -0
  2020. data/ext/libuv/test/test-shutdown-twice.c +85 -0
  2021. data/ext/libuv/test/test-signal-multiple-loops.c +302 -0
  2022. data/ext/libuv/test/test-signal-pending-on-close.c +94 -0
  2023. data/ext/libuv/test/test-signal.c +325 -0
  2024. data/ext/libuv/test/test-socket-buffer-size.c +77 -0
  2025. data/ext/libuv/test/test-spawn.c +1924 -0
  2026. data/ext/libuv/test/test-stdio-over-pipes.c +256 -0
  2027. data/ext/libuv/test/test-strscpy.c +53 -0
  2028. data/ext/libuv/test/test-tcp-alloc-cb-fail.c +123 -0
  2029. data/ext/libuv/test/test-tcp-bind-error.c +254 -0
  2030. data/ext/libuv/test/test-tcp-bind6-error.c +176 -0
  2031. data/ext/libuv/test/test-tcp-close-accept.c +198 -0
  2032. data/ext/libuv/test/test-tcp-close-reset.c +290 -0
  2033. data/ext/libuv/test/test-tcp-close-while-connecting.c +97 -0
  2034. data/ext/libuv/test/test-tcp-close.c +136 -0
  2035. data/ext/libuv/test/test-tcp-connect-error-after-write.c +98 -0
  2036. data/ext/libuv/test/test-tcp-connect-error.c +73 -0
  2037. data/ext/libuv/test/test-tcp-connect-timeout.c +91 -0
  2038. data/ext/libuv/test/test-tcp-connect6-error.c +71 -0
  2039. data/ext/libuv/test/test-tcp-create-socket-early.c +209 -0
  2040. data/ext/libuv/test/test-tcp-flags.c +52 -0
  2041. data/ext/libuv/test/test-tcp-oob.c +146 -0
  2042. data/ext/libuv/test/test-tcp-open.c +400 -0
  2043. data/ext/libuv/test/test-tcp-read-stop.c +76 -0
  2044. data/ext/libuv/test/test-tcp-shutdown-after-write.c +138 -0
  2045. data/ext/libuv/test/test-tcp-try-write-error.c +109 -0
  2046. data/ext/libuv/test/test-tcp-try-write.c +135 -0
  2047. data/ext/libuv/test/test-tcp-unexpected-read.c +117 -0
  2048. data/ext/libuv/test/test-tcp-write-after-connect.c +72 -0
  2049. data/ext/libuv/test/test-tcp-write-fail.c +115 -0
  2050. data/ext/libuv/test/test-tcp-write-queue-order.c +139 -0
  2051. data/ext/libuv/test/test-tcp-write-to-half-open-connection.c +141 -0
  2052. data/ext/libuv/test/test-tcp-writealot.c +180 -0
  2053. data/ext/libuv/test/test-thread-equal.c +45 -0
  2054. data/ext/libuv/test/test-thread.c +286 -0
  2055. data/ext/libuv/test/test-threadpool-cancel.c +349 -0
  2056. data/ext/libuv/test/test-threadpool.c +76 -0
  2057. data/ext/libuv/test/test-timer-again.c +141 -0
  2058. data/ext/libuv/test/test-timer-from-check.c +80 -0
  2059. data/ext/libuv/test/test-timer.c +343 -0
  2060. data/ext/libuv/test/test-tmpdir.c +82 -0
  2061. data/ext/libuv/test/test-tty-duplicate-key.c +321 -0
  2062. data/ext/libuv/test/test-tty.c +464 -0
  2063. data/ext/libuv/test/test-udp-alloc-cb-fail.c +196 -0
  2064. data/ext/libuv/test/test-udp-bind.c +93 -0
  2065. data/ext/libuv/test/test-udp-connect.c +182 -0
  2066. data/ext/libuv/test/test-udp-create-socket-early.c +135 -0
  2067. data/ext/libuv/test/test-udp-dgram-too-big.c +91 -0
  2068. data/ext/libuv/test/test-udp-ipv6.c +200 -0
  2069. data/ext/libuv/test/test-udp-multicast-interface.c +99 -0
  2070. data/ext/libuv/test/test-udp-multicast-interface6.c +103 -0
  2071. data/ext/libuv/test/test-udp-multicast-join.c +181 -0
  2072. data/ext/libuv/test/test-udp-multicast-join6.c +215 -0
  2073. data/ext/libuv/test/test-udp-multicast-ttl.c +94 -0
  2074. data/ext/libuv/test/test-udp-open.c +350 -0
  2075. data/ext/libuv/test/test-udp-options.c +156 -0
  2076. data/ext/libuv/test/test-udp-send-and-recv.c +212 -0
  2077. data/ext/libuv/test/test-udp-send-hang-loop.c +99 -0
  2078. data/ext/libuv/test/test-udp-send-immediate.c +148 -0
  2079. data/ext/libuv/test/test-udp-send-unreachable.c +150 -0
  2080. data/ext/libuv/test/test-udp-try-send.c +121 -0
  2081. data/ext/libuv/test/test-uname.c +69 -0
  2082. data/ext/libuv/test/test-walk-handles.c +77 -0
  2083. data/ext/libuv/test/test-watcher-cross-stop.c +111 -0
  2084. data/ext/libuv/test/test.gyp +293 -0
  2085. data/ext/libuv/tools/make_dist_html.py +124 -0
  2086. data/ext/libuv/tools/vswhere_usability_wrapper.cmd +33 -0
  2087. data/ext/libuv/uv.gyp +368 -0
  2088. data/ext/libuv/vcbuild.bat +184 -0
  2089. data/lib/mt-libuv/version.rb +1 -1
  2090. data/mt-libuv.gemspec +26 -26
  2091. metadata +2088 -1
@@ -0,0 +1,2260 @@
1
+ # Copyright (c) 2013 Google Inc. 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.
4
+
5
+ # Notes:
6
+ #
7
+ # This is all roughly based on the Makefile system used by the Linux
8
+ # kernel, but is a non-recursive make -- we put the entire dependency
9
+ # graph in front of make and let it figure it out.
10
+ #
11
+ # The code below generates a separate .mk file for each target, but
12
+ # all are sourced by the top-level Makefile. This means that all
13
+ # variables in .mk-files clobber one another. Be careful to use :=
14
+ # where appropriate for immediate evaluation, and similarly to watch
15
+ # that you're not relying on a variable value to last beween different
16
+ # .mk files.
17
+ #
18
+ # TODOs:
19
+ #
20
+ # Global settings and utility functions are currently stuffed in the
21
+ # toplevel Makefile. It may make sense to generate some .mk files on
22
+ # the side to keep the the files readable.
23
+
24
+ from __future__ import print_function
25
+
26
+ import os
27
+ import re
28
+ import sys
29
+ import subprocess
30
+ import gyp
31
+ import gyp.common
32
+ import gyp.xcode_emulation
33
+ from gyp.common import GetEnvironFallback
34
+ from gyp.common import GypError
35
+
36
+ import hashlib
37
+
38
+ generator_default_variables = {
39
+ 'EXECUTABLE_PREFIX': '',
40
+ 'EXECUTABLE_SUFFIX': '',
41
+ 'STATIC_LIB_PREFIX': 'lib',
42
+ 'SHARED_LIB_PREFIX': 'lib',
43
+ 'STATIC_LIB_SUFFIX': '.a',
44
+ 'INTERMEDIATE_DIR': '$(obj).$(TOOLSET)/$(TARGET)/geni',
45
+ 'SHARED_INTERMEDIATE_DIR': '$(obj)/gen',
46
+ 'PRODUCT_DIR': '$(builddir)',
47
+ 'RULE_INPUT_ROOT': '%(INPUT_ROOT)s', # This gets expanded by Python.
48
+ 'RULE_INPUT_DIRNAME': '%(INPUT_DIRNAME)s', # This gets expanded by Python.
49
+ 'RULE_INPUT_PATH': '$(abspath $<)',
50
+ 'RULE_INPUT_EXT': '$(suffix $<)',
51
+ 'RULE_INPUT_NAME': '$(notdir $<)',
52
+ 'CONFIGURATION_NAME': '$(BUILDTYPE)',
53
+ }
54
+
55
+ # Make supports multiple toolsets
56
+ generator_supports_multiple_toolsets = True
57
+
58
+ # Request sorted dependencies in the order from dependents to dependencies.
59
+ generator_wants_sorted_dependencies = False
60
+
61
+ # Placates pylint.
62
+ generator_additional_non_configuration_keys = []
63
+ generator_additional_path_sections = []
64
+ generator_extra_sources_for_rules = []
65
+ generator_filelist_paths = None
66
+
67
+
68
+ def CalculateVariables(default_variables, params):
69
+ """Calculate additional variables for use in the build (called by gyp)."""
70
+ flavor = gyp.common.GetFlavor(params)
71
+ if flavor == 'mac':
72
+ default_variables.setdefault('OS', 'mac')
73
+ default_variables.setdefault('SHARED_LIB_SUFFIX', '.dylib')
74
+ default_variables.setdefault('SHARED_LIB_DIR',
75
+ generator_default_variables['PRODUCT_DIR'])
76
+ default_variables.setdefault('LIB_DIR',
77
+ generator_default_variables['PRODUCT_DIR'])
78
+
79
+ # Copy additional generator configuration data from Xcode, which is shared
80
+ # by the Mac Make generator.
81
+ import gyp.generator.xcode as xcode_generator
82
+ global generator_additional_non_configuration_keys
83
+ generator_additional_non_configuration_keys = getattr(xcode_generator,
84
+ 'generator_additional_non_configuration_keys', [])
85
+ global generator_additional_path_sections
86
+ generator_additional_path_sections = getattr(xcode_generator,
87
+ 'generator_additional_path_sections', [])
88
+ global generator_extra_sources_for_rules
89
+ generator_extra_sources_for_rules = getattr(xcode_generator,
90
+ 'generator_extra_sources_for_rules', [])
91
+ COMPILABLE_EXTENSIONS.update({'.m': 'objc', '.mm' : 'objcxx'})
92
+ else:
93
+ operating_system = flavor
94
+ if flavor == 'android':
95
+ operating_system = 'linux' # Keep this legacy behavior for now.
96
+ default_variables.setdefault('OS', operating_system)
97
+ if flavor == 'aix':
98
+ default_variables.setdefault('SHARED_LIB_SUFFIX', '.a')
99
+ else:
100
+ default_variables.setdefault('SHARED_LIB_SUFFIX', '.so')
101
+ default_variables.setdefault('SHARED_LIB_DIR','$(builddir)/lib.$(TOOLSET)')
102
+ default_variables.setdefault('LIB_DIR', '$(obj).$(TOOLSET)')
103
+
104
+
105
+ def CalculateGeneratorInputInfo(params):
106
+ """Calculate the generator specific info that gets fed to input (called by
107
+ gyp)."""
108
+ generator_flags = params.get('generator_flags', {})
109
+ android_ndk_version = generator_flags.get('android_ndk_version', None)
110
+ # Android NDK requires a strict link order.
111
+ if android_ndk_version:
112
+ global generator_wants_sorted_dependencies
113
+ generator_wants_sorted_dependencies = True
114
+
115
+ output_dir = params['options'].generator_output or \
116
+ params['options'].toplevel_dir
117
+ builddir_name = generator_flags.get('output_dir', 'out')
118
+ qualified_out_dir = os.path.normpath(os.path.join(
119
+ output_dir, builddir_name, 'gypfiles'))
120
+
121
+ global generator_filelist_paths
122
+ generator_filelist_paths = {
123
+ 'toplevel': params['options'].toplevel_dir,
124
+ 'qualified_out_dir': qualified_out_dir,
125
+ }
126
+
127
+
128
+ # The .d checking code below uses these functions:
129
+ # wildcard, sort, foreach, shell, wordlist
130
+ # wildcard can handle spaces, the rest can't.
131
+ # Since I could find no way to make foreach work with spaces in filenames
132
+ # correctly, the .d files have spaces replaced with another character. The .d
133
+ # file for
134
+ # Chromium\ Framework.framework/foo
135
+ # is for example
136
+ # out/Release/.deps/out/Release/Chromium?Framework.framework/foo
137
+ # This is the replacement character.
138
+ SPACE_REPLACEMENT = '?'
139
+
140
+
141
+ LINK_COMMANDS_LINUX = """\
142
+ quiet_cmd_alink = AR($(TOOLSET)) $@
143
+ cmd_alink = rm -f $@ && $(AR.$(TOOLSET)) crs $@ $(filter %.o,$^)
144
+
145
+ quiet_cmd_alink_thin = AR($(TOOLSET)) $@
146
+ cmd_alink_thin = rm -f $@ && $(AR.$(TOOLSET)) crsT $@ $(filter %.o,$^)
147
+
148
+ # Due to circular dependencies between libraries :(, we wrap the
149
+ # special "figure out circular dependencies" flags around the entire
150
+ # input list during linking.
151
+ quiet_cmd_link = LINK($(TOOLSET)) $@
152
+ cmd_link = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ -Wl,--start-group $(LD_INPUTS) -Wl,--end-group $(LIBS)
153
+
154
+ # We support two kinds of shared objects (.so):
155
+ # 1) shared_library, which is just bundling together many dependent libraries
156
+ # into a link line.
157
+ # 2) loadable_module, which is generating a module intended for dlopen().
158
+ #
159
+ # They differ only slightly:
160
+ # In the former case, we want to package all dependent code into the .so.
161
+ # In the latter case, we want to package just the API exposed by the
162
+ # outermost module.
163
+ # This means shared_library uses --whole-archive, while loadable_module doesn't.
164
+ # (Note that --whole-archive is incompatible with the --start-group used in
165
+ # normal linking.)
166
+
167
+ # Other shared-object link notes:
168
+ # - Set SONAME to the library filename so our binaries don't reference
169
+ # the local, absolute paths used on the link command-line.
170
+ quiet_cmd_solink = SOLINK($(TOOLSET)) $@
171
+ cmd_solink = $(LINK.$(TOOLSET)) -shared $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -Wl,-soname=$(@F) -o $@ -Wl,--whole-archive $(LD_INPUTS) -Wl,--no-whole-archive $(LIBS)
172
+
173
+ quiet_cmd_solink_module = SOLINK_MODULE($(TOOLSET)) $@
174
+ cmd_solink_module = $(LINK.$(TOOLSET)) -shared $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -Wl,-soname=$(@F) -o $@ -Wl,--start-group $(filter-out FORCE_DO_CMD, $^) -Wl,--end-group $(LIBS)
175
+ """
176
+
177
+ LINK_COMMANDS_MAC = """\
178
+ quiet_cmd_alink = LIBTOOL-STATIC $@
179
+ cmd_alink = rm -f $@ && ./gyp-mac-tool filter-libtool libtool $(GYP_LIBTOOLFLAGS) -static -o $@ $(filter %.o,$^)
180
+
181
+ quiet_cmd_link = LINK($(TOOLSET)) $@
182
+ cmd_link = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o "$@" $(LD_INPUTS) $(LIBS)
183
+
184
+ quiet_cmd_solink = SOLINK($(TOOLSET)) $@
185
+ cmd_solink = $(LINK.$(TOOLSET)) -shared $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o "$@" $(LD_INPUTS) $(LIBS)
186
+
187
+ quiet_cmd_solink_module = SOLINK_MODULE($(TOOLSET)) $@
188
+ cmd_solink_module = $(LINK.$(TOOLSET)) -bundle $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ $(filter-out FORCE_DO_CMD, $^) $(LIBS)
189
+ """
190
+
191
+ LINK_COMMANDS_ANDROID = """\
192
+ quiet_cmd_alink = AR($(TOOLSET)) $@
193
+ cmd_alink = rm -f $@ && $(AR.$(TOOLSET)) crs $@ $(filter %.o,$^)
194
+
195
+ quiet_cmd_alink_thin = AR($(TOOLSET)) $@
196
+ cmd_alink_thin = rm -f $@ && $(AR.$(TOOLSET)) crsT $@ $(filter %.o,$^)
197
+
198
+ # Due to circular dependencies between libraries :(, we wrap the
199
+ # special "figure out circular dependencies" flags around the entire
200
+ # input list during linking.
201
+ quiet_cmd_link = LINK($(TOOLSET)) $@
202
+ quiet_cmd_link_host = LINK($(TOOLSET)) $@
203
+ cmd_link = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ -Wl,--start-group $(LD_INPUTS) -Wl,--end-group $(LIBS)
204
+ cmd_link_host = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ $(LD_INPUTS) $(LIBS)
205
+
206
+ # Other shared-object link notes:
207
+ # - Set SONAME to the library filename so our binaries don't reference
208
+ # the local, absolute paths used on the link command-line.
209
+ quiet_cmd_solink = SOLINK($(TOOLSET)) $@
210
+ cmd_solink = $(LINK.$(TOOLSET)) -shared $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -Wl,-soname=$(@F) -o $@ -Wl,--whole-archive $(LD_INPUTS) -Wl,--no-whole-archive $(LIBS)
211
+
212
+ quiet_cmd_solink_module = SOLINK_MODULE($(TOOLSET)) $@
213
+ cmd_solink_module = $(LINK.$(TOOLSET)) -shared $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -Wl,-soname=$(@F) -o $@ -Wl,--start-group $(filter-out FORCE_DO_CMD, $^) -Wl,--end-group $(LIBS)
214
+ quiet_cmd_solink_module_host = SOLINK_MODULE($(TOOLSET)) $@
215
+ cmd_solink_module_host = $(LINK.$(TOOLSET)) -shared $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -Wl,-soname=$(@F) -o $@ $(filter-out FORCE_DO_CMD, $^) $(LIBS)
216
+ """
217
+
218
+
219
+ LINK_COMMANDS_AIX = """\
220
+ quiet_cmd_alink = AR($(TOOLSET)) $@
221
+ cmd_alink = rm -f $@ && $(AR.$(TOOLSET)) -X32_64 crs $@ $(filter %.o,$^)
222
+
223
+ quiet_cmd_alink_thin = AR($(TOOLSET)) $@
224
+ cmd_alink_thin = rm -f $@ && $(AR.$(TOOLSET)) -X32_64 crs $@ $(filter %.o,$^)
225
+
226
+ quiet_cmd_link = LINK($(TOOLSET)) $@
227
+ cmd_link = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ $(LD_INPUTS) $(LIBS)
228
+
229
+ quiet_cmd_solink = SOLINK($(TOOLSET)) $@
230
+ cmd_solink = $(LINK.$(TOOLSET)) -shared $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ $(LD_INPUTS) $(LIBS)
231
+
232
+ quiet_cmd_solink_module = SOLINK_MODULE($(TOOLSET)) $@
233
+ cmd_solink_module = $(LINK.$(TOOLSET)) -shared $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ $(filter-out FORCE_DO_CMD, $^) $(LIBS)
234
+ """
235
+
236
+
237
+ LINK_COMMANDS_OS390 = """\
238
+ quiet_cmd_alink = AR($(TOOLSET)) $@
239
+ cmd_alink = rm -f $@ && $(AR.$(TOOLSET)) crs $@ $(filter %.o,$^)
240
+
241
+ quiet_cmd_alink_thin = AR($(TOOLSET)) $@
242
+ cmd_alink_thin = rm -f $@ && $(AR.$(TOOLSET)) crsT $@ $(filter %.o,$^)
243
+
244
+ quiet_cmd_link = LINK($(TOOLSET)) $@
245
+ cmd_link = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ $(LD_INPUTS) $(LIBS)
246
+
247
+ quiet_cmd_solink = SOLINK($(TOOLSET)) $@
248
+ cmd_solink = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ $(LD_INPUTS) $(LIBS) -Wl,DLL
249
+
250
+ quiet_cmd_solink_module = SOLINK_MODULE($(TOOLSET)) $@
251
+ cmd_solink_module = $(LINK.$(TOOLSET)) $(GYP_LDFLAGS) $(LDFLAGS.$(TOOLSET)) -o $@ $(filter-out FORCE_DO_CMD, $^) $(LIBS) -Wl,DLL
252
+ """
253
+
254
+
255
+ # Header of toplevel Makefile.
256
+ # This should go into the build tree, but it's easier to keep it here for now.
257
+ SHARED_HEADER = ("""\
258
+ # We borrow heavily from the kernel build setup, though we are simpler since
259
+ # we don't have Kconfig tweaking settings on us.
260
+
261
+ # The implicit make rules have it looking for RCS files, among other things.
262
+ # We instead explicitly write all the rules we care about.
263
+ # It's even quicker (saves ~200ms) to pass -r on the command line.
264
+ MAKEFLAGS=-r
265
+
266
+ # The source directory tree.
267
+ srcdir := %(srcdir)s
268
+ abs_srcdir := $(abspath $(srcdir))
269
+
270
+ # The name of the builddir.
271
+ builddir_name ?= %(builddir)s
272
+
273
+ # The V=1 flag on command line makes us verbosely print command lines.
274
+ ifdef V
275
+ quiet=
276
+ else
277
+ quiet=quiet_
278
+ endif
279
+
280
+ # Specify BUILDTYPE=Release on the command line for a release build.
281
+ BUILDTYPE ?= %(default_configuration)s
282
+
283
+ # Directory all our build output goes into.
284
+ # Note that this must be two directories beneath src/ for unit tests to pass,
285
+ # as they reach into the src/ directory for data with relative paths.
286
+ builddir ?= $(builddir_name)/$(BUILDTYPE)
287
+ abs_builddir := $(abspath $(builddir))
288
+ depsdir := $(builddir)/.deps
289
+
290
+ # Object output directory.
291
+ obj := $(builddir)/obj
292
+ abs_obj := $(abspath $(obj))
293
+
294
+ # We build up a list of every single one of the targets so we can slurp in the
295
+ # generated dependency rule Makefiles in one pass.
296
+ all_deps :=
297
+
298
+ %(make_global_settings)s
299
+
300
+ CC.target ?= %(CC.target)s
301
+ CFLAGS.target ?= $(CPPFLAGS) $(CFLAGS)
302
+ CXX.target ?= %(CXX.target)s
303
+ CXXFLAGS.target ?= $(CPPFLAGS) $(CXXFLAGS)
304
+ LINK.target ?= %(LINK.target)s
305
+ LDFLAGS.target ?= $(LDFLAGS)
306
+ AR.target ?= $(AR)
307
+
308
+ # C++ apps need to be linked with g++.
309
+ LINK ?= $(CXX.target)
310
+
311
+ # TODO(evan): move all cross-compilation logic to gyp-time so we don't need
312
+ # to replicate this environment fallback in make as well.
313
+ CC.host ?= %(CC.host)s
314
+ CFLAGS.host ?= $(CPPFLAGS_host) $(CFLAGS_host)
315
+ CXX.host ?= %(CXX.host)s
316
+ CXXFLAGS.host ?= $(CPPFLAGS_host) $(CXXFLAGS_host)
317
+ LINK.host ?= %(LINK.host)s
318
+ LDFLAGS.host ?= $(LDFLAGS_host)
319
+ AR.host ?= %(AR.host)s
320
+
321
+ # Define a dir function that can handle spaces.
322
+ # http://www.gnu.org/software/make/manual/make.html#Syntax-of-Functions
323
+ # "leading spaces cannot appear in the text of the first argument as written.
324
+ # These characters can be put into the argument value by variable substitution."
325
+ empty :=
326
+ space := $(empty) $(empty)
327
+
328
+ # http://stackoverflow.com/questions/1189781/using-make-dir-or-notdir-on-a-path-with-spaces
329
+ replace_spaces = $(subst $(space),""" + SPACE_REPLACEMENT + """,$1)
330
+ unreplace_spaces = $(subst """ + SPACE_REPLACEMENT + """,$(space),$1)
331
+ dirx = $(call unreplace_spaces,$(dir $(call replace_spaces,$1)))
332
+
333
+ # Flags to make gcc output dependency info. Note that you need to be
334
+ # careful here to use the flags that ccache and distcc can understand.
335
+ # We write to a dep file on the side first and then rename at the end
336
+ # so we can't end up with a broken dep file.
337
+ depfile = $(depsdir)/$(call replace_spaces,$@).d
338
+ DEPFLAGS = %(makedep_args)s -MF $(depfile).raw
339
+
340
+ # We have to fixup the deps output in a few ways.
341
+ # (1) the file output should mention the proper .o file.
342
+ # ccache or distcc lose the path to the target, so we convert a rule of
343
+ # the form:
344
+ # foobar.o: DEP1 DEP2
345
+ # into
346
+ # path/to/foobar.o: DEP1 DEP2
347
+ # (2) we want missing files not to cause us to fail to build.
348
+ # We want to rewrite
349
+ # foobar.o: DEP1 DEP2 \\
350
+ # DEP3
351
+ # to
352
+ # DEP1:
353
+ # DEP2:
354
+ # DEP3:
355
+ # so if the files are missing, they're just considered phony rules.
356
+ # We have to do some pretty insane escaping to get those backslashes
357
+ # and dollar signs past make, the shell, and sed at the same time.
358
+ # Doesn't work with spaces, but that's fine: .d files have spaces in
359
+ # their names replaced with other characters."""
360
+ r"""
361
+ define fixup_dep
362
+ # The depfile may not exist if the input file didn't have any #includes.
363
+ touch $(depfile).raw
364
+ # Fixup path as in (1).
365
+ sed -e "s|^$(notdir $@)|$@|" $(depfile).raw >> $(depfile)
366
+ # Add extra rules as in (2).
367
+ # We remove slashes and replace spaces with new lines;
368
+ # remove blank lines;
369
+ # delete the first line and append a colon to the remaining lines.
370
+ sed -e 's|\\||' -e 'y| |\n|' $(depfile).raw |\
371
+ grep -v '^$$' |\
372
+ sed -e 1d -e 's|$$|:|' \
373
+ >> $(depfile)
374
+ rm $(depfile).raw
375
+ endef
376
+ """
377
+ """
378
+ # Command definitions:
379
+ # - cmd_foo is the actual command to run;
380
+ # - quiet_cmd_foo is the brief-output summary of the command.
381
+
382
+ quiet_cmd_cc = CC($(TOOLSET)) $@
383
+ cmd_cc = $(CC.$(TOOLSET)) $(GYP_CFLAGS) $(DEPFLAGS) $(CFLAGS.$(TOOLSET)) -c -o $@ $<
384
+
385
+ quiet_cmd_cxx = CXX($(TOOLSET)) $@
386
+ cmd_cxx = $(CXX.$(TOOLSET)) $(GYP_CXXFLAGS) $(DEPFLAGS) $(CXXFLAGS.$(TOOLSET)) -c -o $@ $<
387
+ %(extra_commands)s
388
+ quiet_cmd_touch = TOUCH $@
389
+ cmd_touch = touch $@
390
+
391
+ quiet_cmd_copy = COPY $@
392
+ # send stderr to /dev/null to ignore messages when linking directories.
393
+ cmd_copy = ln -f "$<" "$@" 2>/dev/null || (rm -rf "$@" && cp %(copy_archive_args)s "$<" "$@")
394
+
395
+ %(link_commands)s
396
+ """
397
+
398
+ r"""
399
+ # Define an escape_quotes function to escape single quotes.
400
+ # This allows us to handle quotes properly as long as we always use
401
+ # use single quotes and escape_quotes.
402
+ escape_quotes = $(subst ','\'',$(1))
403
+ # This comment is here just to include a ' to unconfuse syntax highlighting.
404
+ # Define an escape_vars function to escape '$' variable syntax.
405
+ # This allows us to read/write command lines with shell variables (e.g.
406
+ # $LD_LIBRARY_PATH), without triggering make substitution.
407
+ escape_vars = $(subst $$,$$$$,$(1))
408
+ # Helper that expands to a shell command to echo a string exactly as it is in
409
+ # make. This uses printf instead of echo because printf's behaviour with respect
410
+ # to escape sequences is more portable than echo's across different shells
411
+ # (e.g., dash, bash).
412
+ exact_echo = printf '%%s\n' '$(call escape_quotes,$(1))'
413
+ """
414
+ """
415
+ # Helper to compare the command we're about to run against the command
416
+ # we logged the last time we ran the command. Produces an empty
417
+ # string (false) when the commands match.
418
+ # Tricky point: Make has no string-equality test function.
419
+ # The kernel uses the following, but it seems like it would have false
420
+ # positives, where one string reordered its arguments.
421
+ # arg_check = $(strip $(filter-out $(cmd_$(1)), $(cmd_$@)) \\
422
+ # $(filter-out $(cmd_$@), $(cmd_$(1))))
423
+ # We instead substitute each for the empty string into the other, and
424
+ # say they're equal if both substitutions produce the empty string.
425
+ # .d files contain """ + SPACE_REPLACEMENT + \
426
+ """ instead of spaces, take that into account.
427
+ command_changed = $(or $(subst $(cmd_$(1)),,$(cmd_$(call replace_spaces,$@))),\\
428
+ $(subst $(cmd_$(call replace_spaces,$@)),,$(cmd_$(1))))
429
+
430
+ # Helper that is non-empty when a prerequisite changes.
431
+ # Normally make does this implicitly, but we force rules to always run
432
+ # so we can check their command lines.
433
+ # $? -- new prerequisites
434
+ # $| -- order-only dependencies
435
+ prereq_changed = $(filter-out FORCE_DO_CMD,$(filter-out $|,$?))
436
+
437
+ # Helper that executes all postbuilds until one fails.
438
+ define do_postbuilds
439
+ @E=0;\\
440
+ for p in $(POSTBUILDS); do\\
441
+ eval $$p;\\
442
+ E=$$?;\\
443
+ if [ $$E -ne 0 ]; then\\
444
+ break;\\
445
+ fi;\\
446
+ done;\\
447
+ if [ $$E -ne 0 ]; then\\
448
+ rm -rf "$@";\\
449
+ exit $$E;\\
450
+ fi
451
+ endef
452
+
453
+ # do_cmd: run a command via the above cmd_foo names, if necessary.
454
+ # Should always run for a given target to handle command-line changes.
455
+ # Second argument, if non-zero, makes it do asm/C/C++ dependency munging.
456
+ # Third argument, if non-zero, makes it do POSTBUILDS processing.
457
+ # Note: We intentionally do NOT call dirx for depfile, since it contains """ + \
458
+ SPACE_REPLACEMENT + """ for
459
+ # spaces already and dirx strips the """ + SPACE_REPLACEMENT + \
460
+ """ characters.
461
+ define do_cmd
462
+ $(if $(or $(command_changed),$(prereq_changed)),
463
+ @$(call exact_echo, $($(quiet)cmd_$(1)))
464
+ @mkdir -p "$(call dirx,$@)" "$(dir $(depfile))"
465
+ $(if $(findstring flock,$(word %(flock_index)d,$(cmd_$1))),
466
+ @$(cmd_$(1))
467
+ @echo " $(quiet_cmd_$(1)): Finished",
468
+ @$(cmd_$(1))
469
+ )
470
+ @$(call exact_echo,$(call escape_vars,cmd_$(call replace_spaces,$@) := $(cmd_$(1)))) > $(depfile)
471
+ @$(if $(2),$(fixup_dep))
472
+ $(if $(and $(3), $(POSTBUILDS)),
473
+ $(call do_postbuilds)
474
+ )
475
+ )
476
+ endef
477
+
478
+ # Declare the "%(default_target)s" target first so it is the default,
479
+ # even though we don't have the deps yet.
480
+ .PHONY: %(default_target)s
481
+ %(default_target)s:
482
+
483
+ # make looks for ways to re-generate included makefiles, but in our case, we
484
+ # don't have a direct way. Explicitly telling make that it has nothing to do
485
+ # for them makes it go faster.
486
+ %%.d: ;
487
+
488
+ # Use FORCE_DO_CMD to force a target to run. Should be coupled with
489
+ # do_cmd.
490
+ .PHONY: FORCE_DO_CMD
491
+ FORCE_DO_CMD:
492
+
493
+ """)
494
+
495
+ SHARED_HEADER_MAC_COMMANDS = """
496
+ quiet_cmd_objc = CXX($(TOOLSET)) $@
497
+ cmd_objc = $(CC.$(TOOLSET)) $(GYP_OBJCFLAGS) $(DEPFLAGS) -c -o $@ $<
498
+
499
+ quiet_cmd_objcxx = CXX($(TOOLSET)) $@
500
+ cmd_objcxx = $(CXX.$(TOOLSET)) $(GYP_OBJCXXFLAGS) $(DEPFLAGS) -c -o $@ $<
501
+
502
+ # Commands for precompiled header files.
503
+ quiet_cmd_pch_c = CXX($(TOOLSET)) $@
504
+ cmd_pch_c = $(CC.$(TOOLSET)) $(GYP_PCH_CFLAGS) $(DEPFLAGS) $(CXXFLAGS.$(TOOLSET)) -c -o $@ $<
505
+ quiet_cmd_pch_cc = CXX($(TOOLSET)) $@
506
+ cmd_pch_cc = $(CC.$(TOOLSET)) $(GYP_PCH_CXXFLAGS) $(DEPFLAGS) $(CXXFLAGS.$(TOOLSET)) -c -o $@ $<
507
+ quiet_cmd_pch_m = CXX($(TOOLSET)) $@
508
+ cmd_pch_m = $(CC.$(TOOLSET)) $(GYP_PCH_OBJCFLAGS) $(DEPFLAGS) -c -o $@ $<
509
+ quiet_cmd_pch_mm = CXX($(TOOLSET)) $@
510
+ cmd_pch_mm = $(CC.$(TOOLSET)) $(GYP_PCH_OBJCXXFLAGS) $(DEPFLAGS) -c -o $@ $<
511
+
512
+ # gyp-mac-tool is written next to the root Makefile by gyp.
513
+ # Use $(4) for the command, since $(2) and $(3) are used as flag by do_cmd
514
+ # already.
515
+ quiet_cmd_mac_tool = MACTOOL $(4) $<
516
+ cmd_mac_tool = ./gyp-mac-tool $(4) $< "$@"
517
+
518
+ quiet_cmd_mac_package_framework = PACKAGE FRAMEWORK $@
519
+ cmd_mac_package_framework = ./gyp-mac-tool package-framework "$@" $(4)
520
+
521
+ quiet_cmd_infoplist = INFOPLIST $@
522
+ cmd_infoplist = $(CC.$(TOOLSET)) -E -P -Wno-trigraphs -x c $(INFOPLIST_DEFINES) "$<" -o "$@"
523
+ """
524
+
525
+
526
+ def WriteRootHeaderSuffixRules(writer):
527
+ extensions = sorted(COMPILABLE_EXTENSIONS.keys(), key=str.lower)
528
+
529
+ writer.write('# Suffix rules, putting all outputs into $(obj).\n')
530
+ for ext in extensions:
531
+ writer.write('$(obj).$(TOOLSET)/%%.o: $(srcdir)/%%%s FORCE_DO_CMD\n' % ext)
532
+ writer.write('\t@$(call do_cmd,%s,1)\n' % COMPILABLE_EXTENSIONS[ext])
533
+
534
+ writer.write('\n# Try building from generated source, too.\n')
535
+ for ext in extensions:
536
+ writer.write(
537
+ '$(obj).$(TOOLSET)/%%.o: $(obj).$(TOOLSET)/%%%s FORCE_DO_CMD\n' % ext)
538
+ writer.write('\t@$(call do_cmd,%s,1)\n' % COMPILABLE_EXTENSIONS[ext])
539
+ writer.write('\n')
540
+ for ext in extensions:
541
+ writer.write('$(obj).$(TOOLSET)/%%.o: $(obj)/%%%s FORCE_DO_CMD\n' % ext)
542
+ writer.write('\t@$(call do_cmd,%s,1)\n' % COMPILABLE_EXTENSIONS[ext])
543
+ writer.write('\n')
544
+
545
+
546
+ SHARED_HEADER_SUFFIX_RULES_COMMENT1 = ("""\
547
+ # Suffix rules, putting all outputs into $(obj).
548
+ """)
549
+
550
+
551
+ SHARED_HEADER_SUFFIX_RULES_COMMENT2 = ("""\
552
+ # Try building from generated source, too.
553
+ """)
554
+
555
+
556
+ SHARED_FOOTER = """\
557
+ # "all" is a concatenation of the "all" targets from all the included
558
+ # sub-makefiles. This is just here to clarify.
559
+ all:
560
+
561
+ # Add in dependency-tracking rules. $(all_deps) is the list of every single
562
+ # target in our tree. Only consider the ones with .d (dependency) info:
563
+ d_files := $(wildcard $(foreach f,$(all_deps),$(depsdir)/$(f).d))
564
+ ifneq ($(d_files),)
565
+ include $(d_files)
566
+ endif
567
+ """
568
+
569
+ header = """\
570
+ # This file is generated by gyp; do not edit.
571
+
572
+ """
573
+
574
+ # Maps every compilable file extension to the do_cmd that compiles it.
575
+ COMPILABLE_EXTENSIONS = {
576
+ '.c': 'cc',
577
+ '.cc': 'cxx',
578
+ '.cpp': 'cxx',
579
+ '.cxx': 'cxx',
580
+ '.s': 'cc',
581
+ '.S': 'cc',
582
+ }
583
+
584
+ def Compilable(filename):
585
+ """Return true if the file is compilable (should be in OBJS)."""
586
+ for res in (filename.endswith(e) for e in COMPILABLE_EXTENSIONS):
587
+ if res:
588
+ return True
589
+ return False
590
+
591
+
592
+ def Linkable(filename):
593
+ """Return true if the file is linkable (should be on the link line)."""
594
+ return filename.endswith('.o')
595
+
596
+
597
+ def Target(filename):
598
+ """Translate a compilable filename to its .o target."""
599
+ return os.path.splitext(filename)[0] + '.o'
600
+
601
+
602
+ def EscapeShellArgument(s):
603
+ """Quotes an argument so that it will be interpreted literally by a POSIX
604
+ shell. Taken from
605
+ http://stackoverflow.com/questions/35817/whats-the-best-way-to-escape-ossystem-calls-in-python
606
+ """
607
+ return "'" + s.replace("'", "'\\''") + "'"
608
+
609
+
610
+ def EscapeMakeVariableExpansion(s):
611
+ """Make has its own variable expansion syntax using $. We must escape it for
612
+ string to be interpreted literally."""
613
+ return s.replace('$', '$$')
614
+
615
+
616
+ def EscapeCppDefine(s):
617
+ """Escapes a CPP define so that it will reach the compiler unaltered."""
618
+ s = EscapeShellArgument(s)
619
+ s = EscapeMakeVariableExpansion(s)
620
+ # '#' characters must be escaped even embedded in a string, else Make will
621
+ # treat it as the start of a comment.
622
+ return s.replace('#', r'\#')
623
+
624
+
625
+ def QuoteIfNecessary(string):
626
+ """TODO: Should this ideally be replaced with one or more of the above
627
+ functions?"""
628
+ if '"' in string:
629
+ string = '"' + string.replace('"', '\\"') + '"'
630
+ return string
631
+
632
+
633
+ def StringToMakefileVariable(string):
634
+ """Convert a string to a value that is acceptable as a make variable name."""
635
+ return re.sub('[^a-zA-Z0-9_]', '_', string)
636
+
637
+
638
+ srcdir_prefix = ''
639
+ def Sourceify(path):
640
+ """Convert a path to its source directory form."""
641
+ if '$(' in path:
642
+ return path
643
+ if os.path.isabs(path):
644
+ return path
645
+ return srcdir_prefix + path
646
+
647
+
648
+ def QuoteSpaces(s, quote=r'\ '):
649
+ return s.replace(' ', quote)
650
+
651
+
652
+ # TODO: Avoid code duplication with _ValidateSourcesForMSVSProject in msvs.py.
653
+ def _ValidateSourcesForOSX(spec, all_sources):
654
+ """Makes sure if duplicate basenames are not specified in the source list.
655
+
656
+ Arguments:
657
+ spec: The target dictionary containing the properties of the target.
658
+ """
659
+ if spec.get('type', None) != 'static_library':
660
+ return
661
+
662
+ basenames = {}
663
+ for source in all_sources:
664
+ name, ext = os.path.splitext(source)
665
+ is_compiled_file = ext in [
666
+ '.c', '.cc', '.cpp', '.cxx', '.m', '.mm', '.s', '.S']
667
+ if not is_compiled_file:
668
+ continue
669
+ basename = os.path.basename(name) # Don't include extension.
670
+ basenames.setdefault(basename, []).append(source)
671
+
672
+ error = ''
673
+ for basename, files in basenames.items():
674
+ if len(files) > 1:
675
+ error += ' %s: %s\n' % (basename, ' '.join(files))
676
+
677
+ if error:
678
+ print('static library %s has several files with the same basename:\n' %
679
+ spec['target_name'] + error + 'libtool on OS X will generate' +
680
+ ' warnings for them.')
681
+ raise GypError('Duplicate basenames in sources section, see list above')
682
+
683
+
684
+ # Map from qualified target to path to output.
685
+ target_outputs = {}
686
+ # Map from qualified target to any linkable output. A subset
687
+ # of target_outputs. E.g. when mybinary depends on liba, we want to
688
+ # include liba in the linker line; when otherbinary depends on
689
+ # mybinary, we just want to build mybinary first.
690
+ target_link_deps = {}
691
+
692
+
693
+ class MakefileWriter(object):
694
+ """MakefileWriter packages up the writing of one target-specific foobar.mk.
695
+
696
+ Its only real entry point is Write(), and is mostly used for namespacing.
697
+ """
698
+
699
+ def __init__(self, generator_flags, flavor):
700
+ self.generator_flags = generator_flags
701
+ self.flavor = flavor
702
+
703
+ self.suffix_rules_srcdir = {}
704
+ self.suffix_rules_objdir1 = {}
705
+ self.suffix_rules_objdir2 = {}
706
+
707
+ # Generate suffix rules for all compilable extensions.
708
+ for ext in COMPILABLE_EXTENSIONS.keys():
709
+ # Suffix rules for source folder.
710
+ self.suffix_rules_srcdir.update({ext: ("""\
711
+ $(obj).$(TOOLSET)/$(TARGET)/%%.o: $(srcdir)/%%%s FORCE_DO_CMD
712
+ @$(call do_cmd,%s,1)
713
+ """ % (ext, COMPILABLE_EXTENSIONS[ext]))})
714
+
715
+ # Suffix rules for generated source files.
716
+ self.suffix_rules_objdir1.update({ext: ("""\
717
+ $(obj).$(TOOLSET)/$(TARGET)/%%.o: $(obj).$(TOOLSET)/%%%s FORCE_DO_CMD
718
+ @$(call do_cmd,%s,1)
719
+ """ % (ext, COMPILABLE_EXTENSIONS[ext]))})
720
+ self.suffix_rules_objdir2.update({ext: ("""\
721
+ $(obj).$(TOOLSET)/$(TARGET)/%%.o: $(obj)/%%%s FORCE_DO_CMD
722
+ @$(call do_cmd,%s,1)
723
+ """ % (ext, COMPILABLE_EXTENSIONS[ext]))})
724
+
725
+
726
+ def Write(self, qualified_target, base_path, output_filename, spec, configs,
727
+ part_of_all):
728
+ """The main entry point: writes a .mk file for a single target.
729
+
730
+ Arguments:
731
+ qualified_target: target we're generating
732
+ base_path: path relative to source root we're building in, used to resolve
733
+ target-relative paths
734
+ output_filename: output .mk file name to write
735
+ spec, configs: gyp info
736
+ part_of_all: flag indicating this target is part of 'all'
737
+ """
738
+ gyp.common.EnsureDirExists(output_filename)
739
+
740
+ self.fp = open(output_filename, 'w')
741
+
742
+ self.fp.write(header)
743
+
744
+ self.qualified_target = qualified_target
745
+ self.path = base_path
746
+ self.target = spec['target_name']
747
+ self.type = spec['type']
748
+ self.toolset = spec['toolset']
749
+
750
+ self.is_mac_bundle = gyp.xcode_emulation.IsMacBundle(self.flavor, spec)
751
+ if self.flavor == 'mac':
752
+ self.xcode_settings = gyp.xcode_emulation.XcodeSettings(spec)
753
+ else:
754
+ self.xcode_settings = None
755
+
756
+ deps, link_deps = self.ComputeDeps(spec)
757
+
758
+ # Some of the generation below can add extra output, sources, or
759
+ # link dependencies. All of the out params of the functions that
760
+ # follow use names like extra_foo.
761
+ extra_outputs = []
762
+ extra_sources = []
763
+ extra_link_deps = []
764
+ extra_mac_bundle_resources = []
765
+ mac_bundle_deps = []
766
+
767
+ if self.is_mac_bundle:
768
+ self.output = self.ComputeMacBundleOutput(spec)
769
+ self.output_binary = self.ComputeMacBundleBinaryOutput(spec)
770
+ else:
771
+ self.output = self.output_binary = self.ComputeOutput(spec)
772
+
773
+ self.is_standalone_static_library = bool(
774
+ spec.get('standalone_static_library', 0))
775
+ self._INSTALLABLE_TARGETS = ('executable', 'loadable_module',
776
+ 'shared_library')
777
+ if (self.is_standalone_static_library or
778
+ self.type in self._INSTALLABLE_TARGETS):
779
+ self.alias = os.path.basename(self.output)
780
+ install_path = self._InstallableTargetInstallPath()
781
+ else:
782
+ self.alias = self.output
783
+ install_path = self.output
784
+
785
+ self.WriteLn("TOOLSET := " + self.toolset)
786
+ self.WriteLn("TARGET := " + self.target)
787
+
788
+ # Actions must come first, since they can generate more OBJs for use below.
789
+ if 'actions' in spec:
790
+ self.WriteActions(spec['actions'], extra_sources, extra_outputs,
791
+ extra_mac_bundle_resources, part_of_all)
792
+
793
+ # Rules must be early like actions.
794
+ if 'rules' in spec:
795
+ self.WriteRules(spec['rules'], extra_sources, extra_outputs,
796
+ extra_mac_bundle_resources, part_of_all)
797
+
798
+ if 'copies' in spec:
799
+ self.WriteCopies(spec['copies'], extra_outputs, part_of_all)
800
+
801
+ # Bundle resources.
802
+ if self.is_mac_bundle:
803
+ all_mac_bundle_resources = (
804
+ spec.get('mac_bundle_resources', []) + extra_mac_bundle_resources)
805
+ self.WriteMacBundleResources(all_mac_bundle_resources, mac_bundle_deps)
806
+ self.WriteMacInfoPlist(mac_bundle_deps)
807
+
808
+ # Sources.
809
+ all_sources = spec.get('sources', []) + extra_sources
810
+ if all_sources:
811
+ if self.flavor == 'mac':
812
+ # libtool on OS X generates warnings for duplicate basenames in the same
813
+ # target.
814
+ _ValidateSourcesForOSX(spec, all_sources)
815
+ self.WriteSources(
816
+ configs, deps, all_sources, extra_outputs,
817
+ extra_link_deps, part_of_all,
818
+ gyp.xcode_emulation.MacPrefixHeader(
819
+ self.xcode_settings, lambda p: Sourceify(self.Absolutify(p)),
820
+ self.Pchify))
821
+ sources = [x for x in all_sources if Compilable(x)]
822
+ if sources:
823
+ self.WriteLn(SHARED_HEADER_SUFFIX_RULES_COMMENT1)
824
+ extensions = set([os.path.splitext(s)[1] for s in sources])
825
+ for ext in extensions:
826
+ if ext in self.suffix_rules_srcdir:
827
+ self.WriteLn(self.suffix_rules_srcdir[ext])
828
+ self.WriteLn(SHARED_HEADER_SUFFIX_RULES_COMMENT2)
829
+ for ext in extensions:
830
+ if ext in self.suffix_rules_objdir1:
831
+ self.WriteLn(self.suffix_rules_objdir1[ext])
832
+ for ext in extensions:
833
+ if ext in self.suffix_rules_objdir2:
834
+ self.WriteLn(self.suffix_rules_objdir2[ext])
835
+ self.WriteLn('# End of this set of suffix rules')
836
+
837
+ # Add dependency from bundle to bundle binary.
838
+ if self.is_mac_bundle:
839
+ mac_bundle_deps.append(self.output_binary)
840
+
841
+ self.WriteTarget(spec, configs, deps, extra_link_deps + link_deps,
842
+ mac_bundle_deps, extra_outputs, part_of_all)
843
+
844
+ # Update global list of target outputs, used in dependency tracking.
845
+ target_outputs[qualified_target] = install_path
846
+
847
+ # Update global list of link dependencies.
848
+ if self.type in ('static_library', 'shared_library'):
849
+ target_link_deps[qualified_target] = self.output_binary
850
+
851
+ # Currently any versions have the same effect, but in future the behavior
852
+ # could be different.
853
+ if self.generator_flags.get('android_ndk_version', None):
854
+ self.WriteAndroidNdkModuleRule(self.target, all_sources, link_deps)
855
+
856
+ self.fp.close()
857
+
858
+
859
+ def WriteSubMake(self, output_filename, makefile_path, targets, build_dir):
860
+ """Write a "sub-project" Makefile.
861
+
862
+ This is a small, wrapper Makefile that calls the top-level Makefile to build
863
+ the targets from a single gyp file (i.e. a sub-project).
864
+
865
+ Arguments:
866
+ output_filename: sub-project Makefile name to write
867
+ makefile_path: path to the top-level Makefile
868
+ targets: list of "all" targets for this sub-project
869
+ build_dir: build output directory, relative to the sub-project
870
+ """
871
+ gyp.common.EnsureDirExists(output_filename)
872
+ self.fp = open(output_filename, 'w')
873
+ self.fp.write(header)
874
+ # For consistency with other builders, put sub-project build output in the
875
+ # sub-project dir (see test/subdirectory/gyptest-subdir-all.py).
876
+ self.WriteLn('export builddir_name ?= %s' %
877
+ os.path.join(os.path.dirname(output_filename), build_dir))
878
+ self.WriteLn('.PHONY: all')
879
+ self.WriteLn('all:')
880
+ if makefile_path:
881
+ makefile_path = ' -C ' + makefile_path
882
+ self.WriteLn('\t$(MAKE)%s %s' % (makefile_path, ' '.join(targets)))
883
+ self.fp.close()
884
+
885
+
886
+ def WriteActions(self, actions, extra_sources, extra_outputs,
887
+ extra_mac_bundle_resources, part_of_all):
888
+ """Write Makefile code for any 'actions' from the gyp input.
889
+
890
+ extra_sources: a list that will be filled in with newly generated source
891
+ files, if any
892
+ extra_outputs: a list that will be filled in with any outputs of these
893
+ actions (used to make other pieces dependent on these
894
+ actions)
895
+ part_of_all: flag indicating this target is part of 'all'
896
+ """
897
+ env = self.GetSortedXcodeEnv()
898
+ for action in actions:
899
+ name = StringToMakefileVariable('%s_%s' % (self.qualified_target,
900
+ action['action_name']))
901
+ self.WriteLn('### Rules for action "%s":' % action['action_name'])
902
+ inputs = action['inputs']
903
+ outputs = action['outputs']
904
+
905
+ # Build up a list of outputs.
906
+ # Collect the output dirs we'll need.
907
+ dirs = set()
908
+ for out in outputs:
909
+ dir = os.path.split(out)[0]
910
+ if dir:
911
+ dirs.add(dir)
912
+ if int(action.get('process_outputs_as_sources', False)):
913
+ extra_sources += outputs
914
+ if int(action.get('process_outputs_as_mac_bundle_resources', False)):
915
+ extra_mac_bundle_resources += outputs
916
+
917
+ # Write the actual command.
918
+ action_commands = action['action']
919
+ if self.flavor == 'mac':
920
+ action_commands = [gyp.xcode_emulation.ExpandEnvVars(command, env)
921
+ for command in action_commands]
922
+ command = gyp.common.EncodePOSIXShellList(action_commands)
923
+ if 'message' in action:
924
+ self.WriteLn('quiet_cmd_%s = ACTION %s $@' % (name, action['message']))
925
+ else:
926
+ self.WriteLn('quiet_cmd_%s = ACTION %s $@' % (name, name))
927
+ if len(dirs) > 0:
928
+ command = 'mkdir -p %s' % ' '.join(dirs) + '; ' + command
929
+
930
+ cd_action = 'cd %s; ' % Sourceify(self.path or '.')
931
+
932
+ # command and cd_action get written to a toplevel variable called
933
+ # cmd_foo. Toplevel variables can't handle things that change per
934
+ # makefile like $(TARGET), so hardcode the target.
935
+ command = command.replace('$(TARGET)', self.target)
936
+ cd_action = cd_action.replace('$(TARGET)', self.target)
937
+
938
+ # Set LD_LIBRARY_PATH in case the action runs an executable from this
939
+ # build which links to shared libs from this build.
940
+ # actions run on the host, so they should in theory only use host
941
+ # libraries, but until everything is made cross-compile safe, also use
942
+ # target libraries.
943
+ # TODO(piman): when everything is cross-compile safe, remove lib.target
944
+ self.WriteLn('cmd_%s = LD_LIBRARY_PATH=$(builddir)/lib.host:'
945
+ '$(builddir)/lib.target:$$LD_LIBRARY_PATH; '
946
+ 'export LD_LIBRARY_PATH; '
947
+ '%s%s'
948
+ % (name, cd_action, command))
949
+ self.WriteLn()
950
+ outputs = [self.Absolutify(o) for o in outputs]
951
+ # The makefile rules are all relative to the top dir, but the gyp actions
952
+ # are defined relative to their containing dir. This replaces the obj
953
+ # variable for the action rule with an absolute version so that the output
954
+ # goes in the right place.
955
+ # Only write the 'obj' and 'builddir' rules for the "primary" output (:1);
956
+ # it's superfluous for the "extra outputs", and this avoids accidentally
957
+ # writing duplicate dummy rules for those outputs.
958
+ # Same for environment.
959
+ self.WriteLn("%s: obj := $(abs_obj)" % QuoteSpaces(outputs[0]))
960
+ self.WriteLn("%s: builddir := $(abs_builddir)" % QuoteSpaces(outputs[0]))
961
+ self.WriteSortedXcodeEnv(outputs[0], self.GetSortedXcodeEnv())
962
+
963
+ for input in inputs:
964
+ assert ' ' not in input, (
965
+ "Spaces in action input filenames not supported (%s)" % input)
966
+ for output in outputs:
967
+ assert ' ' not in output, (
968
+ "Spaces in action output filenames not supported (%s)" % output)
969
+
970
+ # See the comment in WriteCopies about expanding env vars.
971
+ outputs = [gyp.xcode_emulation.ExpandEnvVars(o, env) for o in outputs]
972
+ inputs = [gyp.xcode_emulation.ExpandEnvVars(i, env) for i in inputs]
973
+
974
+ self.WriteDoCmd(outputs, map(Sourceify, map(self.Absolutify, inputs)),
975
+ part_of_all=part_of_all, command=name)
976
+
977
+ # Stuff the outputs in a variable so we can refer to them later.
978
+ outputs_variable = 'action_%s_outputs' % name
979
+ self.WriteLn('%s := %s' % (outputs_variable, ' '.join(outputs)))
980
+ extra_outputs.append('$(%s)' % outputs_variable)
981
+ self.WriteLn()
982
+
983
+ self.WriteLn()
984
+
985
+
986
+ def WriteRules(self, rules, extra_sources, extra_outputs,
987
+ extra_mac_bundle_resources, part_of_all):
988
+ """Write Makefile code for any 'rules' from the gyp input.
989
+
990
+ extra_sources: a list that will be filled in with newly generated source
991
+ files, if any
992
+ extra_outputs: a list that will be filled in with any outputs of these
993
+ rules (used to make other pieces dependent on these rules)
994
+ part_of_all: flag indicating this target is part of 'all'
995
+ """
996
+ env = self.GetSortedXcodeEnv()
997
+ for rule in rules:
998
+ name = StringToMakefileVariable('%s_%s' % (self.qualified_target,
999
+ rule['rule_name']))
1000
+ count = 0
1001
+ self.WriteLn('### Generated for rule %s:' % name)
1002
+
1003
+ all_outputs = []
1004
+
1005
+ for rule_source in rule.get('rule_sources', []):
1006
+ dirs = set()
1007
+ (rule_source_dirname, rule_source_basename) = os.path.split(rule_source)
1008
+ (rule_source_root, rule_source_ext) = \
1009
+ os.path.splitext(rule_source_basename)
1010
+
1011
+ outputs = [self.ExpandInputRoot(out, rule_source_root,
1012
+ rule_source_dirname)
1013
+ for out in rule['outputs']]
1014
+
1015
+ for out in outputs:
1016
+ dir = os.path.dirname(out)
1017
+ if dir:
1018
+ dirs.add(dir)
1019
+ if int(rule.get('process_outputs_as_sources', False)):
1020
+ extra_sources += outputs
1021
+ if int(rule.get('process_outputs_as_mac_bundle_resources', False)):
1022
+ extra_mac_bundle_resources += outputs
1023
+ inputs = map(Sourceify, map(self.Absolutify, [rule_source] +
1024
+ rule.get('inputs', [])))
1025
+ actions = ['$(call do_cmd,%s_%d)' % (name, count)]
1026
+
1027
+ if name == 'resources_grit':
1028
+ # HACK: This is ugly. Grit intentionally doesn't touch the
1029
+ # timestamp of its output file when the file doesn't change,
1030
+ # which is fine in hash-based dependency systems like scons
1031
+ # and forge, but not kosher in the make world. After some
1032
+ # discussion, hacking around it here seems like the least
1033
+ # amount of pain.
1034
+ actions += ['@touch --no-create $@']
1035
+
1036
+ # See the comment in WriteCopies about expanding env vars.
1037
+ outputs = [gyp.xcode_emulation.ExpandEnvVars(o, env) for o in outputs]
1038
+ inputs = [gyp.xcode_emulation.ExpandEnvVars(i, env) for i in inputs]
1039
+
1040
+ outputs = [self.Absolutify(o) for o in outputs]
1041
+ all_outputs += outputs
1042
+ # Only write the 'obj' and 'builddir' rules for the "primary" output
1043
+ # (:1); it's superfluous for the "extra outputs", and this avoids
1044
+ # accidentally writing duplicate dummy rules for those outputs.
1045
+ self.WriteLn('%s: obj := $(abs_obj)' % outputs[0])
1046
+ self.WriteLn('%s: builddir := $(abs_builddir)' % outputs[0])
1047
+ self.WriteMakeRule(outputs, inputs, actions,
1048
+ command="%s_%d" % (name, count))
1049
+ # Spaces in rule filenames are not supported, but rule variables have
1050
+ # spaces in them (e.g. RULE_INPUT_PATH expands to '$(abspath $<)').
1051
+ # The spaces within the variables are valid, so remove the variables
1052
+ # before checking.
1053
+ variables_with_spaces = re.compile(r'\$\([^ ]* \$<\)')
1054
+ for output in outputs:
1055
+ output = re.sub(variables_with_spaces, '', output)
1056
+ assert ' ' not in output, (
1057
+ "Spaces in rule filenames not yet supported (%s)" % output)
1058
+ self.WriteLn('all_deps += %s' % ' '.join(outputs))
1059
+
1060
+ action = [self.ExpandInputRoot(ac, rule_source_root,
1061
+ rule_source_dirname)
1062
+ for ac in rule['action']]
1063
+ mkdirs = ''
1064
+ if len(dirs) > 0:
1065
+ mkdirs = 'mkdir -p %s; ' % ' '.join(dirs)
1066
+ cd_action = 'cd %s; ' % Sourceify(self.path or '.')
1067
+
1068
+ # action, cd_action, and mkdirs get written to a toplevel variable
1069
+ # called cmd_foo. Toplevel variables can't handle things that change
1070
+ # per makefile like $(TARGET), so hardcode the target.
1071
+ if self.flavor == 'mac':
1072
+ action = [gyp.xcode_emulation.ExpandEnvVars(command, env)
1073
+ for command in action]
1074
+ action = gyp.common.EncodePOSIXShellList(action)
1075
+ action = action.replace('$(TARGET)', self.target)
1076
+ cd_action = cd_action.replace('$(TARGET)', self.target)
1077
+ mkdirs = mkdirs.replace('$(TARGET)', self.target)
1078
+
1079
+ # Set LD_LIBRARY_PATH in case the rule runs an executable from this
1080
+ # build which links to shared libs from this build.
1081
+ # rules run on the host, so they should in theory only use host
1082
+ # libraries, but until everything is made cross-compile safe, also use
1083
+ # target libraries.
1084
+ # TODO(piman): when everything is cross-compile safe, remove lib.target
1085
+ self.WriteLn(
1086
+ "cmd_%(name)s_%(count)d = LD_LIBRARY_PATH="
1087
+ "$(builddir)/lib.host:$(builddir)/lib.target:$$LD_LIBRARY_PATH; "
1088
+ "export LD_LIBRARY_PATH; "
1089
+ "%(cd_action)s%(mkdirs)s%(action)s" % {
1090
+ 'action': action,
1091
+ 'cd_action': cd_action,
1092
+ 'count': count,
1093
+ 'mkdirs': mkdirs,
1094
+ 'name': name,
1095
+ })
1096
+ self.WriteLn(
1097
+ 'quiet_cmd_%(name)s_%(count)d = RULE %(name)s_%(count)d $@' % {
1098
+ 'count': count,
1099
+ 'name': name,
1100
+ })
1101
+ self.WriteLn()
1102
+ count += 1
1103
+
1104
+ outputs_variable = 'rule_%s_outputs' % name
1105
+ self.WriteList(all_outputs, outputs_variable)
1106
+ extra_outputs.append('$(%s)' % outputs_variable)
1107
+
1108
+ self.WriteLn('### Finished generating for rule: %s' % name)
1109
+ self.WriteLn()
1110
+ self.WriteLn('### Finished generating for all rules')
1111
+ self.WriteLn('')
1112
+
1113
+
1114
+ def WriteCopies(self, copies, extra_outputs, part_of_all):
1115
+ """Write Makefile code for any 'copies' from the gyp input.
1116
+
1117
+ extra_outputs: a list that will be filled in with any outputs of this action
1118
+ (used to make other pieces dependent on this action)
1119
+ part_of_all: flag indicating this target is part of 'all'
1120
+ """
1121
+ self.WriteLn('### Generated for copy rule.')
1122
+
1123
+ variable = StringToMakefileVariable(self.qualified_target + '_copies')
1124
+ outputs = []
1125
+ for copy in copies:
1126
+ for path in copy['files']:
1127
+ # Absolutify() may call normpath, and will strip trailing slashes.
1128
+ path = Sourceify(self.Absolutify(path))
1129
+ filename = os.path.split(path)[1]
1130
+ output = Sourceify(self.Absolutify(os.path.join(copy['destination'],
1131
+ filename)))
1132
+
1133
+ # If the output path has variables in it, which happens in practice for
1134
+ # 'copies', writing the environment as target-local doesn't work,
1135
+ # because the variables are already needed for the target name.
1136
+ # Copying the environment variables into global make variables doesn't
1137
+ # work either, because then the .d files will potentially contain spaces
1138
+ # after variable expansion, and .d file handling cannot handle spaces.
1139
+ # As a workaround, manually expand variables at gyp time. Since 'copies'
1140
+ # can't run scripts, there's no need to write the env then.
1141
+ # WriteDoCmd() will escape spaces for .d files.
1142
+ env = self.GetSortedXcodeEnv()
1143
+ output = gyp.xcode_emulation.ExpandEnvVars(output, env)
1144
+ path = gyp.xcode_emulation.ExpandEnvVars(path, env)
1145
+ self.WriteDoCmd([output], [path], 'copy', part_of_all)
1146
+ outputs.append(output)
1147
+ self.WriteLn('%s = %s' % (variable, ' '.join(map(QuoteSpaces, outputs))))
1148
+ extra_outputs.append('$(%s)' % variable)
1149
+ self.WriteLn()
1150
+
1151
+
1152
+ def WriteMacBundleResources(self, resources, bundle_deps):
1153
+ """Writes Makefile code for 'mac_bundle_resources'."""
1154
+ self.WriteLn('### Generated for mac_bundle_resources')
1155
+
1156
+ for output, res in gyp.xcode_emulation.GetMacBundleResources(
1157
+ generator_default_variables['PRODUCT_DIR'], self.xcode_settings,
1158
+ map(Sourceify, map(self.Absolutify, resources))):
1159
+ _, ext = os.path.splitext(output)
1160
+ if ext != '.xcassets':
1161
+ # Make does not supports '.xcassets' emulation.
1162
+ self.WriteDoCmd([output], [res], 'mac_tool,,,copy-bundle-resource',
1163
+ part_of_all=True)
1164
+ bundle_deps.append(output)
1165
+
1166
+
1167
+ def WriteMacInfoPlist(self, bundle_deps):
1168
+ """Write Makefile code for bundle Info.plist files."""
1169
+ info_plist, out, defines, extra_env = gyp.xcode_emulation.GetMacInfoPlist(
1170
+ generator_default_variables['PRODUCT_DIR'], self.xcode_settings,
1171
+ lambda p: Sourceify(self.Absolutify(p)))
1172
+ if not info_plist:
1173
+ return
1174
+ if defines:
1175
+ # Create an intermediate file to store preprocessed results.
1176
+ intermediate_plist = ('$(obj).$(TOOLSET)/$(TARGET)/' +
1177
+ os.path.basename(info_plist))
1178
+ self.WriteList(defines, intermediate_plist + ': INFOPLIST_DEFINES', '-D',
1179
+ quoter=EscapeCppDefine)
1180
+ self.WriteMakeRule([intermediate_plist], [info_plist],
1181
+ ['$(call do_cmd,infoplist)',
1182
+ # "Convert" the plist so that any weird whitespace changes from the
1183
+ # preprocessor do not affect the XML parser in mac_tool.
1184
+ '@plutil -convert xml1 $@ $@'])
1185
+ info_plist = intermediate_plist
1186
+ # plists can contain envvars and substitute them into the file.
1187
+ self.WriteSortedXcodeEnv(
1188
+ out, self.GetSortedXcodeEnv(additional_settings=extra_env))
1189
+ self.WriteDoCmd([out], [info_plist], 'mac_tool,,,copy-info-plist',
1190
+ part_of_all=True)
1191
+ bundle_deps.append(out)
1192
+
1193
+
1194
+ def WriteSources(self, configs, deps, sources,
1195
+ extra_outputs, extra_link_deps,
1196
+ part_of_all, precompiled_header):
1197
+ """Write Makefile code for any 'sources' from the gyp input.
1198
+ These are source files necessary to build the current target.
1199
+
1200
+ configs, deps, sources: input from gyp.
1201
+ extra_outputs: a list of extra outputs this action should be dependent on;
1202
+ used to serialize action/rules before compilation
1203
+ extra_link_deps: a list that will be filled in with any outputs of
1204
+ compilation (to be used in link lines)
1205
+ part_of_all: flag indicating this target is part of 'all'
1206
+ """
1207
+
1208
+ # Write configuration-specific variables for CFLAGS, etc.
1209
+ for configname in sorted(configs.keys()):
1210
+ config = configs[configname]
1211
+ self.WriteList(config.get('defines'), 'DEFS_%s' % configname, prefix='-D',
1212
+ quoter=EscapeCppDefine)
1213
+
1214
+ if self.flavor == 'mac':
1215
+ cflags = self.xcode_settings.GetCflags(configname)
1216
+ cflags_c = self.xcode_settings.GetCflagsC(configname)
1217
+ cflags_cc = self.xcode_settings.GetCflagsCC(configname)
1218
+ cflags_objc = self.xcode_settings.GetCflagsObjC(configname)
1219
+ cflags_objcc = self.xcode_settings.GetCflagsObjCC(configname)
1220
+ else:
1221
+ cflags = config.get('cflags')
1222
+ cflags_c = config.get('cflags_c')
1223
+ cflags_cc = config.get('cflags_cc')
1224
+
1225
+ self.WriteLn("# Flags passed to all source files.");
1226
+ self.WriteList(cflags, 'CFLAGS_%s' % configname)
1227
+ self.WriteLn("# Flags passed to only C files.");
1228
+ self.WriteList(cflags_c, 'CFLAGS_C_%s' % configname)
1229
+ self.WriteLn("# Flags passed to only C++ files.");
1230
+ self.WriteList(cflags_cc, 'CFLAGS_CC_%s' % configname)
1231
+ if self.flavor == 'mac':
1232
+ self.WriteLn("# Flags passed to only ObjC files.");
1233
+ self.WriteList(cflags_objc, 'CFLAGS_OBJC_%s' % configname)
1234
+ self.WriteLn("# Flags passed to only ObjC++ files.");
1235
+ self.WriteList(cflags_objcc, 'CFLAGS_OBJCC_%s' % configname)
1236
+ includes = config.get('include_dirs')
1237
+ if includes:
1238
+ includes = [Sourceify(self.Absolutify(include)) for include in includes]
1239
+ self.WriteList(includes, 'INCS_%s' % configname, prefix='-I')
1240
+
1241
+ compilable = filter(Compilable, sources)
1242
+ objs = [self.Objectify(self.Absolutify(Target(x))) for x in compilable]
1243
+ self.WriteList(objs, 'OBJS')
1244
+
1245
+ for obj in objs:
1246
+ assert ' ' not in obj, (
1247
+ "Spaces in object filenames not supported (%s)" % obj)
1248
+ self.WriteLn('# Add to the list of files we specially track '
1249
+ 'dependencies for.')
1250
+ self.WriteLn('all_deps += $(OBJS)')
1251
+ self.WriteLn()
1252
+
1253
+ # Make sure our dependencies are built first.
1254
+ if deps:
1255
+ self.WriteMakeRule(['$(OBJS)'], deps,
1256
+ comment = 'Make sure our dependencies are built '
1257
+ 'before any of us.',
1258
+ order_only = True)
1259
+
1260
+ # Make sure the actions and rules run first.
1261
+ # If they generate any extra headers etc., the per-.o file dep tracking
1262
+ # will catch the proper rebuilds, so order only is still ok here.
1263
+ if extra_outputs:
1264
+ self.WriteMakeRule(['$(OBJS)'], extra_outputs,
1265
+ comment = 'Make sure our actions/rules run '
1266
+ 'before any of us.',
1267
+ order_only = True)
1268
+
1269
+ pchdeps = precompiled_header.GetObjDependencies(compilable, objs )
1270
+ if pchdeps:
1271
+ self.WriteLn('# Dependencies from obj files to their precompiled headers')
1272
+ for source, obj, gch in pchdeps:
1273
+ self.WriteLn('%s: %s' % (obj, gch))
1274
+ self.WriteLn('# End precompiled header dependencies')
1275
+
1276
+ if objs:
1277
+ extra_link_deps.append('$(OBJS)')
1278
+ self.WriteLn("""\
1279
+ # CFLAGS et al overrides must be target-local.
1280
+ # See "Target-specific Variable Values" in the GNU Make manual.""")
1281
+ self.WriteLn("$(OBJS): TOOLSET := $(TOOLSET)")
1282
+ self.WriteLn("$(OBJS): GYP_CFLAGS := "
1283
+ "$(DEFS_$(BUILDTYPE)) "
1284
+ "$(INCS_$(BUILDTYPE)) "
1285
+ "%s " % precompiled_header.GetInclude('c') +
1286
+ "$(CFLAGS_$(BUILDTYPE)) "
1287
+ "$(CFLAGS_C_$(BUILDTYPE))")
1288
+ self.WriteLn("$(OBJS): GYP_CXXFLAGS := "
1289
+ "$(DEFS_$(BUILDTYPE)) "
1290
+ "$(INCS_$(BUILDTYPE)) "
1291
+ "%s " % precompiled_header.GetInclude('cc') +
1292
+ "$(CFLAGS_$(BUILDTYPE)) "
1293
+ "$(CFLAGS_CC_$(BUILDTYPE))")
1294
+ if self.flavor == 'mac':
1295
+ self.WriteLn("$(OBJS): GYP_OBJCFLAGS := "
1296
+ "$(DEFS_$(BUILDTYPE)) "
1297
+ "$(INCS_$(BUILDTYPE)) "
1298
+ "%s " % precompiled_header.GetInclude('m') +
1299
+ "$(CFLAGS_$(BUILDTYPE)) "
1300
+ "$(CFLAGS_C_$(BUILDTYPE)) "
1301
+ "$(CFLAGS_OBJC_$(BUILDTYPE))")
1302
+ self.WriteLn("$(OBJS): GYP_OBJCXXFLAGS := "
1303
+ "$(DEFS_$(BUILDTYPE)) "
1304
+ "$(INCS_$(BUILDTYPE)) "
1305
+ "%s " % precompiled_header.GetInclude('mm') +
1306
+ "$(CFLAGS_$(BUILDTYPE)) "
1307
+ "$(CFLAGS_CC_$(BUILDTYPE)) "
1308
+ "$(CFLAGS_OBJCC_$(BUILDTYPE))")
1309
+
1310
+ self.WritePchTargets(precompiled_header.GetPchBuildCommands())
1311
+
1312
+ # If there are any object files in our input file list, link them into our
1313
+ # output.
1314
+ extra_link_deps += [source for source in sources if Linkable(source)]
1315
+
1316
+ self.WriteLn()
1317
+
1318
+ def WritePchTargets(self, pch_commands):
1319
+ """Writes make rules to compile prefix headers."""
1320
+ if not pch_commands:
1321
+ return
1322
+
1323
+ for gch, lang_flag, lang, input in pch_commands:
1324
+ extra_flags = {
1325
+ 'c': '$(CFLAGS_C_$(BUILDTYPE))',
1326
+ 'cc': '$(CFLAGS_CC_$(BUILDTYPE))',
1327
+ 'm': '$(CFLAGS_C_$(BUILDTYPE)) $(CFLAGS_OBJC_$(BUILDTYPE))',
1328
+ 'mm': '$(CFLAGS_CC_$(BUILDTYPE)) $(CFLAGS_OBJCC_$(BUILDTYPE))',
1329
+ }[lang]
1330
+ var_name = {
1331
+ 'c': 'GYP_PCH_CFLAGS',
1332
+ 'cc': 'GYP_PCH_CXXFLAGS',
1333
+ 'm': 'GYP_PCH_OBJCFLAGS',
1334
+ 'mm': 'GYP_PCH_OBJCXXFLAGS',
1335
+ }[lang]
1336
+ self.WriteLn("%s: %s := %s " % (gch, var_name, lang_flag) +
1337
+ "$(DEFS_$(BUILDTYPE)) "
1338
+ "$(INCS_$(BUILDTYPE)) "
1339
+ "$(CFLAGS_$(BUILDTYPE)) " +
1340
+ extra_flags)
1341
+
1342
+ self.WriteLn('%s: %s FORCE_DO_CMD' % (gch, input))
1343
+ self.WriteLn('\t@$(call do_cmd,pch_%s,1)' % lang)
1344
+ self.WriteLn('')
1345
+ assert ' ' not in gch, (
1346
+ "Spaces in gch filenames not supported (%s)" % gch)
1347
+ self.WriteLn('all_deps += %s' % gch)
1348
+ self.WriteLn('')
1349
+
1350
+
1351
+ def ComputeOutputBasename(self, spec):
1352
+ """Return the 'output basename' of a gyp spec.
1353
+
1354
+ E.g., the loadable module 'foobar' in directory 'baz' will produce
1355
+ 'libfoobar.so'
1356
+ """
1357
+ assert not self.is_mac_bundle
1358
+
1359
+ if self.flavor == 'mac' and self.type in (
1360
+ 'static_library', 'executable', 'shared_library', 'loadable_module'):
1361
+ return self.xcode_settings.GetExecutablePath()
1362
+
1363
+ target = spec['target_name']
1364
+ target_prefix = ''
1365
+ target_ext = ''
1366
+ if self.type == 'static_library':
1367
+ if target[:3] == 'lib':
1368
+ target = target[3:]
1369
+ target_prefix = 'lib'
1370
+ target_ext = '.a'
1371
+ elif self.type in ('loadable_module', 'shared_library'):
1372
+ if target[:3] == 'lib':
1373
+ target = target[3:]
1374
+ target_prefix = 'lib'
1375
+ if self.flavor == 'aix':
1376
+ target_ext = '.a'
1377
+ else:
1378
+ target_ext = '.so'
1379
+ elif self.type == 'none':
1380
+ target = '%s.stamp' % target
1381
+ elif self.type != 'executable':
1382
+ print(("ERROR: What output file should be generated?",
1383
+ "type", self.type, "target", target))
1384
+
1385
+ target_prefix = spec.get('product_prefix', target_prefix)
1386
+ target = spec.get('product_name', target)
1387
+ product_ext = spec.get('product_extension')
1388
+ if product_ext:
1389
+ target_ext = '.' + product_ext
1390
+
1391
+ return target_prefix + target + target_ext
1392
+
1393
+
1394
+ def _InstallImmediately(self):
1395
+ return self.toolset == 'target' and self.flavor == 'mac' and self.type in (
1396
+ 'static_library', 'executable', 'shared_library', 'loadable_module')
1397
+
1398
+
1399
+ def ComputeOutput(self, spec):
1400
+ """Return the 'output' (full output path) of a gyp spec.
1401
+
1402
+ E.g., the loadable module 'foobar' in directory 'baz' will produce
1403
+ '$(obj)/baz/libfoobar.so'
1404
+ """
1405
+ assert not self.is_mac_bundle
1406
+
1407
+ path = os.path.join('$(obj).' + self.toolset, self.path)
1408
+ if self.type == 'executable' or self._InstallImmediately():
1409
+ path = '$(builddir)'
1410
+ path = spec.get('product_dir', path)
1411
+ return os.path.join(path, self.ComputeOutputBasename(spec))
1412
+
1413
+
1414
+ def ComputeMacBundleOutput(self, spec):
1415
+ """Return the 'output' (full output path) to a bundle output directory."""
1416
+ assert self.is_mac_bundle
1417
+ path = generator_default_variables['PRODUCT_DIR']
1418
+ return os.path.join(path, self.xcode_settings.GetWrapperName())
1419
+
1420
+
1421
+ def ComputeMacBundleBinaryOutput(self, spec):
1422
+ """Return the 'output' (full output path) to the binary in a bundle."""
1423
+ path = generator_default_variables['PRODUCT_DIR']
1424
+ return os.path.join(path, self.xcode_settings.GetExecutablePath())
1425
+
1426
+
1427
+ def ComputeDeps(self, spec):
1428
+ """Compute the dependencies of a gyp spec.
1429
+
1430
+ Returns a tuple (deps, link_deps), where each is a list of
1431
+ filenames that will need to be put in front of make for either
1432
+ building (deps) or linking (link_deps).
1433
+ """
1434
+ deps = []
1435
+ link_deps = []
1436
+ if 'dependencies' in spec:
1437
+ deps.extend([target_outputs[dep] for dep in spec['dependencies']
1438
+ if target_outputs[dep]])
1439
+ for dep in spec['dependencies']:
1440
+ if dep in target_link_deps:
1441
+ link_deps.append(target_link_deps[dep])
1442
+ deps.extend(link_deps)
1443
+ # TODO: It seems we need to transitively link in libraries (e.g. -lfoo)?
1444
+ # This hack makes it work:
1445
+ # link_deps.extend(spec.get('libraries', []))
1446
+ return (gyp.common.uniquer(deps), gyp.common.uniquer(link_deps))
1447
+
1448
+
1449
+ def WriteDependencyOnExtraOutputs(self, target, extra_outputs):
1450
+ self.WriteMakeRule([self.output_binary], extra_outputs,
1451
+ comment = 'Build our special outputs first.',
1452
+ order_only = True)
1453
+
1454
+
1455
+ def WriteTarget(self, spec, configs, deps, link_deps, bundle_deps,
1456
+ extra_outputs, part_of_all):
1457
+ """Write Makefile code to produce the final target of the gyp spec.
1458
+
1459
+ spec, configs: input from gyp.
1460
+ deps, link_deps: dependency lists; see ComputeDeps()
1461
+ extra_outputs: any extra outputs that our target should depend on
1462
+ part_of_all: flag indicating this target is part of 'all'
1463
+ """
1464
+
1465
+ self.WriteLn('### Rules for final target.')
1466
+
1467
+ if extra_outputs:
1468
+ self.WriteDependencyOnExtraOutputs(self.output_binary, extra_outputs)
1469
+ self.WriteMakeRule(extra_outputs, deps,
1470
+ comment=('Preserve order dependency of '
1471
+ 'special output on deps.'),
1472
+ order_only = True)
1473
+
1474
+ target_postbuilds = {}
1475
+ if self.type != 'none':
1476
+ for configname in sorted(configs.keys()):
1477
+ config = configs[configname]
1478
+ if self.flavor == 'mac':
1479
+ ldflags = self.xcode_settings.GetLdflags(configname,
1480
+ generator_default_variables['PRODUCT_DIR'],
1481
+ lambda p: Sourceify(self.Absolutify(p)))
1482
+
1483
+ # TARGET_POSTBUILDS_$(BUILDTYPE) is added to postbuilds later on.
1484
+ gyp_to_build = gyp.common.InvertRelativePath(self.path)
1485
+ target_postbuild = self.xcode_settings.AddImplicitPostbuilds(
1486
+ configname,
1487
+ QuoteSpaces(os.path.normpath(os.path.join(gyp_to_build,
1488
+ self.output))),
1489
+ QuoteSpaces(os.path.normpath(os.path.join(gyp_to_build,
1490
+ self.output_binary))))
1491
+ if target_postbuild:
1492
+ target_postbuilds[configname] = target_postbuild
1493
+ else:
1494
+ ldflags = config.get('ldflags', [])
1495
+ # Compute an rpath for this output if needed.
1496
+ if any(dep.endswith('.so') or '.so.' in dep for dep in deps):
1497
+ # We want to get the literal string "$ORIGIN" into the link command,
1498
+ # so we need lots of escaping.
1499
+ ldflags.append(r'-Wl,-rpath=\$$ORIGIN/lib.%s/' % self.toolset)
1500
+ ldflags.append(r'-Wl,-rpath-link=\$(builddir)/lib.%s/' %
1501
+ self.toolset)
1502
+ library_dirs = config.get('library_dirs', [])
1503
+ ldflags += [('-L%s' % library_dir) for library_dir in library_dirs]
1504
+ self.WriteList(ldflags, 'LDFLAGS_%s' % configname)
1505
+ if self.flavor == 'mac':
1506
+ self.WriteList(self.xcode_settings.GetLibtoolflags(configname),
1507
+ 'LIBTOOLFLAGS_%s' % configname)
1508
+ libraries = spec.get('libraries')
1509
+ if libraries:
1510
+ # Remove duplicate entries
1511
+ libraries = gyp.common.uniquer(libraries)
1512
+ if self.flavor == 'mac':
1513
+ libraries = self.xcode_settings.AdjustLibraries(libraries)
1514
+ self.WriteList(libraries, 'LIBS')
1515
+ self.WriteLn('%s: GYP_LDFLAGS := $(LDFLAGS_$(BUILDTYPE))' %
1516
+ QuoteSpaces(self.output_binary))
1517
+ self.WriteLn('%s: LIBS := $(LIBS)' % QuoteSpaces(self.output_binary))
1518
+
1519
+ if self.flavor == 'mac':
1520
+ self.WriteLn('%s: GYP_LIBTOOLFLAGS := $(LIBTOOLFLAGS_$(BUILDTYPE))' %
1521
+ QuoteSpaces(self.output_binary))
1522
+
1523
+ # Postbuild actions. Like actions, but implicitly depend on the target's
1524
+ # output.
1525
+ postbuilds = []
1526
+ if self.flavor == 'mac':
1527
+ if target_postbuilds:
1528
+ postbuilds.append('$(TARGET_POSTBUILDS_$(BUILDTYPE))')
1529
+ postbuilds.extend(
1530
+ gyp.xcode_emulation.GetSpecPostbuildCommands(spec))
1531
+
1532
+ if postbuilds:
1533
+ # Envvars may be referenced by TARGET_POSTBUILDS_$(BUILDTYPE),
1534
+ # so we must output its definition first, since we declare variables
1535
+ # using ":=".
1536
+ self.WriteSortedXcodeEnv(self.output, self.GetSortedXcodePostbuildEnv())
1537
+
1538
+ for configname in target_postbuilds:
1539
+ self.WriteLn('%s: TARGET_POSTBUILDS_%s := %s' %
1540
+ (QuoteSpaces(self.output),
1541
+ configname,
1542
+ gyp.common.EncodePOSIXShellList(target_postbuilds[configname])))
1543
+
1544
+ # Postbuilds expect to be run in the gyp file's directory, so insert an
1545
+ # implicit postbuild to cd to there.
1546
+ postbuilds.insert(0, gyp.common.EncodePOSIXShellList(['cd', self.path]))
1547
+ for i, postbuild in enumerate(postbuilds):
1548
+ if not postbuild.startswith('$'):
1549
+ postbuilds[i] = EscapeShellArgument(postbuild)
1550
+ self.WriteLn('%s: builddir := $(abs_builddir)' % QuoteSpaces(self.output))
1551
+ self.WriteLn('%s: POSTBUILDS := %s' % (
1552
+ QuoteSpaces(self.output), ' '.join(postbuilds)))
1553
+
1554
+ # A bundle directory depends on its dependencies such as bundle resources
1555
+ # and bundle binary. When all dependencies have been built, the bundle
1556
+ # needs to be packaged.
1557
+ if self.is_mac_bundle:
1558
+ # If the framework doesn't contain a binary, then nothing depends
1559
+ # on the actions -- make the framework depend on them directly too.
1560
+ self.WriteDependencyOnExtraOutputs(self.output, extra_outputs)
1561
+
1562
+ # Bundle dependencies. Note that the code below adds actions to this
1563
+ # target, so if you move these two lines, move the lines below as well.
1564
+ self.WriteList(map(QuoteSpaces, bundle_deps), 'BUNDLE_DEPS')
1565
+ self.WriteLn('%s: $(BUNDLE_DEPS)' % QuoteSpaces(self.output))
1566
+
1567
+ # After the framework is built, package it. Needs to happen before
1568
+ # postbuilds, since postbuilds depend on this.
1569
+ if self.type in ('shared_library', 'loadable_module'):
1570
+ self.WriteLn('\t@$(call do_cmd,mac_package_framework,,,%s)' %
1571
+ self.xcode_settings.GetFrameworkVersion())
1572
+
1573
+ # Bundle postbuilds can depend on the whole bundle, so run them after
1574
+ # the bundle is packaged, not already after the bundle binary is done.
1575
+ if postbuilds:
1576
+ self.WriteLn('\t@$(call do_postbuilds)')
1577
+ postbuilds = [] # Don't write postbuilds for target's output.
1578
+
1579
+ # Needed by test/mac/gyptest-rebuild.py.
1580
+ self.WriteLn('\t@true # No-op, used by tests')
1581
+
1582
+ # Since this target depends on binary and resources which are in
1583
+ # nested subfolders, the framework directory will be older than
1584
+ # its dependencies usually. To prevent this rule from executing
1585
+ # on every build (expensive, especially with postbuilds), expliclity
1586
+ # update the time on the framework directory.
1587
+ self.WriteLn('\t@touch -c %s' % QuoteSpaces(self.output))
1588
+
1589
+ if postbuilds:
1590
+ assert not self.is_mac_bundle, ('Postbuilds for bundles should be done '
1591
+ 'on the bundle, not the binary (target \'%s\')' % self.target)
1592
+ assert 'product_dir' not in spec, ('Postbuilds do not work with '
1593
+ 'custom product_dir')
1594
+
1595
+ if self.type == 'executable':
1596
+ self.WriteLn('%s: LD_INPUTS := %s' % (
1597
+ QuoteSpaces(self.output_binary),
1598
+ ' '.join(map(QuoteSpaces, link_deps))))
1599
+ if self.toolset == 'host' and self.flavor == 'android':
1600
+ self.WriteDoCmd([self.output_binary], link_deps, 'link_host',
1601
+ part_of_all, postbuilds=postbuilds)
1602
+ else:
1603
+ self.WriteDoCmd([self.output_binary], link_deps, 'link', part_of_all,
1604
+ postbuilds=postbuilds)
1605
+
1606
+ elif self.type == 'static_library':
1607
+ for link_dep in link_deps:
1608
+ assert ' ' not in link_dep, (
1609
+ "Spaces in alink input filenames not supported (%s)" % link_dep)
1610
+ if (self.flavor not in ('mac', 'openbsd', 'netbsd', 'win') and not
1611
+ self.is_standalone_static_library):
1612
+ self.WriteDoCmd([self.output_binary], link_deps, 'alink_thin',
1613
+ part_of_all, postbuilds=postbuilds)
1614
+ else:
1615
+ self.WriteDoCmd([self.output_binary], link_deps, 'alink', part_of_all,
1616
+ postbuilds=postbuilds)
1617
+ elif self.type == 'shared_library':
1618
+ self.WriteLn('%s: LD_INPUTS := %s' % (
1619
+ QuoteSpaces(self.output_binary),
1620
+ ' '.join(map(QuoteSpaces, link_deps))))
1621
+ self.WriteDoCmd([self.output_binary], link_deps, 'solink', part_of_all,
1622
+ postbuilds=postbuilds)
1623
+ elif self.type == 'loadable_module':
1624
+ for link_dep in link_deps:
1625
+ assert ' ' not in link_dep, (
1626
+ "Spaces in module input filenames not supported (%s)" % link_dep)
1627
+ if self.toolset == 'host' and self.flavor == 'android':
1628
+ self.WriteDoCmd([self.output_binary], link_deps, 'solink_module_host',
1629
+ part_of_all, postbuilds=postbuilds)
1630
+ else:
1631
+ self.WriteDoCmd(
1632
+ [self.output_binary], link_deps, 'solink_module', part_of_all,
1633
+ postbuilds=postbuilds)
1634
+ elif self.type == 'none':
1635
+ # Write a stamp line.
1636
+ self.WriteDoCmd([self.output_binary], deps, 'touch', part_of_all,
1637
+ postbuilds=postbuilds)
1638
+ else:
1639
+ print("WARNING: no output for", self.type, self.target)
1640
+
1641
+ # Add an alias for each target (if there are any outputs).
1642
+ # Installable target aliases are created below.
1643
+ if ((self.output and self.output != self.target) and
1644
+ (self.type not in self._INSTALLABLE_TARGETS)):
1645
+ self.WriteMakeRule([self.target], [self.output],
1646
+ comment='Add target alias', phony = True)
1647
+ if part_of_all:
1648
+ self.WriteMakeRule(['all'], [self.target],
1649
+ comment = 'Add target alias to "all" target.',
1650
+ phony = True)
1651
+
1652
+ # Add special-case rules for our installable targets.
1653
+ # 1) They need to install to the build dir or "product" dir.
1654
+ # 2) They get shortcuts for building (e.g. "make chrome").
1655
+ # 3) They are part of "make all".
1656
+ if (self.type in self._INSTALLABLE_TARGETS or
1657
+ self.is_standalone_static_library):
1658
+ if self.type == 'shared_library':
1659
+ file_desc = 'shared library'
1660
+ elif self.type == 'static_library':
1661
+ file_desc = 'static library'
1662
+ else:
1663
+ file_desc = 'executable'
1664
+ install_path = self._InstallableTargetInstallPath()
1665
+ installable_deps = [self.output]
1666
+ if (self.flavor == 'mac' and not 'product_dir' in spec and
1667
+ self.toolset == 'target'):
1668
+ # On mac, products are created in install_path immediately.
1669
+ assert install_path == self.output, '%s != %s' % (
1670
+ install_path, self.output)
1671
+
1672
+ # Point the target alias to the final binary output.
1673
+ self.WriteMakeRule([self.target], [install_path],
1674
+ comment='Add target alias', phony = True)
1675
+ if install_path != self.output:
1676
+ assert not self.is_mac_bundle # See comment a few lines above.
1677
+ self.WriteDoCmd([install_path], [self.output], 'copy',
1678
+ comment = 'Copy this to the %s output path.' %
1679
+ file_desc, part_of_all=part_of_all)
1680
+ installable_deps.append(install_path)
1681
+ if self.output != self.alias and self.alias != self.target:
1682
+ self.WriteMakeRule([self.alias], installable_deps,
1683
+ comment = 'Short alias for building this %s.' %
1684
+ file_desc, phony = True)
1685
+ if part_of_all:
1686
+ self.WriteMakeRule(['all'], [install_path],
1687
+ comment = 'Add %s to "all" target.' % file_desc,
1688
+ phony = True)
1689
+
1690
+
1691
+ def WriteList(self, value_list, variable=None, prefix='',
1692
+ quoter=QuoteIfNecessary):
1693
+ """Write a variable definition that is a list of values.
1694
+
1695
+ E.g. WriteList(['a','b'], 'foo', prefix='blah') writes out
1696
+ foo = blaha blahb
1697
+ but in a pretty-printed style.
1698
+ """
1699
+ values = ''
1700
+ if value_list:
1701
+ value_list = [quoter(prefix + l) for l in value_list]
1702
+ values = ' \\\n\t' + ' \\\n\t'.join(value_list)
1703
+ self.fp.write('%s :=%s\n\n' % (variable, values))
1704
+
1705
+
1706
+ def WriteDoCmd(self, outputs, inputs, command, part_of_all, comment=None,
1707
+ postbuilds=False):
1708
+ """Write a Makefile rule that uses do_cmd.
1709
+
1710
+ This makes the outputs dependent on the command line that was run,
1711
+ as well as support the V= make command line flag.
1712
+ """
1713
+ suffix = ''
1714
+ if postbuilds:
1715
+ assert ',' not in command
1716
+ suffix = ',,1' # Tell do_cmd to honor $POSTBUILDS
1717
+ self.WriteMakeRule(outputs, inputs,
1718
+ actions = ['$(call do_cmd,%s%s)' % (command, suffix)],
1719
+ comment = comment,
1720
+ command = command,
1721
+ force = True)
1722
+ # Add our outputs to the list of targets we read depfiles from.
1723
+ # all_deps is only used for deps file reading, and for deps files we replace
1724
+ # spaces with ? because escaping doesn't work with make's $(sort) and
1725
+ # other functions.
1726
+ outputs = [QuoteSpaces(o, SPACE_REPLACEMENT) for o in outputs]
1727
+ self.WriteLn('all_deps += %s' % ' '.join(outputs))
1728
+
1729
+
1730
+ def WriteMakeRule(self, outputs, inputs, actions=None, comment=None,
1731
+ order_only=False, force=False, phony=False, command=None):
1732
+ """Write a Makefile rule, with some extra tricks.
1733
+
1734
+ outputs: a list of outputs for the rule (note: this is not directly
1735
+ supported by make; see comments below)
1736
+ inputs: a list of inputs for the rule
1737
+ actions: a list of shell commands to run for the rule
1738
+ comment: a comment to put in the Makefile above the rule (also useful
1739
+ for making this Python script's code self-documenting)
1740
+ order_only: if true, makes the dependency order-only
1741
+ force: if true, include FORCE_DO_CMD as an order-only dep
1742
+ phony: if true, the rule does not actually generate the named output, the
1743
+ output is just a name to run the rule
1744
+ command: (optional) command name to generate unambiguous labels
1745
+ """
1746
+ outputs = [QuoteSpaces(o) for o in outputs]
1747
+ inputs = map(QuoteSpaces, inputs)
1748
+
1749
+ if comment:
1750
+ self.WriteLn('# ' + comment)
1751
+ if phony:
1752
+ self.WriteLn('.PHONY: ' + ' '.join(outputs))
1753
+ if actions:
1754
+ self.WriteLn("%s: TOOLSET := $(TOOLSET)" % outputs[0])
1755
+ force_append = ' FORCE_DO_CMD' if force else ''
1756
+
1757
+ if order_only:
1758
+ # Order only rule: Just write a simple rule.
1759
+ # TODO(evanm): just make order_only a list of deps instead of this hack.
1760
+ self.WriteLn('%s: | %s%s' %
1761
+ (' '.join(outputs), ' '.join(inputs), force_append))
1762
+ elif len(outputs) == 1:
1763
+ # Regular rule, one output: Just write a simple rule.
1764
+ self.WriteLn('%s: %s%s' % (outputs[0], ' '.join(inputs), force_append))
1765
+ else:
1766
+ # Regular rule, more than one output: Multiple outputs are tricky in
1767
+ # make. We will write three rules:
1768
+ # - All outputs depend on an intermediate file.
1769
+ # - Make .INTERMEDIATE depend on the intermediate.
1770
+ # - The intermediate file depends on the inputs and executes the
1771
+ # actual command.
1772
+ # - The intermediate recipe will 'touch' the intermediate file.
1773
+ # - The multi-output rule will have an do-nothing recipe.
1774
+
1775
+ # Hash the target name to avoid generating overlong filenames.
1776
+ cmdstring = (command if command else self.target).encode('utf-8')
1777
+ cmddigest = hashlib.sha1(cmdstring).hexdigest()
1778
+ intermediate = "%s.intermediate" % (cmddigest)
1779
+ self.WriteLn('%s: %s' % (' '.join(outputs), intermediate))
1780
+ self.WriteLn('\t%s' % '@:');
1781
+ self.WriteLn('%s: %s' % ('.INTERMEDIATE', intermediate))
1782
+ self.WriteLn('%s: %s%s' %
1783
+ (intermediate, ' '.join(inputs), force_append))
1784
+ actions.insert(0, '$(call do_cmd,touch)')
1785
+
1786
+ if actions:
1787
+ for action in actions:
1788
+ self.WriteLn('\t%s' % action)
1789
+ self.WriteLn()
1790
+
1791
+
1792
+ def WriteAndroidNdkModuleRule(self, module_name, all_sources, link_deps):
1793
+ """Write a set of LOCAL_XXX definitions for Android NDK.
1794
+
1795
+ These variable definitions will be used by Android NDK but do nothing for
1796
+ non-Android applications.
1797
+
1798
+ Arguments:
1799
+ module_name: Android NDK module name, which must be unique among all
1800
+ module names.
1801
+ all_sources: A list of source files (will be filtered by Compilable).
1802
+ link_deps: A list of link dependencies, which must be sorted in
1803
+ the order from dependencies to dependents.
1804
+ """
1805
+ if self.type not in ('executable', 'shared_library', 'static_library'):
1806
+ return
1807
+
1808
+ self.WriteLn('# Variable definitions for Android applications')
1809
+ self.WriteLn('include $(CLEAR_VARS)')
1810
+ self.WriteLn('LOCAL_MODULE := ' + module_name)
1811
+ self.WriteLn('LOCAL_CFLAGS := $(CFLAGS_$(BUILDTYPE)) '
1812
+ '$(DEFS_$(BUILDTYPE)) '
1813
+ # LOCAL_CFLAGS is applied to both of C and C++. There is
1814
+ # no way to specify $(CFLAGS_C_$(BUILDTYPE)) only for C
1815
+ # sources.
1816
+ '$(CFLAGS_C_$(BUILDTYPE)) '
1817
+ # $(INCS_$(BUILDTYPE)) includes the prefix '-I' while
1818
+ # LOCAL_C_INCLUDES does not expect it. So put it in
1819
+ # LOCAL_CFLAGS.
1820
+ '$(INCS_$(BUILDTYPE))')
1821
+ # LOCAL_CXXFLAGS is obsolete and LOCAL_CPPFLAGS is preferred.
1822
+ self.WriteLn('LOCAL_CPPFLAGS := $(CFLAGS_CC_$(BUILDTYPE))')
1823
+ self.WriteLn('LOCAL_C_INCLUDES :=')
1824
+ self.WriteLn('LOCAL_LDLIBS := $(LDFLAGS_$(BUILDTYPE)) $(LIBS)')
1825
+
1826
+ # Detect the C++ extension.
1827
+ cpp_ext = {'.cc': 0, '.cpp': 0, '.cxx': 0}
1828
+ default_cpp_ext = '.cpp'
1829
+ for filename in all_sources:
1830
+ ext = os.path.splitext(filename)[1]
1831
+ if ext in cpp_ext:
1832
+ cpp_ext[ext] += 1
1833
+ if cpp_ext[ext] > cpp_ext[default_cpp_ext]:
1834
+ default_cpp_ext = ext
1835
+ self.WriteLn('LOCAL_CPP_EXTENSION := ' + default_cpp_ext)
1836
+
1837
+ self.WriteList(map(self.Absolutify, filter(Compilable, all_sources)),
1838
+ 'LOCAL_SRC_FILES')
1839
+
1840
+ # Filter out those which do not match prefix and suffix and produce
1841
+ # the resulting list without prefix and suffix.
1842
+ def DepsToModules(deps, prefix, suffix):
1843
+ modules = []
1844
+ for filepath in deps:
1845
+ filename = os.path.basename(filepath)
1846
+ if filename.startswith(prefix) and filename.endswith(suffix):
1847
+ modules.append(filename[len(prefix):-len(suffix)])
1848
+ return modules
1849
+
1850
+ # Retrieve the default value of 'SHARED_LIB_SUFFIX'
1851
+ params = {'flavor': 'linux'}
1852
+ default_variables = {}
1853
+ CalculateVariables(default_variables, params)
1854
+
1855
+ self.WriteList(
1856
+ DepsToModules(link_deps,
1857
+ generator_default_variables['SHARED_LIB_PREFIX'],
1858
+ default_variables['SHARED_LIB_SUFFIX']),
1859
+ 'LOCAL_SHARED_LIBRARIES')
1860
+ self.WriteList(
1861
+ DepsToModules(link_deps,
1862
+ generator_default_variables['STATIC_LIB_PREFIX'],
1863
+ generator_default_variables['STATIC_LIB_SUFFIX']),
1864
+ 'LOCAL_STATIC_LIBRARIES')
1865
+
1866
+ if self.type == 'executable':
1867
+ self.WriteLn('include $(BUILD_EXECUTABLE)')
1868
+ elif self.type == 'shared_library':
1869
+ self.WriteLn('include $(BUILD_SHARED_LIBRARY)')
1870
+ elif self.type == 'static_library':
1871
+ self.WriteLn('include $(BUILD_STATIC_LIBRARY)')
1872
+ self.WriteLn()
1873
+
1874
+
1875
+ def WriteLn(self, text=''):
1876
+ self.fp.write(text + '\n')
1877
+
1878
+
1879
+ def GetSortedXcodeEnv(self, additional_settings=None):
1880
+ return gyp.xcode_emulation.GetSortedXcodeEnv(
1881
+ self.xcode_settings, "$(abs_builddir)",
1882
+ os.path.join("$(abs_srcdir)", self.path), "$(BUILDTYPE)",
1883
+ additional_settings)
1884
+
1885
+
1886
+ def GetSortedXcodePostbuildEnv(self):
1887
+ # CHROMIUM_STRIP_SAVE_FILE is a chromium-specific hack.
1888
+ # TODO(thakis): It would be nice to have some general mechanism instead.
1889
+ strip_save_file = self.xcode_settings.GetPerTargetSetting(
1890
+ 'CHROMIUM_STRIP_SAVE_FILE', '')
1891
+ # Even if strip_save_file is empty, explicitly write it. Else a postbuild
1892
+ # might pick up an export from an earlier target.
1893
+ return self.GetSortedXcodeEnv(
1894
+ additional_settings={'CHROMIUM_STRIP_SAVE_FILE': strip_save_file})
1895
+
1896
+
1897
+ def WriteSortedXcodeEnv(self, target, env):
1898
+ for k, v in env:
1899
+ # For
1900
+ # foo := a\ b
1901
+ # the escaped space does the right thing. For
1902
+ # export foo := a\ b
1903
+ # it does not -- the backslash is written to the env as literal character.
1904
+ # So don't escape spaces in |env[k]|.
1905
+ self.WriteLn('%s: export %s := %s' % (QuoteSpaces(target), k, v))
1906
+
1907
+
1908
+ def Objectify(self, path):
1909
+ """Convert a path to its output directory form."""
1910
+ if '$(' in path:
1911
+ path = path.replace('$(obj)/', '$(obj).%s/$(TARGET)/' % self.toolset)
1912
+ if not '$(obj)' in path:
1913
+ path = '$(obj).%s/$(TARGET)/%s' % (self.toolset, path)
1914
+ return path
1915
+
1916
+
1917
+ def Pchify(self, path, lang):
1918
+ """Convert a prefix header path to its output directory form."""
1919
+ path = self.Absolutify(path)
1920
+ if '$(' in path:
1921
+ path = path.replace('$(obj)/', '$(obj).%s/$(TARGET)/pch-%s' %
1922
+ (self.toolset, lang))
1923
+ return path
1924
+ return '$(obj).%s/$(TARGET)/pch-%s/%s' % (self.toolset, lang, path)
1925
+
1926
+
1927
+ def Absolutify(self, path):
1928
+ """Convert a subdirectory-relative path into a base-relative path.
1929
+ Skips over paths that contain variables."""
1930
+ if '$(' in path:
1931
+ # Don't call normpath in this case, as it might collapse the
1932
+ # path too aggressively if it features '..'. However it's still
1933
+ # important to strip trailing slashes.
1934
+ return path.rstrip('/')
1935
+ return os.path.normpath(os.path.join(self.path, path))
1936
+
1937
+
1938
+ def ExpandInputRoot(self, template, expansion, dirname):
1939
+ if '%(INPUT_ROOT)s' not in template and '%(INPUT_DIRNAME)s' not in template:
1940
+ return template
1941
+ path = template % {
1942
+ 'INPUT_ROOT': expansion,
1943
+ 'INPUT_DIRNAME': dirname,
1944
+ }
1945
+ return path
1946
+
1947
+
1948
+ def _InstallableTargetInstallPath(self):
1949
+ """Returns the location of the final output for an installable target."""
1950
+ # Xcode puts shared_library results into PRODUCT_DIR, and some gyp files
1951
+ # rely on this. Emulate this behavior for mac.
1952
+ if (self.type == 'shared_library' and
1953
+ (self.flavor != 'mac' or self.toolset != 'target')):
1954
+ # Install all shared libs into a common directory (per toolset) for
1955
+ # convenient access with LD_LIBRARY_PATH.
1956
+ return '$(builddir)/lib.%s/%s' % (self.toolset, self.alias)
1957
+ return '$(builddir)/' + self.alias
1958
+
1959
+
1960
+ def WriteAutoRegenerationRule(params, root_makefile, makefile_name,
1961
+ build_files):
1962
+ """Write the target to regenerate the Makefile."""
1963
+ options = params['options']
1964
+ build_files_args = [gyp.common.RelativePath(filename, options.toplevel_dir)
1965
+ for filename in params['build_files_arg']]
1966
+
1967
+ gyp_binary = gyp.common.FixIfRelativePath(params['gyp_binary'],
1968
+ options.toplevel_dir)
1969
+ if not gyp_binary.startswith(os.sep):
1970
+ gyp_binary = os.path.join('.', gyp_binary)
1971
+
1972
+ root_makefile.write(
1973
+ "quiet_cmd_regen_makefile = ACTION Regenerating $@\n"
1974
+ "cmd_regen_makefile = cd $(srcdir); %(cmd)s\n"
1975
+ "%(makefile_name)s: %(deps)s\n"
1976
+ "\t$(call do_cmd,regen_makefile)\n\n" % {
1977
+ 'makefile_name': makefile_name,
1978
+ 'deps': ' '.join(map(Sourceify, build_files)),
1979
+ 'cmd': gyp.common.EncodePOSIXShellList(
1980
+ [gyp_binary, '-fmake'] +
1981
+ gyp.RegenerateFlags(options) +
1982
+ build_files_args)})
1983
+
1984
+
1985
+ def PerformBuild(data, configurations, params):
1986
+ options = params['options']
1987
+ for config in configurations:
1988
+ arguments = ['make']
1989
+ if options.toplevel_dir and options.toplevel_dir != '.':
1990
+ arguments += '-C', options.toplevel_dir
1991
+ arguments.append('BUILDTYPE=' + config)
1992
+ print('Building [%s]: %s' % (config, arguments))
1993
+ subprocess.check_call(arguments)
1994
+
1995
+
1996
+ def GenerateOutput(target_list, target_dicts, data, params):
1997
+ options = params['options']
1998
+ flavor = gyp.common.GetFlavor(params)
1999
+ generator_flags = params.get('generator_flags', {})
2000
+ builddir_name = generator_flags.get('output_dir', 'out')
2001
+ android_ndk_version = generator_flags.get('android_ndk_version', None)
2002
+ default_target = generator_flags.get('default_target', 'all')
2003
+
2004
+ def CalculateMakefilePath(build_file, base_name):
2005
+ """Determine where to write a Makefile for a given gyp file."""
2006
+ # Paths in gyp files are relative to the .gyp file, but we want
2007
+ # paths relative to the source root for the master makefile. Grab
2008
+ # the path of the .gyp file as the base to relativize against.
2009
+ # E.g. "foo/bar" when we're constructing targets for "foo/bar/baz.gyp".
2010
+ base_path = gyp.common.RelativePath(os.path.dirname(build_file),
2011
+ options.depth)
2012
+ # We write the file in the base_path directory.
2013
+ output_file = os.path.join(options.depth, base_path, base_name)
2014
+ if options.generator_output:
2015
+ output_file = os.path.join(
2016
+ options.depth, options.generator_output, base_path, base_name)
2017
+ base_path = gyp.common.RelativePath(os.path.dirname(build_file),
2018
+ options.toplevel_dir)
2019
+ return base_path, output_file
2020
+
2021
+ # TODO: search for the first non-'Default' target. This can go
2022
+ # away when we add verification that all targets have the
2023
+ # necessary configurations.
2024
+ default_configuration = None
2025
+ toolsets = set([target_dicts[target]['toolset'] for target in target_list])
2026
+ for target in target_list:
2027
+ spec = target_dicts[target]
2028
+ if spec['default_configuration'] != 'Default':
2029
+ default_configuration = spec['default_configuration']
2030
+ break
2031
+ if not default_configuration:
2032
+ default_configuration = 'Default'
2033
+
2034
+ srcdir = '.'
2035
+ makefile_name = 'Makefile' + options.suffix
2036
+ makefile_path = os.path.join(options.toplevel_dir, makefile_name)
2037
+ if options.generator_output:
2038
+ global srcdir_prefix
2039
+ makefile_path = os.path.join(
2040
+ options.toplevel_dir, options.generator_output, makefile_name)
2041
+ srcdir = gyp.common.RelativePath(srcdir, options.generator_output)
2042
+ srcdir_prefix = '$(srcdir)/'
2043
+
2044
+ flock_command= 'flock'
2045
+ copy_archive_arguments = '-af'
2046
+ makedep_arguments = '-MMD'
2047
+ header_params = {
2048
+ 'default_target': default_target,
2049
+ 'builddir': builddir_name,
2050
+ 'default_configuration': default_configuration,
2051
+ 'flock': flock_command,
2052
+ 'flock_index': 1,
2053
+ 'link_commands': LINK_COMMANDS_LINUX,
2054
+ 'extra_commands': '',
2055
+ 'srcdir': srcdir,
2056
+ 'copy_archive_args': copy_archive_arguments,
2057
+ 'makedep_args': makedep_arguments,
2058
+ }
2059
+ if flavor == 'mac':
2060
+ flock_command = './gyp-mac-tool flock'
2061
+ header_params.update({
2062
+ 'flock': flock_command,
2063
+ 'flock_index': 2,
2064
+ 'link_commands': LINK_COMMANDS_MAC,
2065
+ 'extra_commands': SHARED_HEADER_MAC_COMMANDS,
2066
+ })
2067
+ elif flavor == 'android':
2068
+ header_params.update({
2069
+ 'link_commands': LINK_COMMANDS_ANDROID,
2070
+ })
2071
+ elif flavor == 'zos':
2072
+ copy_archive_arguments = '-fPR'
2073
+ makedep_arguments = '-qmakedep=gcc'
2074
+ header_params.update({
2075
+ 'copy_archive_args': copy_archive_arguments,
2076
+ 'makedep_args': makedep_arguments,
2077
+ 'link_commands': LINK_COMMANDS_OS390,
2078
+ })
2079
+ elif flavor == 'solaris':
2080
+ header_params.update({
2081
+ 'flock': './gyp-flock-tool flock',
2082
+ 'flock_index': 2,
2083
+ })
2084
+ elif flavor == 'freebsd':
2085
+ # Note: OpenBSD has sysutils/flock. lockf seems to be FreeBSD specific.
2086
+ header_params.update({
2087
+ 'flock': 'lockf',
2088
+ })
2089
+ elif flavor == 'openbsd':
2090
+ copy_archive_arguments = '-pPRf'
2091
+ header_params.update({
2092
+ 'copy_archive_args': copy_archive_arguments,
2093
+ })
2094
+ elif flavor == 'aix':
2095
+ copy_archive_arguments = '-pPRf'
2096
+ header_params.update({
2097
+ 'copy_archive_args': copy_archive_arguments,
2098
+ 'link_commands': LINK_COMMANDS_AIX,
2099
+ 'flock': './gyp-flock-tool flock',
2100
+ 'flock_index': 2,
2101
+ })
2102
+
2103
+ header_params.update({
2104
+ 'CC.target': GetEnvironFallback(('CC_target', 'CC'), '$(CC)'),
2105
+ 'AR.target': GetEnvironFallback(('AR_target', 'AR'), '$(AR)'),
2106
+ 'CXX.target': GetEnvironFallback(('CXX_target', 'CXX'), '$(CXX)'),
2107
+ 'LINK.target': GetEnvironFallback(('LINK_target', 'LINK'), '$(LINK)'),
2108
+ 'CC.host': GetEnvironFallback(('CC_host',), 'gcc'),
2109
+ 'AR.host': GetEnvironFallback(('AR_host',), 'ar'),
2110
+ 'CXX.host': GetEnvironFallback(('CXX_host',), 'g++'),
2111
+ 'LINK.host': GetEnvironFallback(('LINK_host',), '$(CXX.host)'),
2112
+ })
2113
+
2114
+ build_file, _, _ = gyp.common.ParseQualifiedTarget(target_list[0])
2115
+ make_global_settings_array = data[build_file].get('make_global_settings', [])
2116
+ wrappers = {}
2117
+ for key, value in make_global_settings_array:
2118
+ if key.endswith('_wrapper'):
2119
+ wrappers[key[:-len('_wrapper')]] = '$(abspath %s)' % value
2120
+ make_global_settings = ''
2121
+ for key, value in make_global_settings_array:
2122
+ if re.match('.*_wrapper', key):
2123
+ continue
2124
+ if value[0] != '$':
2125
+ value = '$(abspath %s)' % value
2126
+ wrapper = wrappers.get(key)
2127
+ if wrapper:
2128
+ value = '%s %s' % (wrapper, value)
2129
+ del wrappers[key]
2130
+ if key in ('CC', 'CC.host', 'CXX', 'CXX.host'):
2131
+ make_global_settings += (
2132
+ 'ifneq (,$(filter $(origin %s), undefined default))\n' % key)
2133
+ # Let gyp-time envvars win over global settings.
2134
+ env_key = key.replace('.', '_') # CC.host -> CC_host
2135
+ if env_key in os.environ:
2136
+ value = os.environ[env_key]
2137
+ make_global_settings += ' %s = %s\n' % (key, value)
2138
+ make_global_settings += 'endif\n'
2139
+ else:
2140
+ make_global_settings += '%s ?= %s\n' % (key, value)
2141
+ # TODO(ukai): define cmd when only wrapper is specified in
2142
+ # make_global_settings.
2143
+
2144
+ header_params['make_global_settings'] = make_global_settings
2145
+
2146
+ gyp.common.EnsureDirExists(makefile_path)
2147
+ root_makefile = open(makefile_path, 'w')
2148
+ root_makefile.write(SHARED_HEADER % header_params)
2149
+ # Currently any versions have the same effect, but in future the behavior
2150
+ # could be different.
2151
+ if android_ndk_version:
2152
+ root_makefile.write(
2153
+ '# Define LOCAL_PATH for build of Android applications.\n'
2154
+ 'LOCAL_PATH := $(call my-dir)\n'
2155
+ '\n')
2156
+ for toolset in toolsets:
2157
+ root_makefile.write('TOOLSET := %s\n' % toolset)
2158
+ WriteRootHeaderSuffixRules(root_makefile)
2159
+
2160
+ # Put build-time support tools next to the root Makefile.
2161
+ dest_path = os.path.dirname(makefile_path)
2162
+ gyp.common.CopyTool(flavor, dest_path)
2163
+
2164
+ # Find the list of targets that derive from the gyp file(s) being built.
2165
+ needed_targets = set()
2166
+ for build_file in params['build_files']:
2167
+ for target in gyp.common.AllTargets(target_list, target_dicts, build_file):
2168
+ needed_targets.add(target)
2169
+
2170
+ build_files = set()
2171
+ include_list = set()
2172
+ for qualified_target in target_list:
2173
+ build_file, target, toolset = gyp.common.ParseQualifiedTarget(
2174
+ qualified_target)
2175
+
2176
+ this_make_global_settings = data[build_file].get('make_global_settings', [])
2177
+ assert make_global_settings_array == this_make_global_settings, (
2178
+ "make_global_settings needs to be the same for all targets. %s vs. %s" %
2179
+ (this_make_global_settings, make_global_settings))
2180
+
2181
+ build_files.add(gyp.common.RelativePath(build_file, options.toplevel_dir))
2182
+ included_files = data[build_file]['included_files']
2183
+ for included_file in included_files:
2184
+ # The included_files entries are relative to the dir of the build file
2185
+ # that included them, so we have to undo that and then make them relative
2186
+ # to the root dir.
2187
+ relative_include_file = gyp.common.RelativePath(
2188
+ gyp.common.UnrelativePath(included_file, build_file),
2189
+ options.toplevel_dir)
2190
+ abs_include_file = os.path.abspath(relative_include_file)
2191
+ # If the include file is from the ~/.gyp dir, we should use absolute path
2192
+ # so that relocating the src dir doesn't break the path.
2193
+ if (params['home_dot_gyp'] and
2194
+ abs_include_file.startswith(params['home_dot_gyp'])):
2195
+ build_files.add(abs_include_file)
2196
+ else:
2197
+ build_files.add(relative_include_file)
2198
+
2199
+ base_path, output_file = CalculateMakefilePath(build_file,
2200
+ target + '.' + toolset + options.suffix + '.mk')
2201
+
2202
+ spec = target_dicts[qualified_target]
2203
+ configs = spec['configurations']
2204
+
2205
+ if flavor == 'mac':
2206
+ gyp.xcode_emulation.MergeGlobalXcodeSettingsToSpec(data[build_file], spec)
2207
+
2208
+ writer = MakefileWriter(generator_flags, flavor)
2209
+ writer.Write(qualified_target, base_path, output_file, spec, configs,
2210
+ part_of_all=qualified_target in needed_targets)
2211
+
2212
+ # Our root_makefile lives at the source root. Compute the relative path
2213
+ # from there to the output_file for including.
2214
+ mkfile_rel_path = gyp.common.RelativePath(output_file,
2215
+ os.path.dirname(makefile_path))
2216
+ include_list.add(mkfile_rel_path)
2217
+
2218
+ # Write out per-gyp (sub-project) Makefiles.
2219
+ depth_rel_path = gyp.common.RelativePath(options.depth, os.getcwd())
2220
+ for build_file in build_files:
2221
+ # The paths in build_files were relativized above, so undo that before
2222
+ # testing against the non-relativized items in target_list and before
2223
+ # calculating the Makefile path.
2224
+ build_file = os.path.join(depth_rel_path, build_file)
2225
+ gyp_targets = [target_dicts[target]['target_name'] for target in target_list
2226
+ if target.startswith(build_file) and
2227
+ target in needed_targets]
2228
+ # Only generate Makefiles for gyp files with targets.
2229
+ if not gyp_targets:
2230
+ continue
2231
+ base_path, output_file = CalculateMakefilePath(build_file,
2232
+ os.path.splitext(os.path.basename(build_file))[0] + '.Makefile')
2233
+ makefile_rel_path = gyp.common.RelativePath(os.path.dirname(makefile_path),
2234
+ os.path.dirname(output_file))
2235
+ writer.WriteSubMake(output_file, makefile_rel_path, gyp_targets,
2236
+ builddir_name)
2237
+
2238
+
2239
+ # Write out the sorted list of includes.
2240
+ root_makefile.write('\n')
2241
+ for include_file in sorted(include_list):
2242
+ # We wrap each .mk include in an if statement so users can tell make to
2243
+ # not load a file by setting NO_LOAD. The below make code says, only
2244
+ # load the .mk file if the .mk filename doesn't start with a token in
2245
+ # NO_LOAD.
2246
+ root_makefile.write(
2247
+ "ifeq ($(strip $(foreach prefix,$(NO_LOAD),\\\n"
2248
+ " $(findstring $(join ^,$(prefix)),\\\n"
2249
+ " $(join ^," + include_file + ")))),)\n")
2250
+ root_makefile.write(" include " + include_file + "\n")
2251
+ root_makefile.write("endif\n")
2252
+ root_makefile.write('\n')
2253
+
2254
+ if (not generator_flags.get('standalone')
2255
+ and generator_flags.get('auto_regeneration', True)):
2256
+ WriteAutoRegenerationRule(params, root_makefile, makefile_name, build_files)
2257
+
2258
+ root_makefile.write(SHARED_FOOTER)
2259
+
2260
+ root_makefile.close()