aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Schumacher <roschuma@microsoft.com>2018-10-25 11:44:43 -0700
committerRobert Schumacher <roschuma@microsoft.com>2018-10-25 15:55:33 -0700
commitff4902053870ad20d807dad804b158124521a7ec (patch)
treef371eaf2a899810a6b2278ed80f4b3e5ae6f9a31
parent30d5f959862fbfca1f7907259cb84f5963bb19d5 (diff)
downloadvcpkg-ff4902053870ad20d807dad804b158124521a7ec.tar.gz
vcpkg-ff4902053870ad20d807dad804b158124521a7ec.zip
[openssl-unix] Consider CMAKE_OSX_SYSROOT
-rw-r--r--ports/openssl-unix/CMakeLists.txt3
-rw-r--r--ports/openssl-unix/CONTROL2
-rw-r--r--ports/openssl-unix/portfile.cmake15
3 files changed, 12 insertions, 8 deletions
diff --git a/ports/openssl-unix/CMakeLists.txt b/ports/openssl-unix/CMakeLists.txt
index 7639d1d4e..e8d916392 100644
--- a/ports/openssl-unix/CMakeLists.txt
+++ b/ports/openssl-unix/CMakeLists.txt
@@ -26,6 +26,7 @@ get_filename_component(COMPILER_ROOT "${CMAKE_C_COMPILER}" DIRECTORY)
message("CMAKE_C_COMPILER=${CMAKE_C_COMPILER}")
message("COMPILER_ROOT=${COMPILER_ROOT}")
message("CMAKE_SYSROOT=${CMAKE_SYSROOT}")
+message("CMAKE_OSX_SYSROOT=${CMAKE_OSX_SYSROOT}")
message("CMAKE_C_FLAGS=${CMAKE_C_FLAGS}")
message("CMAKE_C_FLAGS_RELEASE=${CMAKE_C_FLAGS_RELEASE}")
message("CMAKE_C_FLAGS_DEBUG=${CMAKE_C_FLAGS_DEBUG}")
@@ -43,6 +44,8 @@ if(CMAKE_C_COMPILER_EXTERNAL_TOOLCHAIN)
endif()
if(CMAKE_SYSROOT AND CMAKE_C_COMPILE_OPTIONS_SYSROOT)
set(CFLAGS "${CFLAGS} ${CMAKE_C_COMPILE_OPTIONS_SYSROOT}${CMAKE_SYSROOT}")
+elseif(CMAKE_OSX_SYSROOT AND CMAKE_C_COMPILE_OPTIONS_SYSROOT)
+ set(CFLAGS "${CFLAGS} ${CMAKE_C_COMPILE_OPTIONS_SYSROOT}${CMAKE_OSX_SYSROOT}")
endif()
string(REGEX REPLACE "^ " "" CFLAGS "${CFLAGS}")
diff --git a/ports/openssl-unix/CONTROL b/ports/openssl-unix/CONTROL
index 6413eb371..28dc5da98 100644
--- a/ports/openssl-unix/CONTROL
+++ b/ports/openssl-unix/CONTROL
@@ -1,3 +1,3 @@
Source: openssl-unix
-Version: 1.0.2p
+Version: 1.0.2p-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.
diff --git a/ports/openssl-unix/portfile.cmake b/ports/openssl-unix/portfile.cmake
index 1484fc66c..c877905bb 100644
--- a/ports/openssl-unix/portfile.cmake
+++ b/ports/openssl-unix/portfile.cmake
@@ -4,7 +4,6 @@ endif()
include(vcpkg_common_functions)
set(OPENSSL_VERSION 1.0.2p)
-set(MASTER_COPY_SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/openssl-${OPENSSL_VERSION})
vcpkg_find_acquire_program(PERL)
@@ -14,12 +13,14 @@ vcpkg_download_distfile(OPENSSL_SOURCE_ARCHIVE
SHA512 958c5a7c3324bbdc8f07dfb13e11329d9a1b4452c07cf41fbd2d42b5fe29c95679332a3476d24c2dc2b88be16e4a24744aba675a05a388c0905756c77a8a2f16
)
-vcpkg_extract_source_archive(${OPENSSL_SOURCE_ARCHIVE})
-vcpkg_apply_patches(
- SOURCE_PATH ${MASTER_COPY_SOURCE_PATH}
- PATCHES ${CMAKE_CURRENT_LIST_DIR}/ConfigureIncludeQuotesFix.patch
- ${CMAKE_CURRENT_LIST_DIR}/STRINGIFYPatch.patch
- ${CMAKE_CURRENT_LIST_DIR}/EmbedSymbolsInStaticLibsZ7.patch
+vcpkg_extract_source_archive_ex(
+ OUT_SOURCE_PATH MASTER_COPY_SOURCE_PATH
+ ARCHIVE ${OPENSSL_SOURCE_ARCHIVE}
+ REF ${OPENSSL_VERSION}
+ PATCHES
+ ConfigureIncludeQuotesFix.patch
+ STRINGIFYPatch.patch
+ EmbedSymbolsInStaticLibsZ7.patch
)
if(CMAKE_HOST_WIN32)