From 84f9711f7e548049a19da3fce5774b639398285f Mon Sep 17 00:00:00 2001 From: Joel Galenson Date: Mon, 29 Nov 2021 14:03:27 -0800 Subject: Refresh Android.bp, cargo2android.json, TEST_MAPPING. Test: None Change-Id: I15c7ff0b653f34a8f052e9524e477a42ce1fe81a --- Android.bp | 72 ++++++------------------------------------------------ TEST_MAPPING | 24 ++++++++++-------- cargo2android.json | 5 ++++ 3 files changed, 27 insertions(+), 74 deletions(-) create mode 100644 cargo2android.json 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,48 +39,18 @@ license { ], } -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, - edition: "2018", - features: [ - "alloc", - "default", - "lazy_static", - "std", - ], - rustlibs: [ - "libcfg_if", - "libcrossbeam_utils", - "liblazy_static", - "libmemoffset", - "librand", - "libscopeguard", - ], -} - -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", @@ -90,7 +60,6 @@ rust_defaults { ], rustlibs: [ "libcfg_if", - "libcrossbeam_epoch", "libcrossbeam_utils", "liblazy_static", "libmemoffset", @@ -99,23 +68,12 @@ rust_defaults { ], } -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 @@ rust_library { "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. { - "presubmit": [ + "imports": [ { - "name": "base64_device_test_tests_decode" + "path": "external/rust/crates/base64" }, { - "name": "base64_device_test_tests_encode" + "path": "external/rust/crates/crossbeam-deque" }, { - "name": "base64_device_test_tests_helpers" + "path": "external/rust/crates/tinytemplate" }, { - "name": "crossbeam-epoch_device_test_src_lib" + "path": "external/rust/crates/tinyvec" }, { - "name": "crossbeam-epoch_device_test_tests_loom" - }, + "path": "external/rust/crates/unicode-xid" + } + ], + "presubmit": [ { - "name": "unicode-xid_device_test_src_lib" - }, + "name": "crossbeam-epoch_test_src_lib" + } + ], + "presubmit-rust": [ { - "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 -- cgit v1.2.3