Skip to content

JeffBelgum/rust-snappy

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

54 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Snappy

Build Status

[ Originally forked from https://github.com/thestinger/rust-snappy ]

Documentation

Usage

Add this to your Cargo.toml:

[dependencies]
snappy = "0.4"

and this to your crate root:

extern crate snappy;

Installing Snappy

  • The Snappy C++ library can be installed on Mac OS X using homebrew brew install snappy.
  • If that library is not installed in the usual path, you can export the LD_LIBRARY_PATH and LD_RUN_PATH environment variables before issueing cargo build.
  • Static linking can be requested by an export SNAPPY_SYS_STATIC=1 prior to cargo build.
  • As a fallback, this crate will try to compile the Snappy C++ library itself and statically link against it. (This behavior can be enforced by an export SNAPPY_SYS_STATIC_FROM_SOURCE=1 prior to cargo build.)

Building

The Snappy C++ library is also optionally bundled as a submodule. A

git submodule update --init

will fetch a copy of the library for local compilation. This can will then be used if the c++ library cannot be found on your system or if SNAPPY_SYS_STATIC_FROM_SOURCE is set to 1.

About

Snappy bindings for Rust

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Rust 100.0%