[libc] Disable signal.h API and its users.

The signal.h header file from LLVM libc is incorrect. The signal API and
its users will be enabled once signal.h is fixed.
This commit is contained in:
Siva Chandra Reddy 2021-12-15 23:24:17 +00:00
parent 7b265e9791
commit 2cf203d9f6
5 changed files with 43 additions and 38 deletions

View File

@ -185,21 +185,22 @@ set(TARGET_LIBM_ENTRYPOINTS
if(LLVM_LIBC_FULL_BUILD)
list(APPEND TARGET_LIBC_ENTRYPOINTS
# assert.h entrypoints
libc.src.assert.__assert_fail
# libc.src.assert.__assert_fail
# stdlib.h entrypoints
libc.src.stdlib._Exit
libc.src.stdlib.abort
# libc.src.stdlib.abort
# signal.h entrypoints
libc.src.signal.raise
libc.src.signal.sigaction
libc.src.signal.sigdelset
libc.src.signal.sigaddset
libc.src.signal.sigemptyset
libc.src.signal.sigprocmask
libc.src.signal.sigfillset
libc.src.signal.signal
# TODO: Enable signal.h entrypoints after fixing signal.h
# libc.src.signal.raise
# libc.src.signal.sigaction
# libc.src.signal.sigdelset
# libc.src.signal.sigaddset
# libc.src.signal.sigemptyset
# libc.src.signal.sigprocmask
# libc.src.signal.sigfillset
# libc.src.signal.signal
# sys/mman.h entrypoints
libc.src.sys.mman.mmap

View File

@ -12,8 +12,10 @@ if(NOT LLVM_LIBC_FULL_BUILD)
return()
endif()
add_subdirectory(assert)
add_subdirectory(signal)
# The signal API is currently disabled as signal.h is incorrect.
# since assert uses the signal API, we disable assert also.
# add_subdirectory(assert)
# add_subdirectory(signal)
add_subdirectory(stdio)
# TODO: Add this target conditional to the target OS.
add_subdirectory(sys)

View File

@ -248,14 +248,14 @@ add_entrypoint_object(
.${LIBC_TARGET_OS}._Exit
)
add_entrypoint_object(
abort
SRCS
abort.cpp
HDRS
abort.h
DEPENDS
libc.include.stdlib
libc.src.signal.raise
._Exit
)
# add_entrypoint_object(
# abort
# SRCS
# abort.cpp
# HDRS
# abort.h
# DEPENDS
# libc.include.stdlib
# libc.src.signal.raise
# ._Exit
# )

View File

@ -38,8 +38,10 @@ if(NOT LLVM_LIBC_FULL_BUILD)
return()
endif()
add_subdirectory(assert)
add_subdirectory(signal)
# The signal API is currently disabled as signal.h is incorrect.
# since assert uses the signal API, we disable assert also.
# add_subdirectory(assert)
# add_subdirectory(signal)
add_subdirectory(stdio)
add_subdirectory(sys)
add_subdirectory(threads)

View File

@ -125,19 +125,19 @@ add_libc_unittest(
libc.src.stdlib._Exit
)
add_libc_unittest(
abort_test
SUITE
libc_stdlib_unittests
SRCS
abort_test.cpp
DEPENDS
libc.include.stdlib
libc.include.signal
libc.src.stdlib.abort
libc.src.stdlib._Exit
libc.src.signal.raise
)
# add_libc_unittest(
# abort_test
# SUITE
# libc_stdlib_unittests
# SRCS
# abort_test.cpp
# DEPENDS
# libc.include.stdlib
# libc.include.signal
# libc.src.stdlib.abort
# libc.src.stdlib._Exit
# libc.src.signal.raise
# )
add_libc_unittest(
abs_test