This is the mail archive of the crossgcc@cygnus.com mailing list for the crossgcc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: General questions about installing Cross GCC


   Date: Tue, 06 Jul 1999 19:44:36 +0200
   From: linuxburken <linuxburken@bigfoot.com>

[your editor isn't wrapping long lines, they come out as one long one.
I have fixed this here.]

   I have some general questions about installing Cross GCC. The target I
   have been building the development toolkit is for the ARM chip. The
   directory were I want all files to be installed into is /usr/local/ARM,
   so I have been using the "--prefix=/usr/local/ARM" for all tools when I
   have been configuring them. When I specify the target using the
   "./config.sub" program it will give me the following answer:

   ./config.sub arm-coff
   arm-unknown-coff

   ./config.sub arm--coff
   arm--coff

Are you saying you specify --target as either arm-unknown-coff or arm--coff?
If so, don't.  Specify "--target=arm-coff".  config.sub is an internal
utility, btw, I don't know of any user need to run it directly.

   This will give me toolkit names like: arm-unknown-coff-as,
   arm-unknown-coff-gcc, arm-unknown-coff-ld, etc... or arm--coff-as,
   arm--coff-gcc, arm--coff-ld. However, the GNU Pro Toolkit precompiled
   binaries have names like: arm-coff-as, arm-coff-gcc, arm-coff-ld, etc... 
   How have Cygnus configured them? Have the toolkit name been renamed after
   it has been installed? Can I rename the tools after installation? Will
   gcc find the correct tool if I rename them? (I have been using the
   "--with-gnu-ld" for the binutils-2.9.1 and "--with-gnu-as" and
   "--with-gnu-ld" for the gcc-2.8.1)

As stated above, configure with "--target=arm-coff".
You will then see programs like arm-coff-gcc, arm-coff-ld, etc.

Yes, you can rename them.  As long as you leave $prefix/$target/bin/*
alone (though I suppose even that can be worked around).

   Why does binutils-2.9.1 and gcc-2.8.1 install two copies of "as" and "gcc"
  (with different names) in the following directories:

   /usr/local/ARM/bin/arm--coff-as
   /usr/local/ARM/arm--coff/bin/as

   /usr/local/ARM/bin/arm--coff-gcc
   /usr/local/ARM/arm--coff/bin/gcc

   When should I use "/usr/local/ARM/bin/arm--coff-gcc", and when
   should I use "/usr/local/ARM/arm--coff/bin/gcc"?

$prefix/$target/bin/as is for the compiler to use.  Don't use it.
[well you can, but it's not intended that you do so].
$prefix/bin/${target}-as is for users to use.

Same applies to gcc.

[actually, the above should use $exec_prefix instead of $prefix, but
$exec_prefix defaults to $prefix]

   Why does the binutils-2.9.1 and gcc-2.8.1 make the extra directory
    "/usr/local/ARM/arm--coff" with my configuration?

This is for target specific include files ($prefix/$target/include) and
libraries/object-files/linker-scripts ($prefix/$target/lib).
It's also for as,ld for gcc to use ($prefix/$target/bin).

   One final question, when I installed newlib-1.8.1 it install all include files in:
   /usr/local/ARM/arm--coff/include. But, what about the include directory
   /usr/local/ARM/include? When is this directory used?

$prefix/$target/include is for target specific include files.
$prefix/include is for target independent include files.

   I hope some helpful soul could explain to me why the tools are named
   like this in my configuration and how the directories work.

The reason for the seemingly unnecessary complexity is that the layout
has been designed to allow several toolchains to live under the same
tree at once.  This includes allowing for several hosts.
E.g solaris-cross-arm, solaris-cross-m68k, linux-cross-sh, and
linux-cross-h8300 can all live under one $prefix ($exec_prefix is used
to separate hosts).
_______________________________________________
New CrossGCC FAQ: http://www.objsw.com/CrossGCC
_______________________________________________
To remove yourself from the crossgcc list, send
mail to crossgcc-request@cygnus.com with the
text 'unsubscribe' (without the quotes) in the
body of the message.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]