Re: Need clarification on mixing GCC 4.5 with earlier versions

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

 



Kristofer Wempa <wempa@xxxxxxx> writes:

> Thanks.  That does clarify a few things.  However, I'm not worried about the
> packages I build with GCC 4.5.1 using any of those constructs.  I'm worried
> about any of the existing system libraries that are linked by the packages I
> build.  We define a set of system packages to be a "base system".  That
> includes the kernel, the basic commands and a number of low-level libraries
> (for example, libz).  We build our tool chains on top of that base system.  Any
> of these libraries that are part of our "base system" are built with GCC 4.1.2.
> I can't just assume that all of these system libraries didn't use any of those
> constructs where the ABI changed.  Will there be a potential problem if the
> packages I build with GCC 4.5.1 link against system libraries that used these
> constructs ?  Or, would I have completely build everything (including those
> base system libraries) from scratch with GCC 4.5.1 ?

There is no problem when existing code uses these structs with existing
code.  The only problem arises when code compiled with gcc 4.5.1 calls
code compiled with gcc 4.1.2, and passes a struct or union type which
the ABI changed, or vice-versa.  So you just have to check the code
compiled with gcc 4.5 and make sure that either it does not use any of
the changed struct or union types, or, in the unlikely event that it
does, ensure that it does not pass or receive those types to or from any
code compiled with gcc 4.1.2.

To put it another way, you can only have a problem with code compiled
with gcc 4.5.1, and for any code which could conceivably have a problem,
you will see a note.

Ian


[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