1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
|
[package]
name = "rand"
version = "0.6.4"
authors = ["The Rand Project Developers", "The Rust Project Developers"]
license = "MIT/Apache-2.0"
readme = "README.md"
repository = "https://github.com/rust-random/rand"
documentation = "https://rust-random.github.io/rand"
homepage = "https://crates.io/crates/rand"
description = """
Random number generators and other randomness functionality.
"""
keywords = ["random", "rng"]
categories = ["algorithms", "no-std"]
build = "build.rs"
exclude = ["/utils/*", "/.travis.yml", "/appveyor.yml", ".gitignore"]
[badges]
travis-ci = { repository = "rust-random/rand" }
appveyor = { repository = "rust-random/rand" }
[features]
default = ["std", "rand_os"] # without "std" rand uses libcore
nightly = ["simd_support"] # enables all features requiring nightly rust
std = ["rand_core/std", "alloc", "rand_os"]
alloc = ["rand_core/alloc"] # enables Vec and Box support (without std)
i128_support = [] # enables i128 and u128 support
simd_support = ["packed_simd"] # enables SIMD support
serde1 = ["rand_core/serde1", "rand_isaac/serde1", "rand_xorshift/serde1"] # enables serialization for PRNGs
# re-export optional WASM dependencies to avoid breakage:
wasm-bindgen = ["rand_os/wasm-bindgen"]
stdweb = ["rand_os/stdweb"]
[workspace]
members = [
"rand_core",
"rand_os",
"rand_isaac",
"rand_chacha",
"rand_hc",
"rand_pcg",
"rand_xorshift",
"rand_xoshiro",
]
[dependencies]
rand_core = { path = "rand_core", version = "0.3", default-features = false }
rand_pcg = { path = "rand_pcg", version = "0.1" }
rand_os = { path = "rand_os", version = "0.1", optional = true }
# only for deprecations and benches:
rand_isaac = { path = "rand_isaac", version = "0.1" }
rand_chacha = { path = "rand_chacha", version = "0.1" }
rand_hc = { path = "rand_hc", version = "0.1" }
rand_xorshift = { path = "rand_xorshift", version = "0.1" }
log = { version = "0.4", optional = true }
[dependencies.packed_simd]
# NOTE: so far no version works reliably due to dependence on unstable features
version = "0.3"
# git = "https://github.com/rust-lang-nursery/packed_simd"
optional = true
features = ["into_bits"]
[target.'cfg(unix)'.dependencies]
libc = { version = "0.2", default-features = false }
# TODO: check if all features are required
[target.'cfg(windows)'.dependencies]
winapi = { version = "0.3", features = ["minwindef", "ntsecapi", "profileapi", "winnt"] }
[dev-dependencies]
# This has a histogram implementation used for testing uniformity.
average = "0.9.2"
# Only for benches:
rand_xoshiro = { path = "rand_xoshiro", version = "0.1" }
[build-dependencies]
autocfg = "0.1"
[package.metadata.docs.rs]
all-features = true
[patch.crates-io]
rand_core = { path = "rand_core", version = "0.3", default-features = false }
|