Software size

14 views
Skip to first unread message

uditha chamara

unread,
Jun 20, 2020, 11:27:21 AM6/20/20
to PyInstaller
i want compile my script lower 4mb. how can i do it ?

bwoodsend

unread,
Jun 21, 2020, 4:40:11 AM6/21/20
to PyInstaller
I'm afraid Python is not the language for anything that small. PyInstaller has to include a minimal working Python installation inside your program which is around 20MB - and that's before your code goes in it. Using the

--onefileoption allows it to compress some of it so you can get down to about 7MB. If you're determined, either translate your script in C++ or maybe try Nuitka which tries to do that automatically.

Reply all
Reply to author
Forward
0 new messages