@@ -65,7 +65,7 @@ cmake -S <path-to-llvm-project>/llvm \
6565
6666By default, the enabled runtimes will only be built for the host platform
6767(` -DLLVM_RUNTIME_TARGETS=default ` ). To add additional targets to support
68- cross-compilation via ` flang-new --target=<target-triple> ` , add more triples to
68+ cross-compilation via ` flang --target=<target-triple> ` , add more triples to
6969` LLVM_RUNTIME_TARGETS ` , such as
7070` -DLLVM_RUNTIME_TARGETS="default;aarch64-linux-gnu" ` .
7171
@@ -84,7 +84,7 @@ Instead of building Clang and Flang from scratch, the Runtime-only build uses
8484CMake's environment introspection to find a C, C++, and Fortran compiler. The
8585compiler to be used can be controlled using CMake's standard mechanisms such as
8686` CMAKE_CXX_COMPILER ` , ` CMAKE_CXX_COMPILER ` , and ` CMAKE_Fortran_COMPILER ` .
87- ` CMAKE_Fortran_COMPILER ` must be ` flang-new ` built from the same Git commit as
87+ ` CMAKE_Fortran_COMPILER ` must be ` flang ` built from the same Git commit as
8888flang-rt to ensure they are using the same ABI. The C and C++ compiler
8989can be any compiler supporting the same ABI.
9090
@@ -94,12 +94,12 @@ Use `CMAKE_BINARY_DIR` to point to directory where LLVM has been built.
9494A simple build configuration might look like the following:
9595
9696``` bash
97- cmake -S < path-to-llvm-project> /runtimes \
98- -GNinja \
99- -DLLVM_BINARY_DIR=< path-to-llvm-builddir> \
100- -DCMAKE_Fortran_COMPILER=< path-to-llvm-builddir> /bin/flang-new \
101- -DCMAKE_Fortran_COMPILER_WORKS=yes \
102- -DLLVM_ENABLE_RUNTIMES=flang-rt \
97+ cmake -S < path-to-llvm-project> /runtimes \
98+ -GNinja \
99+ -DLLVM_BINARY_DIR=< path-to-llvm-builddir> \
100+ -DCMAKE_Fortran_COMPILER=< path-to-llvm-builddir> /bin/flang \
101+ -DCMAKE_Fortran_COMPILER_WORKS=yes \
102+ -DLLVM_ENABLE_RUNTIMES=flang-rt \
103103 ...
104104```
105105
@@ -116,19 +116,19 @@ driver using the `-L` option.
116116A more complete build configuration could be the following:
117117
118118``` bash
119- cmake -S < path-to-llvm-project> /runtimes \
120- -GNinja \
121- -DCMAKE_BUILD_TYPE=Release \
122- -DCMAKE_INSTALL_PREFIX=" ${HOME} /local" \
123- -DLLVM_ENABLE_RUNTIMES=" compiler-rt;flang-rt" \
124- -DCMAKE_C_COMPILER=gcc \
125- -DCMAKE_CXX_COMPILER=g++ \
126- -DLLVM_BINARY_DIR=< path-to-llvm-builddir> \
127- -DLLVM_DIR=< path-to-llvm-builddir> /lib/cmake/llvm \
128- -DClang_DIR=< path-to-llvm-builddir> /lib/cmake/clang \
129- -DCMAKE_Fortran_COMPILER=< path-to-llvm-builddir-or-installprefix> /bin/flang-new \
130- -DLLVM_DEFAULT_TARGET_TRIPLE=x86_64-linux-gnu \
131- -DLLVM_RUNTIMES_TARGET=x86_64-linux-gnu \
119+ cmake -S < path-to-llvm-project> /runtimes \
120+ -GNinja \
121+ -DCMAKE_BUILD_TYPE=Release \
122+ -DCMAKE_INSTALL_PREFIX=" ${HOME} /local" \
123+ -DLLVM_ENABLE_RUNTIMES=" compiler-rt;flang-rt" \
124+ -DCMAKE_C_COMPILER=gcc \
125+ -DCMAKE_CXX_COMPILER=g++ \
126+ -DLLVM_BINARY_DIR=< path-to-llvm-builddir> \
127+ -DLLVM_DIR=< path-to-llvm-builddir> /lib/cmake/llvm \
128+ -DClang_DIR=< path-to-llvm-builddir> /lib/cmake/clang \
129+ -DCMAKE_Fortran_COMPILER=< path-to-llvm-builddir-or-installprefix> /bin/flang \
130+ -DLLVM_DEFAULT_TARGET_TRIPLE=x86_64-linux-gnu \
131+ -DLLVM_RUNTIMES_TARGET=x86_64-linux-gnu \
132132 ...
133133```
134134
0 commit comments