我运行时出错了cmake ..
。你能帮我吗?非常感谢
我想构建我的项目。我使用mkdir build
,cd build/
和cmake ..
。然后我收到此错误:
CMake Error at /usr/share/cmake-3.16/Modules/FindQt4.cmake:1314 (message):
Found unsuitable Qt version "5.12.8" from /usr/bin/qmake, this code
requires Qt 4.x
Call Stack (most recent call first):
CMakeLists.txt:8 (FIND_PACKAGE)
-- Configuring incomplete, errors occurred!
See also "/home/jingsheng/src/build/CMakeFiles/CMakeOutput.log".
之后,我用 检查我的 QT 版本qmake --version
。然后我得到:
QMake version 3.1
Using Qt version 5.12.8 in /usr/lib/x86_64-linux-gnu
我的操作系统是 Ubuntu 20.04 LTS。你能帮我吗?我该怎么办?
答案1
Qt4 软件包可从以下网址获取第三方电力购买协议。您必须添加:
sudo add-apt-repository ppa:rock-core/qt4
sudo apt-get update
然后安装必要的开发包
sudo apt-get install libqt4-dev qt4-qmake qt4-dev-tools