[libclc] [llvm] [libclc] Support LLVM_ENABLE_RUNTIMES when building (PR #141574)

Fraser Cormack via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 7 09:01:47 PDT 2025


================
@@ -204,6 +204,13 @@ if ("flang-rt" IN_LIST LLVM_ENABLE_RUNTIMES)
   endif ()
 endif ()
 
+if ("libclc" IN_LIST LLVM_ENABLE_PROJECTS)
+  message(WARNING "Using LLVM_ENABLE_PROJECTS=libclc is deprecated now, and will "
+    "become a fatal error in the LLVM 21 release.  Please use "
+    "-DLLVM_ENABLE_RUNTIMES=libclc or see the instructions at "
+    "https://libclc.llvm.org/ for building the runtimes.")
----------------
frasercrmck wrote:

Yes that's likely the case. With the runtimes build system, the targets don't exist in the LLVM/Clang build. They only exist inside libclc, which is in a separate build.

If you're needing a target dependency, you could depend on the `libclc` target - same thing. Especially if you're only building `clspv` targets anyway.

If you need a file path to the resulting bytecode, then sadly we don't have that available. We'd need to think about adding that - I'm not sure if any other "runtimes" builds expose that granularity to "outside" users. The nuisance is these targets would have to be exposed a level higher than libclc, such as LLVM.

https://github.com/llvm/llvm-project/pull/141574


More information about the llvm-commits mailing list