Skip to content

Commit

Permalink
Merge pull request #572 from brson/rustls
Browse files Browse the repository at this point in the history
Add preliminary rustls support
  • Loading branch information
brson authored Jul 11, 2016
2 parents 8984d8d + ff66ed4 commit ee7dab8
Show file tree
Hide file tree
Showing 6 changed files with 505 additions and 155 deletions.
41 changes: 41 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 9 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,18 @@ license = "MIT OR Apache-2.0"

build = "build.rs"

[features]

default = ["curl-backend", "hyper-backend"]

curl-backend = ["download/curl-backend"]
hyper-backend = ["download/hyper-backend"]
rustls-backend = ["download/rustls-backend"]

[dependencies]
rustup-dist = { path = "src/rustup-dist", version = "0.2.0" }
rustup-utils = { path = "src/rustup-utils", version = "0.2.0" }
download = { path = "src/download" }
error-chain = "0.2.1"
clap = "2.2.4"
regex = "0.1.41"
Expand Down
16 changes: 9 additions & 7 deletions src/download/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,17 @@ license = "MIT/Apache-2.0"

[features]

default = ["hyper-mode", "curl-mode"]
default = ["hyper-backend"]

curl-mode = ["curl"]
hyper-mode = ["hyper", "native-tls", "openssl-sys"]
curl-backend = ["curl"]
hyper-backend = ["hyper", "native-tls", "openssl-sys"]
rustls-backend = ["hyper", "rustls", "lazy_static"]

[dependencies]
error-chain = "0.2.1"
url = "1.1"

[dependencies.curl]
version = "0.3"
optional = true
curl = { version = "0.3", optional = true }
lazy_static = { version = "0.2", optional = true }

[dependencies.hyper]
version = "0.9.8"
Expand All @@ -33,3 +32,6 @@ optional = true
[target.'cfg(not(any(target_os = "windows", target_os = "macos")))'.dependencies]
openssl-sys = { version = "0.7.11", optional = true }

[dependencies.rustls]
git = "https://github.com/ctz/rustls.git"
optional = true
Loading

0 comments on commit ee7dab8

Please sign in to comment.