• Welcome to PlanetSquires Forums.
 

How To Streamline FreeBasic Executables

Started by Jim Dunn, May 12, 2022, 03:21:52 AM

Previous topic - Next topic

Jim Dunn

Hey all, remember when Bob Zale came out with that fancy "only compile into your EXE the parts of the include files that are needed" and it would ignore the rest?

I'm trying to figure out how to do that with FreeBasic.

I created a library (.a) but all my EXE files were the same size, no matter if I called a function or not.

Everything appears to be a static compile, putting everything into the EXE.

Any ideas ???
3.14159265358979323846264338327950
"Ok, yes... I like pie... um, I meant, pi."

José Roca

Take a look to my include files in the Afx framework and my use of PRIVATE in each procedure. Be warned that only works using source code.

Johan Klassen

also, if you split your library into separate files one function per file and compile each as an object and create the library from them the linker should then only link-in the used functions

Jim Dunn

Thank you both -- I see that my "knowledge of PRIVATE" was NULL...

So, while I "AM STUDYING ABOUT PRIVATE"... I went ahead and separated all my functions out into separate files and learned how to create a libjLib.a file.

Thx again!!
3.14159265358979323846264338327950
"Ok, yes... I like pie... um, I meant, pi."