home *** CD-ROM | disk | FTP | other *** search
/ Fresh Fish 6 / FreshFish_September1994.bin / bbs / gnu / gcc-2.6.0-src.lha / GNU / src / amiga / gcc-2.6.0 / gcc.info-6 < prev    next >
Encoding:
GNU Info File  |  1994-07-15  |  46.3 KB  |  1,099 lines

  1. This is Info file gcc.info, produced by Makeinfo-1.54 from the input
  2. file gcc.texi.
  3.  
  4.    This file documents the use and the internals of the GNU compiler.
  5.  
  6.    Published by the Free Software Foundation 675 Massachusetts Avenue
  7. Cambridge, MA 02139 USA
  8.  
  9.    Copyright (C) 1988, 1989, 1992, 1993 Free Software Foundation, Inc.
  10.  
  11.    Permission is granted to make and distribute verbatim copies of this
  12. manual provided the copyright notice and this permission notice are
  13. preserved on all copies.
  14.  
  15.    Permission is granted to copy and distribute modified versions of
  16. this manual under the conditions for verbatim copying, provided also
  17. that the sections entitled "GNU General Public License" and "Protect
  18. Your Freedom--Fight `Look And Feel'" are included exactly as in the
  19. original, and provided that the entire resulting derived work is
  20. distributed under the terms of a permission notice identical to this
  21. one.
  22.  
  23.    Permission is granted to copy and distribute translations of this
  24. manual into another language, under the above conditions for modified
  25. versions, except that the sections entitled "GNU General Public
  26. License" and "Protect Your Freedom--Fight `Look And Feel'", and this
  27. permission notice, may be included in translations approved by the Free
  28. Software Foundation instead of in the original English.
  29.  
  30. 
  31. File: gcc.info,  Node: Configurations,  Next: Other Dir,  Up: Installation
  32.  
  33. Configurations Supported by GNU CC
  34. ==================================
  35.  
  36.    Here are the possible CPU types:
  37.  
  38.      1750a, a29k, alpha, arm, cN, clipper, elxsi, h8300, hppa1.0,
  39.      hppa1.1, i370, i386, i486, i860, i960, m68000, m68k, m88k, mips,
  40.      ns32k, pyramid, romp, rs6000, sh, sparc, sparclite, sparc64, vax,
  41.      we32k.
  42.  
  43.    Here are the recognized company names.  As you can see, customary
  44. abbreviations are used rather than the longer official names.
  45.  
  46.      acorn, alliant, altos, apollo, att, bull, cbm, convergent, convex,
  47.      crds, dec, dg, dolphin, elxsi, encore, harris, hitachi, hp, ibm,
  48.      intergraph, isi, mips, motorola, ncr, next, ns, omron, plexus,
  49.      sequent, sgi, sony, sun, tti, unicom.
  50.  
  51.    The company name is meaningful only to disambiguate when the rest of
  52. the information supplied is insufficient.  You can omit it, writing
  53. just `CPU-SYSTEM', if it is not needed.  For example, `vax-ultrix4.2'
  54. is equivalent to `vax-dec-ultrix4.2'.
  55.  
  56.    Here is a list of system types:
  57.  
  58.      386bsd, aix, acis, amigados, aos, aout, bosx, bsd, clix, ctix,
  59.      cxux, dgux, dynix, ebmon, elf, esix, freebsd, hms, genix, gnu,
  60.      hiux, hpux, iris, irix, isc, linux, luna, lynxos, mach, minix,
  61.      msdos, mvs, netbsd, newsos, nindy, ns, osf, osfrose, riscix,
  62.      riscos, rtu, sco, solaris, sunos, sym, sysv, ultrix, unicos,
  63.      uniplus, unos, vms, vxworks, xenix.
  64.  
  65. You can omit the system type; then `configure' guesses the operating
  66. system from the CPU and company.
  67.  
  68.    You can add a version number to the system type; this may or may not
  69. make a difference.  For example, you can write `bsd4.3' or `bsd4.4' to
  70. distinguish versions of BSD.  In practice, the version number is most
  71. needed for `sysv3' and `sysv4', which are often treated differently.
  72.  
  73.    If you specify an impossible combination such as `i860-dg-vms', then
  74. you may get an error message from `configure', or it may ignore part of
  75. the information and do the best it can with the rest.  `configure'
  76. always prints the canonical name for the alternative that it used.  GNU
  77. CC does not support all possible alternatives.
  78.  
  79.    Often a particular model of machine has a name.  Many machine names
  80. are recognized as aliases for CPU/company combinations.  Thus, the
  81. machine name `sun3', mentioned above, is an alias for `m68k-sun'.
  82. Sometimes we accept a company name as a machine name, when the name is
  83. popularly used for a particular machine.  Here is a table of the known
  84. machine names:
  85.  
  86.      3300, 3b1, 3bN, 7300, altos3068, altos, apollo68, att-7300,
  87.      balance, convex-cN, crds, decstation-3100, decstation, delta,
  88.      encore, fx2800, gmicro, hp7NN, hp8NN, hp9k2NN, hp9k3NN, hp9k7NN,
  89.      hp9k8NN, iris4d, iris, isi68, m3230, magnum, merlin, miniframe,
  90.      mmax, news-3600, news800, news, next, pbd, pc532, pmax, powerpc,
  91.      ps2, risc-news, rtpc, sun2, sun386i, sun386, sun3, sun4, symmetry,
  92.      tower-32, tower.
  93.  
  94. Remember that a machine name specifies both the cpu type and the company
  95. name.  If you want to install your own homemade configuration files,
  96. you can use `local' as the company name to access them.  If you use
  97. configuration `CPU-local', the configuration name without the cpu prefix
  98. is used to form the configuration file names.
  99.  
  100.    Thus, if you specify `m68k-local', configuration uses files
  101. `local.md', `local.h', `local.c', `xm-local.h', `t-local', and
  102. `x-local', all in the directory `config/m68k'.
  103.  
  104.    Here is a list of configurations that have special treatment or
  105. special things you must know:
  106.  
  107. `1750a-*-*'
  108.      MIL-STD-1750A processors.  This port is preliminary.
  109.  
  110.      You should ignore a fatal error during the building of libgcc
  111.      (libgcc is not yet implemented for the 1750A.)
  112.  
  113.      The Tektronix MIL-STD-1750A Assembler requires the file
  114.      `m1750.inc', which is found in the directory `config/1750a'.
  115.  
  116.      GNU CC produced the same sections as the Fairchild F9450 C
  117.      Compiler, namely:
  118.  
  119.     `NREL'
  120.           The program code section.
  121.  
  122.     `SREL'
  123.           The read/write (RAM) data section.
  124.  
  125.     `KREL'
  126.           The read-only (ROM) constants section.
  127.  
  128.     `IREL'
  129.           Initialization section (code to copy KREL to SREL).
  130.  
  131.      The smallest addressable unit is 16 bits (BITS_PER_UNIT is 16).
  132.      This means that type `char' is represented with a 16-bit word per
  133.      character.  The 1750A's "Load/Store Upper/Lower Byte" instructions
  134.      are not used by GNU CC.
  135.  
  136.      There is a problem with long argument lists to functions.  The
  137.      compiler aborts if the sum of space needed by all arguments
  138.      exceeds 14 words.  This is because the arguments are passed in
  139.      registers (R0..R13) not on the stack, and there is a problem with
  140.      passing further arguments (i.e.  beyond those in R0..R13) via the
  141.      stack.
  142.  
  143.      If efficiency is less important than using long argument lists, you
  144.      can change the definition of the `FUNCTION_ARG' macro in
  145.      `config/1750/1750a.h' to always return zero.  If you do that, GNU
  146.      CC will pass all parameters on the stack.
  147.  
  148. `alpha-*-osf1'
  149.      Systems using processors that implement the DEC Alpha architecture
  150.      and are running the OSF/1 operating system, for example the DEC
  151.      Alpha AXP systems.  (VMS on the Alpha is not currently supported
  152.      by GNU CC.)
  153.  
  154.      GNU CC writes a `.verstamp' directive to the assembler output file
  155.      unless it is built as a cross-compiler.  It gets the version to
  156.      use from the system header file `/usr/include/stamp.h'.  If you
  157.      install a new version of OSF/1, you should rebuild GCC to pick up
  158.      the new version stamp.
  159.  
  160.      Note that since the Alpha is a 64-bit architecture,
  161.      cross-compilers from 32-bit machines will not generate code as
  162.      efficient as that generated when the compiler is running on a
  163.      64-bit machine because many optimizations that depend on being
  164.      able to represent a word on the target in an integral value on the
  165.      host cannot be performed.  Building cross-compilers on the Alpha
  166.      for 32-bit machines has only been tested in a few cases and may
  167.      not work properly.
  168.  
  169.      `make compare' may fail on old versions of OSF/1 unless you add
  170.      `-save-temps' to `CFLAGS'.  On these systems, the name of the
  171.      assembler input file is stored in the object file, and that makes
  172.      comparison fail if it differs between the `stage1' and `stage2'
  173.      compilations.  The option `-save-temps' forces a fixed name to be
  174.      used for the assembler input file, instead of a randomly chosen
  175.      name in `/tmp'.  Do not add `-save-temps' unless the comparisons
  176.      fail without that option.  If you add `-save-temps', you will have
  177.      to manually delete the `.i' and `.s' files after each series of
  178.      compilations.
  179.  
  180.      GNU CC now supports both the native (ECOFF) debugging format used
  181.      by DBX and GDB and an encapsulated STABS format for use only with
  182.      GDB.  See the discussion of the `--with-stabs' option of
  183.      `configure' above for more information on these formats and how to
  184.      select them.
  185.  
  186.      There is a bug in DEC's assembler that produces incorrect line
  187.      numbers for ECOFF format when the `.align' directive is used.  To
  188.      work around this problem, GNU CC will not emit such alignment
  189.      directives while writing ECOFF format debugging information even
  190.      if optimization is being performed.  Unfortunately, this has the
  191.      very undesirable side-effect that code addresses when `-O' is
  192.      specified are different depending on whether or not `-g' is also
  193.      specified.
  194.  
  195.      To avoid this behavior, specify `-gstabs+' and use GDB instead of
  196.      DBX.  DEC is now aware of this problem with the assembler and
  197.      hopes to provide a fix shortly.
  198.  
  199. `arm'
  200.      Advanced RISC Machines ARM-family processors.  These are often
  201.      used in embedded applications.  There are no standard Unix
  202.      configurations.  This configuration corresponds to the basic
  203.      instruction sequences and will produce a.out format object modules.
  204.  
  205.      You may need to make a variant of the file `arm.h' for your
  206.      particular configuration.
  207.  
  208. `arm-*-riscix'
  209.      The ARM2 or ARM3 processor running RISC iX, Acorn's port of BSD
  210.      Unix.  If you are running a version of RISC iX prior to 1.2 then
  211.      you must specify the version number during configuration.  Note
  212.      that the assembler shipped with RISC iX does not support stabs
  213.      debugging information; a new version of the assembler, with stabs
  214.      support included, is now available from Acorn.
  215.  
  216. `a29k'
  217.      AMD Am29k-family processors.  These are normally used in embedded
  218.      applications.  There are no standard Unix configurations.  This
  219.      configuration corresponds to AMD's standard calling sequence and
  220.      binary interface and is compatible with other 29k tools.
  221.  
  222.      You may need to make a variant of the file `a29k.h' for your
  223.      particular configuration.
  224.  
  225. `a29k-*-bsd'
  226.      AMD Am29050 used in a system running a variant of BSD Unix.
  227.  
  228. `decstation-*'
  229.      DECstations can support three different personalities: Ultrix, DEC
  230.      OSF/1, and OSF/rose.  To configure GCC for these platforms use the
  231.      following configurations:
  232.  
  233.     `decstation-ultrix'
  234.           Ultrix configuration.
  235.  
  236.     `decstation-osf1'
  237.           Dec's version of OSF/1.
  238.  
  239.     `decstation-osfrose'
  240.           Open Software Foundation reference port of OSF/1 which uses
  241.           the OSF/rose object file format instead of ECOFF.  Normally,
  242.           you would not select this configuration.
  243.  
  244.      The MIPS C compiler needs to be told to increase its table size
  245.      for switch statements with the `-Wf,-XNg1500' option in order to
  246.      compile `cp/parse.c'.  If you use the `-O2' optimization option,
  247.      you also need to use `-Olimit 3000'.  Both of these options are
  248.      automatically generated in the `Makefile' that the shell script
  249.      `configure' builds.  If you override the `CC' make variable and
  250.      use the MIPS compilers, you may need to add `-Wf,-XNg1500 -Olimit
  251.      3000'.
  252.  
  253. `elxsi-elxsi-bsd'
  254.      The Elxsi's C compiler has known limitations that prevent it from
  255.      compiling GNU C.  Please contact `mrs@cygnus.com' for more details.
  256.  
  257. `h8300-*-*'
  258.      The calling convention and structure layout has changed in release
  259.      2.6.  All code must be recompiled.  The calling convention now
  260.      passes the first three arguments in function calls in registers.
  261.      Structures are no longer a multiple of 2 bytes.
  262.  
  263. `hppa*-*-*'
  264.      There are two variants of this CPU, called 1.0 and 1.1, which have
  265.      different machine descriptions.  You must use the right one for
  266.      your machine.  All 7NN machines and 8N7 machines use 1.1, while
  267.      all other 8NN machines use 1.0.
  268.  
  269.      The easiest way to handle this problem is to use `configure hpNNN'
  270.      or `configure hpNNN-hpux', where NNN is the model number of the
  271.      machine.  Then `configure' will figure out if the machine is a 1.0
  272.      or 1.1.  Use `uname -a' to find out the model number of your
  273.      machine.
  274.  
  275.      `-g' does not work on HP-UX, since that system uses a peculiar
  276.      debugging format which GNU CC does not know about.  However, `-g'
  277.      will work if you also use GAS and GDB in conjunction with GCC.  We
  278.      highly recommend using GAS for all HP-PA configurations.
  279.  
  280.      You should be using GAS-2.3 (or later) along with GDB-4.12 (or
  281.      later).  These can be retrieved from all the traditional GNU ftp
  282.      archive sites.
  283.  
  284.      Build GAS and install the resulting binary as:
  285.  
  286.           /usr/local/lib/gcc-lib/CONFIGURATION/GCCVERSION/as
  287.  
  288.      where CONFIGURATION is the configuration name (perhaps
  289.      `hpNNN-hpux') and GCCVERSION is the GNU CC version number.  Do
  290.      this *before* starting the build process, otherwise you will get
  291.      errors from the HPUX assembler while building `libgcc2.a'.  The
  292.      command
  293.  
  294.           make install-dir
  295.  
  296.      will create the necessary directory hierarchy so you can install
  297.      GAS before building GCC.
  298.  
  299.      To enable debugging, configure GNU CC with the `--with-gnu-as'
  300.      option before building.
  301.  
  302.      It has been reported that GNU CC produces invalid assembly code for
  303.      1.1 machines running HP-UX 8.02 when using the HP assembler.
  304.      Typically the errors look like this:
  305.           as: bug.s @line#15 [err#1060]
  306.             Argument 0 or 2 in FARG upper
  307.                    - lookahead = ARGW1=FR,RTNVAL=GR
  308.           as: foo.s @line#28 [err#1060]
  309.             Argument 0 or 2 in FARG upper
  310.                    - lookahead = ARGW1=FR
  311.  
  312.      You can check the version of HP-UX you are running by executing
  313.      the command `uname -r'.   If you are indeed running HP-UX 8.02 on
  314.      a PA and using the HP assembler then configure GCC with
  315.      "hpNNN-hpux8.02".
  316.  
  317. `i370-*-*'
  318.      This port is very preliminary and has many known bugs.  We hope to
  319.      have a higher-quality port for this machine soon.
  320.  
  321. `i386-*-linux'
  322.      Bash-1.12 has a bug that causes configure to fail.  The symptom is
  323.      that the c++ subdirectory, cp, is not configured.  Bash-1.14 and
  324.      later work fine.
  325.  
  326. `i386-*-sco'
  327.      Compilation with RCC is recommended.  Also, it may be a good idea
  328.      to link with GNU malloc instead of the malloc that comes with the
  329.      system.
  330.  
  331. `i386-*-sco3.2.4'
  332.      Use this configuration for SCO release 3.2 version 4.
  333.  
  334. `i386-*-isc'
  335.      It may be good idea to link with GNU malloc instead of the malloc
  336.      that comes with the system.
  337.  
  338. `i386-*-esix'
  339.      It may be good idea to link with GNU malloc instead of the malloc
  340.      that comes with the system.
  341.  
  342. `i386-ibm-aix'
  343.      You need to use GAS version 2.1 or later, and and LD from GNU
  344.      binutils version 2.2 or later.
  345.  
  346. `i386-sequent'
  347.      Go to the Berkeley universe before compiling.  In addition, you
  348.      probably need to create a file named `string.h' containing just
  349.      one line: `#include <strings.h>'.
  350.  
  351. `i386-sun-sunos4'
  352.      You may find that you need another version of GNU CC to begin
  353.      bootstrapping with, since the current version when built with the
  354.      system's own compiler seems to get an infinite loop compiling part
  355.      of `libgcc2.c'.  GNU CC version 2 compiled with GNU CC (any
  356.      version) seems not to have this problem.
  357.  
  358.      See *Note Sun Install::, for information on installing GNU CC on
  359.      Sun systems.
  360.  
  361. `i860-intel-osf1'
  362.      This is the Paragon.  If you have version 1.0 of the operating
  363.      system, see *Note Installation Problems::, for special things you
  364.      need to do to compensate for peculiarities in the system.
  365.  
  366. `m68000-hp-bsd'
  367.      HP 9000 series 200 running BSD.  Note that the C compiler that
  368.      comes with this system cannot compile GNU CC; contact
  369.      `law@cs.utah.edu' to get binaries of GNU CC for bootstrapping.
  370.  
  371. `m68k-altos'
  372.      Altos 3068.  You must use the GNU assembler, linker and debugger.
  373.      Also, you must fix a kernel bug.  Details in the file
  374.      `README.ALTOS'.
  375.  
  376. `m68k-att-sysv'
  377.      AT&T 3b1, a.k.a. 7300 PC.  Special procedures are needed to
  378.      compile GNU CC with this machine's standard C compiler, due to
  379.      bugs in that compiler.  You can bootstrap it more easily with
  380.      previous versions of GNU CC if you have them.
  381.  
  382.      Installing GNU CC on the 3b1 is difficult if you do not already
  383.      have GNU CC running, due to bugs in the installed C compiler.
  384.      However, the following procedure might work.  We are unable to
  385.      test it.
  386.  
  387.        1. Comment out the `#include "config.h"' line on line 37 of
  388.           `cccp.c' and do `make cpp'.  This makes a preliminary version
  389.           of GNU cpp.
  390.  
  391.        2. Save the old `/lib/cpp' and copy the preliminary GNU cpp to
  392.           that file name.
  393.  
  394.        3. Undo your change in `cccp.c', or reinstall the original
  395.           version, and do `make cpp' again.
  396.  
  397.        4. Copy this final version of GNU cpp into `/lib/cpp'.
  398.  
  399.        5. Replace every occurrence of `obstack_free' in the file
  400.           `tree.c' with `_obstack_free'.
  401.  
  402.        6. Run `make' to get the first-stage GNU CC.
  403.  
  404.        7. Reinstall the original version of `/lib/cpp'.
  405.  
  406.        8. Now you can compile GNU CC with itself and install it in the
  407.           normal fashion.
  408.  
  409. `m68k-bull-sysv'
  410.      Bull DPX/2 series 200 and 300 with BOS-2.00.45 up to BOS-2.01. GNU
  411.      CC works either with native assembler or GNU assembler. You can use
  412.      GNU assembler with native coff generation by providing
  413.      `--with-gnu-as' to the configure script or use GNU assembler with
  414.      dbx-in-coff encapsulation by providing `--with-gnu-as --stabs'.
  415.      For any problem with native assembler or for availability of the
  416.      DPX/2 port of GAS, contact `F.Pierresteguy@frcl.bull.fr'.
  417.  
  418. `m68k-crds-unox'
  419.      Use `configure unos' for building on Unos.
  420.  
  421.      The Unos assembler is named `casm' instead of `as'.  For some
  422.      strange reason linking `/bin/as' to `/bin/casm' changes the
  423.      behavior, and does not work.  So, when installing GNU CC, you
  424.      should install the following script as `as' in the subdirectory
  425.      where the passes of GCC are installed:
  426.  
  427.           #!/bin/sh
  428.           casm $*
  429.  
  430.      The default Unos library is named `libunos.a' instead of `libc.a'.
  431.      To allow GNU CC to function, either change all references to
  432.      `-lc' in `gcc.c' to `-lunos' or link `/lib/libc.a' to
  433.      `/lib/libunos.a'.
  434.  
  435.      When compiling GNU CC with the standard compiler, to overcome bugs
  436.      in the support of `alloca', do not use `-O' when making stage 2.
  437.      Then use the stage 2 compiler with `-O' to make the stage 3
  438.      compiler.  This compiler will have the same characteristics as the
  439.      usual stage 2 compiler on other systems.  Use it to make a stage 4
  440.      compiler and compare that with stage 3 to verify proper
  441.      compilation.
  442.  
  443.      (Perhaps simply defining `ALLOCA' in `x-crds' as described in the
  444.      comments there will make the above paragraph superfluous.  Please
  445.      inform us of whether this works.)
  446.  
  447.      Unos uses memory segmentation instead of demand paging, so you
  448.      will need a lot of memory.  5 Mb is barely enough if no other
  449.      tasks are running.  If linking `cc1' fails, try putting the object
  450.      files into a library and linking from that library.
  451.  
  452. `m68k-hp-hpux'
  453.      HP 9000 series 300 or 400 running HP-UX.  HP-UX version 8.0 has a
  454.      bug in the assembler that prevents compilation of GNU CC.  To fix
  455.      it, get patch PHCO_0800 from HP.
  456.  
  457.      In addition, if you wish to use gas `--with-gnu-as' you must use
  458.      gas version 2.1 or later, and you must use the GNU linker version
  459.      2.1 or later.  Earlier versions of gas relied upon a program which
  460.      converted the gas output into the native HP/UX format, but that
  461.      program has not been kept up to date.  gdb does not understand
  462.      that native HP/UX format, so you must use gas if you wish to use
  463.      gdb.
  464.  
  465. `m68k-sun'
  466.      Sun 3.  We do not provide a configuration file to use the Sun FPA
  467.      by default, because programs that establish signal handlers for
  468.      floating point traps inherently cannot work with the FPA.
  469.  
  470.      See *Note Sun Install::, for information on installing GNU CC on
  471.      Sun systems.
  472.  
  473. `m88k-*-svr3'
  474.      Motorola m88k running the AT&T/Unisoft/Motorola V.3 reference port.
  475.      These systems tend to use the Green Hills C, revision 1.8.5, as the
  476.      standard C compiler.  There are apparently bugs in this compiler
  477.      that result in object files differences between stage 2 and stage
  478.      3.  If this happens, make the stage 4 compiler and compare it to
  479.      the stage 3 compiler.  If the stage 3 and stage 4 object files are
  480.      identical, this suggests you encountered a problem with the
  481.      standard C compiler; the stage 3 and 4 compilers may be usable.
  482.  
  483.      It is best, however, to use an older version of GNU CC for
  484.      bootstrapping if you have one.
  485.  
  486. `m88k-*-dgux'
  487.      Motorola m88k running DG/UX.  To build native or cross compilers on
  488.      DG/UX, you must first change to the 88open BCS software development
  489.      environment.  This is done by issuing this command:
  490.  
  491.           eval `sde-target m88kbcs`
  492.  
  493. `m88k-tektronix-sysv3'
  494.      Tektronix XD88 running UTekV 3.2e.  Do not turn on optimization
  495.      while building stage1 if you bootstrap with the buggy Green Hills
  496.      compiler.  Also, The bundled LAI System V NFS is buggy so if you
  497.      build in an NFS mounted directory, start from a fresh reboot, or
  498.      avoid NFS all together.  Otherwise you may have trouble getting
  499.      clean comparisons between stages.
  500.  
  501. `mips-mips-bsd'
  502.      MIPS machines running the MIPS operating system in BSD mode.  It's
  503.      possible that some old versions of the system lack the functions
  504.      `memcpy', `memcmp', and `memset'.  If your system lacks these, you
  505.      must remove or undo the definition of `TARGET_MEM_FUNCTIONS' in
  506.      `mips-bsd.h'.
  507.  
  508.      The MIPS C compiler needs to be told to increase its table size
  509.      for switch statements with the `-Wf,-XNg1500' option in order to
  510.      compile `cp/parse.c'.  If you use the `-O2' optimization option,
  511.      you also need to use `-Olimit 3000'.  Both of these options are
  512.      automatically generated in the `Makefile' that the shell script
  513.      `configure' builds.  If you override the `CC' make variable and
  514.      use the MIPS compilers, you may need to add `-Wf,-XNg1500 -Olimit
  515.      3000'.
  516.  
  517. `mips-mips-riscos*'
  518.      The MIPS C compiler needs to be told to increase its table size
  519.      for switch statements with the `-Wf,-XNg1500' option in order to
  520.      compile `cp/parse.c'.  If you use the `-O2' optimization option,
  521.      you also need to use `-Olimit 3000'.  Both of these options are
  522.      automatically generated in the `Makefile' that the shell script
  523.      `configure' builds.  If you override the `CC' make variable and
  524.      use the MIPS compilers, you may need to add `-Wf,-XNg1500 -Olimit
  525.      3000'.
  526.  
  527.      MIPS computers running RISC-OS can support four different
  528.      personalities: default, BSD 4.3, System V.3, and System V.4 (older
  529.      versions of RISC-OS don't support V.4).  To configure GCC for
  530.      these platforms use the following configurations:
  531.  
  532.     `mips-mips-riscos`rev''
  533.           Default configuration for RISC-OS, revision `rev'.
  534.  
  535.     `mips-mips-riscos`rev'bsd'
  536.           BSD 4.3 configuration for RISC-OS, revision `rev'.
  537.  
  538.     `mips-mips-riscos`rev'sysv4'
  539.           System V.4 configuration for RISC-OS, revision `rev'.
  540.  
  541.     `mips-mips-riscos`rev'sysv'
  542.           System V.3 configuration for RISC-OS, revision `rev'.
  543.  
  544.      The revision `rev' mentioned above is the revision of RISC-OS to
  545.      use.  You must reconfigure GCC when going from a RISC-OS revision
  546.      4 to RISC-OS revision 5.  This has the effect of avoiding a linker
  547.      bug (see *Note Installation Problems::, for more details).
  548.  
  549. `mips-sgi-*'
  550.      Silicon Graphics MIPS machines running IRIX.  In order to compile
  551.      GCC on an SGI the "c.hdr.lib" option must be installed from the
  552.      CD-ROM supplied from Silicon Graphics.  This is found on the 2nd
  553.      CD in release 4.0.1.
  554.  
  555.      `make compare' may fail on version 5 of IRIX unless you add
  556.      `-save-temps' to `CFLAGS'.  On these systems, the name of the
  557.      assembler input file is stored in the object file, and that makes
  558.      comparison fail if it differs between the `stage1' and `stage2'
  559.      compilations.  The option `-save-temps' forces a fixed name to be
  560.      used for the assembler input file, instead of a randomly chosen
  561.      name in `/tmp'.  Do not add `-save-temps' unless the comparisons
  562.      fail without that option.  If you do you `-save-temps', you will
  563.      have to manually delete the `.i' and `.s' files after each series
  564.      of compilations.
  565.  
  566.      The MIPS C compiler needs to be told to increase its table size
  567.      for switch statements with the `-Wf,-XNg1500' option in order to
  568.      compile `cp/parse.c'.  If you use the `-O2' optimization option,
  569.      you also need to use `-Olimit 3000'.  Both of these options are
  570.      automatically generated in the `Makefile' that the shell script
  571.      `configure' builds.  If you override the `CC' make variable and
  572.      use the MIPS compilers, you may need to add `-Wf,-XNg1500 -Olimit
  573.      3000'.
  574.  
  575.      On Irix version 4.0.5F, and perhaps on some other versions as well,
  576.      there is an assembler bug that reorders instructions incorrectly.
  577.      To work around it, specify the target configuration
  578.      `mips-sgi-irix4loser'.  This configuration inhibits assembler
  579.      optimization.
  580.  
  581.      In a compiler configured with target `mips-sgi-irix4', you can turn
  582.      off assembler optimization by using the `-noasmopt' option.  This
  583.      compiler option passes the option `-O0' to the assembler, to
  584.      inhibit reordering.
  585.  
  586.      The `-noasmopt' option can be useful for testing whether a problem
  587.      is due to erroneous assembler reordering.  Even if a problem does
  588.      not go away with `-noasmopt', it may still be due to assembler
  589.      reordering--perhaps GNU CC itself was miscompiled as a result.
  590.  
  591.      See the file `README.IRIX5' for information on how to make
  592.      debugging work.
  593.  
  594. `mips-sony-sysv'
  595.      Sony MIPS NEWS.  This works in NEWSOS 5.0.1, but not in 5.0.2
  596.      (which uses ELF instead of COFF).  Support for 5.0.2 will probably
  597.      be provided soon by volunteers.  In particular, the linker does
  598.      not like the code generated by GCC when shared libraries are
  599.      linked in.
  600.  
  601. `ns32k-encore'
  602.      Encore ns32000 system.  Encore systems are supported only under
  603.      BSD.
  604.  
  605. `ns32k-*-genix'
  606.      National Semiconductor ns32000 system.  Genix has bugs in `alloca'
  607.      and `malloc'; you must get the compiled versions of these from GNU
  608.      Emacs.
  609.  
  610. `ns32k-sequent'
  611.      Go to the Berkeley universe before compiling.  In addition, you
  612.      probably need to create a file named `string.h' containing just
  613.      one line: `#include <strings.h>'.
  614.  
  615. `ns32k-utek'
  616.      UTEK ns32000 system ("merlin").  The C compiler that comes with
  617.      this system cannot compile GNU CC; contact `tektronix!reed!mason'
  618.      to get binaries of GNU CC for bootstrapping.
  619.  
  620. `romp-*-aos'
  621. `romp-*-mach'
  622.      The only operating systems supported for the IBM RT PC are AOS and
  623.      MACH.  GNU CC does not support AIX running on the RT.  We
  624.      recommend you compile GNU CC with an earlier version of itself; if
  625.      you compile GNU CC with `hc', the Metaware compiler, it will work,
  626.      but you will get mismatches between the stage 2 and stage 3
  627.      compilers in various files.  These errors are minor differences in
  628.      some floating-point constants and can be safely ignored; the stage
  629.      3 compiler is correct.
  630.  
  631. `rs6000-*-aix'
  632.      If you are running AIX version 3.2.5 and have XLC version 1.3.0.0,
  633.      you must obtain XLC 1.3.0.2 by requesting PTF 421749 from IBM.  If
  634.      you are using an older version of AIX you may have an old version
  635.      of the IBM assembler, which cannot correctly handle debugging
  636.      directives.  See the file `README.RS6000' for more details.
  637.  
  638.      The PowerPC and POWER2 architectures are now supported, but have
  639.      not been very extensively tested due to lack of appropriate
  640.      systems.  Only AIX is supported on the PowerPC.  GNU CC does not
  641.      yet support the 64-bit PowerPC instructions.
  642.  
  643.      Objective C does not work on this architecture.
  644.  
  645.      AIX on the RS/6000 provides support (NLS) for environments outside
  646.      of the United States.  Compilers and assemblers use NLS to support
  647.      locale-specific representations of various objects including
  648.      floating-point numbers ("." vs "," for separating decimal
  649.      fractions).  There have been problems reported where the library
  650.      linked with GNU CC does not produce the same floating-point
  651.      formats that the assembler accepts.  If you have this problem, set
  652.      the LANG environment variable to "C" or "En_US".
  653.  
  654. `vax-dec-ultrix'
  655.      Don't try compiling with Vax C (`vcc').  It produces incorrect code
  656.      in some cases (for example, when `alloca' is used).
  657.  
  658.      Meanwhile, compiling `cp/parse.c' with pcc does not work because of
  659.      an internal table size limitation in that compiler.  To avoid this
  660.      problem, compile just the GNU C compiler first, and use it to
  661.      recompile building all the languages that you want to run.
  662.  
  663. `sparc-sun-*'
  664.      See *Note Sun Install::, for information on installing GNU CC on
  665.      Sun systems.
  666.  
  667. `vax-dec-vms'
  668.      See *Note VMS Install::, for details on how to install GNU CC on
  669.      VMS.
  670.  
  671. `we32k-*-*'
  672.      These computers are also known as the 3b2, 3b5, 3b20 and other
  673.      similar names.  (However, the 3b1 is actually a 68000; see *Note
  674.      Configurations::.)
  675.  
  676.      Don't use `-g' when compiling with the system's compiler.  The
  677.      system's linker seems to be unable to handle such a large program
  678.      with debugging information.
  679.  
  680.      The system's compiler runs out of capacity when compiling `stmt.c'
  681.      in GNU CC.  You can work around this by building `cpp' in GNU CC
  682.      first, then use that instead of the system's preprocessor with the
  683.      system's C compiler to compile `stmt.c'.  Here is how:
  684.  
  685.           mv /lib/cpp /lib/cpp.att
  686.           cp cpp /lib/cpp.gnu
  687.           echo '/lib/cpp.gnu -traditional ${1+"$@"}' > /lib/cpp
  688.           chmod +x /lib/cpp
  689.  
  690.      The system's compiler produces bad code for some of the GNU CC
  691.      optimization files.  So you must build the stage 2 compiler without
  692.      optimization.  Then build a stage 3 compiler with optimization.
  693.      That executable should work.  Here are the necessary commands:
  694.  
  695.           make LANGUAGES=c CC=stage1/xgcc CFLAGS="-Bstage1/ -g"
  696.           make stage2
  697.           make CC=stage2/xgcc CFLAGS="-Bstage2/ -g -O"
  698.  
  699.      You may need to raise the ULIMIT setting to build a C++ compiler,
  700.      as the file `cc1plus' is larger than one megabyte.
  701.  
  702. 
  703. File: gcc.info,  Node: Other Dir,  Next: Cross-Compiler,  Prev: Configurations,  Up: Installation
  704.  
  705. Compilation in a Separate Directory
  706. ===================================
  707.  
  708.    If you wish to build the object files and executables in a directory
  709. other than the one containing the source files, here is what you must
  710. do differently:
  711.  
  712.   1. Make sure you have a version of Make that supports the `VPATH'
  713.      feature.  (GNU Make supports it, as do Make versions on most BSD
  714.      systems.)
  715.  
  716.   2. If you have ever run `configure' in the source directory, you must
  717.      undo the configuration.  Do this by running:
  718.  
  719.           make distclean
  720.  
  721.   3. Go to the directory in which you want to build the compiler before
  722.      running `configure':
  723.  
  724.           mkdir gcc-sun3
  725.           cd gcc-sun3
  726.  
  727.      On systems that do not support symbolic links, this directory must
  728.      be on the same file system as the source code directory.
  729.  
  730.   4. Specify where to find `configure' when you run it:
  731.  
  732.           ../gcc/configure ...
  733.  
  734.      This also tells `configure' where to find the compiler sources;
  735.      `configure' takes the directory from the file name that was used to
  736.      invoke it.  But if you want to be sure, you can specify the source
  737.      directory with the `--srcdir' option, like this:
  738.  
  739.           ../gcc/configure --srcdir=../gcc sun3
  740.  
  741.      The directory you specify with `--srcdir' need not be the same as
  742.      the one that `configure' is found in.
  743.  
  744.    Now, you can run `make' in that directory.  You need not repeat the
  745. configuration steps shown above, when ordinary source files change.  You
  746. must, however, run `configure' again when the configuration files
  747. change, if your system does not support symbolic links.
  748.  
  749. 
  750. File: gcc.info,  Node: Cross-Compiler,  Next: Sun Install,  Prev: Other Dir,  Up: Installation
  751.  
  752. Building and Installing a Cross-Compiler
  753. ========================================
  754.  
  755.    GNU CC can function as a cross-compiler for many machines, but not
  756. all.
  757.  
  758.    * Cross-compilers for the Mips as target using the Mips assembler
  759.      currently do not work, because the auxiliary programs
  760.      `mips-tdump.c' and `mips-tfile.c' can't be compiled on anything
  761.      but a Mips.  It does work to cross compile for a Mips if you use
  762.      the GNU assembler and linker.
  763.  
  764.    * Cross-compilers between machines with different floating point
  765.      formats have not all been made to work.  GNU CC now has a floating
  766.      point emulator with which these can work, but each target machine
  767.      description needs to be updated to take advantage of it.
  768.  
  769.    * Cross-compilation between machines of different word sizes has not
  770.      really been addressed yet.
  771.  
  772.    Since GNU CC generates assembler code, you probably need a
  773. cross-assembler that GNU CC can run, in order to produce object files.
  774. If you want to link on other than the target machine, you need a
  775. cross-linker as well.  You also need header files and libraries suitable
  776. for the target machine that you can install on the host machine.
  777.  
  778. * Menu:
  779.  
  780. * Steps of Cross::      Using a cross-compiler involves several steps
  781.                           that may be carried out on different machines.
  782. * Configure Cross::     Configuring a cross-compiler.
  783. * Tools and Libraries:: Where to put the linker and assembler, and the C library.
  784. * Cross Headers::       Finding and installing header files
  785.                           for a cross-compiler.
  786. * Cross Runtime::       Supplying arithmetic runtime routines (`libgcc1.a').
  787. * Build Cross::         Actually compiling the cross-compiler.
  788.  
  789. 
  790. File: gcc.info,  Node: Steps of Cross,  Next: Configure Cross,  Up: Cross-Compiler
  791.  
  792. Steps of Cross-Compilation
  793. --------------------------
  794.  
  795.    To compile and run a program using a cross-compiler involves several
  796. steps:
  797.  
  798.    * Run the cross-compiler on the host machine to produce assembler
  799.      files for the target machine.  This requires header files for the
  800.      target machine.
  801.  
  802.    * Assemble the files produced by the cross-compiler.  You can do this
  803.      either with an assembler on the target machine, or with a
  804.      cross-assembler on the host machine.
  805.  
  806.    * Link those files to make an executable.  You can do this either
  807.      with a linker on the target machine, or with a cross-linker on the
  808.      host machine.  Whichever machine you use, you need libraries and
  809.      certain startup files (typically `crt....o') for the target
  810.      machine.
  811.  
  812.    It is most convenient to do all of these steps on the same host
  813. machine, since then you can do it all with a single invocation of GNU
  814. CC.  This requires a suitable cross-assembler and cross-linker.  For
  815. some targets, the GNU assembler and linker are available.
  816.  
  817. 
  818. File: gcc.info,  Node: Configure Cross,  Next: Tools and Libraries,  Prev: Steps of Cross,  Up: Cross-Compiler
  819.  
  820. Configuring a Cross-Compiler
  821. ----------------------------
  822.  
  823.    To build GNU CC as a cross-compiler, you start out by running
  824. `configure'.  You must specify two different configurations, the host
  825. and the target.  Use the `--host=HOST' option for the host and
  826. `--target=TARGET' to specify the target type.  For example, here is how
  827. to configure for a cross-compiler that runs on a hypothetical Intel 386
  828. system and produces code for an HP 68030 system running BSD:
  829.  
  830.      ./configure --target=m68k-hp-bsd4.3 --host=i386-bozotheclone-bsd4.3
  831.  
  832. 
  833. File: gcc.info,  Node: Tools and Libraries,  Next: Cross Headers,  Prev: Configure Cross,  Up: Cross-Compiler
  834.  
  835. Tools and Libraries for a Cross-Compiler
  836. ----------------------------------------
  837.  
  838.    If you have a cross-assembler and cross-linker available, you should
  839. install them now.  Put them in the directory `/usr/local/TARGET/bin'.
  840. Here is a table of the tools you should put in this directory:
  841.  
  842. `as'
  843.      This should be the cross-assembler.
  844.  
  845. `ld'
  846.      This should be the cross-linker.
  847.  
  848. `ar'
  849.      This should be the cross-archiver: a program which can manipulate
  850.      archive files (linker libraries) in the target machine's format.
  851.  
  852. `ranlib'
  853.      This should be a program to construct a symbol table in an archive
  854.      file.
  855.  
  856.    The installation of GNU CC will find these programs in that
  857. directory, and copy or link them to the proper place to for the
  858. cross-compiler to find them when run later.
  859.  
  860.    The easiest way to provide these files is to build the Binutils
  861. package and GAS.  Configure them with the same `--host' and `--target'
  862. options that you use for configuring GNU CC, then build and install
  863. them.  They install their executables automatically into the proper
  864. directory.  Alas, they do not support all the targets that GNU CC
  865. supports.
  866.  
  867.    If you want to install libraries to use with the cross-compiler,
  868. such as a standard C library, put them in the directory
  869. `/usr/local/TARGET/lib'; installation of GNU CC copies all all the
  870. files in that subdirectory into the proper place for GNU CC to find
  871. them and link with them.  Here's an example of copying some libraries
  872. from a target machine:
  873.  
  874.      ftp TARGET-MACHINE
  875.      lcd /usr/local/TARGET/lib
  876.      cd /lib
  877.      get libc.a
  878.      cd /usr/lib
  879.      get libg.a
  880.      get libm.a
  881.      quit
  882.  
  883. The precise set of libraries you'll need, and their locations on the
  884. target machine, vary depending on its operating system.
  885.  
  886.    Many targets require "start files" such as `crt0.o' and `crtn.o'
  887. which are linked into each executable; these too should be placed in
  888. `/usr/local/TARGET/lib'.  There may be several alternatives for
  889. `crt0.o', for use with profiling or other compilation options.  Check
  890. your target's definition of `STARTFILE_SPEC' to find out what start
  891. files it uses.  Here's an example of copying these files from a target
  892. machine:
  893.  
  894.      ftp TARGET-MACHINE
  895.      lcd /usr/local/TARGET/lib
  896.      prompt
  897.      cd /lib
  898.      mget *crt*.o
  899.      cd /usr/lib
  900.      mget *crt*.o
  901.      quit
  902.  
  903. 
  904. File: gcc.info,  Node: Cross Runtime,  Next: Build Cross,  Prev: Cross Headers,  Up: Cross-Compiler
  905.  
  906. `libgcc.a' and Cross-Compilers
  907. ------------------------------
  908.  
  909.    Code compiled by GNU CC uses certain runtime support functions
  910. implicitly.  Some of these functions can be compiled successfully with
  911. GNU CC itself, but a few cannot be.  These problem functions are in the
  912. source file `libgcc1.c'; the library made from them is called
  913. `libgcc1.a'.
  914.  
  915.    When you build a native compiler, these functions are compiled with
  916. some other compiler-the one that you use for bootstrapping GNU CC.
  917. Presumably it knows how to open code these operations, or else knows how
  918. to call the run-time emulation facilities that the machine comes with.
  919. But this approach doesn't work for building a cross-compiler.  The
  920. compiler that you use for building knows about the host system, not the
  921. target system.
  922.  
  923.    So, when you build a cross-compiler you have to supply a suitable
  924. library `libgcc1.a' that does the job it is expected to do.
  925.  
  926.    To compile `libgcc1.c' with the cross-compiler itself does not work.
  927. The functions in this file are supposed to implement arithmetic
  928. operations that GNU CC does not know how to open code, for your target
  929. machine.  If these functions are compiled with GNU CC itself, they will
  930. compile into infinite recursion.
  931.  
  932.    On any given target, most of these functions are not needed.  If GNU
  933. CC can open code an arithmetic operation, it will not call these
  934. functions to perform the operation.  It is possible that on your target
  935. machine, none of these functions is needed.  If so, you can supply an
  936. empty library as `libgcc1.a'.
  937.  
  938.    Many targets need library support only for multiplication and
  939. division.  If you are linking with a library that contains functions for
  940. multiplication and division, you can tell GNU CC to call them directly
  941. by defining the macros `MULSI3_LIBCALL', and the like.  These macros
  942. need to be defined in the target description macro file.  For some
  943. targets, they are defined already.  This may be sufficient to avoid the
  944. need for libgcc1.a; if so, you can supply an empty library.
  945.  
  946.    Some targets do not have floating point instructions; they need other
  947. functions in `libgcc1.a', which do floating arithmetic.  Recent
  948. versions of GNU CC have a file which emulates floating point.  With a
  949. certain amount of work, you should be able to construct a floating
  950. point emulator that can be used as `libgcc1.a'.  Perhaps future
  951. versions will contain code to do this automatically and conveniently.
  952. That depends on whether someone wants to implement it.
  953.  
  954.    If your target system has another C compiler, you can configure GNU
  955. CC as a native compiler on that machine, build just `libgcc1.a' with
  956. `make libgcc1.a' on that machine, and use the resulting file with the
  957. cross-compiler.  To do this, execute the following on the target
  958. machine:
  959.  
  960.      cd TARGET-BUILD-DIR
  961.      ./configure --host=sparc --target=sun3
  962.      make libgcc1.a
  963.  
  964. And then this on the host machine:
  965.  
  966.      ftp TARGET-MACHINE
  967.      binary
  968.      cd TARGET-BUILD-DIR
  969.      get libgcc1.a
  970.      quit
  971.  
  972.    Another way to provide the functions you need in `libgcc1.a' is to
  973. define the appropriate `perform_...' macros for those functions.  If
  974. these definitions do not use the C arithmetic operators that they are
  975. meant to implement, you should be able to compile them with the
  976. cross-compiler you are building.  (If these definitions already exist
  977. for your target file, then you are all set.)
  978.  
  979.    To build `libgcc1.a' using the perform macros, use
  980. `LIBGCC1=libgcc1.a OLDCC=./xgcc' when building the compiler.
  981. Otherwise, you should place your replacement library under the name
  982. `libgcc1.a' in the directory in which you will build the
  983. cross-compiler, before you run `make'.
  984.  
  985. 
  986. File: gcc.info,  Node: Cross Headers,  Next: Cross Runtime,  Prev: Tools and Libraries,  Up: Cross-Compiler
  987.  
  988. Cross-Compilers and Header Files
  989. --------------------------------
  990.  
  991.    If you are cross-compiling a standalone program or a program for an
  992. embedded system, then you may not need any header files except the few
  993. that are part of GNU CC (and those of your program).  However, if you
  994. intend to link your program with a standard C library such as `libc.a',
  995. then you probably need to compile with the header files that go with
  996. the library you use.
  997.  
  998.    The GNU C compiler does not come with these files, because (1) they
  999. are system-specific, and (2) they belong in a C library, not in a
  1000. compiler.
  1001.  
  1002.    If the GNU C library supports your target machine, then you can get
  1003. the header files from there (assuming you actually use the GNU library
  1004. when you link your program).
  1005.  
  1006.    If your target machine comes with a C compiler, it probably comes
  1007. with suitable header files also.  If you make these files accessible
  1008. from the host machine, the cross-compiler can use them also.
  1009.  
  1010.    Otherwise, you're on your own in finding header files to use when
  1011. cross-compiling.
  1012.  
  1013.    When you have found suitable header files, put them in
  1014. `/usr/local/TARGET/include', before building the cross compiler.  Then
  1015. installation will run fixincludes properly and install the corrected
  1016. versions of the header files where the compiler will use them.
  1017.  
  1018.    Provide the header files before you build the cross-compiler, because
  1019. the build stage actually runs the cross-compiler to produce parts of
  1020. `libgcc.a'.  (These are the parts that *can* be compiled with GNU CC.)
  1021. Some of them need suitable header files.
  1022.  
  1023.    Here's an example showing how to copy the header files from a target
  1024. machine.  On the target machine, do this:
  1025.  
  1026.      (cd /usr/include; tar cf - .) > tarfile
  1027.  
  1028.    Then, on the host machine, do this:
  1029.  
  1030.      ftp TARGET-MACHINE
  1031.      lcd /usr/local/TARGET/include
  1032.      get tarfile
  1033.      quit
  1034.      tar xf tarfile
  1035.  
  1036. 
  1037. File: gcc.info,  Node: Build Cross,  Prev: Cross Runtime,  Up: Cross-Compiler
  1038.  
  1039. Actually Building the Cross-Compiler
  1040. ------------------------------------
  1041.  
  1042.    Now you can proceed just as for compiling a single-machine compiler
  1043. through the step of building stage 1.  If you have not provided some
  1044. sort of `libgcc1.a', then compilation will give up at the point where
  1045. it needs that file, printing a suitable error message.  If you do
  1046. provide `libgcc1.a', then building the compiler will automatically
  1047. compile and link a test program called `cross-test'; if you get errors
  1048. in the linking, it means that not all of the necessary routines in
  1049. `libgcc1.a' are available.
  1050.  
  1051.    If you are making a cross-compiler for an embedded system, and there
  1052. is no `stdio.h' header for it, then the compilation of `enquire' will
  1053. probably fail.  The job of `enquire' is to run on the target machine
  1054. and figure out by experiment the nature of its floating point
  1055. representation.  `enquire' records its findings in the header file
  1056. `float.h'.  If you can't produce this file by running `enquire' on the
  1057. target machine, then you will need to come up with a suitable `float.h'
  1058. in some other way (or else, avoid using it in your programs).
  1059.  
  1060.    Do not try to build stage 2 for a cross-compiler.  It doesn't work to
  1061. rebuild GNU CC as a cross-compiler using the cross-compiler, because
  1062. that would produce a program that runs on the target machine, not on the
  1063. host.  For example, if you compile a 386-to-68030 cross-compiler with
  1064. itself, the result will not be right either for the 386 (because it was
  1065. compiled into 68030 code) or for the 68030 (because it was configured
  1066. for a 386 as the host).  If you want to compile GNU CC into 68030 code,
  1067. whether you compile it on a 68030 or with a cross-compiler on a 386, you
  1068. must specify a 68030 as the host when you configure it.
  1069.  
  1070.    To install the cross-compiler, use `make install', as usual.
  1071.  
  1072. 
  1073. File: gcc.info,  Node: Sun Install,  Next: VMS Install,  Prev: Cross-Compiler,  Up: Installation
  1074.  
  1075. Installing GNU CC on the Sun
  1076. ============================
  1077.  
  1078.    On Solaris (version 2.1), do not use the linker or other tools in
  1079. `/usr/ucb' to build GNU CC.  Use `/usr/ccs/bin'.
  1080.  
  1081.    Make sure the environment variable `FLOAT_OPTION' is not set when
  1082. you compile `libgcc.a'.  If this option were set to `f68881' when
  1083. `libgcc.a' is compiled, the resulting code would demand to be linked
  1084. with a special startup file and would not link properly without special
  1085. pains.
  1086.  
  1087.    There is a bug in `alloca' in certain versions of the Sun library.
  1088. To avoid this bug, install the binaries of GNU CC that were compiled by
  1089. GNU CC.  They use `alloca' as a built-in function and never the one in
  1090. the library.
  1091.  
  1092.    Some versions of the Sun compiler crash when compiling GNU CC.  The
  1093. problem is a segmentation fault in cpp.  This problem seems to be due to
  1094. the bulk of data in the environment variables.  You may be able to avoid
  1095. it by using the following command to compile GNU CC with Sun CC:
  1096.  
  1097.      make CC="TERMCAP=x OBJS=x LIBFUNCS=x STAGESTUFF=x cc"
  1098.  
  1099.