@@ -138,6 +138,23 @@ foreach(proj ${LLVM_ENABLE_PROJECTS})
138
138
endif ()
139
139
endforeach ()
140
140
141
+ # Select the runtimes to build
142
+ #
143
+ # As we migrate runtimes to using the bootstrapping build, the set of default runtimes
144
+ # should grow as we remove those runtimes from LLVM_ENABLE_PROJECTS above.
145
+ set (LLVM_DEFAULT_RUNTIMES "libcxx;libcxxabi;libunwind" )
146
+ set (LLVM_SUPPORTED_RUNTIMES "libc;libunwind;libcxxabi;pstl;libcxx;compiler-rt;openmp;llvm-libgcc;offload;flang-rt" )
147
+ set (LLVM_ENABLE_RUNTIMES "" CACHE STRING
148
+ "Semicolon-separated list of runtimes to build, or \" all\" (${LLVM_DEFAULT_RUNTIMES} ). Supported runtimes are ${LLVM_SUPPORTED_RUNTIMES} ." )
149
+ if (LLVM_ENABLE_RUNTIMES STREQUAL "all" )
150
+ set (LLVM_ENABLE_RUNTIMES ${LLVM_DEFAULT_RUNTIMES} )
151
+ endif ()
152
+ foreach (proj IN LISTS LLVM_ENABLE_RUNTIMES)
153
+ if (NOT "${proj} " IN_LIST LLVM_SUPPORTED_RUNTIMES)
154
+ message (FATAL_ERROR "Runtime \" ${proj} \" is not a supported runtime. Supported runtimes are: ${LLVM_SUPPORTED_RUNTIMES} " )
155
+ endif ()
156
+ endforeach ()
157
+
141
158
if ("flang" IN_LIST LLVM_ENABLE_PROJECTS)
142
159
if (NOT "mlir" IN_LIST LLVM_ENABLE_PROJECTS)
143
160
message (STATUS "Enabling MLIR as a dependency to flang" )
@@ -190,23 +207,6 @@ if ("flang-rt" IN_LIST LLVM_ENABLE_RUNTIMES)
190
207
endif ()
191
208
endif ()
192
209
193
- # Select the runtimes to build
194
- #
195
- # As we migrate runtimes to using the bootstrapping build, the set of default runtimes
196
- # should grow as we remove those runtimes from LLVM_ENABLE_PROJECTS above.
197
- set (LLVM_DEFAULT_RUNTIMES "libcxx;libcxxabi;libunwind" )
198
- set (LLVM_SUPPORTED_RUNTIMES "libc;libunwind;libcxxabi;pstl;libcxx;compiler-rt;openmp;llvm-libgcc;offload;flang-rt" )
199
- set (LLVM_ENABLE_RUNTIMES "" CACHE STRING
200
- "Semicolon-separated list of runtimes to build, or \" all\" (${LLVM_DEFAULT_RUNTIMES} ). Supported runtimes are ${LLVM_SUPPORTED_RUNTIMES} ." )
201
- if (LLVM_ENABLE_RUNTIMES STREQUAL "all" )
202
- set (LLVM_ENABLE_RUNTIMES ${LLVM_DEFAULT_RUNTIMES} )
203
- endif ()
204
- foreach (proj IN LISTS LLVM_ENABLE_RUNTIMES)
205
- if (NOT "${proj} " IN_LIST LLVM_SUPPORTED_RUNTIMES)
206
- message (FATAL_ERROR "Runtime \" ${proj} \" is not a supported runtime. Supported runtimes are: ${LLVM_SUPPORTED_RUNTIMES} " )
207
- endif ()
208
- endforeach ()
209
-
210
210
# Set a shorthand option to enable the GPU build of the 'libc' project.
211
211
option (LIBC_GPU_BUILD "Enable the 'libc' project targeting the GPU" OFF )
212
212
if (LIBC_GPU_BUILD)
0 commit comments