Skip to content

Commit

Permalink
Cargo bug workaround
Browse files Browse the repository at this point in the history
Using `cargo vendor` with `zstd-sys` does not copy the `zstd` directory,
due to a bug in Cargo: rust-lang/cargo#9555

This commit replaces the "exclude" field with a negation, which
causes an issue with current version of Cargo, by an equivalent
"include" field.
  • Loading branch information
olivierlemasle committed Jun 7, 2021
1 parent 3636f9e commit add97e3
Showing 1 changed file with 17 additions and 6 deletions.
23 changes: 17 additions & 6 deletions zstd-safe/zstd-sys/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,24 @@ repository = "https://github.com/gyscos/zstd-rs"
version = "1.6.0+zstd.1.5.0"
edition = "2018"

exclude = [
"zstd",
"!zstd/LICENSE",
"!zstd/COPYING",
"!zstd/lib/**/**.h",
"!zstd/lib/**/**.c",
# Use include instead of exclude, as a (temporary)
# workaround for https://github.com/rust-lang/cargo/issues/9555
include = [
"/LICENSE",
"/*.*",
"/src/",
"/zstd/LICENSE",
"/zstd/COPYING",
"/zstd/lib/**/*.c",
"/zstd/lib/**/*.h",
]
# exclude = [
# "zstd",
# "!zstd/LICENSE",
# "!zstd/COPYING",
# "!zstd/lib/**/**.h",
# "!zstd/lib/**/**.c",
# ]

[package.metadata.docs.rs]
features = ["experimental"]
Expand Down

0 comments on commit add97e3

Please sign in to comment.