Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

README.md中几处(或许)需要修改的地方 #20

Closed
shniubobo opened this issue Jul 31, 2020 · 2 comments
Closed

README.md中几处(或许)需要修改的地方 #20

shniubobo opened this issue Jul 31, 2020 · 2 comments

Comments

@shniubobo
Copy link
Contributor

  1. 新加的languages文件夹没有包括在“编译后打包后要做的事”里,不加这个文件夹会出错:

    FileNotFoundError: [WinError 3] 系统找不到指定的路径。: './languages'
    
  2. 现在运行pyinstaller已经不需要--hidden-import pkg_resources.py2_warn这个选项了,这个问题已经在新版本的setuptools中修复了(见 setuptools 45.0.0 may cause PyInstaller 3.3 packaged executable fail to launch pypa/setuptools#1963 (comment) ),会出这个问题的版本是setuptools>=45.0.0,<49.1.1。

    保留README.md里的原文当然没有问题,但也可以选择改为这样:

    先安装上pyinstaller并确保setuptools为最新版本

    pip install pyinstaller
    pip install setuptools --upgrade
    

    直接使用这个命令进行编译:

    pyinstaller -wy -i icon.ico QuickCut.py
    

    如果你是 Mac 编译,为了图标格式兼容,要使用:

    pyinstaller -wy -i icon.icns QuickCut.py
    

    经测试,在 Windows 10 中,Python=3.8.3, pyinstaller=3.6, setuptools=49.2.0的情况下,以及在 Ubuntu 18.04 中,Python=3.8.5, pyinstaller=3.6, setuptools=49.2.0的情况下,编译出的文件可以正常执行。

  3. README.md中的pyaudio下载地址只提供了Windows的.whl文件,Linux和Mac OS应该没法用。

    我测试用的是Ubuntu 18.04,pyaudio的依赖只有一个包,装pyaudio前运行这个即可:

    sudo apt install portaudio19-dev
    

    不过没法确定其他发行版以及Mac OS是否也是如此。

@HaujetZhao
Copy link
Owner

已更新

@leavelet
Copy link
Contributor

leavelet commented Aug 1, 2020

Mac的pyaudio安装方法我马上写在mac打包的readme里面

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants