GCC4 Portability

Per Bjornsson perbj at stanford.edu
Tue Mar 15 20:29:11 UTC 2005


On Tue, 2005-03-15 at 15:10 -0500, David Cary Hart wrote:
> On Tue, 2005-03-15 at 19:55 +0000, Mike Hearn wrote:
> > On Tue, 15 Mar 2005 11:55:20 -0500, David Cary Hart wrote:
> > > Sorry. I know as much about C as I do about B12.
> > > 
> > > If I compile an rpm with gcc4, are there any problems associated with
> > > installing that rpm on a machine running FC3 that I need to understand?
> > 
> > Yes, this is a total swamp. I suggest you read this:
> > 
> >   http://autopackage.org/docs/devguide/ch07.html
> > 
> > It's a little out of date, doesn't cover all the issues, is inaccurate in
> > places etc but AFAIK it's the only documentation on this stuff that exists.
> 
> That's a remarkably authoritative and credible document then -;) It's
> also beyond my level of comprehension but I get the idea. It's worse
> than I thought. If I'm reading this correctly then the reverse is also a
> potential problem (using FC3 rpms in FC4 test 1).

Then you're not really reading it correctly though; "build on older, run
on newer" binary compatibility works _much_ better than the other way
around (and it can certainly be argued that this is also much more
important; if you want a binary to work on lots of platforms you just
compile it on the oldest one you care about - it can be a chroot if
everything is set up correctly, look around e.g. for Mach and maybe Red
Hat ABE if you're looking into RHEL). As long as the compiler ABI is the
same (basically this is pretty much always true for C and it's supposed
to be true for the GCC 3.4->4.0 changeover for C++) and the right
libraries are available there shouldn't be a problem. If there is a
problem, that's a bug, provided that you do have the right library
versions available.

Cheers,
Per

-- 
Per Bjornsson <perbj at stanford.edu>
Ph.D. Candidate, Department of Applied Physics, Stanford University




More information about the fedora-devel-list mailing list