Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(16)

Side by Side Diff: third_party/instrumented_libraries/BUILD.gn

Issue 2775913002: Instrumented libraries: Remove dependence on GYP_DEFINES (Closed)
Patch Set: fix python syntax Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 # Copyright 2015 The Chromium Authors. All rights reserved. 1 # Copyright 2015 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import("//build/config/sanitizers/sanitizers.gni") 5 import("//build/config/sanitizers/sanitizers.gni")
6 import("//build/toolchain/goma.gni") 6 import("//build/toolchain/goma.gni")
7 7
8 declare_args() { 8 declare_args() {
9 # The platform on which the instrumented libraries are being built. 9 # The platform on which the instrumented libraries are being built.
10 instrumented_libraries_platform = "trusty" 10 instrumented_libraries_platform = "trusty"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 } 50 }
51 51
52 if (is_msan) { 52 if (is_msan) {
53 if (msan_track_origins == 0) { 53 if (msan_track_origins == 0) {
54 archive_prefix = "msan-no-origins" 54 archive_prefix = "msan-no-origins"
55 } else if (msan_track_origins == 2) { 55 } else if (msan_track_origins == 2) {
56 archive_prefix = "msan-chained-origins" 56 archive_prefix = "msan-chained-origins"
57 } 57 }
58 } 58 }
59 59
60 # TODO(GYP): scripts/download_binaries.py uses GYP_DEFINES to decide whether 60 action("download_prebuilt_instrumented_libraries") {
61 # to download the archives extracted here. 61 tarfile_name = "$archive_prefix-$instrumented_libraries_platform.tgz"
62 shafile = "binaries/$tarfile_name.sha1"
63 tarfile = "$target_out_dir/$tarfile_name"
Michael Achenbach 2017/03/28 07:55:05 Please note that now different out directories don
64 inputs = [ shafile ]
65 outputs = [ tarfile ]
66 script = "scripts/download_binaries.py"
67 args = [ rebase_path(shafile), rebase_path(tarfile) ]
68 }
69
62 # Note: This requires a clobber whenever Ubuntu version changes. 70 # Note: This requires a clobber whenever Ubuntu version changes.
63 action("extract_prebuilt_instrumented_libraries") { 71 action("extract_prebuilt_instrumented_libraries") {
72 deps = [ ":download_prebuilt_instrumented_libraries" ]
64 visibility = [ ":prebuilt" ] 73 visibility = [ ":prebuilt" ]
65 script = "scripts/unpack_binaries.py" 74 script = "scripts/unpack_binaries.py"
66 depfile = "$target_out_dir/$archive_prefix.d" 75 depfile = "$target_out_dir/$archive_prefix.d"
76 tarfile = get_target_outputs(":download_prebuilt_instrumented_libraries")
67 args = [ 77 args = [
68 archive_prefix, 78 rebase_path(tarfile[0]),
69 rebase_path("binaries"), 79 rebase_path("$target_out_dir/$archive_prefix.txt"),
70 rebase_path(root_out_dir + "/instrumented_libraries_prebuilt"), 80 rebase_path(root_out_dir + "/instrumented_libraries_prebuilt"),
71 rebase_path(target_out_dir, root_out_dir),
72 ] 81 ]
73 outputs = [ 82 outputs = [
74 "$target_out_dir/$archive_prefix.txt", 83 "$target_out_dir/$archive_prefix.txt",
75 ] 84 ]
76 data = [ 85 data = [
77 "$root_out_dir/instrumented_libraries_prebuilt/", 86 "$root_out_dir/instrumented_libraries_prebuilt/",
78 ] 87 ]
79 } 88 }
80 89
81 config("prebuilt_ldflags") { 90 config("prebuilt_ldflags") {
(...skipping 722 matching lines...) Expand 10 before | Expand all | Expand 10 after
804 "--disable-gudev", 813 "--disable-gudev",
805 ] 814 ]
806 pre_build = "scripts/pre-build/udev.sh" 815 pre_build = "scripts/pre-build/udev.sh"
807 } 816 }
808 817
809 instrumented_library("zlib1g") { 818 instrumented_library("zlib1g") {
810 # --disable-static is not supported 819 # --disable-static is not supported
811 patch = "patches/zlib1g.diff" 820 patch = "patches/zlib1g.diff"
812 } 821 }
813 } 822 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698