Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release candidate v0.3 #20

Merged
merged 5 commits into from
Oct 22, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 17 additions & 10 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,18 +1,20 @@
[package]

name = "magic-sys"
description = "Declarations for `libmagic`"
readme = "README.md"
description = "Declarations for the `libmagic` C library"
keywords = [
"magic",
"file",
"ffi",
"bindings",
]
categories = [
"external-ffi-bindings",
]
repository = "https://github.com/robo9k/rust-magic-sys.git"
license = "MIT/Apache-2.0"
version = "0.2.1"
authors = ["robo9k <robo@9k.lv>"]
version = "0.3.0-alpha.1"
authors = ["robo9k <robo9k@symlink.io>"]
links = "magic"
build = "build.rs"
exclude = [
".gitignore",
".gitattributes",
Expand All @@ -21,9 +23,13 @@ exclude = [
"rust-toolchain.toml",
"shell.nix",
"nix/",
"deny.toml",
]
rust-version = "1.38"

[badges]
maintenance = { status = "passively-maintained" }

[features]
default = ["v5-38"]
v5-04 = []
Expand All @@ -41,9 +47,6 @@ v5-35 = ["v5-32"]
v5-38 = ["v5-35"]
v5-40 = ["v5-38"]

[dependencies]
libc = "0.2.13"

[build-dependencies]
vcpkg = "0.2.15"

Expand All @@ -52,8 +55,12 @@ git = "https://github.com/microsoft/vcpkg"
rev = "078f3e5"
dependencies = ["libmagic"]

[dependencies.libc]
version = "0.2.104"
default-features = false

[package.metadata.vcpkg.target]
x86_64-pc-windows-msvc = { triplet="x64-windows-static-md" }
x86_64-pc-windows-msvc = { triplet = "x64-windows-static-md" }

[package.metadata]
msrv = "1.38.0"
Expand Down
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
rust-magic-sys [![linux build status](https://github.com/robo9k/rust-magic-sys/actions/workflows/linux.yml/badge.svg)](https://github.com/robo9k/rust-magic-sys/actions/workflows/linux.yml) [![windows build status](https://github.com/robo9k/rust-magic-sys/actions/workflows/windows.yml/badge.svg)](https://github.com/robo9k/rust-magic-sys/actions/workflows/windows.yml) [![mac build status](https://github.com/robo9k/rust-magic-sys/actions/workflows/mac.yml/badge.svg)](https://github.com/robo9k/rust-magic-sys/actions/workflows/mac.yml)
==============

[Rust](http://www.rust-lang.org/) declarations for [libmagic](http://darwinsys.com/file/).
[Rust](https://www.rust-lang.org/f) declarations for [libmagic](https://www.darwinsys.com/file/).

---

This [cargo -sys package](http://doc.crates.io/build-script.html#*-sys-packages) provides `libmagic` declarations for e.g. the [`magic` binding](https://github.com/robo9k/rust-magic).
This [cargo -sys package](https://doc.rust-lang.org/cargo/reference/build-scripts.html) provides `libmagic` declarations for e.g. the [`magic` binding](https://crates.io/crates/magic).


# Usage
Expand All @@ -14,7 +14,7 @@ This [cargo -sys package](http://doc.crates.io/build-script.html#*-sys-packages)

```toml
[dependencies]
magic-sys = "0.2.0"
magic-sys = "0.3"
```

The `rustdoc` is available on [docs.rs](https://docs.rs/magic-sys).
Expand All @@ -28,7 +28,7 @@ Each API version has a crate feature like "v5-38" (v5.38 is also the default), s
If you use a different version of `libmagic`, adjust your configuration:
```toml
[dependencies.magic-sys]
version = "0.2.1"
version = "0.3"
default-features = false
features = ["v5-41"]
```
Expand All @@ -44,7 +44,7 @@ sudo apt-get install libmagic1 libmagic-dev
On RHEL/Cent OS, Gentoo and others you will need to install the `file` package.


On Mac OS X you can use [Homebrew](http://brew.sh/):
On Mac OS X you can use [Homebrew](https://brew.sh/):
```sh
brew install libmagic
```
Expand Down Expand Up @@ -87,8 +87,8 @@ If you do not use `cargo vcpkg build`, you will have to either
# License

Licensed under either of
* Apache License, Version 2.0 ([LICENSE-APACHE](LICENSE-APACHE) or http://www.apache.org/licenses/LICENSE-2.0)
* MIT license ([LICENSE-MIT](LICENSE-MIT) or http://opensource.org/licenses/MIT)
* Apache License, Version 2.0 ([LICENSE-APACHE](LICENSE-APACHE) or https://www.apache.org/licenses/LICENSE-2.0)
* MIT license ([LICENSE-MIT](LICENSE-MIT) or https://opensource.org/licenses/MIT)

at your option.

Expand Down