]> git.lizzy.rs Git - rust.git/blobdiff - src/libstd/sys/sgx/alloc.rs
SGX target: fix std unit tests
[rust.git] / src / libstd / sys / sgx / alloc.rs
index 94dc8ec25b5872e5f9339c0c6260388740944b02..98eb8397436bfeb98b06852cea90c6e541c5e5ed 100644 (file)
@@ -4,6 +4,8 @@
 
 // Using a SpinMutex because we never want to exit the enclave waiting for the
 // allocator.
+#[cfg_attr(test, linkage = "available_externally")]
+#[export_name = "_ZN16__rust_internals3std3sys3sgx5alloc8DLMALLOCE"]
 static DLMALLOC: SpinMutex<dlmalloc::Dlmalloc> = SpinMutex::new(dlmalloc::DLMALLOC_INIT);
 
 #[stable(feature = "alloc_system_type", since = "1.28.0")]