exe built with cx_Freeze, PyQt5, Python3 can't import ExtensionLoader_PyQt5_QtWidgets.py and run

前端 未结 2 1411
花落未央
花落未央 2021-01-07 08:37

I\'m trying to pack my app Python3, PyQt5 for Windows using cx_Freeze. I\'ve installed Python 3.4.3, Python-win32, PyQT5, cxfreeze. Application itself, run in console, works

2条回答
  •  温柔的废话
    2021-01-07 09:17

    you could try this:

    1. add 'libEGL.dll' to your working folder. This is from Python3x\Lib\site-packages\PyQt5

    2. In cx-freeze setup.py add:

      if sys.platform == "win32": includefiles = ['libEGL.dll'] #here you should add other files if you need to

    3. In cx-freeze setup.py link "includefiles" to build_exe_options like this:

      build_exe_options= { ... ... 'include_files': includefiles, }

提交回复
热议问题