-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
openssl dependency doesn't work #709
Comments
I ran into this problem recently and turns out my |
Yikes, forgot about this over the weekend. Seeng that you're on a Mac, I'd bet the problem is that your computer currently still has the archaic version of openssl that OSX ships with. Try updating openssl. |
The problem is OS X doesn't ship with |
Incidentally, the README of sfackler/rust-openssl states
|
If you're using homebrew, I found that http://stackoverflow.com/a/17231736 fixed this issue for me. |
Sure, but that's just a stopgap. We can't expect everyone to install a new version of OpenSSL into Three possible solutions that come to mind:
|
I am uncomfortable with option 2, particularly because I do not want to be the person on the hook to rush out an updated release with the download link changed to a new version when the next Heartbleed is inevitably found. Common Crypto is part of Hyper's encryption support is already generic through the Once rust-lang/rfcs#1361 lands, it'll be possible to switch SSL backends based on the target in a sane way. |
@sfackler CommonCrypto is provided in Incidentally, while iOS provides basic encryption/decryption using |
Ah thanks |
On Debian you should just install libssl-dev package and it will work, or just update libssl. |
Use:
|
I hit this problem, found this issue, |
Thank you @BProg, that command worked for me on Xubuntu as well. As the referenced rust-lang/rfcs#1361 has already landed and this issue persists at least for now, could I recommend adding these fixes (at least for OSX/Debian-based Linux) directly in a note in the README? It would help beginners like me, who may not know to search through the Issues list. |
Current homebrew (v0.9.9) is refusing to link openssl 😕
I'm failing to compile hyper 0.9.10. Should this be using something different than openssl on macOS or is this still correct? I'd love to get this working somehow. |
You can try using the 'security-framework' feature instead of the 'ssl' On Tue, Aug 9, 2016, 7:19 AM Kilian Koeltzsch [email protected]
|
Sorry to ask, but I'm rather new to using rust... I've added |
hyper = { version = "0.9", default-features = false, features = ["security-framework"] } |
Seems to me that hyper should use the |
@kballard I'm close to publishing https://github.com/sfackler/rust-native-tls which should handle all of that and I believe we'll be able to make the default SSL backend for hyper. |
A workaround to link against openssl (installed with homebrew) is to use a custom .cargo/config:
Anyway, using security-framework seems the way to go. |
Same thing for windows:
|
I just ran into this issue for the first time today (new Hyper user), and @sfackler has provided the best answer. I changed it slightly to use the latest version of hyper from GitHub. Cargo.toml:
|
Compiling openssl v0.7.4
Build failed, waiting for other jobs to finish...
failed to run custom build command for
openssl v0.7.4
Process didn't exit successfully:
/Users/reactor/Projects/r_gifts/target/debug/build/openssl-3ceab475d186eefe/build-script-build
(exit code: 101)--- stdout
TARGET = Some("x86_64-apple-darwin")
OPT_LEVEL = Some("0")
PROFILE = Some("debug")
TARGET = Some("x86_64-apple-darwin")
debug=true opt-level=0
HOST = Some("x86_64-apple-darwin")
TARGET = Some("x86_64-apple-darwin")
TARGET = Some("x86_64-apple-darwin")
HOST = Some("x86_64-apple-darwin")
CC_x86_64-apple-darwin = None
CC_x86_64_apple_darwin = None
HOST_CC = None
CC = None
HOST = Some("x86_64-apple-darwin")
TARGET = Some("x86_64-apple-darwin")
HOST = Some("x86_64-apple-darwin")
CFLAGS_x86_64-apple-darwin = None
CFLAGS_x86_64_apple_darwin = None
HOST_CFLAGS = None
CFLAGS = None
running: "cc" "-O0" "-ffunction-sections" "-fdata-sections" "-g" "-m64" "-fPIC" "-o" "/Users/reactor/Projects/r_gifts/target/debug/build/openssl-3ceab475d186eefe/out/src/c_helpers.o" "-c" "src/c_helpers.c"
ExitStatus(Code(1))
command did not execute successfully, got: exit code: 1
--- stderr
src/c_helpers.c:1:10: fatal error: 'openssl/ssl.h' file not found
include <openssl/ssl.h>
1 error generated.
' panicked at 'explicit panic', /Users/reactor/.cargo/registry/src/github.com-0a35038f75765ae4/gcc-0.3.21/src/lib.rs:772thread '
The text was updated successfully, but these errors were encountered: