Details
-
Bug
-
Resolution: Fixed
-
P2: Important
-
6.5.1, 6.5.2, 6.5.3, 6.6.1, 6.6
-
None
-
MacOS (x64 and ARM64)
-
-
2921a70e5 (dev), 06e9da856 (6.7), c1ef2ae81 (6.6), bbd641479 (tqtc/lts-6.5)
Description
In the file qt6/qtbase/cmake/QtPostProcessHelpers.cmake file in the qt_internal_generate_user_facing_tools_info() function the generated symlinks for MacOS do not take into account that some of the applications are formal MacOS .app packages. This causes the generated symlinks to be invalid. Downstream this causes problems when trying to create a Qt6 based application and packaging it against the qt-feedstock generated packages. The testing phase of the conda-build will fail because it tries to validate the executables and determines that they are missing.
Here is a corrected function that will generate the proper symlinks on MacOS systems
function(qt_internal_generate_user_facing_tools_info) if("${INSTALL_PUBLICBINDIR}" STREQUAL "") return() endif() get_property(user_facing_tool_targets GLOBAL PROPERTY QT_USER_FACING_TOOL_TARGETS) set(lines "") foreach(target ${user_facing_tool_targets}) get_target_property(filename ${target} OUTPUT_NAME) set(sym_link_target ${target}) if(NOT filename) set(filename ${target}) endif() if(APPLE) get_target_property(is_macos_bundle ${target} MACOSX_BUNDLE ) if(is_macos_bundle) set(filename "${filename}.app/Contents/MacOS/${filename}") endif() endif() qt_path_join(tool_target_path "${CMAKE_INSTALL_PREFIX}" "${INSTALL_BINDIR}" "${filename}") qt_path_join(tool_link_path "${INSTALL_PUBLICBINDIR}" "${sym_link_target}${PROJECT_VERSION_MAJOR}") list(APPEND lines "${tool_target_path} ${tool_link_path}") endforeach() string(REPLACE ";" "\n" content "${lines}") string(APPEND content "\n") set(out_file "${PROJECT_BINARY_DIR}/user_facing_tool_links.txt") file(WRITE "${out_file}" "${content}") endfunction()
Attachments
For Gerrit Dashboard: QTBUG-120487 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
528074,8 | CMake: Fix user_facing_tool_links.txt for Apple platforms | dev | qt/qtbase | Status: MERGED | +2 | 0 |
529426,2 | CMake: Fix user_facing_tool_links.txt for Apple platforms | 6.7 | qt/qtbase | Status: MERGED | +2 | 0 |
531319,2 | CMake: Fix user_facing_tool_links.txt for Apple platforms | 6.6 | qt/qtbase | Status: MERGED | +2 | 0 |
532957,3 | CMake: Fix user_facing_tool_links.txt for Apple platforms | tqtc/lts-6.5 | qt/tqtc-qtbase | Status: MERGED | +2 | 0 |