summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2018-01-21 19:05:32 +0100
committerGitHub <noreply@github.com>2018-01-21 19:05:32 +0100
commit1bcc233245516f99aaa0afe1959c207ddb7c99d4 (patch)
tree0be830f62b67c7896dff931279067d70bdc4e133
parentMerge pull request #72 from N00byKing/patch-2 (diff)
parentCMakeLists: Fix unicorn build for macOS developers with x86_64-only systems (diff)
downloadyuzu-1bcc233245516f99aaa0afe1959c207ddb7c99d4.tar
yuzu-1bcc233245516f99aaa0afe1959c207ddb7c99d4.tar.gz
yuzu-1bcc233245516f99aaa0afe1959c207ddb7c99d4.tar.bz2
yuzu-1bcc233245516f99aaa0afe1959c207ddb7c99d4.tar.lz
yuzu-1bcc233245516f99aaa0afe1959c207ddb7c99d4.tar.xz
yuzu-1bcc233245516f99aaa0afe1959c207ddb7c99d4.tar.zst
yuzu-1bcc233245516f99aaa0afe1959c207ddb7c99d4.zip
Diffstat (limited to '')
-rw-r--r--CMakeLists.txt9
1 files changed, 6 insertions, 3 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5dee41abc..5e904a53f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -15,6 +15,8 @@ CMAKE_DEPENDENT_OPTION(YUZU_USE_BUNDLED_SDL2 "Download bundled SDL2 binaries" ON
option(ENABLE_QT "Enable the Qt frontend" ON)
CMAKE_DEPENDENT_OPTION(YUZU_USE_BUNDLED_QT "Download bundled Qt binaries" ON "ENABLE_SDL2;MSVC" OFF)
+option(YUZU_USE_BUNDLED_UNICORN "Build/Download bundled Unicorn" ON)
+
if(NOT EXISTS ${CMAKE_SOURCE_DIR}/.git/hooks/pre-commit)
message(STATUS "Copying pre-commit hook")
file(COPY hooks/pre-commit
@@ -209,8 +211,7 @@ else()
endif()
# If unicorn isn't found, msvc -> download bundled unicorn; everyone else -> build external
-find_package(Unicorn QUIET)
-if (NOT UNICORN_FOUND)
+if (YUZU_USE_BUNDLED_UNICORN)
if (MSVC)
message(STATUS "unicorn not found, falling back to bundled")
# Detect toolchain and platform
@@ -249,7 +250,7 @@ if (NOT UNICORN_FOUND)
find_package(PythonInterp 2.7 REQUIRED)
add_custom_command(OUTPUT ${LIBUNICORN_LIBRARY}
- COMMAND ${CMAKE_COMMAND} -E env UNICORN_ARCHS="aarch64" PYTHON="${PYTHON_EXECUTABLE}" /bin/sh make.sh
+ COMMAND ${CMAKE_COMMAND} -E env UNICORN_ARCHS="aarch64" PYTHON="${PYTHON_EXECUTABLE}" /bin/sh make.sh macos-universal-no
WORKING_DIRECTORY ${UNICORN_PREFIX}
)
# ALL makes this custom target build every time
@@ -259,6 +260,8 @@ if (NOT UNICORN_FOUND)
)
unset(UNICORN_LIB_NAME)
endif()
+else()
+ find_package(Unicorn REQUIRED)
endif()
if (UNICORN_FOUND)