我有 2 个 python 版本,python3.6 安装在 virtualenv 上用于开发,我试图安装 PyQt 和 Qt 包仅用于 python3.6,
我已经使用 sudo pip3.6 install pyqt5 安装了 PyQt5,我所遵循的说明表明 Qt 包含在 PyQt5 中,同样在 /usr/lib64/python3.6/site-packages/PyQt5 中的 pyqt5 包中我看到了里面的 Qt 文件夹,但是当我输入 qmake --version 来检查 qt 版本时,它给了我以下错误:
qmake --version
bash: qmake: command not found...
Similar command is: 'make'
使用时:
make --version
它给出了以下内容:
GNU Make 3.82
Built for x86_64-redhat-linux-gnu
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
使用
rpm -ql qt
给出以下内容:
package qt is not installed
当我输入 sudo pip3.6 install qt5 重新安装它时,它给出了以下错误“```
Could not find a version that satisfies the requirement qt5 (from versions: ) No matching distribution found for qt5"
当我使用 yum install qt5 时:
Loaded plugins: fastestmirror, langpacks base | 3.6 kB 00:00 epel/x86_64/metalink | 24 kB 00:00 epel | 4.3 kB 00:00 extras | 3.4 kB 00:00 ius | 2.3 kB 00:00 updates | 3.4 kB 00:00 (1/3): ius/x86_64/primary_db | 206 kB 00:00 (2/3): epel/x86_64/updateinfo | 806 kB 00:01 (3/3): epel/x86_64/primary_db | 4.8 MB 00:08 Loading mirror speeds from cached hostfile * base:
mirror.sov.uk.goscomb.net * epel: ftp.heanet.ie * extras: mirror.ox.ac.uk * ius: lon.mirror.rackspace.com * updates: mirror.sov.uk.goscomb.net 没有可用的 qt5 软件包。错误:无事可做
有人能帮忙吗?谢谢
答案1
查找 qt5 包:# yum search qt5
...并搜索 qmake:yum provides */bin/qmake*
安装CentOS 7系统qt5:
# yum install qt5-qtbase-devel
... 提供 /usr/bin/qmake-qt5