如何修复 Ubuntu 上的 CMake 'The imported target "Qt6::lprodump" references the file /usr/lib/qt6/libexec/lprodump ...'
问题:
当尝试编译你的 CMake 项目时,你会看到类似这样的错误消息
qt_lprodump_error.txt
CMake Error at /usr/lib/x86_64-linux-gnu/cmake/Qt6LinguistTools/Qt6LinguistToolsTargets.cmake:131 (message):
The imported target "Qt6::lprodump" references the file
"/usr/lib/qt6/libexec/lprodump"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
"/usr/lib/x86_64-linux-gnu/cmake/Qt6LinguistTools/Qt6LinguistToolsTargets.cmake"
but not all the files it references.
Call Stack (most recent call first):
/usr/lib/x86_64-linux-gnu/cmake/Qt6LinguistTools/Qt6LinguistToolsConfig.cmake:47 (include)
/usr/lib/x86_64-linux-gnu/cmake/Qt6/Qt6Config.cmake:219 (find_package)
cMake/FreeCAD_Helpers/SetupQt.cmake:33 (find_package)
CMakeLists.txt:82 (include)解决方案
install_qt6_tools_dev_tools.sh
sudo apt -y install qt6-tools-dev-tools在 Ubuntu 22.04 上测试
If this post helped you, please consider buying me a coffee or donating via PayPal to support research & publishing of new posts on TechOverflow