Bug 222222 - Method to Compile Code for Older RH OS Releases
Summary: Method to Compile Code for Older RH OS Releases
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: glibc
Version: 6
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jakub Jelinek
QA Contact: Brian Brock
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2007-01-10 22:17 UTC by Daniel Qarras
Modified: 2007-11-30 22:11 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2007-01-11 19:44:54 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Daniel Qarras 2007-01-10 22:17:07 UTC
This is not a real bug report so I'm not expecting step-by-step answer but even
a possible/impossible comment with some hints would be much appreciated.

I am using RHEL4 "everywhere" and all is good till I need to give binary I've
created to someone else who is running RHEL3 and is not going to upgrade to
RHEL4. How can I compile my C and/or C++ code so that it surely works on RHEL3
(or even on RHEL2)? Provided, of course, that only those APIs/features are used
that also available on an older release?

It also seems that this will be a bigger problem in the future with DT_GNU_HASH,
a hello-world compiled on FC6 gives only a floating point exception on currect
Debian stable :-/

Comment 1 Jakub Jelinek 2007-01-10 23:21:02 UTC
To compile/link binaries for RHEL3 on RHEL4 we ship compat-glibc and
compat-gcc-32.

DT_GNU_HASH only binaries/libraries are in rpm land caught by rpm requires.
If you want to link something for older distros, you can just use compat-gcc-34
or use -Wl,--hash-style=both or -Wl,--hash-style=sysv.  FC6 release notes
explain this in detail.

Comment 3 Daniel Qarras 2007-01-11 19:04:33 UTC
Thanks, that was a kind of hint I was looking for. Keep up the good work!

(I would close this but I am not able to do it. Feel free to close this one.)

For reference, FC6 Release Notes are at:

http://fedora.redhat.com/docs/release-notes/fc6/en_US/


Note You need to log in before you can comment on or make changes to this bug.