• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1[
2  {
3    "cmd": [
4      "python",
5      "-u",
6      "\nimport subprocess\nimport sys\n\nwhich = 'where' if sys.platform == 'win32' else 'which'\ngit = subprocess.check_output([which, 'git'])\nprint 'git was found at %s' % git\nif 'cipd_bin_packages' not in git:\n  print >> sys.stderr, 'Git must be obtained through CIPD.'\n  sys.exit(1)\n"
7    ],
8    "env": {
9      "CHROME_HEADLESS": "1",
10      "PATH": "<PATH>:RECIPE_REPO[depot_tools]"
11    },
12    "name": "Assert that Git is from CIPD",
13    "~followup_annotations": [
14      "@@@STEP_LOG_LINE@python.inline@@@@",
15      "@@@STEP_LOG_LINE@python.inline@import subprocess@@@",
16      "@@@STEP_LOG_LINE@python.inline@import sys@@@",
17      "@@@STEP_LOG_LINE@python.inline@@@@",
18      "@@@STEP_LOG_LINE@python.inline@which = 'where' if sys.platform == 'win32' else 'which'@@@",
19      "@@@STEP_LOG_LINE@python.inline@git = subprocess.check_output([which, 'git'])@@@",
20      "@@@STEP_LOG_LINE@python.inline@print 'git was found at %s' % git@@@",
21      "@@@STEP_LOG_LINE@python.inline@if 'cipd_bin_packages' not in git:@@@",
22      "@@@STEP_LOG_LINE@python.inline@  print >> sys.stderr, 'Git must be obtained through CIPD.'@@@",
23      "@@@STEP_LOG_LINE@python.inline@  sys.exit(1)@@@",
24      "@@@STEP_LOG_END@python.inline@@@"
25    ]
26  },
27  {
28    "cmd": [
29      "vpython",
30      "-u",
31      "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py",
32      "--json-output",
33      "/path/to/tmp/json",
34      "ensure-directory",
35      "--mode",
36      "0777",
37      "[START_DIR]/cache/work"
38    ],
39    "infra_step": true,
40    "name": "makedirs checkout_path"
41  },
42  {
43    "cmd": [
44      "vpython",
45      "-u",
46      "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py",
47      "--json-output",
48      "/path/to/tmp/json",
49      "remove",
50      "[START_DIR]/cache/work/.gclient_entries"
51    ],
52    "infra_step": true,
53    "name": "remove [START_DIR]/cache/work/.gclient_entries"
54  },
55  {
56    "cmd": [
57      "python",
58      "-u",
59      "RECIPE_MODULE[depot_tools::bot_update]/resources/bot_update.py",
60      "--spec-path",
61      "cache_dir = '[START_DIR]/cache/git'\nsolutions = [{'custom_vars': {'checkout_chromium': True}, 'deps_file': '.DEPS.git', 'managed': False, 'name': 'skia', 'url': 'https://skia.googlesource.com/skia.git'}]",
62      "--patch_root",
63      "skia",
64      "--revision_mapping_file",
65      "{\"got_revision\": \"skia\"}",
66      "--git-cache-dir",
67      "[START_DIR]/cache/git",
68      "--cleanup-dir",
69      "[CLEANUP]/bot_update",
70      "--output_json",
71      "/path/to/tmp/json",
72      "--revision",
73      "skia@abc123"
74    ],
75    "cwd": "[START_DIR]/cache/work",
76    "env": {
77      "GIT_HTTP_LOW_SPEED_LIMIT": "102400",
78      "GIT_HTTP_LOW_SPEED_TIME": "1800"
79    },
80    "env_suffixes": {
81      "DEPOT_TOOLS_UPDATE": [
82        "0"
83      ],
84      "PATH": [
85        "RECIPE_REPO[depot_tools]"
86      ]
87    },
88    "infra_step": true,
89    "name": "bot_update",
90    "~followup_annotations": [
91      "@@@STEP_TEXT@Some step text@@@",
92      "@@@STEP_LOG_LINE@json.output@{@@@",
93      "@@@STEP_LOG_LINE@json.output@  \"did_run\": true, @@@",
94      "@@@STEP_LOG_LINE@json.output@  \"fixed_revisions\": {@@@",
95      "@@@STEP_LOG_LINE@json.output@    \"skia\": \"abc123\"@@@",
96      "@@@STEP_LOG_LINE@json.output@  }, @@@",
97      "@@@STEP_LOG_LINE@json.output@  \"manifest\": {@@@",
98      "@@@STEP_LOG_LINE@json.output@    \"skia\": {@@@",
99      "@@@STEP_LOG_LINE@json.output@      \"repository\": \"https://fake.org/skia.git\", @@@",
100      "@@@STEP_LOG_LINE@json.output@      \"revision\": \"abc123\"@@@",
101      "@@@STEP_LOG_LINE@json.output@    }@@@",
102      "@@@STEP_LOG_LINE@json.output@  }, @@@",
103      "@@@STEP_LOG_LINE@json.output@  \"patch_failure\": false, @@@",
104      "@@@STEP_LOG_LINE@json.output@  \"patch_root\": \"skia\", @@@",
105      "@@@STEP_LOG_LINE@json.output@  \"properties\": {@@@",
106      "@@@STEP_LOG_LINE@json.output@    \"got_revision\": \"abc123\", @@@",
107      "@@@STEP_LOG_LINE@json.output@    \"got_revision_cp\": \"refs/heads/master@{#164710}\"@@@",
108      "@@@STEP_LOG_LINE@json.output@  }, @@@",
109      "@@@STEP_LOG_LINE@json.output@  \"root\": \"skia\", @@@",
110      "@@@STEP_LOG_LINE@json.output@  \"source_manifest\": {@@@",
111      "@@@STEP_LOG_LINE@json.output@    \"directories\": {@@@",
112      "@@@STEP_LOG_LINE@json.output@      \"skia\": {@@@",
113      "@@@STEP_LOG_LINE@json.output@        \"git_checkout\": {@@@",
114      "@@@STEP_LOG_LINE@json.output@          \"repo_url\": \"https://fake.org/skia.git\", @@@",
115      "@@@STEP_LOG_LINE@json.output@          \"revision\": \"abc123\"@@@",
116      "@@@STEP_LOG_LINE@json.output@        }@@@",
117      "@@@STEP_LOG_LINE@json.output@      }@@@",
118      "@@@STEP_LOG_LINE@json.output@    }, @@@",
119      "@@@STEP_LOG_LINE@json.output@    \"version\": 0@@@",
120      "@@@STEP_LOG_LINE@json.output@  }, @@@",
121      "@@@STEP_LOG_LINE@json.output@  \"step_text\": \"Some step text\"@@@",
122      "@@@STEP_LOG_LINE@json.output@}@@@",
123      "@@@STEP_LOG_END@json.output@@@",
124      "@@@SET_BUILD_PROPERTY@got_revision@\"abc123\"@@@",
125      "@@@SET_BUILD_PROPERTY@got_revision_cp@\"refs/heads/master@{#164710}\"@@@"
126    ]
127  },
128  {
129    "cmd": [
130      "python",
131      "-u",
132      "RECIPE_REPO[depot_tools]/gclient.py",
133      "runhooks"
134    ],
135    "cwd": "[START_DIR]/cache/work",
136    "env": {
137      "DEPOT_TOOLS_UPDATE": "0",
138      "GYP_CHROMIUM_NO_ACTION": "0"
139    },
140    "env_suffixes": {
141      "PATH": [
142        "RECIPE_REPO[depot_tools]"
143      ]
144    },
145    "name": "gclient runhooks"
146  },
147  {
148    "cmd": [
149      "vpython",
150      "-u",
151      "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py",
152      "--json-output",
153      "/path/to/tmp/json",
154      "ensure-directory",
155      "--mode",
156      "0777",
157      "[START_DIR]/tmp"
158    ],
159    "infra_step": true,
160    "name": "makedirs tmp_dir"
161  },
162  {
163    "cmd": [],
164    "name": "ensure xcode",
165    "~followup_annotations": [
166      "@@@STEP_TEXT@Ensuring Xcode version 12c33 in [START_DIR]/cache/Xcode.app@@@"
167    ]
168  },
169  {
170    "cmd": [
171      "[START_DIR]/mac_toolchain/mac_toolchain",
172      "install",
173      "-kind",
174      "ios",
175      "-xcode-version",
176      "12c33",
177      "-output-dir",
178      "[START_DIR]/cache/Xcode.app"
179    ],
180    "name": "ensure xcode.install xcode",
181    "~followup_annotations": [
182      "@@@STEP_NEST_LEVEL@1@@@"
183    ]
184  },
185  {
186    "cmd": [
187      "sudo",
188      "xcode-select",
189      "-switch",
190      "[START_DIR]/cache/Xcode.app"
191    ],
192    "name": "ensure xcode.select xcode",
193    "~followup_annotations": [
194      "@@@STEP_NEST_LEVEL@1@@@"
195    ]
196  },
197  {
198    "cmd": [
199      "python",
200      "-u",
201      "[START_DIR]/cache/work/skia/tools/build_command_buffer.py",
202      "--chrome-dir",
203      "[START_DIR]/cache/work",
204      "--output-dir",
205      "[START_DIR]/cache/work/skia/out/Build-Mac-Clang-x86_64-Debug-CommandBuffer/Debug",
206      "--extra-gn-args",
207      "mac_sdk_min=\"10.13\"",
208      "--no-sync",
209      "--no-hooks",
210      "--make-output-dir"
211    ],
212    "env": {
213      "CHROME_HEADLESS": "1",
214      "PATH": "<PATH>:RECIPE_REPO[depot_tools]"
215    },
216    "name": "build command_buffer"
217  },
218  {
219    "cmd": [
220      "python",
221      "-u",
222      "[START_DIR]/cache/work/skia/bin/fetch-gn"
223    ],
224    "cwd": "[START_DIR]/cache/work/skia",
225    "env": {
226      "CHROME_HEADLESS": "1",
227      "PATH": "<PATH>:RECIPE_REPO[depot_tools]"
228    },
229    "infra_step": true,
230    "name": "fetch-gn"
231  },
232  {
233    "cmd": [
234      "[START_DIR]/ccache_mac/bin/ccache",
235      "-s"
236    ],
237    "cwd": "[START_DIR]/cache/work/skia",
238    "env": {
239      "CCACHE_COMPILERCHECK": "content",
240      "CCACHE_DIR": "[START_DIR]/cache/ccache",
241      "CCACHE_MAXFILES": "0",
242      "CCACHE_MAXSIZE": "50G",
243      "CHROME_HEADLESS": "1",
244      "MACOSX_DEPLOYMENT_TARGET": "10.13",
245      "PATH": "<PATH>:RECIPE_REPO[depot_tools]"
246    },
247    "name": "ccache stats-start"
248  },
249  {
250    "cmd": [
251      "[START_DIR]/cache/work/skia/bin/gn",
252      "gen",
253      "[START_DIR]/cache/work/skia/out/Build-Mac-Clang-x86_64-Debug-CommandBuffer/Debug",
254      "--args=cc=\"clang\" cc_wrapper=\"[START_DIR]/ccache_mac/bin/ccache\" cxx=\"clang++\" extra_cflags=[\"-DREBUILD_IF_CHANGED_xcode_build_version=12c33\", \"-O1\"] skia_gl_standard=\"\" target_cpu=\"x86_64\" werror=true"
255    ],
256    "cwd": "[START_DIR]/cache/work/skia",
257    "env": {
258      "CCACHE_COMPILERCHECK": "content",
259      "CCACHE_DIR": "[START_DIR]/cache/ccache",
260      "CCACHE_MAXFILES": "0",
261      "CCACHE_MAXSIZE": "50G",
262      "CHROME_HEADLESS": "1",
263      "MACOSX_DEPLOYMENT_TARGET": "10.13",
264      "PATH": "<PATH>:RECIPE_REPO[depot_tools]"
265    },
266    "name": "gn gen"
267  },
268  {
269    "cmd": [
270      "ninja",
271      "-C",
272      "[START_DIR]/cache/work/skia/out/Build-Mac-Clang-x86_64-Debug-CommandBuffer/Debug"
273    ],
274    "cwd": "[START_DIR]/cache/work/skia",
275    "env": {
276      "CCACHE_COMPILERCHECK": "content",
277      "CCACHE_DIR": "[START_DIR]/cache/ccache",
278      "CCACHE_MAXFILES": "0",
279      "CCACHE_MAXSIZE": "50G",
280      "CHROME_HEADLESS": "1",
281      "MACOSX_DEPLOYMENT_TARGET": "10.13",
282      "PATH": "<PATH>:RECIPE_REPO[depot_tools]"
283    },
284    "name": "ninja"
285  },
286  {
287    "cmd": [
288      "[START_DIR]/ccache_mac/bin/ccache",
289      "-s"
290    ],
291    "cwd": "[START_DIR]/cache/work/skia",
292    "env": {
293      "CCACHE_COMPILERCHECK": "content",
294      "CCACHE_DIR": "[START_DIR]/cache/ccache",
295      "CCACHE_MAXFILES": "0",
296      "CCACHE_MAXSIZE": "50G",
297      "CHROME_HEADLESS": "1",
298      "MACOSX_DEPLOYMENT_TARGET": "10.13",
299      "PATH": "<PATH>:RECIPE_REPO[depot_tools]"
300    },
301    "name": "ccache stats-end"
302  },
303  {
304    "cmd": [
305      "python",
306      "-u",
307      "import errno\nimport glob\nimport os\nimport shutil\nimport sys\n\nsrc = sys.argv[1]\ndst = sys.argv[2]\nbuild_products = ['dm', 'dm.exe', 'dm.app', 'fm', 'fm.exe', 'nanobench.app', 'get_images_from_skps', 'get_images_from_skps.exe', 'hello-opencl', 'hello-opencl.exe', 'nanobench', 'nanobench.exe', 'skpbench', 'skpbench.exe', '*.so', '*.dll', '*.dylib', 'skia_launcher', 'skottie_tool', 'lib/*.so', 'run_testlab', 'skqp-universal-debug.apk']\n\ntry:\n  os.makedirs(dst)\nexcept OSError as e:\n  if e.errno != errno.EEXIST:\n    raise\n\nfor pattern in build_products:\n  path = os.path.join(src, pattern)\n  for f in glob.glob(path):\n    dst_path = os.path.join(dst, os.path.relpath(f, src))\n    if not os.path.isdir(os.path.dirname(dst_path)):\n      os.makedirs(os.path.dirname(dst_path))\n    print 'Copying build product %s to %s' % (f, dst_path)\n    shutil.move(f, dst_path)\n",
308      "[START_DIR]/cache/work/skia/out/Build-Mac-Clang-x86_64-Debug-CommandBuffer/Debug",
309      "[START_DIR]/[SWARM_OUT_DIR]"
310    ],
311    "infra_step": true,
312    "name": "copy build products",
313    "~followup_annotations": [
314      "@@@STEP_LOG_LINE@python.inline@import errno@@@",
315      "@@@STEP_LOG_LINE@python.inline@import glob@@@",
316      "@@@STEP_LOG_LINE@python.inline@import os@@@",
317      "@@@STEP_LOG_LINE@python.inline@import shutil@@@",
318      "@@@STEP_LOG_LINE@python.inline@import sys@@@",
319      "@@@STEP_LOG_LINE@python.inline@@@@",
320      "@@@STEP_LOG_LINE@python.inline@src = sys.argv[1]@@@",
321      "@@@STEP_LOG_LINE@python.inline@dst = sys.argv[2]@@@",
322      "@@@STEP_LOG_LINE@python.inline@build_products = ['dm', 'dm.exe', 'dm.app', 'fm', 'fm.exe', 'nanobench.app', 'get_images_from_skps', 'get_images_from_skps.exe', 'hello-opencl', 'hello-opencl.exe', 'nanobench', 'nanobench.exe', 'skpbench', 'skpbench.exe', '*.so', '*.dll', '*.dylib', 'skia_launcher', 'skottie_tool', 'lib/*.so', 'run_testlab', 'skqp-universal-debug.apk']@@@",
323      "@@@STEP_LOG_LINE@python.inline@@@@",
324      "@@@STEP_LOG_LINE@python.inline@try:@@@",
325      "@@@STEP_LOG_LINE@python.inline@  os.makedirs(dst)@@@",
326      "@@@STEP_LOG_LINE@python.inline@except OSError as e:@@@",
327      "@@@STEP_LOG_LINE@python.inline@  if e.errno != errno.EEXIST:@@@",
328      "@@@STEP_LOG_LINE@python.inline@    raise@@@",
329      "@@@STEP_LOG_LINE@python.inline@@@@",
330      "@@@STEP_LOG_LINE@python.inline@for pattern in build_products:@@@",
331      "@@@STEP_LOG_LINE@python.inline@  path = os.path.join(src, pattern)@@@",
332      "@@@STEP_LOG_LINE@python.inline@  for f in glob.glob(path):@@@",
333      "@@@STEP_LOG_LINE@python.inline@    dst_path = os.path.join(dst, os.path.relpath(f, src))@@@",
334      "@@@STEP_LOG_LINE@python.inline@    if not os.path.isdir(os.path.dirname(dst_path)):@@@",
335      "@@@STEP_LOG_LINE@python.inline@      os.makedirs(os.path.dirname(dst_path))@@@",
336      "@@@STEP_LOG_LINE@python.inline@    print 'Copying build product %s to %s' % (f, dst_path)@@@",
337      "@@@STEP_LOG_LINE@python.inline@    shutil.move(f, dst_path)@@@",
338      "@@@STEP_LOG_END@python.inline@@@"
339    ]
340  },
341  {
342    "name": "$result"
343  }
344]