[libc-commits] [libc] e0de24c - [libc] Re-enable wctob with fixes

Michael Jones via libc-commits libc-commits at lists.llvm.org
Wed Mar 29 12:49:35 PDT 2023


Author: Michael Jones
Date: 2023-03-29T12:49:29-07:00
New Revision: e0de24cb0d5512ae4c69def6b91ec345780f7882

URL: https://github.com/llvm/llvm-project/commit/e0de24cb0d5512ae4c69def6b91ec345780f7882
DIFF: https://github.com/llvm/llvm-project/commit/e0de24cb0d5512ae4c69def6b91ec345780f7882.diff

LOG: [libc] Re-enable wctob with fixes

The stdio test failures were due to headers potentially not being built
in the correct order. This should set up the dependencies correctly.

Reviewed By: sivachandra

Differential Revision: https://reviews.llvm.org/D146551

Added: 
    

Modified: 
    libc/config/linux/x86_64/entrypoints.txt
    libc/include/CMakeLists.txt
    libc/include/llvm-libc-types/CMakeLists.txt
    libc/src/wchar/CMakeLists.txt

Removed: 
    


################################################################################
diff  --git a/libc/config/linux/x86_64/entrypoints.txt b/libc/config/linux/x86_64/entrypoints.txt
index 5c0b3103f5615..9936bf7182e57 100644
--- a/libc/config/linux/x86_64/entrypoints.txt
+++ b/libc/config/linux/x86_64/entrypoints.txt
@@ -197,7 +197,7 @@ set(TARGET_LIBC_ENTRYPOINTS
     libc.src.unistd.write
 
     # wchar.h entrypoints
-    # libc.src.wchar.wctob
+    libc.src.wchar.wctob
 )
 
 set(TARGET_LIBM_ENTRYPOINTS

diff  --git a/libc/include/CMakeLists.txt b/libc/include/CMakeLists.txt
index 9c48fd782c590..bd2458eb3856a 100644
--- a/libc/include/CMakeLists.txt
+++ b/libc/include/CMakeLists.txt
@@ -184,6 +184,7 @@ add_gen_header(
     .llvm-libc-macros.file_seek_macros
     .llvm-libc-macros.stdio_macros
     .llvm-libc-types.size_t
+    .llvm-libc-types.ssize_t
     .llvm-libc-types.FILE
     .llvm-libc-types.cookie_io_functions_t
 )

diff  --git a/libc/include/llvm-libc-types/CMakeLists.txt b/libc/include/llvm-libc-types/CMakeLists.txt
index 1df2e7c962c1b..289307b76bbdb 100644
--- a/libc/include/llvm-libc-types/CMakeLists.txt
+++ b/libc/include/llvm-libc-types/CMakeLists.txt
@@ -1,5 +1,6 @@
 add_header(off64_t HDR off64_t.h)
 add_header(size_t HDR size_t.h)
+add_header(ssize_t HDR ssize_t.h)
 add_header(__atfork_callback_t HDR __atfork_callback_t.h)
 add_header(__bsearchcompare_t HDR __bsearchcompare_t.h)
 add_header(__call_once_func_t HDR __call_once_func_t.h)
@@ -19,7 +20,7 @@ add_header(cc_t HDR cc_t.h)
 add_header(clock_t HDR clock_t.h)
 add_header(clockid_t HDR clockid_t.h)
 add_header(cnd_t HDR cnd_t.h)
-add_header(cookie_io_functions_t HDR cookie_io_functions_t.h DEPENDS .off64_t)
+add_header(cookie_io_functions_t HDR cookie_io_functions_t.h DEPENDS .off64_t .ssize_t)
 add_header(cpu_set_t HDR cpu_set_t.h)
 add_header(double_t HDR double_t.h)
 add_header(DIR HDR DIR.h)
@@ -58,7 +59,6 @@ add_header(suseconds_t HDR suseconds_t.h)
 add_header(struct_timeval HDR struct_timeval.h DEPENDS .suseconds_t .time_t)
 add_header(struct_rlimit HDR struct_rlimit.h DEPENDS .rlim_t)
 add_header(struct_rusage HDR struct_rusage.h DEPENDS .struct_timeval)
-add_header(ssize_t HDR ssize_t.h)
 add_header(struct_dirent HDR struct_dirent.h DEPENDS .ino_t .off_t)
 add_header(union_sigval HDR union_sigval.h)
 add_header(siginfo_t HDR siginfo_t.h DEPENDS .union_sigval .pid_t .uid_t)

diff  --git a/libc/src/wchar/CMakeLists.txt b/libc/src/wchar/CMakeLists.txt
index 5cf980e958a99..7af881dac79e8 100644
--- a/libc/src/wchar/CMakeLists.txt
+++ b/libc/src/wchar/CMakeLists.txt
@@ -7,5 +7,6 @@ add_entrypoint_object(
     wctob.h
   DEPENDS 
     libc.include.stdio
+    libc.include.wchar
     libc.src.__support.wctype_utils
 )


        


More information about the libc-commits mailing list