Dynamic Library in Linux

You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers.
No questions about C++ programming or topics which are answered in the tutorials!
Post Reply
eMgz
Posts: 10
Joined: Sat Sep 29, 2007 2:54 am
Contact:

Dynamic Library in Linux

Post by eMgz »

Hi all, im trying to use irrlicht on Linux for an important work at college that uses CVS (Concurrent Versions System). The problem is that the static library is too big (36MB) as is the dynamic library (23.5MB) for an internal CVS and the work is more like a 2D than a 3D application (its about traffic simulation, like a SimCity, but i still need the third D).
Am I doing something wrong? I compiled the source/Irrlicht with make sharedlib and make install.
Maybe irrlicht isnt the engine im looking for this work because the machines here arent so fast and most of them runs Mesa (I need to install the Nvidia drivers properly), if so, can anyone suggest a lighter/better one for this case?

Thanks.
no hard no fun - eMgz
CuteAlien
Admin
Posts: 9716
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Post by CuteAlien »

Compile the engine with -s (for strip symbols from binary) and it will get a lot smaller. It will still need a few MB (maybe around 6, but Id didn't try with current version) , so if that is still too much you might consider just checking in the sources of the engine.

I don't know how well it runs with Mesa - you have to try yourself if the speed is sufficient. But without hardware acceleration I don't think it matters that much which engine you use. Irrlicht might work even rather well in that case, as you can just use it's software renderer.

Edit: On linux you can also call after compilation:
strip yourapplication
I just tested that with the binary of the examples which were linked statically and it reduced it from 20MB to 2,5 MB.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
eMgz
Posts: 10
Joined: Sat Sep 29, 2007 2:54 am
Contact:

Post by eMgz »

Thanks for the reply, the -s option worked very well, now the shared object is about 4MB, i think that the CVS users can handle it.
And yes, the matter here is about the renderer, not the engine!
no hard no fun - eMgz
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

Mesa gave me only a handful of FPS last time I tried. The burningsvideo is much faster, at least with the low quality settings.
If you need to strip the size even further you should disable those things not necessary for your app, e.g. some mesh loaders or the GUI.
Post Reply