Refresh Android.bp, cargo2android.json, TEST_MAPPING.
Test: None
Change-Id: I15c7ff0b653f34a8f052e9524e477a42ce1fe81a
diff --git a/Android.bp b/Android.bp
index 72585fa..1ded857 100644
--- a/Android.bp
+++ b/Android.bp
@@ -1,4 +1,4 @@
-// This file is generated by cargo2android.py --run --device --dependencies --tests.
+// This file is generated by cargo2android.py --config cargo2android.json.
// Do not modify this file as changes will be overridden on upgrade.
package {
@@ -39,12 +39,18 @@
],
}
-rust_defaults {
- name: "crossbeam-epoch_defaults",
+rust_test {
+ name: "crossbeam-epoch_test_src_lib",
+ host_supported: true,
crate_name: "crossbeam_epoch",
+ cargo_env_compat: true,
+ cargo_pkg_version: "0.9.5",
srcs: ["src/lib.rs"],
test_suites: ["general-tests"],
auto_gen_config: true,
+ test_options: {
+ unit_test: true,
+ },
edition: "2018",
features: [
"alloc",
@@ -62,60 +68,12 @@
],
}
-rust_test_host {
- name: "crossbeam-epoch_host_test_src_lib",
- defaults: ["crossbeam-epoch_defaults"],
- test_options: {
- unit_test: true,
- },
-}
-
-rust_test {
- name: "crossbeam-epoch_device_test_src_lib",
- defaults: ["crossbeam-epoch_defaults"],
-}
-
-rust_defaults {
- name: "crossbeam-epoch_defaults_loom",
- crate_name: "loom",
- srcs: ["tests/loom.rs"],
- test_suites: ["general-tests"],
- auto_gen_config: true,
- edition: "2018",
- features: [
- "alloc",
- "default",
- "lazy_static",
- "std",
- ],
- rustlibs: [
- "libcfg_if",
- "libcrossbeam_epoch",
- "libcrossbeam_utils",
- "liblazy_static",
- "libmemoffset",
- "librand",
- "libscopeguard",
- ],
-}
-
-rust_test_host {
- name: "crossbeam-epoch_host_test_tests_loom",
- defaults: ["crossbeam-epoch_defaults_loom"],
- test_options: {
- unit_test: true,
- },
-}
-
-rust_test {
- name: "crossbeam-epoch_device_test_tests_loom",
- defaults: ["crossbeam-epoch_defaults_loom"],
-}
-
rust_library {
name: "libcrossbeam_epoch",
host_supported: true,
crate_name: "crossbeam_epoch",
+ cargo_env_compat: true,
+ cargo_pkg_version: "0.9.5",
srcs: ["src/lib.rs"],
edition: "2018",
features: [
@@ -132,17 +90,3 @@
"libscopeguard",
],
}
-
-// dependent_library ["feature_list"]
-// autocfg-1.0.1
-// cfg-if-1.0.0
-// crossbeam-utils-0.8.5 "lazy_static,std"
-// getrandom-0.2.3 "std"
-// lazy_static-1.4.0
-// libc-0.2.97
-// memoffset-0.6.4 "default"
-// ppv-lite86-0.2.10 "simd,std"
-// rand-0.8.4 "alloc,default,getrandom,libc,rand_chacha,rand_hc,std,std_rng"
-// rand_chacha-0.3.1 "std"
-// rand_core-0.6.3 "alloc,getrandom,std"
-// scopeguard-1.1.0
diff --git a/TEST_MAPPING b/TEST_MAPPING
index 9f94cda..161921c 100644
--- a/TEST_MAPPING
+++ b/TEST_MAPPING
@@ -1,26 +1,30 @@
// Generated by update_crate_tests.py for tests that depend on this crate.
{
+ "imports": [
+ {
+ "path": "external/rust/crates/base64"
+ },
+ {
+ "path": "external/rust/crates/crossbeam-deque"
+ },
+ {
+ "path": "external/rust/crates/tinytemplate"
+ },
+ {
+ "path": "external/rust/crates/tinyvec"
+ },
+ {
+ "path": "external/rust/crates/unicode-xid"
+ }
+ ],
"presubmit": [
{
- "name": "base64_device_test_tests_decode"
- },
+ "name": "crossbeam-epoch_test_src_lib"
+ }
+ ],
+ "presubmit-rust": [
{
- "name": "base64_device_test_tests_encode"
- },
- {
- "name": "base64_device_test_tests_helpers"
- },
- {
- "name": "crossbeam-epoch_device_test_src_lib"
- },
- {
- "name": "crossbeam-epoch_device_test_tests_loom"
- },
- {
- "name": "unicode-xid_device_test_src_lib"
- },
- {
- "name": "unicode-xid_device_test_tests_exhaustive_tests"
+ "name": "crossbeam-epoch_test_src_lib"
}
]
}
diff --git a/cargo2android.json b/cargo2android.json
new file mode 100644
index 0000000..d36fb44
--- /dev/null
+++ b/cargo2android.json
@@ -0,0 +1,5 @@
+{
+ "device": true,
+ "run": true,
+ "tests": true
+}
\ No newline at end of file