-
Notifications
You must be signed in to change notification settings - Fork 257
Make boringssl-src optional #537
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -172,7 +172,13 @@ fn build_grpc(cc: &mut cc::Build, library: &str) { | |
config.define("gRPC_BUILD_CODEGEN", "false"); | ||
// We don't need to build benchmarks. | ||
config.define("gRPC_BENCHMARK_PROVIDER", "none"); | ||
config.define("gRPC_SSL_PROVIDER", "package"); | ||
|
||
// `package` should only be set for secure feature, otherwise cmake will always search for | ||
// ssl library. | ||
if cfg!(feature = "secure") { | ||
config.define("gRPC_SSL_PROVIDER", "package"); | ||
} | ||
Comment on lines
+178
to
+180
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. why not just define the cmake config regardless of the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @hug-dev can you add a comment here? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I did that to fix a failing test on Mac OS, after your recommendation.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. How about
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Done! |
||
#[cfg(feature = "secure")] | ||
if cfg!(feature = "openssl") { | ||
if cfg!(feature = "openssl-vendored") { | ||
config.register_dep("openssl"); | ||
|
@@ -254,6 +260,7 @@ fn figure_ssl_path(build_dir: &str) { | |
println!("cargo:rustc-link-lib=crypto"); | ||
} | ||
|
||
#[cfg(feature = "secure")] | ||
fn build_boringssl(config: &mut CmakeConfig) { | ||
let boringssl_artifact = boringssl_src::Build::new().build(); | ||
config.define( | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Was about to comment about that :D With nothing there, there was an error that
-A deref-nullptr
was not recognised byrustc
, with only--deny=warnings
the errors were still showing. Not sure whyThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess maybe l102 overwrites L11.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, I thought that as well, that putting an empty string here would empty the
RUSTFLAGS
defined before. It still failed but that seems to be for another reason?