Remove `core2` dependency entirely
This commit is contained in:
parent
b7dd16da99
commit
add371d263
|
@ -72,9 +72,6 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "bitcoin-io"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"core2",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "bitcoin_hashes"
|
||||
|
@ -116,15 +113,6 @@ version = "0.1.2"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "d4c819a1287eb618df47cc647173c5c4c66ba19d888a6e50d605672aed3140de"
|
||||
|
||||
[[package]]
|
||||
name = "core2"
|
||||
version = "0.3.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "2cf12d2dad3ed124aa116f59561428478993d69ab81ae4d30e5349c9c5b5a5f6"
|
||||
dependencies = [
|
||||
"memchr",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "dyn-clone"
|
||||
version = "1.0.0"
|
||||
|
@ -153,9 +141,6 @@ name = "hex-conservative"
|
|||
version = "0.1.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "30ed443af458ccb6d81c1e7e661545f94d3176752fb1df2f543b902a1e0f51e2"
|
||||
dependencies = [
|
||||
"core2",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "hex_lit"
|
||||
|
@ -198,12 +183,6 @@ version = "0.2.64"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "74dfca3d9957906e8d1e6a0b641dc9a59848e793f1da2165889fd4f62d10d79c"
|
||||
|
||||
[[package]]
|
||||
name = "memchr"
|
||||
version = "2.0.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "e01e64d9017d18e7fc09d8e4fe0e28ff6931019e979fb8019319db7ca827f8a6"
|
||||
|
||||
[[package]]
|
||||
name = "memmap2"
|
||||
version = "0.5.10"
|
||||
|
|
|
@ -71,9 +71,6 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "bitcoin-io"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"core2",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "bitcoin_hashes"
|
||||
|
@ -115,15 +112,6 @@ version = "1.0.0"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd"
|
||||
|
||||
[[package]]
|
||||
name = "core2"
|
||||
version = "0.3.3"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "239fa3ae9b63c2dc74bd3fa852d4792b8b305ae64eeede946265b6af62f1fff3"
|
||||
dependencies = [
|
||||
"memchr",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "dyn-clone"
|
||||
version = "1.0.11"
|
||||
|
@ -152,9 +140,6 @@ name = "hex-conservative"
|
|||
version = "0.1.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "30ed443af458ccb6d81c1e7e661545f94d3176752fb1df2f543b902a1e0f51e2"
|
||||
dependencies = [
|
||||
"core2",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "hex_lit"
|
||||
|
@ -197,12 +182,6 @@ version = "0.2.142"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "6a987beff54b60ffa6d51982e1aa1146bc42f19bd26be28b0586f252fccf5317"
|
||||
|
||||
[[package]]
|
||||
name = "memchr"
|
||||
version = "2.5.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d"
|
||||
|
||||
[[package]]
|
||||
name = "memmap2"
|
||||
version = "0.5.10"
|
||||
|
|
|
@ -27,7 +27,7 @@ bitcoinconsensus-std = ["bitcoinconsensus/std", "std"]
|
|||
# Instead no-std enables additional features required for this crate to be usable without std.
|
||||
# As a result, both can be enabled without conflict.
|
||||
std = ["secp256k1/std", "bitcoin-io/std", "hashes/std", "bech32/std", "internals/std", "hex/std"]
|
||||
no-std = ["hashes/alloc", "hashes/core2", "bitcoin-io/core2", "bitcoin-io/alloc", "bech32/alloc", "secp256k1/alloc", "hex/alloc", "hex/core2"]
|
||||
no-std = ["hashes/alloc", "hashes/io", "bitcoin-io/alloc", "bech32/alloc", "secp256k1/alloc", "hex/alloc"]
|
||||
|
||||
[package.metadata.docs.rs]
|
||||
all-features = true
|
||||
|
|
|
@ -84,7 +84,7 @@ impl PublicKey {
|
|||
|
||||
reader.read_exact(&mut bytes[1..])?;
|
||||
Self::from_slice(bytes).map_err(|e| {
|
||||
// Need a static string for core2
|
||||
// Need a static string for no-std io
|
||||
#[cfg(feature = "std")]
|
||||
let reason = e;
|
||||
#[cfg(not(feature = "std"))]
|
||||
|
|
|
@ -17,8 +17,6 @@ if cargo --version | grep ${MSRV}; then
|
|||
cargo update -p schemars --precise 0.8.12
|
||||
# schemars_derive 0.8.13 uses edition 2021
|
||||
cargo update -p schemars_derive --precise 0.8.12
|
||||
# memchr 2.6.0 uses edition 2021
|
||||
cargo update -p memchr --precise 2.5.0
|
||||
# byteorder 1.5.0 uses edition 2021
|
||||
cargo update -p byteorder --precise 1.4.3
|
||||
|
||||
|
|
|
@ -17,8 +17,8 @@ default = ["std"]
|
|||
std = ["alloc", "hex/std", "bitcoin-io/std"]
|
||||
alloc = ["hex/alloc"]
|
||||
serde-std = ["serde/std"]
|
||||
# If you want I/O you must enable either "std" or "core2".
|
||||
core2 = ["bitcoin-io/core2", "hex/core2"]
|
||||
# If you want I/O you must enable either "std" or "io".
|
||||
io = ["bitcoin-io"]
|
||||
# Smaller (but slower) implementation of sha256, sha512 and ripemd160
|
||||
small-hash = []
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
set -ex
|
||||
|
||||
FEATURES="serde serde-std std core2 alloc"
|
||||
FEATURES="serde serde-std std io alloc"
|
||||
|
||||
cargo --version
|
||||
rustc --version
|
||||
|
|
|
@ -18,7 +18,7 @@ cortex-m-rt = "0.6.10"
|
|||
cortex-m-semihosting = "0.3.3"
|
||||
panic-halt = "0.2.0"
|
||||
alloc-cortex-m = { version = "0.4.1", optional = true }
|
||||
bitcoin_hashes = { path="../", default-features = false, features = ["core2"] }
|
||||
bitcoin_hashes = { path="../", default-features = false, features = ["io"] }
|
||||
bitcoin-io = { path = "../../io", default_features = false }
|
||||
|
||||
[[bin]]
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
// SPDX-License-Identifier: CC0-1.0
|
||||
|
||||
//! `std` / `core2` Impls.
|
||||
//! `std` / `io` Impls.
|
||||
//!
|
||||
//! Implementations of traits defined in `std` / `core2` and not in `core`.
|
||||
//! Implementations of traits defined in `std` / `io` and not in `core`.
|
||||
//!
|
||||
|
||||
use bitcoin_io::impl_write;
|
||||
|
|
|
@ -15,11 +15,8 @@ exclude = ["tests", "contrib"]
|
|||
[features]
|
||||
default = ["std"]
|
||||
std = []
|
||||
alloc = ["core2/alloc"]
|
||||
alloc = []
|
||||
|
||||
[package.metadata.docs.rs]
|
||||
all-features = true
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
||||
[dependencies]
|
||||
core2 = { version = "0.3", default-features = false, optional = true }
|
||||
|
|
Loading…
Reference in New Issue