OLD | NEW |
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 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 # GYP: //tools/android/forwarder2/forwarder.gyp:forwarder2 | 5 # GYP: //tools/android/forwarder2/forwarder.gyp:forwarder2 |
6 group("forwarder2") { | 6 group("forwarder2") { |
7 data_deps = [ | 7 data_deps = [ |
8 ":host_forwarder($host_toolchain)", | |
9 ":host_forwarder_copy($host_toolchain)", | 8 ":host_forwarder_copy($host_toolchain)", |
10 ":device_forwarder($default_toolchain)", | |
11 ":device_forwarder_prepare_dist($default_toolchain)", | 9 ":device_forwarder_prepare_dist($default_toolchain)", |
12 ] | 10 ] |
13 } | 11 } |
14 | 12 |
15 if (current_toolchain == default_toolchain) { | 13 if (current_toolchain == default_toolchain) { |
16 import("//build/config/android/rules.gni") | 14 import("//build/config/android/rules.gni") |
17 | 15 |
18 # GYP: //tools/android/forwarder2/forwarder.gyp:device_forwarder | 16 # GYP: //tools/android/forwarder2/forwarder.gyp:device_forwarder |
19 executable("device_forwarder") { | 17 executable("device_forwarder") { |
20 sources = [ | 18 sources = [ |
(...skipping 17 matching lines...) Expand all Loading... |
38 "self_deleter_helper.h", | 36 "self_deleter_helper.h", |
39 "socket.cc", | 37 "socket.cc", |
40 "socket.h", | 38 "socket.h", |
41 "util.h", | 39 "util.h", |
42 ] | 40 ] |
43 deps = [ | 41 deps = [ |
44 "//base", | 42 "//base", |
45 "//build/config/sanitizers:deps", | 43 "//build/config/sanitizers:deps", |
46 "//tools/android/common", | 44 "//tools/android/common", |
47 ] | 45 ] |
48 data_deps = [ "//build/android/pylib/device/commands" ] | 46 data_deps = [ |
| 47 "//build/android/pylib/device/commands", |
| 48 ] |
49 } | 49 } |
50 | 50 |
51 # GYP: //tools/android/forwarder2/forwarder.gyp:forwarder2 | 51 # GYP: //tools/android/forwarder2/forwarder.gyp:forwarder2 |
52 create_native_executable_dist("device_forwarder_prepare_dist") { | 52 create_native_executable_dist("device_forwarder_prepare_dist") { |
53 dist_dir = "$root_build_dir/forwarder_dist" | 53 dist_dir = "$root_build_dir/forwarder_dist" |
54 binary = "$root_build_dir/device_forwarder" | 54 binary = "$root_build_dir/device_forwarder" |
55 deps = [ | 55 deps = [ |
56 ":device_forwarder", | 56 ":device_forwarder", |
57 ] | 57 ] |
58 } | 58 } |
(...skipping 24 matching lines...) Expand all Loading... |
83 "util.h", | 83 "util.h", |
84 ] | 84 ] |
85 deps = [ | 85 deps = [ |
86 "//base", | 86 "//base", |
87 "//build/config/sanitizers:deps", | 87 "//build/config/sanitizers:deps", |
88 "//tools/android/common", | 88 "//tools/android/common", |
89 ] | 89 ] |
90 } | 90 } |
91 | 91 |
92 # GYP: //tools/android/forwarder2/forwarder.gyp:forwarder2 | 92 # GYP: //tools/android/forwarder2/forwarder.gyp:forwarder2 |
93 copy("host_forwarder_copy") { | 93 action("host_forwarder_copy") { |
| 94 # Symlink rather than copy. When copied and using a component build, it |
| 95 # fails to find libbase.so (since it's actually at clang_x64/libbase.so). |
| 96 script = "//build/symlink.py" |
| 97 _src = "$root_out_dir/host_forwarder" |
| 98 _target = "$root_build_dir/host_forwarder" |
94 sources = [ | 99 sources = [ |
95 "$root_out_dir/host_forwarder", | 100 _src, |
96 ] | 101 ] |
97 outputs = [ | 102 outputs = [ |
98 "$root_build_dir/host_forwarder", | 103 _target, |
99 ] | 104 ] |
100 deps = [ | 105 deps = [ |
101 ":host_forwarder", | 106 ":host_forwarder", |
102 ] | 107 ] |
| 108 args = [ |
| 109 "-f", |
| 110 rebase_path(_src, root_build_dir), |
| 111 rebase_path(_target, root_build_dir), |
| 112 ] |
103 } | 113 } |
104 } | 114 } |
OLD | NEW |