[package]
name = "neptune"
description = "Poseidon hashing over BLS12-381 for Filecoin."
version = "6.2.0"
authors = ["porcuquine <porcuquine@gmail.com>"]
edition = "2018"
license = "MIT OR Apache-2.0"
repository = "https://github.com/filecoin-project/neptune"
resolver = "2"

[dependencies]
lazy_static = "1.4.0"
bellperson = { version = "0.20", default-features = false }
blake2s_simd = "0.5"
blstrs = { version = "0.4.2" }
byteorder = "1"
ec-gpu = { version = "0.1.0", optional = true }
ec-gpu-gen = { version = "0.1.0", optional = true }
ff = "0.11.0"
generic-array = "0.14.4"
itertools = { version = "0.8.0" }
log = "0.4.8"
rust-gpu-tools = { version = "0.5.0", default-features = false, optional = true }

[dev-dependencies]
criterion = "0.3"
rand = "0.8.0"
sha2 = "0.9"
tempdir = "0.3"
rand_xorshift = "0.3.0"
serde_json = "1.0.53"
pasta_curves = "0.2.1"

[build-dependencies]
blstrs = "0.4.2"
ec-gpu = { version = "0.1.0", optional = true }
ec-gpu-gen = { version = "0.1.0", optional = true }
execute = "0.2.9"
hex = "0.4"
sha2 = "0.9"

[[bench]]
name = "hash"
harness = false

[[bench]]
name = "synthesis"
harness = false

[profile.bench]
incremental = false
codegen-units = 1

[features]
default = [ "bellperson/default" ]
cuda = ["rust-gpu-tools/cuda", "blstrs/gpu", "ec-gpu-gen", "ec-gpu"]
opencl = ["rust-gpu-tools/opencl", "blstrs/gpu", "ec-gpu-gen", "ec-gpu"]
# The supported arities for Poseidon running on the GPU are specified at compile-time.
arity2 = []
arity4 = []
arity8 = []
arity11 = []
arity16 = []
arity24 = []
arity36 = []
# With this feature set, also the strengthened version of the kernel will be compiled.
strengthened = []
wasm = [ "bellperson/wasm" ]

[workspace]
members = [
  "gbench",
]
