Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
rust-gcrypt
Libgcrypt bindings for Rust.
Version 1.5.0 or greater of libgcrypt is required to use this wrapper. Some features may require a more recent version.
The libgcrypt-sys crate will attempt to find the library by parsing the output
of libgcrypt-config
. The path to the library and its header files can also be
configured by setting the environment variables LIBGCRYPT_LIB
and
LIBGCRYPT_INCLUDE_DIR
before building the crate. A working installation of
gcc is also required.
The required libraries and binaries can be installed by running:
Debian / Ubuntu
$ sudo apt-get install libgcrypt11-dev
or
$ sudo apt-get install libgcrypt20-dev
RHEL / CentOS / Fedora
$ sudo yum install libgcrypt-devel
Mac OS X
$ brew install libgcrypt
Usage
Put this in your Cargo.toml
:
[]
= "0.2"
And this in your crate root:
extern crate gcrypt;
The library requires initialization before first use. The functions init
and
init_fips
can be used to initialize the library. The closure passed to these
functions is used to configure the library. More information on configuration
options can be found in the libgcrypt
documentation.
An example:
let token = init;
Calling any function in the wrapper that requires initialization before init
or init_fips
are called will cause the wrapper to attempt to initialize the
library with a default configuration.