Skip to content

Fix Windows boringssl build by disabling warning 4191. #956

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

Merged
merged 5 commits into from
May 13, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion cmake/external/boringssl.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ if(TARGET boringssl OR NOT DOWNLOAD_BORINGSSL)
endif()

set(patch_file
${CMAKE_CURRENT_LIST_DIR}/../../scripts/git/patches/boringssl/0001-disable-C4255-converting-empty-params-to-void.patch)
${CMAKE_CURRENT_LIST_DIR}/../../scripts/git/patches/boringssl/0001-disable-warnings.patch)

set(boringssl_commit_tag 83da28a68f32023fd3b95a8ae94991a07b1f6c62)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,25 +1,13 @@
From 831806231dd360278dac2a37e3c3158420ad7bb3 Mon Sep 17 00:00:00 2001
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With the patch hand-edited, I had to remove the Git-specific stuff from it and make it a normal patch file.

From: "google.com" <google.com>
Date: Mon, 7 Jun 2021 13:57:27 -0400
Subject: [PATCH] disable C4255 converting () to (void)

---
src/CMakeLists.txt | 2 ++
1 file changed, 2 insertions(+)

diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index b7f468fe6..48f61bfd8 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -193,6 +193,8 @@ elseif(MSVC)
@@ -193,6 +193,10 @@ elseif(MSVC)
# possible loss of data
"C4244" # 'function' : conversion from 'int' to 'uint8_t',
# possible loss of data
+ "C4255" # 'function' : no function prototype given: converting '()' to
+ # '(void)'
+ "C4191" # 'operator/operation' : unsafe conversion from 'type of
+ # expression' to 'type required'
"C4267" # conversion from 'size_t' to 'int', possible loss of data
"C4371" # layout of class may have changed from a previous version of the
# compiler due to better packing of member '...'
--
2.32.0.rc1.229.g3e70b5a671-goog