QNX RTOS v4 Knowledge Base
QNX RTOS v4 Knowledge Base
Title |
What are the Aplib_s and Photon_s libraries? |
Ref. No. |
QNX.000008959 |
Category(ies) |
Development |
Issue |
In order to save memory footprint in an embedded application, it was suggested we use these libraries.
Could you please explain what is in (or not in) Aplib_s and Photon_s that reduces the size? Is there any documentation of those libraries and their correct (and intended) use?
|
Solution |
Aplib_s and photon_s are the shared versions of Aplib and the Photon toolkit. Linking shared may or may not reduce your application's total footprint in memory, depending on your environment:
If your system consists of many applications, then linking staticly is wasteful since your executables will contain a lot of duplicate code.
If your system consists of only one application (even multiple instances of the same one), then linking staticly might make sense, since your executable will only contain the modules you need (whereas a shared library contains them all). *Keep in mind that PWM (Photon Window Manager) is an application.
If your system consists of only a few applications (more than one), this is a grey area, and you will have to do some experimentation to achieve optimum results.
|
|