lib{c,sys}: return wrapped syscall APIs to libc

These provide standard APIs, but are implemented using another system
call (e.g., pipe implemented in terms of pipe2) or are interposed by the
threading library to support cancelation.

After discussion with kib (see D44111), I've concluded that it is
better to keep most public interfaces in libc with as little
as possible in libsys.

Reviewed by:	kib
Differential Revision:	https://reviews.freebsd.org/D44241
This commit is contained in:
Brooks Davis
2024-03-13 17:42:01 +00:00
parent ef5fddd344
commit d7847a8d35
72 changed files with 125 additions and 94 deletions
-16
View File
@@ -40,21 +40,6 @@ SRCS+= \
interposing_table.c \
libsys_sigwait.c
SRCS+= getdents.c lstat.c mknod.c stat.c
SRCS+= creat.c
SRCS+= lockf.c wait.c wait3.c waitpid.c waitid.c
SRCS+= recv.c recvmmsg.c send.c sendmmsg.c
SRCS+= brk.c
SRCS+= closefrom.c
SRCS+= pipe.c
SRCS+= shm_open.c
SRCS+= vadvise.c
SRCS+= POSIX2x_Fork.c
SRCS+= compat-stub.c
.if ${LIB} == "c"
# Trapping stubs in dynamic libc to be filtered by libsys.
SOBJS+= libc_stubs.pico
@@ -113,7 +98,6 @@ INTERPOSED = \
write \
writev
SRCS+= ${INTERPOSED:S/$/.c/}
PSEUDO+= ${INTERPOSED}
# Add machine dependent asm sources: