From e8b38ab432faf419a6cc092082c34c233800ccea Mon Sep 17 00:00:00 2001 From: Eric Boren Date: Fri, 8 Jun 2018 12:37:53 -0400 Subject: [recipes] Make ct_skps use binaries from a build task Bug: skia:6473 Change-Id: I10a169dd47cb76839fd401254eaeb4c46b2ece8f Reviewed-on: https://skia-review.googlesource.com/128549 Reviewed-by: Ravi Mistry Commit-Queue: Eric Boren --- infra/bots/recipe_modules/build/default.py | 2 +- .../Build-Debian9-Clang-x86_64-Release-Static.json | 102 +++++++++++++++++++++ ...E-CPU-AVX2-x86_64-Debug-All-CT_DM_10k_SKPs.json | 102 --------------------- infra/bots/recipe_modules/build/examples/full.py | 2 +- 4 files changed, 104 insertions(+), 104 deletions(-) create mode 100644 infra/bots/recipe_modules/build/examples/full.expected/Build-Debian9-Clang-x86_64-Release-Static.json delete mode 100644 infra/bots/recipe_modules/build/examples/full.expected/Test-Ubuntu14-Clang-GCE-CPU-AVX2-x86_64-Debug-All-CT_DM_10k_SKPs.json (limited to 'infra/bots/recipe_modules') diff --git a/infra/bots/recipe_modules/build/default.py b/infra/bots/recipe_modules/build/default.py index 63c168b2d1..bb2a019365 100644 --- a/infra/bots/recipe_modules/build/default.py +++ b/infra/bots/recipe_modules/build/default.py @@ -71,7 +71,7 @@ def compile_fn(api, checkout_root, out_dir): extra_ldflags.append('-fuse-ld=lld') extra_cflags.append('-DDUMMY_clang_linux_version=%s' % api.run.asset_version('clang_linux', skia_dir)) - if os == 'Ubuntu14': + if 'Static' in extra_tokens: extra_ldflags.extend(['-static-libstdc++', '-static-libgcc']) elif compiler == 'Clang': diff --git a/infra/bots/recipe_modules/build/examples/full.expected/Build-Debian9-Clang-x86_64-Release-Static.json b/infra/bots/recipe_modules/build/examples/full.expected/Build-Debian9-Clang-x86_64-Release-Static.json new file mode 100644 index 0000000000..4b070d45e0 --- /dev/null +++ b/infra/bots/recipe_modules/build/examples/full.expected/Build-Debian9-Clang-x86_64-Release-Static.json @@ -0,0 +1,102 @@ +[ + { + "cmd": [ + "python", + "-u", + "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", + "--json-output", + "/path/to/tmp/json", + "copy", + "[START_DIR]/cache/work/skia/infra/bots/assets/clang_linux/VERSION", + "/path/to/tmp/" + ], + "infra_step": true, + "name": "Get clang_linux VERSION" + }, + { + "cmd": [ + "python", + "-u", + "[START_DIR]/cache/work/skia/bin/fetch-gn" + ], + "cwd": "[START_DIR]/cache/work/skia", + "env": { + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_PACKAGE_REPO[depot_tools]" + }, + "infra_step": true, + "name": "fetch-gn" + }, + { + "cmd": [ + "[START_DIR]/cache/work/skia/bin/gn", + "gen", + "[START_DIR]/cache/work/skia/out/Build-Debian9-Clang-x86_64-Release-Static/Release", + "--args=cc=\"[START_DIR]/clang_linux/bin/clang\" cxx=\"[START_DIR]/clang_linux/bin/clang++\" extra_cflags=[\"-B[START_DIR]/clang_linux/bin\", \"-DDUMMY_clang_linux_version=42\"] extra_ldflags=[\"-B[START_DIR]/clang_linux/bin\", \"-fuse-ld=lld\", \"-static-libstdc++\", \"-static-libgcc\"] is_debug=false target_cpu=\"x86_64\"" + ], + "cwd": "[START_DIR]/cache/work/skia", + "env": { + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_PACKAGE_REPO[depot_tools]" + }, + "name": "gn gen" + }, + { + "cmd": [ + "ninja", + "-k", + "0", + "-C", + "[START_DIR]/cache/work/skia/out/Build-Debian9-Clang-x86_64-Release-Static/Release" + ], + "cwd": "[START_DIR]/cache/work/skia", + "env": { + "CHROME_HEADLESS": "1", + "PATH": ":RECIPE_PACKAGE_REPO[depot_tools]" + }, + "name": "ninja" + }, + { + "cmd": [ + "python", + "-u", + "import errno\nimport glob\nimport os\nimport shutil\nimport sys\n\nsrc = sys.argv[1]\ndst = sys.argv[2]\nbuild_products_whitelist = ['bookmaker', 'dm', 'dm.exe', 'dm.app', 'nanobench.app', 'get_images_from_skps', 'get_images_from_skps.exe', 'nanobench', 'nanobench.exe', 'skpbench', 'skpbench.exe', '*.so', '*.dll', '*.dylib', 'skia_launcher', 'skiaserve', 'lib/*.so', 'run_testlab', 'skqp-universal-debug.apk', 'whitelist_devices.json']\n\ntry:\n os.makedirs(dst)\nexcept OSError as e:\n if e.errno != errno.EEXIST:\n raise\n\nfor pattern in build_products_whitelist:\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", + "[START_DIR]/cache/work/skia/out/Build-Debian9-Clang-x86_64-Release-Static/Release", + "[START_DIR]/[SWARM_OUT_DIR]/out/Release" + ], + "infra_step": true, + "name": "copy build products", + "~followup_annotations": [ + "@@@STEP_LOG_LINE@python.inline@import errno@@@", + "@@@STEP_LOG_LINE@python.inline@import glob@@@", + "@@@STEP_LOG_LINE@python.inline@import os@@@", + "@@@STEP_LOG_LINE@python.inline@import shutil@@@", + "@@@STEP_LOG_LINE@python.inline@import sys@@@", + "@@@STEP_LOG_LINE@python.inline@@@@", + "@@@STEP_LOG_LINE@python.inline@src = sys.argv[1]@@@", + "@@@STEP_LOG_LINE@python.inline@dst = sys.argv[2]@@@", + "@@@STEP_LOG_LINE@python.inline@build_products_whitelist = ['bookmaker', 'dm', 'dm.exe', 'dm.app', 'nanobench.app', 'get_images_from_skps', 'get_images_from_skps.exe', 'nanobench', 'nanobench.exe', 'skpbench', 'skpbench.exe', '*.so', '*.dll', '*.dylib', 'skia_launcher', 'skiaserve', 'lib/*.so', 'run_testlab', 'skqp-universal-debug.apk', 'whitelist_devices.json']@@@", + "@@@STEP_LOG_LINE@python.inline@@@@", + "@@@STEP_LOG_LINE@python.inline@try:@@@", + "@@@STEP_LOG_LINE@python.inline@ os.makedirs(dst)@@@", + "@@@STEP_LOG_LINE@python.inline@except OSError as e:@@@", + "@@@STEP_LOG_LINE@python.inline@ if e.errno != errno.EEXIST:@@@", + "@@@STEP_LOG_LINE@python.inline@ raise@@@", + "@@@STEP_LOG_LINE@python.inline@@@@", + "@@@STEP_LOG_LINE@python.inline@for pattern in build_products_whitelist:@@@", + "@@@STEP_LOG_LINE@python.inline@ path = os.path.join(src, pattern)@@@", + "@@@STEP_LOG_LINE@python.inline@ for f in glob.glob(path):@@@", + "@@@STEP_LOG_LINE@python.inline@ dst_path = os.path.join(dst, os.path.relpath(f, src))@@@", + "@@@STEP_LOG_LINE@python.inline@ if not os.path.isdir(os.path.dirname(dst_path)):@@@", + "@@@STEP_LOG_LINE@python.inline@ os.makedirs(os.path.dirname(dst_path))@@@", + "@@@STEP_LOG_LINE@python.inline@ print 'Copying build product %s to %s' % (f, dst_path)@@@", + "@@@STEP_LOG_LINE@python.inline@ shutil.move(f, dst_path)@@@", + "@@@STEP_LOG_END@python.inline@@@" + ] + }, + { + "name": "$result", + "recipe_result": null, + "status_code": 0 + } +] \ No newline at end of file diff --git a/infra/bots/recipe_modules/build/examples/full.expected/Test-Ubuntu14-Clang-GCE-CPU-AVX2-x86_64-Debug-All-CT_DM_10k_SKPs.json b/infra/bots/recipe_modules/build/examples/full.expected/Test-Ubuntu14-Clang-GCE-CPU-AVX2-x86_64-Debug-All-CT_DM_10k_SKPs.json deleted file mode 100644 index 235adc68f2..0000000000 --- a/infra/bots/recipe_modules/build/examples/full.expected/Test-Ubuntu14-Clang-GCE-CPU-AVX2-x86_64-Debug-All-CT_DM_10k_SKPs.json +++ /dev/null @@ -1,102 +0,0 @@ -[ - { - "cmd": [ - "python", - "-u", - "RECIPE_MODULE[recipe_engine::file]/resources/fileutil.py", - "--json-output", - "/path/to/tmp/json", - "copy", - "[START_DIR]/cache/work/skia/infra/bots/assets/clang_linux/VERSION", - "/path/to/tmp/" - ], - "infra_step": true, - "name": "Get clang_linux VERSION" - }, - { - "cmd": [ - "python", - "-u", - "[START_DIR]/cache/work/skia/bin/fetch-gn" - ], - "cwd": "[START_DIR]/cache/work/skia", - "env": { - "CHROME_HEADLESS": "1", - "PATH": ":RECIPE_PACKAGE_REPO[depot_tools]" - }, - "infra_step": true, - "name": "fetch-gn" - }, - { - "cmd": [ - "[START_DIR]/cache/work/skia/bin/gn", - "gen", - "[START_DIR]/cache/work/skia/out/Test-Ubuntu14-Clang-GCE-CPU-AVX2-x86_64-Debug-All-CT_DM_10k_SKPs/Debug", - "--args=cc=\"[START_DIR]/clang_linux/bin/clang\" cxx=\"[START_DIR]/clang_linux/bin/clang++\" extra_cflags=[\"-B[START_DIR]/clang_linux/bin\", \"-DDUMMY_clang_linux_version=42\", \"-O1\"] extra_ldflags=[\"-B[START_DIR]/clang_linux/bin\", \"-fuse-ld=lld\", \"-static-libstdc++\", \"-static-libgcc\"]" - ], - "cwd": "[START_DIR]/cache/work/skia", - "env": { - "CHROME_HEADLESS": "1", - "PATH": ":RECIPE_PACKAGE_REPO[depot_tools]" - }, - "name": "gn gen" - }, - { - "cmd": [ - "ninja", - "-k", - "0", - "-C", - "[START_DIR]/cache/work/skia/out/Test-Ubuntu14-Clang-GCE-CPU-AVX2-x86_64-Debug-All-CT_DM_10k_SKPs/Debug" - ], - "cwd": "[START_DIR]/cache/work/skia", - "env": { - "CHROME_HEADLESS": "1", - "PATH": ":RECIPE_PACKAGE_REPO[depot_tools]" - }, - "name": "ninja" - }, - { - "cmd": [ - "python", - "-u", - "import errno\nimport glob\nimport os\nimport shutil\nimport sys\n\nsrc = sys.argv[1]\ndst = sys.argv[2]\nbuild_products_whitelist = ['bookmaker', 'dm', 'dm.exe', 'dm.app', 'nanobench.app', 'get_images_from_skps', 'get_images_from_skps.exe', 'nanobench', 'nanobench.exe', 'skpbench', 'skpbench.exe', '*.so', '*.dll', '*.dylib', 'skia_launcher', 'skiaserve', 'lib/*.so', 'run_testlab', 'skqp-universal-debug.apk', 'whitelist_devices.json']\n\ntry:\n os.makedirs(dst)\nexcept OSError as e:\n if e.errno != errno.EEXIST:\n raise\n\nfor pattern in build_products_whitelist:\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", - "[START_DIR]/cache/work/skia/out/Test-Ubuntu14-Clang-GCE-CPU-AVX2-x86_64-Debug-All-CT_DM_10k_SKPs/Debug", - "[START_DIR]/[SWARM_OUT_DIR]/out/Debug" - ], - "infra_step": true, - "name": "copy build products", - "~followup_annotations": [ - "@@@STEP_LOG_LINE@python.inline@import errno@@@", - "@@@STEP_LOG_LINE@python.inline@import glob@@@", - "@@@STEP_LOG_LINE@python.inline@import os@@@", - "@@@STEP_LOG_LINE@python.inline@import shutil@@@", - "@@@STEP_LOG_LINE@python.inline@import sys@@@", - "@@@STEP_LOG_LINE@python.inline@@@@", - "@@@STEP_LOG_LINE@python.inline@src = sys.argv[1]@@@", - "@@@STEP_LOG_LINE@python.inline@dst = sys.argv[2]@@@", - "@@@STEP_LOG_LINE@python.inline@build_products_whitelist = ['bookmaker', 'dm', 'dm.exe', 'dm.app', 'nanobench.app', 'get_images_from_skps', 'get_images_from_skps.exe', 'nanobench', 'nanobench.exe', 'skpbench', 'skpbench.exe', '*.so', '*.dll', '*.dylib', 'skia_launcher', 'skiaserve', 'lib/*.so', 'run_testlab', 'skqp-universal-debug.apk', 'whitelist_devices.json']@@@", - "@@@STEP_LOG_LINE@python.inline@@@@", - "@@@STEP_LOG_LINE@python.inline@try:@@@", - "@@@STEP_LOG_LINE@python.inline@ os.makedirs(dst)@@@", - "@@@STEP_LOG_LINE@python.inline@except OSError as e:@@@", - "@@@STEP_LOG_LINE@python.inline@ if e.errno != errno.EEXIST:@@@", - "@@@STEP_LOG_LINE@python.inline@ raise@@@", - "@@@STEP_LOG_LINE@python.inline@@@@", - "@@@STEP_LOG_LINE@python.inline@for pattern in build_products_whitelist:@@@", - "@@@STEP_LOG_LINE@python.inline@ path = os.path.join(src, pattern)@@@", - "@@@STEP_LOG_LINE@python.inline@ for f in glob.glob(path):@@@", - "@@@STEP_LOG_LINE@python.inline@ dst_path = os.path.join(dst, os.path.relpath(f, src))@@@", - "@@@STEP_LOG_LINE@python.inline@ if not os.path.isdir(os.path.dirname(dst_path)):@@@", - "@@@STEP_LOG_LINE@python.inline@ os.makedirs(os.path.dirname(dst_path))@@@", - "@@@STEP_LOG_LINE@python.inline@ print 'Copying build product %s to %s' % (f, dst_path)@@@", - "@@@STEP_LOG_LINE@python.inline@ shutil.move(f, dst_path)@@@", - "@@@STEP_LOG_END@python.inline@@@" - ] - }, - { - "name": "$result", - "recipe_result": null, - "status_code": 0 - } -] \ No newline at end of file diff --git a/infra/bots/recipe_modules/build/examples/full.py b/infra/bots/recipe_modules/build/examples/full.py index 5f686ada7c..dc3d1b7a01 100644 --- a/infra/bots/recipe_modules/build/examples/full.py +++ b/infra/bots/recipe_modules/build/examples/full.py @@ -38,6 +38,7 @@ TEST_BUILDERS = [ 'Build-Debian9-Clang-x86_64-Release-Fast', 'Build-Debian9-Clang-x86_64-Release-Mini', 'Build-Debian9-Clang-x86_64-Release-NoDEPS', + 'Build-Debian9-Clang-x86_64-Release-Static', 'Build-Debian9-Clang-x86_64-Release-SwiftShader', 'Build-Debian9-Clang-x86_64-Release-Vulkan', 'Build-Debian9-EMCC-wasm-Release', @@ -56,7 +57,6 @@ TEST_BUILDERS = [ 'Build-Win-Clang-x86-Debug-Exceptions', 'Build-Win-Clang-x86_64-Release-Vulkan', 'Housekeeper-PerCommit-CheckGeneratedFiles', - 'Test-Ubuntu14-Clang-GCE-CPU-AVX2-x86_64-Debug-All-CT_DM_10k_SKPs' ] # Default properties used for TEST_BUILDERS. -- cgit v1.2.3