解决pyinstaller打包pyqt5的问题

yipeiwu_com6年前Python基础

pyinstaller打包使用pyqt5模块的时候,在win平台下,由于pyinstaller无法准确获取QT动态库文件路径,会报错导致无法打开运行程序,并提示错误信息pyinstaller failed to execute script pyi_rth_qt5plugins此时我们需要在打包的时候直接告诉pyinstaller到哪里去找,这个路径分隔符需要是unix形式:

pyinstaller --paths C:/****/Python/Python35-32/Lib/site-packages/PyQt5/Qt/bin -F -w ****.py

以上这篇解决pyinstaller打包pyqt5的问题就是小编分享给大家的全部内容了,希望能给大家一个参考,也希望大家多多支持【听图阁-专注于Python设计】。

相关文章

python正则表达式re模块详解

快速入门 import re pattern = 'this' text = 'Does this text match the pattern?' match = re...

用python中的matplotlib绘制方程图像代码

用python中的matplotlib绘制方程图像代码

import numpy as np import matplotlib.pyplot as plt def main(): # 设置x和y的坐标范围 x=np.aran...

python中将一个全部为int的list 转化为str的list方法

假设有这样一个List [1,2,3,4,5] 转化为下面这个样子 [‘1','2','3','4','5'] 解决方法一: a = [1,2,3] b = [ str(i) for...

Python读写ini文件的方法

本文实例讲述了Python读写ini文件的方法。分享给大家供大家参考。具体如下: 比如有一个文件update.ini,里面有这些内容: [ZIP] EngineVersion=0 D...

浅谈PYTHON 关于文件的操作

1.打开文件: f=open(r'E:\PythonProjects\test7\a.txt',mode='rt',encoding='utf-8') 以上三个单引号内分别表示:要打开的...