verify sys_socket header includes

This commit is contained in:
auronandace
2026-06-01 07:42:51 +01:00
parent 664fab3763
commit d2df4c9d69
2 changed files with 12 additions and 2 deletions
+4 -1
View File
@@ -6,7 +6,10 @@
# - arpa/inet.h
# - netdb.h
# - sys/socket.h (where it should be defined)
sys_includes = []
#
# TODO split out uint32_t to prevent including all of stdint.h
# stdint needed for uint32_t for socklen_t
sys_includes = ["stdint.h"]
include_guard = "_RELIBC_BITS_SOCKLEN_T_H"
language = "C"
style = "type"
+8 -1
View File
@@ -1,5 +1,12 @@
# POSIX header spec: https://pubs.opengroup.org/onlinepubs/9799919799/basedefs/sys_socket.h.html
#
# Spec quotations relating to includes:
# - "The <sys/socket.h> header shall define the iovec structure as described in <sys/uio.h>."
# - "The <sys/socket.h> header shall define the size_t and ssize_t types as described in <sys/types.h>."
# - "Inclusion of <sys/socket.h> may also make visible all symbols from <sys/uio.h>."
#
# bits/iovec.h brings in size_t
sys_includes = ["stddef.h", "stdint.h"]
# bits/socklen_t brings in stdint.h for uint32_t for socklen_t
include_guard = "_RELIBC_SYS_SOCKET_H"
after_includes = """
#include <bits/iovec.h> // for iovec from sys/uio.h