From c70332d480f39678526ca968f396649973997655 Mon Sep 17 00:00:00 2001 From: Joey Yandle Date: Tue, 6 Aug 2019 13:55:43 -0700 Subject: [PATCH] make rand dependency optional, and select it always when std feature is enabled --- Cargo.toml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 2cb70293..d80357d5 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -17,13 +17,13 @@ subtle = { version = "2", default-features = false } sha3 = { version = "0.8", default-features = false } digest = { version = "0.8", default-features = false } rand_core = { version = "0.4", default-features = false } -rand = { version = "0.6", default-features = false } +rand = { version = "0.6", default-features = false, optional = true } byteorder = { version = "1", default-features = false } serde = { version = "1", default-features = false } serde_derive = { version = "1", default-features = false } failure = { version = "0.1", default-features = false, features = ["derive"] } merlin = { version = "1.2", default-features = false } -clear_on_drop = "0.2" +clear_on_drop = { version = "0.2", default-features = false, features = ["nightly"] } [dev-dependencies] hex = "0.3" @@ -35,7 +35,7 @@ rand_chacha = "0.1" default = ["std", "avx2_backend"] avx2_backend = ["curve25519-dalek/avx2_backend"] yoloproofs = [] -std = ["rand/std", "serde/std", "merlin/std", "curve25519-dalek/std"] +std = ["rand", "rand/std", "serde/std", "merlin/std", "curve25519-dalek/std"] alloc = ["rand_core/alloc", "serde/alloc", "curve25519-dalek/alloc"] [[test]]