mirror of
https://github.com/brentvollebregt/auto-py-to-exe.git
synced 2026-04-26 04:05:49 +03:00
[GH-ISSUE #111] .exe size difference between pyinstaller and auto-py-to-exe #105
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @timellado on GitHub (Jul 30, 2020).
Original GitHub issue: https://github.com/brentvollebregt/auto-py-to-exe/issues/111
Hello,
I´ve a question about how auto-py-to-exe make the .exe file in the onedir mode, as I have run the same command in raw PyInstaller and auto-py-to-exe, and the .exe file generated in auto-py-to-exe is 2 mb heavier. Also, it´s estrange that the heavy file (auto-py-to-exe) is working fine and the one generated by pure PyInstaller is not, sending me an import error.
I also run the auto-py-to-exe, extract its spec file from the temporary folder, run this spec file in cmd using PyInstaller and also it fails when running the .exe, having the issue that the .exe file is 2mb lighter than the one generated using auto-py-to-exe.
Do you have any idea of what can be making the .exe file in auto-py-to-exe being heavier?
As a fact, if I copy the .exe file generated by auto-py-to-exe and replace the .exe in the folder generated by PyInstaller, the script works.
Folder generated with auto-py-to-exe
Folder generated with PyInstaller
Also, do you know a way in auto-py-to-exe to remove some binary files generated in the onedir folder? the way to do it with PyInstaller is for example in the spec file writing:
A = Analysis(...)a.binaries = a.binaries - TOC([ ('some.dll', None, None), ('another.dll', None, None) ])Can I do this in auto-py-to-exe?
BR,
Tomás Mellado
@brentvollebregt commented on GitHub (Jul 31, 2020):
I tried this comparison myself on a small Python script and the output differed by 53 bytes in an almost 13MB build output. Is there any chance that auto-py-to-exe and the PyInstaller you used to test this are in different Python distributions? If so, you may have had unnecessary modules added (just because they existed in the environment).
In terms of removing binaries, it appears the PyInstaller does not have an option in it's CLI so this tool does not support that unfortunately. To get around this we would need to generate spec files - this tool currently uses the CLI.
@timellado commented on GitHub (Aug 4, 2020):
Yeah, at the end I just used the .spec as deleting binaries was a key aspect for me. Anyways nice work with this super helpful tool! make me understand a lot of thing about PyInstaller!
Best Regards!