I am trying to link an application with multiple static libraries in GCC.
There are two libraries that cause problems. Libsupport provides a terminal for the application. It relies on libcpu to provide a serial link, timing and syncronisation. Libcpu relies on libsupport to provide queueing for serial data and more.
If I specify libsupport first when linking libcpu cannot be linked with the queue functions. Is I specify libcpu first lib support can not link the serial link (and more) functions.
It looks like GCC parses a library only once and discard any unused objects.
Can I ask gcc to parse libraries multiple times or to include all objects?