diff --git a/cmake/QtAutoDetectHelpers.cmake b/cmake/QtAutoDetectHelpers.cmake index c24aa2d0b00..36fb377bdba 100644 --- a/cmake/QtAutoDetectHelpers.cmake +++ b/cmake/QtAutoDetectHelpers.cmake @@ -178,6 +178,10 @@ function(qt_auto_detect_vcpkg) endfunction() function(qt_auto_detect_ios) + if("${QT_QMAKE_TARGET_MKSPEC}" STREQUAL "macx-ios-clang") + set(CMAKE_SYSTEM_NAME "iOS" CACHE STRING "") + endif() + if(CMAKE_SYSTEM_NAME STREQUAL iOS) message(STATUS "Using internal CMake ${CMAKE_SYSTEM_NAME} toolchain file.") @@ -472,9 +476,9 @@ macro(qt_internal_setup_autodetect) qt_auto_detect_cyclic_toolchain() qt_auto_detect_cmake_config() - qt_auto_detect_darwin() qt_auto_detect_macos_universal() qt_auto_detect_ios() + qt_auto_detect_darwin() qt_auto_detect_android() qt_auto_detect_pch() qt_auto_detect_wasm() diff --git a/cmake/QtProcessConfigureArgs.cmake b/cmake/QtProcessConfigureArgs.cmake index 68584dfc612..5e2b92a19cf 100644 --- a/cmake/QtProcessConfigureArgs.cmake +++ b/cmake/QtProcessConfigureArgs.cmake @@ -926,11 +926,6 @@ translate_string_input(android-javac-target QT_ANDROID_JAVAC_TARGET) translate_string_input(sdk QT_APPLE_SDK) -if((DEFINED INPUT_xplatform AND INPUT_xplatform STREQUAL "macx-ios-clang") - OR (DEFINED INPUT_platform AND INPUT_platform STREQUAL "macx-ios-clang")) - push("-DCMAKE_SYSTEM_NAME=iOS") -endif() - drop_input(make) drop_input(nomake) translate_boolean_input(install-examples-sources QT_INSTALL_EXAMPLES_SOURCES)