diff options
-rw-r--r-- | cmake/FindWrapLibClang.cmake | 20 | ||||
-rw-r--r-- | coin/module_config.yaml | 14 | ||||
-rw-r--r-- | src/designer/src/components/lib/CMakeLists.txt | 4 |
3 files changed, 32 insertions, 6 deletions
diff --git a/cmake/FindWrapLibClang.cmake b/cmake/FindWrapLibClang.cmake index 33fc29837..3b21966dc 100644 --- a/cmake/FindWrapLibClang.cmake +++ b/cmake/FindWrapLibClang.cmake @@ -18,6 +18,18 @@ function(qt_tools_find_llvm_version_from_lib_dir lib_dir out_var) endfunction() function(qt_tools_find_lib_clang) + if(NOT QDOC_USE_STATIC_LIBCLANG AND DEFINED ENV{QDOC_USE_STATIC_LIBCLANG}) + set(QDOC_USE_STATIC_LIBCLANG "$ENV{QDOC_USE_STATIC_LIBCLANG}") + endif() + + if(QDOC_USE_STATIC_LIBCLANG AND MSVC) + if (NOT CMAKE_BUILD_TYPE STREQUAL "Release") + message(STATUS "Static linkage against libclang with MSVC was requested, but the build is not a release build, therefore libclang cannot be used.") + set(WrapLibClang_FOUND FALSE PARENT_SCOPE) + return() + endif() + endif() + # We already looked up all the libclang information before, just create the target # and exit early. if(QT_LIB_CLANG_LIBS) @@ -26,10 +38,6 @@ function(qt_tools_find_lib_clang) return() endif() - if(NOT QDOC_USE_STATIC_LIBCLANG AND DEFINED ENV{QDOC_USE_STATIC_LIBCLANG}) - set(QDOC_USE_STATIC_LIBCLANG "$ENV{QDOC_USE_STATIC_LIBCLANG}") - endif() - if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Windows") # on Windows we have only two host compilers, MSVC or mingw. The former we never # use for cross-compilation where it isn't also the target compiler. The latter @@ -207,6 +215,10 @@ function(qt_tools_create_lib_clang_target) target_link_directories(WrapLibClang::WrapLibClang INTERFACE ${QT_LIB_CLANG_LIBDIR}) target_include_directories(WrapLibClang::WrapLibClang INTERFACE ${QT_LIB_CLANG_INCLUDEPATH}) target_compile_definitions(WrapLibClang::WrapLibClang INTERFACE ${QT_LIB_CLANG_DEFINES}) + if (NOT TARGET Threads::Threads) + find_package(Threads) + endif() + target_link_libraries(WrapLibClang::WrapLibClang INTERFACE Threads::Threads) endfunction() function(qt_tools_get_flag_list_of_llvm_static_libs out_var) diff --git a/coin/module_config.yaml b/coin/module_config.yaml new file mode 100644 index 000000000..2d4337041 --- /dev/null +++ b/coin/module_config.yaml @@ -0,0 +1,14 @@ +version: 1 +accept_configuration: + condition: property + property: host.os + equals_property: target.os + +build_instructions: + - !include "{{qt/qtbase}}/prepare_building_env.yaml" + - !include "{{qt/qtbase}}/cmake_module_build_instructions.yaml" + +test_instructions: + - type: EnvironmentVariable + variableName: Dummy + variableValue: dummy diff --git a/src/designer/src/components/lib/CMakeLists.txt b/src/designer/src/components/lib/CMakeLists.txt index 354cd60ff..1b3bf7183 100644 --- a/src/designer/src/components/lib/CMakeLists.txt +++ b/src/designer/src/components/lib/CMakeLists.txt @@ -989,7 +989,7 @@ set(qtpropertybrowser_resource_files "images/cursor-whatsthis.png" ) -add_qt_resource(DesignerComponents "qtpropertybrowser" +add_qt_resource(DesignerComponents "qtpropertybrowser_designercomponents" # special case PREFIX "/qt-project.org/qtpropertybrowser" BASE @@ -1036,7 +1036,7 @@ set(findwidget_resource_files "images/wrap.png" ) -add_qt_resource(DesignerComponents "findwidget" +add_qt_resource(DesignerComponents "findwidget_designercomponents" # special case PREFIX "/qt-project.org/shared" BASE |