diff --git a/CMakeLists.txt b/CMakeLists.txt index 570df91c6..deda6250f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -187,15 +187,14 @@ if(SFML_OS_MACOSX) endif() endif() - # configure Xcode templates - if(CMAKE_OSX_ARCHITECTURES) - # maybe multiple arches are present in CMAKE_OSX_ARCHITECTURES - # we simply need to replace ';' by ' ' (space) and store the result in XCODE_TEMPLATES_ARCH - string(REPLACE ";" " " XCODE_TEMPLATES_ARCH "${CMAKE_OSX_ARCHITECTURES}") - else() - # no arch was provided to cmake, so we use the default one - set(XCODE_TEMPLATES_ARCH "\$(NATIVE_ARCH_ACTUAL)") + # only the default architecture (i.e. 64-bit) is supported + if(CMAKE_OSX_ARCHITECTURES AND NOT "${CMAKE_OSX_ARCHITECTURES}" STREQUAL "x86_64") + message(FATAL_ERROR "Only 64-bit architecture is supported") + return() endif() + + # configure Xcode templates + set(XCODE_TEMPLATES_ARCH "\$(NATIVE_ARCH_ACTUAL)") endif() if(SFML_OS_LINUX OR SFML_OS_FREEBSD) @@ -281,7 +280,7 @@ else() COMMAND cp -r ${PROJECT_SOURCE_DIR}/include/SFML/* $/Headers) # adapt install directory to allow distributing dylibs/frameworks in user's frameworks/application bundle - # NOTE: it's not required to link agains SFML.framework + # NOTE: it's not required to link against SFML.framework set_target_properties(SFML PROPERTIES BUILD_WITH_INSTALL_RPATH 1 INSTALL_NAME_DIR "@rpath")