I have a library that I'm building using libtool. When built statically,
I want it to include a certain list of object files.  When linking that
library dynamically, I want to add an additional object (windows
resources, compiled using windres).

I already have it working so that BOTH versions get the resource object
(e.g. special rules to invoke windres, etc).  How can I exclude that
object from the static archive?

The best I could come up with is this: IN the source code for the object, do

----- top of file -----
#if defined(BUILDING_MY_LIBRARY) && defined(DLL_EXPORT)
stuff
#endif
----- end of file -----

This way, the object is included in both the static and shared
libraries, but in the former case it doesn't have any contents.

Is there a better way?

--
Chuck


_______________________________________________
http://lists.gnu.org/mailman/listinfo/libtool

Reply via email to