[Runtimes] Allow HandleLibc.cmake to be called multiple times (#193540)

Summary:
This needs to check to see if it's already been called now that we want
to use it more places than just libcxx.
This commit is contained in:
Joseph Huber
2026-04-22 13:16:50 -05:00
committed by GitHub
parent d9bbb902fe
commit c3c8e40b6c

View File

@@ -10,6 +10,10 @@
include_guard(GLOBAL)
if(TARGET runtimes-libc-headers)
return()
endif()
set(RUNTIMES_SUPPORTED_C_LIBRARIES system llvm-libc picolibc newlib)
set(RUNTIMES_USE_LIBC "system" CACHE STRING "Specify C library to use. Supported values are ${RUNTIMES_SUPPORTED_C_LIBRARIES}.")
if (NOT "${RUNTIMES_USE_LIBC}" IN_LIST RUNTIMES_SUPPORTED_C_LIBRARIES)