Rust declarations for libmagic.
This cargo -sys package provides libmagic
declarations for e.g. the magic
binding.
Usage
magic-sys
is available on crates.io so you can use it like this (in your Cargo.toml
):
[dependencies]
magic-sys = "0.2.0"
The rustdoc
is available on GitHub Pages.
Requirements
libmagic
needs to be installed in a standard location (also see issue #1).
On a Debian based Linux system this can be achieved like this:
sudo apt-get install libmagic1
On RHEL/Cent OS, Gentoo and others you will need to install the file
package.
On Mac OS X you can use Homebrew:
brew install libmagic
Feedback for Windows (issue #2) support is appreciated!
License
Licensed under either of
- Apache License, Version 2.0 (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
at your option.
Contribution
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.