[libc-commits] [PATCH] D138040: [libc] Fix tablegen when using a runtimes build

Siva Chandra via Phabricator via libc-commits libc-commits at lists.llvm.org
Tue Nov 15 10:24:41 PST 2022


sivachandra added inline comments.


================
Comment at: libc/CMakeLists.txt:17
 
+# For a runtimes build we need to manually include tablgen and LLVM directories.
+if ("libc" IN_LIST LLVM_ENABLE_RUNTIMES)
----------------
jhuber6 wrote:
> sivachandra wrote:
> > IIRC, the only dependency we have outside of the `libc` directory is for tablegen. So, could we perhaps move this logic over to something more local to the places where tablegen is used? Also, we want to move away from using the `LLVM_` prefix to libc's CMake variables - just use `LIBC_` for the prefix. In this case, it can be more specific like `LIBC_TABLEGEN_INCLUDE_DIRS`.
> In the future we may need to have some more runtimes specific glue so I figured it was fine to put it up front similar to what most projects do for standalone builds. If you'd prefer it to be right next to where it's used that's fine. I can also change the name.
Tablegen has been a nagging dependency which we want to stop using because it is not the most appropriate for our use case. So, at the least, having tablegen pieces confined to a smaller scope will help with future cleanups.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D138040/new/

https://reviews.llvm.org/D138040



More information about the libc-commits mailing list