Jon Smirl wrote: > > Functions implemented in h files are getting inserted multiple times into > the shared libs (at least on windows). This is easy verified by looking at > the symbol exports for DLLs and noticing that things like GetInterface and > QueryReferent are being exported multiple times. These functions get built > once per lib, but if five libs get linked together there are five copies in > the shared library. It is easy to fix these problems once they are found, > either make the function inline or NS_EXPORT and move it to a cpp file.
No. I believe you are misinterpreting the dump output. The linker is not making multiple copies of the same function by pulling one from each static lib. The linker simply does not do that. You are just seeing the mangled signatures of the various constructors, operators, and methods on those classes. I'd still like to see verification that marking some methods NS_EXPORT without marking the class NS_EXPORT works on all platforms - esp. Mac. I experienced cases in the past (when first getting xptcall stuff working) where the Mac would fail to link because implicit methods (like default ctors) could not be found across dll boundaries unless the class was marked NS_EXPORT. That *may* only apply when the class is being used in an inheritance chain. I don't know. But changed like your patches in http://bugzilla.mozilla.org/show_bug.cgi?id=104172 need to be verified cross platform before they land. John.
