mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-24 10:59:00 +08:00
[openssl] Support static builds on UWP (#19636)
Co-authored-by: Billy Robert O'Neal III <bion@microsoft.com>
This commit is contained in:
parent
39d0da3a71
commit
887cc9c15a
@ -1,11 +1,14 @@
|
||||
vcpkg_fail_port_install(MESSAGE "${PORT} is only for Windows Universal Platform" ON_TARGET "Linux" "OSX")
|
||||
|
||||
vcpkg_check_linkage(ONLY_DYNAMIC_LIBRARY)
|
||||
|
||||
vcpkg_find_acquire_program(JOM)
|
||||
get_filename_component(JOM_EXE_PATH ${JOM} DIRECTORY)
|
||||
vcpkg_add_to_path("${PERL_EXE_PATH}")
|
||||
|
||||
set(OPENSSL_SHARED no-shared)
|
||||
if(VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic")
|
||||
set(OPENSSL_SHARED shared)
|
||||
endif()
|
||||
|
||||
vcpkg_extract_source_archive_ex(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
ARCHIVE ${ARCHIVE}
|
||||
@ -26,7 +29,7 @@ set(CONFIGURE_COMMAND ${PERL} Configure
|
||||
no-uplink
|
||||
no-tests
|
||||
-utf-8
|
||||
shared
|
||||
${OPENSSL_SHARED}
|
||||
)
|
||||
|
||||
if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x86")
|
||||
@ -143,6 +146,12 @@ file(REMOVE
|
||||
"${CURRENT_PACKAGES_DIR}/debug/openssl.cnf.dist"
|
||||
)
|
||||
|
||||
if(VCPKG_LIBRARY_LINKAGE STREQUAL static)
|
||||
# They should be empty, only the exes deleted above were in these directories
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/bin/")
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/bin/")
|
||||
endif()
|
||||
|
||||
file(READ "${CURRENT_PACKAGES_DIR}/include/openssl/dtls1.h" _contents)
|
||||
string(REPLACE "<winsock.h>" "<winsock2.h>" _contents "${_contents}")
|
||||
file(WRITE "${CURRENT_PACKAGES_DIR}/include/openssl/dtls1.h" "${_contents}")
|
||||
|
@ -1,6 +1,7 @@
|
||||
{
|
||||
"name": "openssl",
|
||||
"version-string": "1.1.1l",
|
||||
"port-version": 1,
|
||||
"description": "OpenSSL is an open source project that provides a robust, commercial-grade, and full-featured toolkit for the Transport Layer Security (TLS) and Secure Sockets Layer (SSL) protocols. It is also a general-purpose cryptography library.",
|
||||
"homepage": "https://www.openssl.org"
|
||||
}
|
||||
|
@ -4734,7 +4734,7 @@
|
||||
},
|
||||
"openssl": {
|
||||
"baseline": "1.1.1l",
|
||||
"port-version": 0
|
||||
"port-version": 1
|
||||
},
|
||||
"openssl-unix": {
|
||||
"baseline": "1.1.1h",
|
||||
|
@ -1,5 +1,10 @@
|
||||
{
|
||||
"versions": [
|
||||
{
|
||||
"git-tree": "6d19a647704efae9398b178a0012140c1f1ee8b8",
|
||||
"version-string": "1.1.1l",
|
||||
"port-version": 1
|
||||
},
|
||||
{
|
||||
"git-tree": "1916410d0a836cb70be2341fa3ec3cce74d25267",
|
||||
"version-string": "1.1.1l",
|
||||
|
Loading…
Reference in New Issue
Block a user