summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Vander Stoep <jeffv@google.com>2020-12-21 09:56:33 +0100
committerJeff Vander Stoep <jeffv@google.com>2020-12-21 09:56:33 +0100
commit766c8d344063a5868a8179a5a86d70294238503c (patch)
tree9df5ed4ec6d3849061ff88b35df48858bb4ac762
parent3d4b232b1b31c83cefc7d20d6d9c35ef8ed71fbd (diff)
downloadmatches-766c8d344063a5868a8179a5a86d70294238503c.tar.gz
Add Android.bp
Test: mm Test: atest Change-Id: I4f1f2a1295b70726981e8c998e2c519e082005c9
-rw-r--r--Android.bp53
-rw-r--r--TEST_MAPPING19
2 files changed, 72 insertions, 0 deletions
diff --git a/Android.bp b/Android.bp
new file mode 100644
index 0000000..de4144e
--- /dev/null
+++ b/Android.bp
@@ -0,0 +1,53 @@
+// This file is generated by cargo2android.py --run --device --dependencies --tests.
+
+rust_library {
+ name: "libmatches",
+ // has rustc warnings
+ host_supported: true,
+ crate_name: "matches",
+ srcs: ["lib.rs"],
+ edition: "2015",
+}
+
+rust_defaults {
+ name: "matches_defaults",
+ crate_name: "matches",
+ // has rustc warnings
+ srcs: ["lib.rs"],
+ test_suites: ["general-tests"],
+ auto_gen_config: true,
+ edition: "2015",
+}
+
+rust_test_host {
+ name: "matches_host_test_lib",
+ defaults: ["matches_defaults"],
+}
+
+rust_test {
+ name: "matches_device_test_lib",
+ defaults: ["matches_defaults"],
+}
+
+rust_defaults {
+ name: "matches_defaults_macro_use_one",
+ crate_name: "macro_use_one",
+ // has rustc warnings
+ srcs: ["tests/macro_use_one.rs"],
+ test_suites: ["general-tests"],
+ auto_gen_config: true,
+ edition: "2015",
+ rustlibs: [
+ "libmatches",
+ ],
+}
+
+rust_test_host {
+ name: "matches_host_test_tests_macro_use_one",
+ defaults: ["matches_defaults_macro_use_one"],
+}
+
+rust_test {
+ name: "matches_device_test_tests_macro_use_one",
+ defaults: ["matches_defaults_macro_use_one"],
+}
diff --git a/TEST_MAPPING b/TEST_MAPPING
new file mode 100644
index 0000000..8b581f0
--- /dev/null
+++ b/TEST_MAPPING
@@ -0,0 +1,19 @@
+// Generated by cargo2android.py for tests in Android.bp
+{
+ "presubmit": [
+ {
+ "host": true,
+ "name": "matches_host_test_lib"
+ },
+ {
+ "name": "matches_device_test_lib"
+ },
+ {
+ "host": true,
+ "name": "matches_host_test_tests_macro_use_one"
+ },
+ {
+ "name": "matches_device_test_tests_macro_use_one"
+ }
+ ]
+}