early-access version 2853

This commit is contained in:
pineappleEA
2022-07-23 03:01:36 +02:00
parent 1f2b5081b5
commit 1f111bb69c
8955 changed files with 418777 additions and 999 deletions

View File

@@ -0,0 +1,32 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 893bca7..83ff477 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -562,7 +562,7 @@ endif()
# Add minimal googletest targets. The provided one has many side-effects, and
# googletest has a very straightforward build.
-add_library(boringssl_gtest third_party/googletest/src/gtest-all.cc)
+add_library(boringssl_gtest STATIC third_party/googletest/src/gtest-all.cc)
target_include_directories(boringssl_gtest PRIVATE third_party/googletest)
include_directories(third_party/googletest/include)
@@ -649,3 +649,18 @@ add_custom_target(
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
DEPENDS all_tests bssl_shim handshaker fips_specific_tests_if_any
USES_TERMINAL)
+
+install(TARGETS crypto ssl
+ RUNTIME DESTINATION bin
+ LIBRARY DESTINATION lib
+ ARCHIVE DESTINATION lib)
+
+option(INSTALL_HEADERS "Install headers" ON)
+if(INSTALL_HEADERS)
+ install(DIRECTORY include/ DESTINATION include)
+endif()
+
+option(INSTALL_TOOLS "Install bssl executable" OFF)
+if(INSTALL_TOOLS)
+ install(TARGETS bssl DESTINATION tools/boringssl)
+endif()

View File

@@ -0,0 +1,24 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 83ff477..3008c2a 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -117,7 +117,7 @@ endif()
if(CMAKE_COMPILER_IS_GNUCXX OR CLANG)
# Note clang-cl is odd and sets both CLANG and MSVC. We base our configuration
# primarily on our normal Clang one.
- set(C_CXX_FLAGS "-Werror -Wformat=2 -Wsign-compare -Wmissing-field-initializers -Wwrite-strings -Wvla")
+ set(C_CXX_FLAGS "-Wformat=2 -Wsign-compare -Wmissing-field-initializers -Wwrite-strings -Wvla")
if(MSVC)
# clang-cl sets different default warnings than clang. It also treats -Wall
# as -Weverything, to match MSVC. Instead -W3 is the alias for -Wall.
@@ -238,8 +238,8 @@ elseif(MSVC)
${MSVC_DISABLED_WARNINGS_LIST})
string(REPLACE "C" " -w4" MSVC_LEVEL4_WARNINGS_STR
${MSVC_LEVEL4_WARNINGS_LIST})
- set(CMAKE_C_FLAGS "-utf-8 -Wall -WX ${MSVC_DISABLED_WARNINGS_STR} ${MSVC_LEVEL4_WARNINGS_STR}")
- set(CMAKE_CXX_FLAGS "-utf-8 -Wall -WX ${MSVC_DISABLED_WARNINGS_STR} ${MSVC_LEVEL4_WARNINGS_STR}")
+ set(CMAKE_C_FLAGS "-utf-8 -Wall ${MSVC_DISABLED_WARNINGS_STR} ${MSVC_LEVEL4_WARNINGS_STR}")
+ set(CMAKE_CXX_FLAGS "-utf-8 -Wall ${MSVC_DISABLED_WARNINGS_STR} ${MSVC_LEVEL4_WARNINGS_STR}")
endif()
if(WIN32)

View File

@@ -0,0 +1,48 @@
if(EXISTS "${CURRENT_INSTALLED_DIR}/include/openssl/ssl.h")
message(FATAL_ERROR "Can't build BoringSSL if OpenSSL is installed. Please remove OpenSSL, and try to install BoringSSL again if you need it. Build will continue since BoringSSL is a drop-in replacement for OpenSSL")
endif()
vcpkg_find_acquire_program(PERL)
get_filename_component(PERL_EXE_PATH ${PERL} DIRECTORY)
vcpkg_add_to_path(${PERL_EXE_PATH})
vcpkg_find_acquire_program(NASM)
get_filename_component(NASM_EXE_PATH ${NASM} DIRECTORY)
vcpkg_add_to_path(${NASM_EXE_PATH})
vcpkg_find_acquire_program(GO)
get_filename_component(GO_EXE_PATH ${GO} DIRECTORY)
vcpkg_add_to_path(${GO_EXE_PATH})
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
FEATURES
tools INSTALL_TOOLS
)
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO google/boringssl
REF 479adf98d54a21c1d154aac59b2ce120e1d1a6d6
SHA512 74b5d001c0f5c1846b8818e9e668fa35de5171fc21a8f713d241f57b3e8abe42426fdc66b085cca1853b904def6f4bea573dfed40b8b1422894cca85b0b1a44a
HEAD_REF master
PATCHES
0001-vcpkg.patch
0002-remove-WX-Werror.patch
)
vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
OPTIONS
${FEATURE_OPTIONS}
OPTIONS_DEBUG
-DINSTALL_HEADERS=OFF
-DINSTALL_TOOLS=OFF
)
vcpkg_cmake_install()
if(IS_DIRECTORY ${CURRENT_PACKAGES_DIR}/tools/boringssl)
vcpkg_copy_tool_dependencies("${CURRENT_PACKAGES_DIR}/tools/boringssl")
endif()
file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)

19
externals/vcpkg/ports/boringssl/vcpkg.json vendored Executable file
View File

@@ -0,0 +1,19 @@
{
"name": "boringssl",
"version-date": "2021-06-23",
"port-version": 2,
"description": "BoringSSl is a fork of OpenSSL developed by Google",
"homepage": "https://boringssl.googlesource.com/boringssl",
"supports": "!uwp",
"dependencies": [
{
"name": "vcpkg-cmake",
"host": true
}
],
"features": {
"tools": {
"description": "Build bssl executable"
}
}
}