本文介绍: Arm架构系统安装PySide2

在这里插入图片描述

Step1. 下载Qt资源包

if you need the whole Qt5 (~900MB):

wget http://master.qt.io/archive/qt/5.15/5.15.2/single/qt-everywhere-src-5.15.2.tar.xz

or qtbase (basic module such as QtCore, QtGui and QtWidget)(~90MB):

wget http://master.qt.io/archive/qt/5.15/5.15.2/submodules/qtbase-everywhere-src-5.15.2.tar.xz

Step2. 配置和安装Qt5

(here I used qtbase)

tar -xpf qtbase-everywhere-src-5.15.2.tar.xz
cd qtbase-everywhere-src-5.15.2/
./configure -xcb

(must enable xcb here manually)
Choose “o” to install Qt open source version.

make -j4
sudo make install

Step3. 检查Qt-5.15.2安装情况

Now we have Qt5 under /usr/local/Qt-5.15.2

Step4. 安装PySide2所需的依赖库

Before install PySide2, first we have to deal with some requirements:
General requirements: Python: 3.5+, Qt: 5.12+, libclang: version10, CMake:3.1+, llvm: version10;Here I personally suggest use synaptic to manage library:

sudo apt-get install synaptic

Then install the correct version of libclang and llvm via synaptic.

Step5. 下载和配置PySide2

Download and build PySide2

git clone http://code.qt.io/pyside/pyside-setup.git 
cd pyside-setup/
git checkout 5.15.2

I’m not sure whether the version of Qt5 and PySide2 must match. Anyway, here I used PySide2 5.12.2
Finally, to install PySide2:

 sudo python setup.py install --qmake=/usr/local/Qt-5.15.2/bin/qmake

(qmake is automatically installed with Qt5)

Step6. 检验PySide2是否安装成功

Try PySide2 in Python:

python
from PySide2 import *

原文地址:https://blog.csdn.net/dally2/article/details/134964524

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。

如若转载,请注明出处:http://www.7code.cn/show_53250.html

如若内容造成侵权/违法违规/事实不符,请联系代码007邮箱:suwngjj01@126.com进行投诉反馈,一经查实,立即删除!

发表回复

您的电子邮箱地址不会被公开。 必填项已用 * 标注