简体   繁体   English

如何在python中使用pyinstaller插入或包含包?

[英]How to insert or include package using pyinstaller in python?

I use library pptx, Pyinstaller.我使用库 pptx,Pyinstaller。

I'm trying to include pptx library in an .EXE file using Pyinstaller.我正在尝试使用 Pyinstaller 在 .EXE 文件中包含 pptx 库。

But the EXE file log output is:但是EXE文件日志输出是:

pptx.packagenotfounderror.

How can i include pptx library in EXE file?如何在 EXE 文件中包含 pptx 库?

Please help me.请帮我。

Well when working with PyInstaller, it's always useful to know好吧,当使用 PyInstaller 时,了解它总是有用的

  • What flags you used你使用了什么标志
  • The content of your .spec file .spec 文件的内容

It would be useful to see the two above.看到上面的两个会很有用。

You don't need to explicitly add a library.您不需要显式添加库。 If you imported it somewhere in your code, PyInstaller will notice and add it accordingly.如果您在代码中的某处导入它,PyInstaller 会注意到并相应地添加它。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM