public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
From: n8tm@aol.comnojunk (Tim Prince)
To: help-gcc@gnu.org
Subject: Re: gcc and linux newbie's question
Date: Tue, 21 Dec 1999 23:07:00 -0000	[thread overview]
Message-ID: <19991222020521.12122.00000413@ng-cv1.aol.com> (raw)
In-Reply-To: <38604854.E5CEA5DE@polyu.edu.hk>

>    objdir   /usr/local/bin/gcc-objdir   (currently empty)

Normally, you would build into a directory distinct from the installation
prefix, which would default to /usr/local, however this should work.

>If not, are there any preferred directories to
>hold the "sources" and "objects"?

There are a few packages, such as binutils, which prefer the build directory to
be immediately below the top level source directory.  This works also for
building the compilers, but I believe a totally separate directory is
considered preferable, and would be more convenient in case you must repeat the
unpacking of the distribution.

>I set CC by   export CC=/usr/local/bin/gcc.
>Am I correct?

If that is the compiler you wish to use for the first phase in boot-strapping
the new one.  In a normal linux installation you would not require setting CC,
or (with the same effect) 'export CC=/usr/bin/gcc'

>config.guess
>failed to determine the host type. 

the common choices for gcc-2.95.2 on linux would be i586-pc-linux-gnu (if you
have glibc; makes no difference whether you use i586 or i686) or
i586-pc-linux-gnulibc1 (if you have libc5).  I'm not sure what configure does
to interrogate your system, some combination of uname -a and checking your
library version.  If there were a similar listing among the configure choices
which included k6, you could use that; otherwise I think you need to use one of
the above.  

In your decision, you should consider that the compiler will use a subdirectory
$prefix/lib/gcc-lib/$host/gcc-2.95.2 among others.  If your original compiler
is gcc it should have a similar directory, and by making the $host and $prefix
names match, you can use the version options e.g. -V2.95.2 to select between
them.  linux distributions may be installed with $host as i386-linux,
i586-vendor-linux, or some such.  Making the $host match this way also assures
that the compiler is built starting from the same set of include files, if
there is a directory such as $prefix/$host/include.
Tim Prince
tprince@computer.org

WARNING: multiple messages have this Message-ID
From: n8tm@aol.comnojunk (Tim Prince)
To: help-gcc@gnu.org
Subject: Re: gcc and linux newbie's question
Date: Fri, 31 Dec 1999 22:24:00 -0000	[thread overview]
Message-ID: <19991222020521.12122.00000413@ng-cv1.aol.com> (raw)
Message-ID: <19991231222400.x79ahz9fxnVMVYruXsXHHHD-vMO5j5V9xgVmYYuQ79k@z> (raw)
In-Reply-To: <38604854.E5CEA5DE@polyu.edu.hk>

>    objdir   /usr/local/bin/gcc-objdir   (currently empty)

Normally, you would build into a directory distinct from the installation
prefix, which would default to /usr/local, however this should work.

>If not, are there any preferred directories to
>hold the "sources" and "objects"?

There are a few packages, such as binutils, which prefer the build directory to
be immediately below the top level source directory.  This works also for
building the compilers, but I believe a totally separate directory is
considered preferable, and would be more convenient in case you must repeat the
unpacking of the distribution.

>I set CC by   export CC=/usr/local/bin/gcc.
>Am I correct?

If that is the compiler you wish to use for the first phase in boot-strapping
the new one.  In a normal linux installation you would not require setting CC,
or (with the same effect) 'export CC=/usr/bin/gcc'

>config.guess
>failed to determine the host type. 

the common choices for gcc-2.95.2 on linux would be i586-pc-linux-gnu (if you
have glibc; makes no difference whether you use i586 or i686) or
i586-pc-linux-gnulibc1 (if you have libc5).  I'm not sure what configure does
to interrogate your system, some combination of uname -a and checking your
library version.  If there were a similar listing among the configure choices
which included k6, you could use that; otherwise I think you need to use one of
the above.  

In your decision, you should consider that the compiler will use a subdirectory
$prefix/lib/gcc-lib/$host/gcc-2.95.2 among others.  If your original compiler
is gcc it should have a similar directory, and by making the $host and $prefix
names match, you can use the version options e.g. -V2.95.2 to select between
them.  linux distributions may be installed with $host as i386-linux,
i586-vendor-linux, or some such.  Making the $host match this way also assures
that the compiler is built starting from the same set of include files, if
there is a directory such as $prefix/$host/include.
Tim Prince
tprince@computer.org

  parent reply	other threads:[~1999-12-21 23:07 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-12-19 23:31 Hankel O'Fung
1999-12-20  5:58 ` Tim Prince
1999-12-21 19:48   ` root
1999-12-21 20:47     ` llewelly
1999-12-31 22:24       ` llewelly
1999-12-21 23:07     ` Tim Prince [this message]
1999-12-31 22:24       ` Tim Prince
1999-12-31 22:24     ` root
1999-12-31 22:24   ` Tim Prince
1999-12-31 22:24 ` Hankel O'Fung

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=19991222020521.12122.00000413@ng-cv1.aol.com \
    --to=n8tm@aol.comnojunk \
    --cc=help-gcc@gnu.org \
    /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).