X-Git-Url: http://plrg.eecs.uci.edu/git/?a=blobdiff_plain;f=docs%2FGCCFEBuildInstrs.html;h=6eb409b79c278324024a5ca4891199bce0367e52;hb=21e993c1b1083ef91441a363997d0efc8e646191;hp=e58533e75a9db83ff6a1525a75d503fba110e54e;hpb=d9c9bf77d82a00c2fe34db2da00244523f4ac288;p=oota-llvm.git diff --git a/docs/GCCFEBuildInstrs.html b/docs/GCCFEBuildInstrs.html index e58533e75a9..6eb409b79c2 100644 --- a/docs/GCCFEBuildInstrs.html +++ b/docs/GCCFEBuildInstrs.html @@ -8,9 +8,9 @@ -
+

Building the LLVM GCC Front-End -

+
  1. Building llvm-gcc from Source
  2. @@ -24,10 +24,10 @@ -

    Building llvm-gcc from Source

    +

    Building llvm-gcc from Source

    -
    +

    This section describes how to acquire and build llvm-gcc 4.2, which is based on the GCC 4.2.1 front-end. Supported languages are Ada, C, C++, Fortran, @@ -67,10 +67,10 @@ svn co http://llvm.org/svn/llvm-project/llvm-gcc-4.2/trunk dst-directory

    -

    Building the Ada front-end

    +

    Building the Ada front-end

    -
    +

    Building with support for Ada amounts to following the directions in the top-level README.LLVM file, adding ",ada" to EXTRALANGS, for example: EXTRALANGS=,ada

    @@ -84,10 +84,11 @@ top-level README.LLVM file, adding ",ada" to EXTRALANGS, for example:
  3. The build requires having a compiler that supports Ada, C and C++. The Ada front-end is written in Ada so an Ada compiler is needed to build it. Compilers known to work with the - LLVM 2.5 release + LLVM 2.7 release are gcc-4.2 and the 2005, 2006 and 2007 versions of the GNAT GPL Edition. + GNAT GPL 2008, gcc-4.3 and later will not work. The LLVM parts of llvm-gcc are written in C++ so a C++ compiler is needed to build them. The rest of gcc is written in C. Some linux distributions provide a version of gcc that supports all @@ -99,7 +100,12 @@ top-level README.LLVM file, adding ",ada" to EXTRALANGS, for example:

  4. Because the Ada front-end is experimental, it is wise to build the compiler with checking enabled. This causes it to run much slower, but helps catch mistakes in the compiler (please report any problems using - LLVM bugzilla).

  5. + LLVM bugzilla).

    +
  6. The Ada front-end fails to + bootstrap, due to lack of LLVM support for + setjmp/longjmp style exception handling (used + internally by the compiler), so you must specify + --disable-bootstrap.

Supposing appropriate compilers are available, llvm-gcc with Ada support can @@ -110,9 +116,9 @@ top-level README.LLVM file, adding ",ada" to EXTRALANGS, for example: and unpack it:

-wget http://llvm.org/releases/2.5/llvm-2.5.tar.gz
-tar xzf llvm-2.5.tar.gz
-mv llvm-2.5 llvm
+wget http://llvm.org/releases/2.7/llvm-2.7.tgz
+tar xzf llvm-2.7.tgz
+mv llvm-2.7 llvm
 

or check out the @@ -127,9 +133,9 @@ mv llvm-2.5 llvm and unpack it:

-wget http://llvm.org/releases/2.5/llvm-gcc-4.2-2.5.source.tar.gz
-tar xzf llvm-gcc-4.2-2.5.source.tar.gz
-mv llvm-gcc4.2-2.5.source llvm-gcc-4.2
+wget http://llvm.org/releases/2.7/llvm-gcc-4.2-2.7.source.tgz
+tar xzf llvm-gcc-4.2-2.7.source.tgz
+mv llvm-gcc-4.2-2.7.source llvm-gcc-4.2
 

or check out the @@ -152,29 +158,32 @@ cd llvm-objects

  • Configure LLVM (here it is configured to install into /usr/local):

    -../llvm/configure --prefix=/usr/local
    +../llvm/configure --prefix=/usr/local --enable-optimized --enable-assertions
     

    If you have a multi-compiler setup and the C++ compiler is not the default, then you can configure like this:

    -CXX=PATH_TO_C++_COMPILER ../llvm/configure --prefix=/usr/local
    +CXX=PATH_TO_C++_COMPILER ../llvm/configure --prefix=/usr/local --enable-optimized --enable-assertions
     
    + +

    To compile without checking (not recommended), replace + --enable-assertions with --disable-assertions.

    +
  • -
  • Build LLVM with checking enabled (use ENABLE_OPTIMIZED=1 to - build without checking):

    +
  • Build LLVM:

    -make ENABLE_OPTIMIZED=0
    +make
     
  • Install LLVM (optional):

    -make ENABLE_OPTIMIZED=0 install
    +make install
     
  • @@ -190,7 +199,8 @@ cd llvm-gcc-4.2-objects
  • Configure llvm-gcc (here it is configured to install into /usr/local). The --enable-checking flag turns on sanity checks inside the compiler. - If you omit it then LLVM should be built with make ENABLE_OPTIMIZED=1. + To turn off these checks (not recommended), replace --enable-checking + with --disable-checking. Additional languages can be appended to the --enable-languages switch, for example --enable-languages=ada,c,c++.

    @@ -223,10 +233,10 @@ make install -

    Building the Fortran front-end

    +

    Building the Fortran front-end

    -
    +

    To build with support for Fortran, follow the directions in the top-level README.LLVM file, adding ",fortran" to EXTRALANGS, for example:

    @@ -237,10 +247,10 @@ EXTRALANGS=,fortran
    -

    License Information

    +

    License Information

    -
    +

    The LLVM GCC frontend is licensed to you under the GNU General Public License and the GNU Lesser General Public License. Please see the files COPYING and @@ -261,7 +271,7 @@ More information is available in the FAQ. Valid HTML 4.01 - LLVM Compiler Infrastructure
    + LLVM Compiler Infrastructure
    Last modified: $Date$