| 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 import("//build/config/android/rules.gni") | 5 import("//build/config/android/rules.gni") |
| 6 import("//third_party/ijar/ijar.gni") |
| 6 | 7 |
| 7 sun_tools_jar_path = "$root_gen_dir/sun_tools_jar/tools.jar" | 8 sun_tools_jar_path = "$root_gen_dir/sun_tools_jar/tools.jar" |
| 8 | 9 |
| 9 action("find_sun_tools_jar") { | 10 action("find_sun_tools_jar") { |
| 10 script = "//build/android/gyp/find_sun_tools_jar.py" | 11 script = "//build/android/gyp/find_sun_tools_jar.py" |
| 11 depfile = "$target_gen_dir/$target_name.d" | 12 depfile = "$target_gen_dir/$target_name.d" |
| 12 outputs = [ | 13 outputs = [ |
| 13 depfile, | 14 depfile, |
| 14 sun_tools_jar_path, | 15 sun_tools_jar_path, |
| 15 ] | 16 ] |
| 16 args = [ | 17 args = [ |
| 17 "--depfile", | 18 "--depfile", |
| 18 rebase_path(depfile, root_build_dir), | 19 rebase_path(depfile, root_build_dir), |
| 19 "--output", | 20 "--output", |
| 20 rebase_path(sun_tools_jar_path, root_build_dir), | 21 rebase_path(sun_tools_jar_path, root_build_dir), |
| 21 ] | 22 ] |
| 22 } | 23 } |
| 23 | 24 |
| 24 java_prebuilt("sun_tools_java") { | 25 java_prebuilt("sun_tools_java") { |
| 25 jar_path = sun_tools_jar_path | 26 jar_path = sun_tools_jar_path |
| 26 jar_dep = ":find_sun_tools_jar" | 27 jar_dep = ":find_sun_tools_jar" |
| 27 } | 28 } |
| 28 | 29 |
| 30 generate_interface_jar("android_ijar") { |
| 31 input_jar = android_sdk_jar |
| 32 output_jar = "$root_out_dir/lib.java/android.interface.jar" |
| 33 } |
| 34 |
| 29 action("cpplib_stripped") { | 35 action("cpplib_stripped") { |
| 30 _strip_bin = "${android_tool_prefix}strip" | 36 _strip_bin = "${android_tool_prefix}strip" |
| 31 _soname = "libc++_shared.so" | 37 _soname = "libc++_shared.so" |
| 32 _input_so = "${android_libcpp_root}/libs/${android_app_abi}/${_soname}" | 38 _input_so = "${android_libcpp_root}/libs/${android_app_abi}/${_soname}" |
| 33 _output_so = "${root_shlib_dir}/${_soname}" | 39 _output_so = "${root_shlib_dir}/${_soname}" |
| 34 | 40 |
| 35 script = "//build/gn_run_binary.py" | 41 script = "//build/gn_run_binary.py" |
| 36 inputs = [ | 42 inputs = [ |
| 37 _strip_bin, | 43 _strip_bin, |
| 38 ] | 44 ] |
| 39 sources = [ | 45 sources = [ |
| 40 _input_so, | 46 _input_so, |
| 41 ] | 47 ] |
| 42 outputs = [ | 48 outputs = [ |
| 43 _output_so, | 49 _output_so, |
| 44 ] | 50 ] |
| 45 | 51 |
| 46 _rebased_strip_bin = rebase_path(_strip_bin, root_out_dir) | 52 _rebased_strip_bin = rebase_path(_strip_bin, root_out_dir) |
| 47 _rebased_input_so = rebase_path(_input_so, root_out_dir) | 53 _rebased_input_so = rebase_path(_input_so, root_out_dir) |
| 48 _rebased_output_so = rebase_path(_output_so, root_out_dir) | 54 _rebased_output_so = rebase_path(_output_so, root_out_dir) |
| 49 args = [ | 55 args = [ |
| 50 _rebased_strip_bin, | 56 _rebased_strip_bin, |
| 51 "--strip-unneeded", | 57 "--strip-unneeded", |
| 52 "-o", | 58 "-o", |
| 53 _rebased_output_so, | 59 _rebased_output_so, |
| 54 _rebased_input_so, | 60 _rebased_input_so, |
| 55 ] | 61 ] |
| 56 } | 62 } |
| OLD | NEW |