summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSamuli Piippo <samuli.piippo@qt.io>2021-03-23 10:47:05 +0200
committerSamuli Piippo <samuli.piippo@qt.io>2021-03-24 07:50:48 +0200
commit598b72dac2f467fcc244e0b7ef348c034daf428b (patch)
treed42685f8ce3df629d782fcd102cc312de9fd683b /src
parentf9104e056677d5456ee92a91a9b2cb6a996099bb (diff)
cmake: fix build with system assimp
Re-generate src/core/configure.cmake and use the renamed WrapQt3DAssimp. Change-Id: Ifd4accb55216af61c0a4e29b3723eae6c9b853eb Reviewed-by: Mike Krus <mike.krus@kdab.com>
Diffstat (limited to 'src')
-rw-r--r--src/3rdparty/assimp/assimp.cmake2
-rw-r--r--src/core/configure.cmake37
2 files changed, 14 insertions, 25 deletions
diff --git a/src/3rdparty/assimp/assimp.cmake b/src/3rdparty/assimp/assimp.cmake
index 59d27fc1c..66b5e8388 100644
--- a/src/3rdparty/assimp/assimp.cmake
+++ b/src/3rdparty/assimp/assimp.cmake
@@ -11,7 +11,7 @@ function(qt3d_extend_target_for_assimp target)
set(assimpDir ${PROJECT_SOURCE_DIR}/src/3rdparty/assimp)
qt_internal_extend_target(${target} CONDITION QT_FEATURE_qt3d_system_assimp AND (NOT CMAKE_CROSSCOMPILING OR NOT host_build)
LIBRARIES
- WrapAssimp::WrapAssimp
+ WrapQt3DAssimp::WrapQt3DAssimp
)
qt_internal_extend_target(${target} CONDITION NOT QT_FEATURE_qt3d_system_assimp OR (CMAKE_CROSSCOMPILING AND host_build)
diff --git a/src/core/configure.cmake b/src/core/configure.cmake
index bdc1fb8be..e8c05ef53 100644
--- a/src/core/configure.cmake
+++ b/src/core/configure.cmake
@@ -1,8 +1,10 @@
+
+
#### Inputs
-# input assimp
-set(INPUT_assimp "undefined" CACHE STRING "")
-set_property(CACHE INPUT_assimp PROPERTY STRINGS undefined qt system no)
+# input qt3d-assimp
+set(INPUT_qt3d_assimp "undefined" CACHE STRING "")
+set_property(CACHE INPUT_qt3d_assimp PROPERTY STRINGS undefined qt system no)
@@ -14,21 +16,12 @@ qt_config_compile_test("assimp"
LABEL ""
PROJECT_PATH "${CMAKE_CURRENT_SOURCE_DIR}/../../config.tests/assimp"
# special case begin
- LIBRARIES WrapAssimp::WrapAssimp
- PACKAGES PACKAGE WrapAssimp 5
+ LIBRARIES WrapQt3DAssimp::WrapQt3DAssimp
+ PACKAGES PACKAGE WrapQt3DAssimp 5
# special case end
)
-qt_find_package(WrapAssimp 5 PROVIDED_TARGETS WrapAssimp::WrapAssimp)
-
-
-qt_config_compile_test("assimp"
- LABEL "Assimp"
- PROJECT_PATH "${CMAKE_CURRENT_SOURCE_DIR}/../../config.tests/assimp"
- LIBRARIES WrapAssimp::WrapAssimp
- PACKAGES PACKAGE WrapAssimp 5)
-
#### Tests
@@ -50,33 +43,28 @@ qt_feature("qt3d-render" PUBLIC
LABEL "Render aspect"
PURPOSE "Use the 3D Render Aspect library"
)
-
qt_feature("qt3d-input" PUBLIC
SECTION "Aspects"
LABEL "Input aspect"
PURPOSE "Use the 3D Input Aspect library"
)
-
qt_feature("qt3d-logic" PUBLIC
SECTION "Aspects"
LABEL "Logic aspect"
PURPOSE "Use the 3D Logic Aspect library"
)
-
qt_feature("qt3d-extras" PUBLIC
SECTION "Aspects"
LABEL "Extras aspect"
PURPOSE "Use the 3D Extra library"
CONDITION QT_FEATURE_qt3d_render AND QT_FEATURE_qt3d_input AND QT_FEATURE_qt3d_logic
)
-
qt_feature("qt3d-animation" PUBLIC
SECTION "Aspects"
LABEL "Animation aspect"
PURPOSE "Use the 3D Animation Aspect library"
CONDITION QT_FEATURE_qt3d_render
)
-
qt_feature("qt3d-simd-sse2" PRIVATE
LABEL "Use SSE2 instructions"
PURPOSE "Use SSE2 SIMD instructions to accelerate matrix operations"
@@ -84,7 +72,6 @@ qt_feature("qt3d-simd-sse2" PRIVATE
ENABLE INPUT_qt3d_simd STREQUAL 'sse2' OR INPUT_qt3d_simd STREQUAL 'avx2'
DISABLE INPUT_qt3d_simd STREQUAL 'no' OR ( TEST_architecture_arch STREQUAL i386 )
)
-
qt_feature("qt3d-simd-avx2" PRIVATE
LABEL "Use AVX2 instructions"
PURPOSE "Use AVX2 SIMD instructions to accelerate matrix operations"
@@ -97,9 +84,11 @@ qt_configure_add_summary_entry(ARGS "qt3d-assimp")
qt_configure_add_summary_entry(ARGS "qt3d-system-assimp")
qt_configure_add_summary_entry(ARGS "qt3d-simd-sse2")
qt_configure_add_summary_entry(ARGS "qt3d-simd-avx2")
-qt_configure_add_summary_entry(ARGS "qt3d-animation")
-qt_configure_add_summary_entry(ARGS "qt3d-extras")
+qt_configure_add_summary_section(NAME "Aspects")
+qt_configure_add_summary_entry(ARGS "qt3d-render")
qt_configure_add_summary_entry(ARGS "qt3d-input")
qt_configure_add_summary_entry(ARGS "qt3d-logic")
-qt_configure_add_summary_entry(ARGS "qt3d-render")
-qt_configure_end_summary_section() # end of "Qt3D" section
+qt_configure_add_summary_entry(ARGS "qt3d-animation")
+qt_configure_add_summary_entry(ARGS "qt3d-extras")
+qt_configure_end_summary_section() # end of "Aspects" section
+qt_configure_end_summary_section() # end of "Qt 3D" section