[libc-commits] [PATCH] D149216: [libc] Add path to include generated headers for hermetic tests

Joseph Huber via Phabricator via libc-commits libc-commits at lists.llvm.org
Tue Apr 25 16:31:53 PDT 2023


jhuber6 created this revision.
jhuber6 added reviewers: sivachandra, michaelrj, lntue.
Herald added subscribers: libc-commits, ecnelises, tschuett.
Herald added projects: libc-project, All.
jhuber6 requested review of this revision.

The generated header files live in the build directory's include path.
When targeting a hermetic build we want to make sure we only use headers
generated by the project itself if availible.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D149216

Files:
  libc/test/UnitTest/CMakeLists.txt


Index: libc/test/UnitTest/CMakeLists.txt
===================================================================
--- libc/test/UnitTest/CMakeLists.txt
+++ libc/test/UnitTest/CMakeLists.txt
@@ -37,6 +37,7 @@
   )
 endforeach()
 
+target_compile_options(LibcHermeticTest PRIVATE ${LIBC_BUILD_DIR}/include)
 target_compile_options(LibcHermeticTest PRIVATE -ffreestanding -nostdlib -nostdlib++)
 
 add_library(


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D149216.516979.patch
Type: text/x-patch
Size: 403 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libc-commits/attachments/20230425/6b4538e3/attachment.bin>


More information about the libc-commits mailing list