[PATCH] D66648: [compiler-rt] Respect CMAKE_C_FLAGS when building builtins in-tree
Sergej Jaskiewicz via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Aug 23 13:49:28 PDT 2019
broadwaylamb added a comment.
In D66648#1643274 <https://reviews.llvm.org/D66648#1643274>, @compnerd wrote:
> Im not sure if this works. This sets the flags from the global flags, which may not be what we want as compiler-rt can be built as part of llvm itself.
Building builtins as part of LLVM itself is exactly what I’m trying to accomplish. But it turns out there was no way to specify C flags just for builtins from the LLVM cmake invocation, which is what I’ve attempted to address here.
The global `CMAKE_C_FLAGS` will not be caught by builtins with this change simply because they won’t be passed to the “nested” CMake invocation. Instead, to specify CMAKE_C_FLAGS for builtins, you’ll need to pass them like this: `-DBUILTINS_CMAKE_ARGS="-DCMAKE_C_FLAGS=..."` when building LLVM.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D66648/new/
https://reviews.llvm.org/D66648
More information about the llvm-commits
mailing list