[libc] Add a redirecting <syscall.h> header. (#191069)
The amount of legacy code including `<syscall.h>` header instead of `<sys/syscall.h>` (which is the regular header location on Linux systems) out there is large. Add a simple one-liner redirecting header to fix this compatibility issues. In this PR I omit the regular licensing blurb at the top, given the transient nature of this file, but I'm happy to add this if needed. Also, given that it's effectively a compatibility shim, YAML generation is not used.
This commit is contained in:
1 parent
e3adaf0be8
commit
cacd8625ea
5 files changed
+9
No files matched your search
@@ -53,6 +53,7 @@ set(TARGET_PUBLIC_HEADERS
|
||||
libc.include.sys_un
|
||||
libc.include.sys_utsname
|
||||
libc.include.sys_wait
|
||||
libc.include.syscall
|
||||
libc.include.sysexits
|
||||
libc.include.termios
|
||||
libc.include.threads
|
||||
|
||||
@@ -52,6 +52,7 @@ set(TARGET_PUBLIC_HEADERS
|
||||
libc.include.sys_types
|
||||
libc.include.sys_utsname
|
||||
libc.include.sys_wait
|
||||
libc.include.syscall
|
||||
libc.include.sysexits
|
||||
libc.include.termios
|
||||
libc.include.threads
|
||||
|
||||
@@ -56,6 +56,7 @@ set(TARGET_PUBLIC_HEADERS
|
||||
libc.include.sys_un
|
||||
libc.include.sys_utsname
|
||||
libc.include.sys_wait
|
||||
libc.include.syscall
|
||||
libc.include.sysexits
|
||||
libc.include.termios
|
||||
libc.include.threads
|
||||
|
||||
@@ -180,6 +180,11 @@ add_header_macro(
|
||||
.llvm-libc-types.uint_ur_t
|
||||
)
|
||||
|
||||
add_header(
|
||||
syscall
|
||||
HDR
|
||||
syscall.h
|
||||
)
|
||||
|
||||
add_header_macro(
|
||||
sysexits
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
#include <sys/syscall.h>
|
||||
Reference in new issue
Block a user