public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
From: David Daney <ddaney@avtrex.com>
To: John Carter <john.carter@tait.co.nz>
Cc: gcc-help@gcc.gnu.org
Subject: Re: Building _statically linked_ crosscompiler toolchain.
Date: Fri, 08 Jun 2007 03:42:00 -0000	[thread overview]
Message-ID: <4668D016.2040802@avtrex.com> (raw)
In-Reply-To: <Pine.LNX.4.64.0706081345240.4980@parore.tait.co.nz>

John Carter wrote:
> On Thu, 7 Jun 2007, David Daney wrote:
>
>> glibc does not work very well statically linked.  So I don't think 
>> that is a good idea.
>
> People keep saying that....but never saying in what way doesn't it 
> work or why.

Well perhaps we are all crazy.  You asked for advice, and you got some.  
If you want to learn for yourself go right ahead.  Try doing something 
like building everything with CFLAGS=-static (or you could temporarily 
remove *.so from your /usr/lib directory when building the toolchain).

>> Perhaps you should build the toolchain on the oldest distribution 
>> that will have to be supported.  An alternative is to have a build 
>> for each incompatible host system.
>
> So do something that takes several hours to build on my latest and
> greatest and fastest 3.4Ghz 1Gb ram dual core system.....
>
> And build it on every system in the team...
>
> Including the bloke with the 100Mhz celeron  & 256 MB ram.
>
No.  Just build on this system (it could take a day or two if you are 
serious about the specifications) and use the result everywhere.

> Hmm.
>
> Hmm. One of the reasons for having a single "blessed" build of the
> compiler is it is one less variable to check & account for when the
> inevitable "Works for Joe, but Not For John" class of bugs arises.
>
> Sigh! Why is this so hard?
>
Try compiling a program for Windows Vista and then run it on MS-DOS, 
Windows 3.1 and WindowsME.  What do you think would happen?

> Why have we taken a leap back into the dark ages where we cannot share
> a user space program without either recompiling or having identical 
> systems.
>
I have programs that I built on RedHat 7, that run fine on FC6 x86_64.  
Doing things the opposite way just does not work.

If you want to build something that will run most places install the 
oldest OS version you will have to support and build it there.  That 
usually works.  The fact is that most Linux distributions move forward 
fairly rapidly, but the major ones try to maintain binary compatibility 
with previous versions.


  reply	other threads:[~2007-06-08  3:42 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-07 23:54 John Carter
2007-06-08  0:19 ` David Daney
2007-06-08  1:57   ` John Carter
2007-06-08  3:42     ` David Daney [this message]
2007-06-08  0:28 ` Brian Dessent
2007-06-08  2:04   ` John Carter
     [not found]     ` <"4  6  68CF36.239D1814"@dessent.net>
2007-06-08  3:38     ` Brian Dessent
2007-06-08  4:58       ` John Carter
2007-06-08  5:28         ` Brian Dessent
2007-06-11  5:50         ` John Carter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4668D016.2040802@avtrex.com \
    --to=ddaney@avtrex.com \
    --cc=gcc-help@gcc.gnu.org \
    --cc=john.carter@tait.co.nz \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).