]> Savannah Git Hosting - gnulib.git/commit
sys_un-h: Ensure that <sys/un.h> defines sa_family_t.
authorBruno Haible <bruno@clisp.org>
Fri, 10 Jan 2025 22:52:54 +0000 (23:52 +0100)
committerBruno Haible <bruno@clisp.org>
Fri, 10 Jan 2025 22:54:51 +0000 (23:54 +0100)
commitd3a9a1f7cd4cb2e66dae5efa660c3dc83f75f9b9
tree7e4779213c3b01fb25234b6e7bfeb444eb562133
parent822b521d0873914e7da1582380349bc0c2121be5
sys_un-h: Ensure that <sys/un.h> defines sa_family_t.

* lib/sys_un.in.h: Include <sys/socket.h> or define sa_family_t
explicitly.
* m4/sys_socket_h.m4 (gl_PREREQ_SYS_SA_FAMILY): New macro, extracted
from gl_SYS_SOCKET_H.
(gl_SYS_SOCKET_H): Invoke it.
(gl_SYS_SOCKET_H_DEFAULTS): Don't initialize HAVE_SA_FAMILY_T.
* m4/sys_un_h.m4 (gl_SYS_UN_H): Invoke gl_PREREQ_SYS_SA_FAMILY. Test
whether <sys/un.h> defines sa_family_t. If not, set GL_GENERATE_SYS_UN_H
to true.
* modules/sys_un-h (Makefile.am): Substitute HAVE_SA_FAMILY_T,
HAVE_SA_FAMILY_T_IN_SYS_UN_H.
* tests/test-sys_un-h.c: Include intprops.h. Verify that sa_family_t is
defined and an unsigned integer type.
* modules/sys_un-h-tests (Depends-on): Add intprops.
* doc/posix-headers/sys_un.texi: Mention the problem with sa_family_t.
ChangeLog
doc/posix-headers/sys_un.texi
lib/sys_un.in.h
m4/sys_socket_h.m4
m4/sys_un_h.m4
modules/sys_un-h
modules/sys_un-h-tests
tests/test-sys_un-h.c