From 3931463c760b0762373686b04ebff52d602e533f Mon Sep 17 00:00:00 2001 From: John Preston Date: Fri, 29 Nov 2019 15:09:00 +0300 Subject: [PATCH] Build OS X 10.10-10.11 version with Qt 5.6.2. --- external/openssl/CMakeLists.txt | 21 ++++++++++++++++----- external/qt/CMakeLists.txt | 14 ++++++++++++++ external/qt/package.cmake | 6 +++++- variables.cmake | 7 ++++++- 4 files changed, 41 insertions(+), 7 deletions(-) diff --git a/external/openssl/CMakeLists.txt b/external/openssl/CMakeLists.txt index 1c77d81..c1565e4 100644 --- a/external/openssl/CMakeLists.txt +++ b/external/openssl/CMakeLists.txt @@ -7,10 +7,17 @@ add_library(external_openssl INTERFACE IMPORTED GLOBAL) add_library(desktop-app::external_openssl ALIAS external_openssl) -target_include_directories(external_openssl SYSTEM -INTERFACE - ${libs_loc}/openssl_1_1_1/include -) +if (NOT APPLE OR NOT build_osx) + target_include_directories(external_openssl SYSTEM + INTERFACE + ${libs_loc}/openssl_1_1_1/include + ) +else() + target_include_directories(external_openssl SYSTEM + INTERFACE + ${libs_loc}/openssl/include + ) +endif() if (WIN32) set(openssl_lib_ext lib) @@ -18,7 +25,11 @@ if (WIN32) else() set(openssl_lib_ext a) if (APPLE) - set(openssl_lib_loc ${libs_loc}/openssl_1_1_1) + if (NOT build_osx) + set(openssl_lib_loc ${libs_loc}/openssl_1_1_1) + else() + set(openssl_lib_loc ${libs_loc}/openssl) + endif() endif() endif() diff --git a/external/qt/CMakeLists.txt b/external/qt/CMakeLists.txt index 5df1385..c7fcaec 100644 --- a/external/qt/CMakeLists.txt +++ b/external/qt/CMakeLists.txt @@ -89,6 +89,20 @@ elseif (APPLE) plugins/bearer/${qt_lib_prefix}qgenericbearer ) else() + set(qt_libs + lib/${qt_lib_prefix}Qt5PrintSupport + lib/${qt_lib_prefix}Qt5PlatformSupport + lib/${qt_lib_prefix}Qt5Network + lib/${qt_lib_prefix}Qt5Widgets + lib/${qt_lib_prefix}Qt5Gui + lib/${qt_lib_prefix}Qt5Core + lib/${qt_lib_prefix}qtharfbuzzng + lib/${qt_lib_prefix}qtfreetype + lib/${qt_lib_prefix}qtpcre + plugins/platforms/${qt_lib_prefix}qcocoa + plugins/imageformats/${qt_lib_prefix}qwebp + plugins/bearer/${qt_lib_prefix}qgenericbearer + ) endif() foreach (lib ${qt_libs}) list(APPEND qt_libs_list "${qt_loc}/${lib}${qt_lib_suffix}") diff --git a/external/qt/package.cmake b/external/qt/package.cmake index 1e9e747..36a1dfd 100644 --- a/external/qt/package.cmake +++ b/external/qt/package.cmake @@ -4,7 +4,11 @@ # For license and copyright information please follow this link: # https://github.com/desktop-app/legal/blob/master/LEGAL -set(qt_version 5.12.5) +if (NOT APPLE OR NOT build_osx) + set(qt_version 5.12.5) +else() + set(qt_version 5.6.2) +endif() if (WIN32) set(qt_loc ${libs_loc}/Qt-${qt_version}) diff --git a/variables.cmake b/variables.cmake index 2d20921..a338607 100644 --- a/variables.cmake +++ b/variables.cmake @@ -19,7 +19,12 @@ if (DESKTOP_APP_SPECIAL_TARGET STREQUAL "" set(disable_autoupdate 1) endif() -set(CMAKE_OSX_DEPLOYMENT_TARGET 10.12 CACHE STRING "Minimum OS X deployment version" FORCE) +if (NOT DESKTOP_APP_SPECIAL_TARGET STREQUAL "osx") + set(CMAKE_OSX_DEPLOYMENT_TARGET 10.12 CACHE STRING "Minimum OS X deployment version" FORCE) +else() + set(DESKTOP_APP_DISABLE_SPELLCHECK ON) + set(CMAKE_OSX_DEPLOYMENT_TARGET 10.10 CACHE STRING "Minimum OS X deployment version" FORCE) +endif() set(build_osx 0) set(build_macstore 0)