JetSon Tx2安装pyside2

发布时间 2023-12-27 21:41:06作者: 星苑

第一步安装pyside2的必要组成

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

第二步配置并安装QT

sudo apt-get install libxcb*
sudo apt-get install libxkbcommon*
tar -xpf qtbase-everywhere-src-5.15.2.tar.xz
cd qtbase-everywhere-src-5.15.2/
./configure -xcb

这里我们在命令行中进行操作时会出现选择,必须在这里手动启用xcb选择“o”来安装 Qt 开源版本,然后选择y,同样注册协议进行安装
第三步使用synaptic安装libclang: version10,和llvm: version10

sudo apt-get install synaptic

然后使用sudo synaptic进行图形化管理包界面
第四步 下载并构建 PySide2

git clone git://code.qt.io/pyside/pyside-setup.git
cd pyside-setup/
git checkout 5.15.2
python3 -m pip install -r requirements.txt

注意requirements.txt这个文件中的numpy和setuptools的版本要安装正确
最后编译

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