aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoel Galenson <jgalenson@google.com>2021-06-03 21:19:39 +0000
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2021-06-03 21:19:39 +0000
commitf7b04b5fa34b456ff4f6260c7d60120edd021271 (patch)
treebec0501e1094cccd9e6fbeded10ef744d623fd62
parent4a609f2310bbdebdd30670badaa8872a08a5245c (diff)
parent85d99d1abf515f2a5747f482c21333b09892b0f4 (diff)
downloadrand_xorshift-f7b04b5fa34b456ff4f6260c7d60120edd021271.tar.gz
Use new c2a functionality instead of a patch. am: b3fa6077a0 am: acaf608c3f am: 1f6601c3fd am: 85d99d1abf
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/rand_xorshift/+/1725432 Change-Id: Idd91f0725e264a212f4ca944307aa98cbb6896b0
-rw-r--r--Android.bp20
-rw-r--r--cargo2android.json9
-rw-r--r--patches/Android.bp.patch24
3 files changed, 20 insertions, 33 deletions
diff --git a/Android.bp b/Android.bp
index 54e1607..ba2feb9 100644
--- a/Android.bp
+++ b/Android.bp
@@ -1,4 +1,5 @@
-// This file is generated by cargo2android.py --run --device --tests --dependencies --patch=patches/Android.bp.patch.
+// This file is generated by cargo2android.py --config cargo2android.json.
+// Do not modify this file as changes will be overridden on upgrade.
package {
default_applicable_licenses: ["external_rust_crates_rand_xorshift_license"],
@@ -56,8 +57,6 @@ rust_defaults {
auto_gen_config: true,
edition: "2018",
rustlibs: [
- // ANDROID: not really used
- //"libbincode",
"librand_core",
],
}
@@ -65,6 +64,9 @@ rust_defaults {
rust_test_host {
name: "rand_xorshift_host_test_src_lib",
defaults: ["rand_xorshift_defaults"],
+ test_options: {
+ unit_test: true,
+ },
}
rust_test {
@@ -80,8 +82,6 @@ rust_defaults {
auto_gen_config: true,
edition: "2018",
rustlibs: [
- // ANDROID: not really used
- //"libbincode",
"librand_core",
"librand_xorshift",
],
@@ -90,6 +90,9 @@ rust_defaults {
rust_test_host {
name: "rand_xorshift_host_test_tests_mod",
defaults: ["rand_xorshift_defaults_mod"],
+ test_options: {
+ unit_test: true,
+ },
}
rust_test {
@@ -98,7 +101,6 @@ rust_test {
}
// dependent_library ["feature_list"]
-// bincode-1.3.1
-// byteorder-1.3.4 "default,std"
-// rand_core-0.6.0
-// serde-1.0.118 "default,std"
+// bincode-1.3.3
+// rand_core-0.6.2
+// serde-1.0.126 "default,std"
diff --git a/cargo2android.json b/cargo2android.json
new file mode 100644
index 0000000..7f3828f
--- /dev/null
+++ b/cargo2android.json
@@ -0,0 +1,9 @@
+{
+ "dependencies": true,
+ "dependency-blocklist": [
+ "bincode"
+ ],
+ "device": true,
+ "run": true,
+ "tests": true
+}
diff --git a/patches/Android.bp.patch b/patches/Android.bp.patch
deleted file mode 100644
index 13b71ce..0000000
--- a/patches/Android.bp.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-diff --git a/Android.bp b/Android.bp
-index 704654e..0e6db92 100644
---- a/Android.bp
-+++ b/Android.bp
-@@ -19,7 +19,8 @@ rust_defaults {
- auto_gen_config: true,
- edition: "2018",
- rustlibs: [
-- "libbincode",
-+ // ANDROID: not really used
-+ //"libbincode",
- "librand_core",
- ],
- }
-@@ -42,7 +43,8 @@ rust_defaults {
- auto_gen_config: true,
- edition: "2018",
- rustlibs: [
-- "libbincode",
-+ // ANDROID: not really used
-+ //"libbincode",
- "librand_core",
- "librand_xorshift",
- ],