Re: supporting multiple versions of GCC with a single shared object release?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I have accidentally mixed binaries compiled by gcc3.2.3 with binaries compiled by gcc3.4.6 in both directions across the main program / .so boundary. I did that in both x86 and AMD64 architectures. In all cases I have had crashes, usually in std::string.

I have mixed gcc3.4.6 with each of gcc4.1.2 and gcc4.3.2 in similar combinations (but only in AMD64) and seen no similar problems.

So there seems to be a significant change in std::string (or something it depends on) somewhere between gcc3.2.3 and gcc3.4.6, but no similar change since.

So I think you would need to switch to some newer version in order to provide compatibility across a range of versions, and then I guess you would lose compatibility back to 3.3.3

BTW, if any of the experts here have specific warnings (what won't work) across the range 3.4.6 through 4.3.2, I'd appreciate them. The fact that it has all worked for me so far doesn't prove it is safe.

mario guerra wrote:
We've used
GCC version 3.3.3 to build it, since that is the standard version
deployed within our company. However, some of our customers are
attempting to incorporate our model into third party simulation
environments which use different versions of GCC, and this sometimes
causes segmentation faults at run time from calls into the stdc++
library.


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux