Optimizing a single library doesn't reduce the library as effectively as optimizing
all libraries simultaneously, because the System Optimizer accounts for
dependencies.
To reduce a library such as libc using the Dietician, you must
iteratively optimize each individual library in your project between two and five times
(depending on the number of dependency levels).
You can reduce a single library to its optimum size if it has no dependencies.
To optimize a single library in an image:
- If your project isn't already open, double-click its
project.bld file in the System Builder
Projects view.
- In the QNX System Builder editor, expand the Shared
Libraries list and select the library you want to optimize.
- In the toolbar, click the Optimize System button (
).
- In the System Optimizer, select the Apply diet(s)
system wide option.
- Click Next. In the next few pages, the Dietician shows the
unnecessary libraries, any additional needed libraries, and the libraries that can
be optimized.
- Click Finish. The Dietician removes unused libraries, adds
the additional required libraries, and generates new, reduced libraries. Reduced
libraries are added to your project's
Reductions/image_name directory.