Skip to content

Commit e6a82fa

Browse files
authored
Merge pull request #204 from ordian/master
secp256k1-sys: remove restriction on cc version
2 parents 0782872 + b22b9e5 commit e6a82fa

File tree

3 files changed

+18
-1
lines changed

3 files changed

+18
-1
lines changed

.travis.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@ matrix:
2626
os: windows
2727

2828
script:
29+
- if [ "$TRAVIS_RUST_VERSION" == "1.22.0" ]; then
30+
cargo generate-lockfile --verbose && cargo update -p cc --precise "1.0.41" --verbose;
31+
fi
2932
- cargo build --verbose --no-default-features
3033
- cargo build --verbose --no-default-features --features="serde"
3134
- cargo build --verbose --no-default-features --features="lowmemory"

README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,17 @@ Contributions to this library are welcome. A few guidelines:
2121
* No new dependencies, please.
2222
* No crypto should be implemented in Rust, with the possible exception of hash functions. Cryptographic contributions should be directed upstream to libsecp256k1.
2323
* This library should always compile with any combination of features on **Rust 1.22**.
24+
25+
## A note on Rust 1.22 support
26+
27+
The build dependency `cc` might require a more recent version of the Rust compiler.
28+
To ensure compilation with Rust 1.22.0, pin its version in your `Cargo.lock`
29+
with `cargo update -p cc --precise 1.0.41`. If you're using `secp256k1` in a library,
30+
to make sure it compiles in CI, you'll need to generate a lockfile first.
31+
Example for Travis CI:
32+
```yml
33+
before_script:
34+
- if [ "$TRAVIS_RUST_VERSION" == "1.22.0" ]; then
35+
cargo generate-lockfile --verbose && cargo update -p cc --precise "1.0.41" --verbose;
36+
fi
37+
```

secp256k1-sys/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ links = "rustsecp256k1_v0_1_1"
1919
features = [ "recovery", "endomorphism", "lowmemory" ]
2020

2121
[build-dependencies]
22-
cc = ">= 1.0.28, <= 1.0.41"
22+
cc = "1.0.28"
2323

2424
[lib]
2525
name = "secp256k1_sys"

0 commit comments

Comments
 (0)