summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoerg Bornemann <[email protected]>2025-04-30 12:44:30 +0200
committerJoerg Bornemann <[email protected]>2025-05-02 18:13:14 +0200
commit25b040acc1e93ba4dd36f307271994be0f0604af (patch)
tree9860aacb459efc67131ad01f242f9128e3ce6e97
parentf016201b6d66408a4dd7427d2b9234909b8f1f92 (diff)
CMake: Don't unconditionally enable the ASM language
CMake MR #10626 doesn't consider the MSVC compiler as valid assembler anymore, thus unconditionally requiring ASM breaks with CMake > 4.0.1 on MSVC. Enable ASM only on non-Android Unix. Remove the ASM language where it's not needed. Pick-to: 6.5 6.8 6.9 Change-Id: I5df71edfce0f4920e39262f722e4bf95a735f31b Reviewed-by: Alexandru Croitor <[email protected]>
-rw-r--r--CMakeLists.txt6
-rw-r--r--cmake/QtBuildInternals/QtStandaloneTestTemplateProject/CMakeLists.txt2
-rw-r--r--src/plugins/sqldrivers/CMakeLists.txt2
-rw-r--r--tests/auto/corelib/io/qresourceengine/CMakeLists.txt2
-rw-r--r--tests/manual/highdpi/dprgadget/CMakeLists.txt2
-rw-r--r--tests/manual/iconbrowser/CMakeLists.txt2
6 files changed, 10 insertions, 6 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index fc7d350f87b..d3a14fc67eb 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -24,9 +24,13 @@ project(QtBase
VERSION "${QT_REPO_MODULE_VERSION}"
DESCRIPTION "Qt Base Libraries"
HOMEPAGE_URL "https://qt.io/"
- LANGUAGES CXX C ASM
+ LANGUAGES CXX C
)
+if(UNIX AND NOT ANDROID)
+ enable_language(ASM)
+endif()
+
set(QT_BUILD_EXTRA_IDE_FILE_PATTERNS bin/* libexec/*)
qt_internal_qtbase_build_repo()
diff --git a/cmake/QtBuildInternals/QtStandaloneTestTemplateProject/CMakeLists.txt b/cmake/QtBuildInternals/QtStandaloneTestTemplateProject/CMakeLists.txt
index 766e372666a..53066afcced 100644
--- a/cmake/QtBuildInternals/QtStandaloneTestTemplateProject/CMakeLists.txt
+++ b/cmake/QtBuildInternals/QtStandaloneTestTemplateProject/CMakeLists.txt
@@ -28,7 +28,7 @@ endif()
# Get the project name base on test directory name
get_filename_component(project_name "${absolute_project_path}" NAME)
-project(${project_name} VERSION 6.0.0 LANGUAGES C CXX ASM)
+project(${project_name} VERSION 6.0.0 LANGUAGES C CXX)
find_package(Qt6 REQUIRED COMPONENTS BuildInternals Core)
diff --git a/src/plugins/sqldrivers/CMakeLists.txt b/src/plugins/sqldrivers/CMakeLists.txt
index 3a9e0c7339a..07520b4e219 100644
--- a/src/plugins/sqldrivers/CMakeLists.txt
+++ b/src/plugins/sqldrivers/CMakeLists.txt
@@ -16,7 +16,7 @@ if(NOT PROJECT_NAME STREQUAL "QtBase" AND NOT PROJECT_NAME STREQUAL "Qt")
VERSION "${QT_REPO_MODULE_VERSION}"
DESCRIPTION "Qt6 SQL driver plugins"
HOMEPAGE_URL "https://qt.io/"
- LANGUAGES CXX C ASM
+ LANGUAGES CXX C
)
find_package(Qt6 ${PROJECT_VERSION} CONFIG REQUIRED COMPONENTS
BuildInternals
diff --git a/tests/auto/corelib/io/qresourceengine/CMakeLists.txt b/tests/auto/corelib/io/qresourceengine/CMakeLists.txt
index a86cc8e76a5..cf4d4ccde74 100644
--- a/tests/auto/corelib/io/qresourceengine/CMakeLists.txt
+++ b/tests/auto/corelib/io/qresourceengine/CMakeLists.txt
@@ -7,7 +7,7 @@
if(NOT QT_BUILD_STANDALONE_TESTS AND NOT QT_BUILDING_QT)
cmake_minimum_required(VERSION 3.16)
- project(tst_qresourceengine LANGUAGES C CXX ASM)
+ project(tst_qresourceengine LANGUAGES C CXX)
find_package(Qt6BuildInternals REQUIRED COMPONENTS STANDALONE_TEST)
endif()
diff --git a/tests/manual/highdpi/dprgadget/CMakeLists.txt b/tests/manual/highdpi/dprgadget/CMakeLists.txt
index 48a84b82f24..6e79cdf7efc 100644
--- a/tests/manual/highdpi/dprgadget/CMakeLists.txt
+++ b/tests/manual/highdpi/dprgadget/CMakeLists.txt
@@ -7,7 +7,7 @@
if (NOT QT_BUILD_STANDALONE_TESTS AND NOT QT_BUILDING_QT)
cmake_minimum_required(VERSION 3.16)
- project(dprgadget LANGUAGES C CXX ASM)
+ project(dprgadget LANGUAGES C CXX)
find_package(Qt6BuildInternals COMPONENTS STANDALONE_TEST)
endif()
diff --git a/tests/manual/iconbrowser/CMakeLists.txt b/tests/manual/iconbrowser/CMakeLists.txt
index b635d15ea45..e33b0958513 100644
--- a/tests/manual/iconbrowser/CMakeLists.txt
+++ b/tests/manual/iconbrowser/CMakeLists.txt
@@ -3,7 +3,7 @@
if (NOT QT_BUILD_STANDALONE_TESTS AND NOT QT_BUILDING_QT)
cmake_minimum_required(VERSION 3.16)
- project(iconbrowser LANGUAGES C CXX ASM)
+ project(iconbrowser LANGUAGES C CXX)
find_package(Qt6BuildInternals COMPONENTS STANDALONE_TEST)
endif()