Skip to content

Commit 4c3dc15

Browse files
committed
Make cdylib crate type optional
1 parent 9c727a9 commit 4c3dc15

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

rustls-platform-verifier/Cargo.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,15 @@ rust-version = "1.71.0"
1111

1212
[lib]
1313
name = "rustls_platform_verifier"
14-
# Note: The `cdylib` specification is for testing only. The shared library
15-
# is not expected to have a stable API.
16-
crate-type = ["cdylib", "rlib"]
1714

1815
[features]
16+
# Note: The `cdylib` specification is for testing only. The shared library
17+
# is not expected to have a stable API.
18+
cdylib = []
1919
# Enables a C interface to use for testing where `cargo` can't be used.
2020
# This feature is not stable, nor is the interface exported when it is enabled.
2121
# Do not rely on this or use it in production.
22-
ffi-testing = ["android_logger", "rustls/ring"]
22+
ffi-testing = ["cdylib", "android_logger", "rustls/ring"]
2323
# Enables APIs that expose lower-level verifier types for debugging purposes.
2424
dbg = []
2525
# Enables `log::debug` base64-encoded logging of all end-entity certificates processed

rustls-platform-verifier/src/lib.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
#![doc = include_str!("../README.md")]
33
#![warn(missing_docs)]
44

5+
#![cfg_attr(feature = "cdylib", crate_type = "cdylib")]
6+
57
use std::sync::Arc;
68

79
#[cfg(feature = "dbg")]

0 commit comments

Comments
 (0)