Weight of simple desktop app

I develop apps than run on x86 based embedded hardware usually with tinycore linux.

now for me, a few megabytes are coconuts :slight_smile:

[quote=80593:@Lee Page]I develop apps than run on x86 based embedded hardware usually with tinycore linux.

now for me, a few megabytes are coconuts :)[/quote]

The size criterion is indeed paramount for environments where memory is scarce. But I doubt most Xojo programmers are in your case. Actually, in 15 years of business under Windows and over 11 with RealBasic Xojo for Mac, I never once had a customer complain about the size of executables…

would be great if we could have automatic Implicit linking for CRTs: no need to manually distribute dll’s etc. Realbasic did this in the past.

Smaller single binaries and no need to fuss about with 3rd party packing/bundler/installers.

Indeed, in PowerBasic they had to add a compiler directive called bloat to increase the size of the produced executable since users of the compiler were getting questioned about the perceived lack of depth in the software due to the small size. If you are used to getting programs on CD and you get something that can be put on a floppy you may wonder how much functionality is really there.

If you are used to getting programs on CD and you get something that can be put on a floppy you may wonder how much functionality is really there.

Floppy lol :slight_smile: :slight_smile:

Peanuts…

[quote=80593:@Lee Page]I develop apps than run on x86 based embedded hardware usually with tinycore linux.

now for me, a few megabytes are coconuts :)[/quote]

Cried laughing. :smiley:

[quote=80578:@Tim Hare]The LLVM compiler might* change the way code is included/excluded. It might* be a game-changer.
[/quote]
Nothing strips DLLs down
Until / unless plugins move to being static libraries that can be stripped (which carries with it its own set of problems*) its unlikely it will change this at all

*using static libraries for plugins would mean EVERY plugin developer would have to use the versions of Xcode gcc and VS that we dictate since static library formats may not be well documented OR compatible across different versions of the compilers used.

[quote=80606:@Lee Page]would be great if we could have automatic Implicit linking for CRTs: no need to manually distribute dll’s etc. Realbasic did this in the past.

Smaller single binaries and no need to fuss about with 3rd party packing/bundler/installers.[/quote]

There are tools to pack everything into a single EXE. They are mentioned here :
https://forum.xojo.com/8964-standalone-exe

[quote=80606:@Lee Page]would be great if we could have automatic Implicit linking for CRTs: no need to manually distribute dll’s etc. Realbasic did this in the past.
[/quote]
Actually thats NOT what it did at all
It put the libraries (dll’s for windows) inside the EXE and loaded them from memory (and at one point wrote them to temporary disk)
This was changed in 2008
See http://kellerfarm.com/life/2008/05/rb_single_file_exe/

This was all recommended to us by engineers at MS who I think admired inventiveness but were stunned it worked as well as it did - and promptly said “Yeah don’t do that as it WILL break in the future”

We learn something new everyday - thanks for the link interesting read.

Was is not an option to do Implicit CRT linking?

Windows shims & security patches suggest that how we do it now is the correct way to make suer those work as intended

Aaron spent time talking with MS engineers who, to paraphrase a conversation from 6 years ago, felt what we did was interesting, and very creative but really not something they’d ever suggest anyone do
It sidestepped a fair amount of what MS does to patch things up to make sure they continue to work

You can reduce exe size by about 30% using UPX. Download and drop the exe and dll’s contained within the app_libs folder. 9MB application ends up being ~3MB…UPX is available for Linux as well.

Yup UPX is great for compression. When building for windows targets i have a little Xojo helper app that packs my binaries with upx, creates an “Iexpress” SED file on the fly and bundles it all up as a nice single installer.

Would be nice to have some native app bundler in Xojo for the future. :slight_smile:

[quote=80673:@Lee Page]Yup UPX is great for compression. When building for windows targets i have a little Xojo helper app that packs my binaries with upx, creates an “Iexpress” SED file on the fly and bundles it all up as a nice single installer.

Would be nice to have some native app bundler in Xojo for the future. :)[/quote]

LLVM should pave an easier road for single binaries once again :wink:

Will Niburu/Planet X arrive before LLVM :slight_smile: looooool

LLVM has already made an appearance in XojoScript and is used for iOS… so not much longer. Maybe the Anunaki will arrive to see the technological achievement’s splendor :slight_smile:

Static libs would be required to build a single binary & that would require us to dictate which versions of which C compilers plugin authors can use on all supported platforms.

I can tell you his Christian would reel about that :stuck_out_tongue:

So - technically possible yes
Likelihood - low

While “Hello World” is a few megabytes in size, a lot of effort is required to double the size of an app.

With the storage and bandwidth that most users have today, app size is mostly irrelevant.

Including the lib folder right ?

Yes. A bit over 4MB for OS X and 5.7MB for Windows. That’s really not much these days. But it would take a long while to write enough code and create enough layouts to double the size of that app.