aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthew Maurer <mmaurer@google.com>2020-07-07 00:50:55 +0000
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2020-07-07 00:50:55 +0000
commit4461f68aaa83d27da9191ce0a4e00362fd654f48 (patch)
tree26f0a39254daeac4c3d03755d3a5f56af3542551
parent3c0300f24692e3c78c6243d55e833f1f7faec434 (diff)
parentd66686cb99df3456a73c7de29b03fcd4e91e1a69 (diff)
downloadpaste-4461f68aaa83d27da9191ce0a4e00362fd654f48.tar.gz
Support building all variants. am: 24ff8fb0ac am: d66686cb99
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/paste/+/1356130 Change-Id: I443bd71896430a727ea40d9d660627e794747ecd
-rw-r--r--Android.bp2
-rw-r--r--src/lib.rs3
2 files changed, 4 insertions, 1 deletions
diff --git a/Android.bp b/Android.bp
index 0c81aad..94c8998 100644
--- a/Android.bp
+++ b/Android.bp
@@ -1,6 +1,6 @@
// This file is generated by cargo2android.py --run --device.
-rust_library_rlib {
+rust_library {
name: "libpaste",
host_supported: true,
crate_name: "paste",
diff --git a/src/lib.rs b/src/lib.rs
index 9cb79d9..ab5806a 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -137,6 +137,9 @@
#![no_std]
+// ANDROID: Use std to allow building as a dylib.
+extern crate std;
+
use proc_macro_hack::proc_macro_hack;
/// Paste identifiers within a macro invocation that expands to an expression.