You’ve built in onedir mode (the default) which as the name suggests produces a directory. The EXE file inside that directory will not function without the rest of the contents of that folder. You need to distribute the folder with the program name. Or build in --onefile
mode.
So, following the steps at https://pyinstaller.readthedocs.io/en/stable/spec-files.html, I could add the run time option -F,--onefile in my spec file by definingoptions=[('F' ,None,'OPTION')]and including this as a parameter of my EXE instance, e.g.exe = EXE(pyz,
a.scripts,
[],
options,...)
--
You received this message because you are subscribed to a topic in the Google Groups "PyInstaller" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/pyinstaller/1D5iK9Uv2TE/unsubscribe.
To unsubscribe from this group and all its topics, send an email to pyinstaller...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pyinstaller/CAP2Qz%2BVW67vrO25M52ubqT9y5DmaEUFX1txwW5fEnAnfZEsmEg%40mail.gmail.com.
You received this message because you are subscribed to the Google Groups "PyInstaller" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pyinstaller...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pyinstaller/CACWiRmn_HGQPmQpg19dTvGu0dPeC3n3uFZ%2BdwAsXseJT52Nb%3Dg%40mail.gmail.com.
I’m afraid that there’s no nice switch in the spec file to toggle between onefile and onedir mode. Converting spec files is possible but you’d be better just creating a new spec file. And for the record, pyinstaller program.spec
ignores --onefile
(and almost all other flags).