2022-11-01 18:58:59 -07:00
vcpkg_minimum_required ( VERSION 2022-10-12 ) # for ${VERSION}
2022-04-06 20:04:46 +02:00
if ( EXISTS "${CURRENT_INSTALLED_DIR}/share/libressl/copyright"
O R E X I S T S " $ { C U R R E N T _ I N S T A L L E D _ D I R } / s h a r e / b o r i n g s s l / c o p y r i g h t " )
2022-01-07 10:22:37 -08:00
message ( FATAL_ERROR "Can't build openssl if libressl/boringssl is installed. Please remove libressl/boringssl, and try install openssl again if you need it." )
2020-11-04 07:59:02 +01:00
endif ( )
2022-04-07 16:48:06 +02:00
if ( VCPKG_TARGET_IS_LINUX )
message ( WARNING
[ [ o p e n s s l c u r r e n t l y r e q u i r e s t h e f o l l o w i n g l i b r a r y f r o m t h e s y s t e m p a c k a g e m a n a g e r :
l i n u x - h e a d e r s
I t c a n b e i n s t a l l e d o n a l p i n e s y s t e m s v i a a p k a d d l i n u x - h e a d e r s . ] ]
)
endif ( )
2022-06-29 21:38:17 +00: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 o p e n s s l / o p e n s s l
2022-11-11 23:12:15 +01:00
R E F " o p e n s s l - $ { V E R S I O N } "
2023-02-10 21:14:37 +02:00
S H A 5 1 2 5 a 8 2 1 a a a a a 8 9 0 2 7 c e 0 8 a 3 4 7 e 5 f c 2 1 6 7 5 7 c 2 9 7 1 e 2 9 f 7 d 2 4 7 9 2 6 0 9 3 7 8 c 5 4 f 6 5 7 8 3 9 b 3 7 7 5 b f 6 3 9 e 7 3 3 0 b 2 8 b 4 f 9 6 e f 0 d 3 2 8 6 9 f 0 a 9 6 a f c b 2 5 c 8 a 2 e 1 c 2 f e 5 1 a 6 e b 4 a a 3
2022-11-11 23:12:15 +01:00
P A T C H E S
w i n d o w s / i n s t a l l - l a y o u t . p a t c h
w i n d o w s / i n s t a l l - p d b s . p a t c h
2023-02-10 21:14:37 +02:00
w i n d o w s / u m u l 1 2 8 - a r m 6 4 . p a t c h # Fixed upstream in https://github.com/openssl/openssl/pull/20244, but not released as of 3.0.8
2020-11-04 07:59:02 +01:00
)
vcpkg_find_acquire_program ( PERL )
get_filename_component ( PERL_EXE_PATH ${ PERL } DIRECTORY )
vcpkg_add_to_path ( "${PERL_EXE_PATH}" )
2022-11-11 23:12:15 +01:00
if ( VCPKG_TARGET_IS_WINDOWS AND NOT VCPKG_TARGET_IS_MINGW )
2020-11-04 07:59:02 +01:00
include ( "${CMAKE_CURRENT_LIST_DIR}/windows/portfile.cmake" )
2021-10-27 07:48:21 +02:00
include ( "${CMAKE_CURRENT_LIST_DIR}/install-pc-files.cmake" )
2020-11-04 07:59:02 +01:00
else ( )
include ( "${CMAKE_CURRENT_LIST_DIR}/unix/portfile.cmake" )
endif ( )
2022-11-11 23:12:15 +01:00
if ( NOT "${VERSION}" MATCHES [[^([0-9]+ ) \ . ( [ 0 - 9 ] + ) \ . ( [ 0 - 9 ] + ) $ ] ] )
message ( FATAL_ERROR "Version regex did not match." )
endif ( )
set ( OPENSSL_VERSION_MAJOR "${CMAKE_MATCH_1}" )
set ( OPENSSL_VERSION_MINOR "${CMAKE_MATCH_2}" )
set ( OPENSSL_VERSION_FIX "${CMAKE_MATCH_3}" )
2021-07-23 13:11:45 +08:00
configure_file ( "${CMAKE_CURRENT_LIST_DIR}/vcpkg-cmake-wrapper.cmake.in" "${CURRENT_PACKAGES_DIR}/share/${PORT}/vcpkg-cmake-wrapper.cmake" @ONLY )
2020-12-11 17:40:21 -08:00
file ( INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" )