Page 1 of 1

150kB for a cli in/out ?

Posted: Fri May 02, 2025 8:03 am
by es_91
Hi

I just wondered how come that such a little program....

Code: Select all

; compiles with PureBasic 6.2 x64 @ Windows to more than 150 kB
OpenConsole  ()
Print  ("!")
Input  ()
...compiles to close to or more than 20 kB.

Could some explanation be given, i am just curious. What else is the program doing?

Re: 150kB for a cli in/out ?

Posted: Fri May 02, 2025 8:08 am
by Fred
It's just static CRT link vs dynamic CRT link. Nothing 'useless' is added the the exe. If you want back smaller exe, you need to check the 'Dynamic UCRT' option, but then your program will be Win10+ (which shouldn't be an issue as Win10 is almost deprecated). When we will support only Win10+ in PB, we will link always again dynamic UCRT and this option will be history.