2020-04-15 08:20:24 +08:00
if ( EXISTS "${CURRENT_INSTALLED_DIR}/include/openssl/ssl.h" )
2020-08-19 07:41:19 +08:00
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" )
2020-04-15 08:20:24 +08:00
endif ( )
vcpkg_find_acquire_program ( PERL )
2023-09-29 14:21:24 +08:00
get_filename_component ( PERL_EXE_PATH "${PERL}" DIRECTORY )
vcpkg_add_to_path ( "${PERL_EXE_PATH}" )
2020-04-15 08:20:24 +08:00
vcpkg_find_acquire_program ( NASM )
2023-09-29 14:21:24 +08:00
get_filename_component ( NASM_EXE_PATH "${NASM}" DIRECTORY )
vcpkg_add_to_path ( "${NASM_EXE_PATH}" )
2020-04-15 08:20:24 +08:00
vcpkg_find_acquire_program ( GO )
2023-09-29 14:21:24 +08:00
get_filename_component ( GO_EXE_PATH "${GO}" DIRECTORY )
vcpkg_add_to_path ( "${GO_EXE_PATH}" )
2020-04-15 08:20:24 +08:00
vcpkg_from_github (
O U T _ S O U R C E _ P A T H S O U R C E _ P A T H
R E P O g o o g l e / b o r i n g s s l
2024-10-03 22:56:14 +08:00
R E F 0 . 2 0 2 4 0 9 1 3 . 0
S H A 5 1 2 b f b 3 6 d 7 d 0 a 9 0 b b e d e 3 f 7 7 9 6 7 5 2 5 c d 9 3 7 7 e 7 4 8 8 1 1 4 c 3 d 0 f b 5 7 6 0 1 5 d 0 3 6 1 e 7 f 4 4 6 0 8 0 1 a a b 8 e f 8 a 4 7 0 9 0 8 5 4 1 b c 9 d 7 f 7 6 c d b d d 8 2 3 a f 4 f d 6 a a e b b 4 c a c 7 1 1 e e 5 b 5 b 9 f a
2020-04-15 08:20:24 +08:00
H E A D _ R E F m a s t e r
P A T C H E S
2023-09-29 14:21:24 +08:00
0 0 0 1 - s t a t i c - g t e s t . p a t c h
2022-06-03 03:55:46 +08:00
0 0 0 2 - r e m o v e - W X - W e r r o r . p a t c h
2023-09-29 14:21:24 +08:00
0 0 0 3 - f i x - s h a r e d - s y m b o l - v i s i b i l i t y . p a t c h
2020-04-15 08:20:24 +08:00
)
2023-10-14 02:06:57 +08:00
if ( VCPKG_TARGET_IS_WINDOWS )
# the FindOpenSSL.cmake script differentiates debug and release binaries using this suffix.
set ( CMAKE_CONFIGURE_OPTIONS_DEBUG "-DCMAKE_DEBUG_POSTFIX=d" )
endif ( )
2022-06-03 03:55:46 +08:00
vcpkg_cmake_configure (
S O U R C E _ P A T H " $ { S O U R C E _ P A T H } "
2020-04-15 08:20:24 +08:00
O P T I O N S _ D E B U G
2023-10-14 02:06:57 +08:00
$ { C M A K E _ C O N F I G U R E _ O P T I O N S _ D E B U G }
2020-04-15 08:20:24 +08:00
)
2022-06-03 03:55:46 +08:00
vcpkg_cmake_install ( )
2023-05-18 00:21:23 +08:00
vcpkg_copy_pdbs ( )
2023-09-29 14:21:24 +08:00
vcpkg_cmake_config_fixup ( PACKAGE_NAME OpenSSL CONFIG_PATH lib/cmake/OpenSSL )
2020-04-15 08:20:24 +08:00
2023-09-29 14:21:24 +08:00
file ( REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include" )
vcpkg_copy_tools ( TOOL_NAMES bssl AUTO_CLEAN )
if ( VCPKG_LIBRARY_LINKAGE STREQUAL "static" )
file ( REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/bin" "${CURRENT_PACKAGES_DIR}/debug/bin" )
2020-04-15 08:20:24 +08:00
endif ( )
2023-09-29 14:21:24 +08:00
include ( "${CMAKE_CURRENT_LIST_DIR}/install-pc-files.cmake" )
2023-05-18 00:21:23 +08:00
file ( INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" )
vcpkg_install_copyright ( FILE_LIST "${SOURCE_PATH}/LICENSE" )