[libc-commits] [libc] [libc] Support %lc in printf (PR #169983)
Alexey Samsonov via libc-commits
libc-commits at lists.llvm.org
Fri Dec 19 10:49:25 PST 2025
================
@@ -43,6 +43,14 @@ if(NOT TARGET ${target_error_mapper})
set(target_error_mapper libc.src.stdio.printf_core.generic.error_mapper)
endif()
+set(wchar_deps libc.src.__support.wchar.wcrtomb)
+set(wchar_compile_flags "")
+
+if(${LIBC_TARGET_OS} STREQUAL "windows" OR WIN32)
+ set(wchar_deps "")
+ list(APPEND wchar_compile_flags "-DLIBC_COPT_PRINTF_DISABLE_WIDE")
----------------
vonosmas wrote:
I would like to have a single place where we construct all defines (such as `-DLIBC_COPT_PRINTF_DISABLE_WIDE`) that would be used to build ~all llvm-libc source files, instead of having a file-specific defines in subdirectories (such as under `/src/stdio/printf_core`). @michaelrj-google - what is the recommended approach?
https://github.com/llvm/llvm-project/pull/169983
More information about the libc-commits
mailing list