aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Walbran <qwandor@google.com>2023-12-06 17:16:55 +0000
committerAndrew Walbran <qwandor@google.com>2023-12-06 17:16:55 +0000
commitf41a4d0d53fa7925dc244df8d4ad78498ead3d24 (patch)
tree9c58ecc53b7de4e2c2f00abebc37fbd7a2ed8a29
parent3dd3db72533c687e927cb7a7eaaec93a1a253ee3 (diff)
downloadprotobuf-codegen-f41a4d0d53fa7925dc244df8d4ad78498ead3d24.tar.gz
Migrate to cargo_embargo.
Bug: 293289578 Test: Ran cargo_embargo, compared Android.bp Change-Id: I49819967c7a2e3e7a701209e7e35f65e5dc39c9b
-rw-r--r--2.27.1/Android.bp16
-rw-r--r--2.27.1/cargo2android.json9
-rw-r--r--2.27.1/cargo_embargo.json18
3 files changed, 22 insertions, 21 deletions
diff --git a/2.27.1/Android.bp b/2.27.1/Android.bp
index e705500..1466182 100644
--- a/2.27.1/Android.bp
+++ b/2.27.1/Android.bp
@@ -1,4 +1,4 @@
-// This file is generated by cargo2android.py --config cargo2android.json.
+// This file is generated by cargo_embargo.
// Do not modify this file as changes will be overridden on upgrade.
package {
@@ -27,11 +27,7 @@ rust_library_host {
cargo_pkg_version: "2.27.1",
srcs: ["src/lib.rs"],
edition: "2015",
- rustlibs: [
- "libprotobuf_deprecated",
- ],
- product_available: true,
- vendor_available: true,
+ rustlibs: ["libprotobuf_deprecated"],
}
rust_test_host {
@@ -46,9 +42,7 @@ rust_test_host {
unit_test: true,
},
edition: "2015",
- rustlibs: [
- "libprotobuf_deprecated",
- ],
+ rustlibs: ["libprotobuf_deprecated"],
}
rust_binary_host {
@@ -59,9 +53,7 @@ rust_binary_host {
srcs: ["src/bin/protoc-gen-rust.rs"],
edition: "2015",
rustlibs: [
- "libprotobuf_deprecated",
"libprotobuf_codegen_deprecated",
+ "libprotobuf_deprecated",
],
- product_available: true,
- vendor_available: true,
}
diff --git a/2.27.1/cargo2android.json b/2.27.1/cargo2android.json
deleted file mode 100644
index de731c4..0000000
--- a/2.27.1/cargo2android.json
+++ /dev/null
@@ -1,9 +0,0 @@
-{
- "run": true,
- "tests": true,
- "name-suffix": "_deprecated",
- "dep-suffixes": {
- "protobuf": "_deprecated",
- "protobuf_codegen": "_deprecated"
- }
-}
diff --git a/2.27.1/cargo_embargo.json b/2.27.1/cargo_embargo.json
new file mode 100644
index 0000000..14de05c
--- /dev/null
+++ b/2.27.1/cargo_embargo.json
@@ -0,0 +1,18 @@
+{
+ "module_blocklist": [
+ "protobuf_bin_gen_rust_do_not_use"
+ ],
+ "module_name_overrides": {
+ "libprotobuf": "libprotobuf_deprecated",
+ "libprotobuf_codegen": "libprotobuf_codegen_deprecated",
+ "protobuf-codegen_test_src_lib": "protobuf-codegen_deprecated_test_src_lib",
+ "protoc_gen_rust": "protoc-gen-rust-deprecated"
+ },
+ "package": {
+ "protobuf-codegen": {
+ "device_supported": false
+ }
+ },
+ "run_cargo": false,
+ "tests": true
+}