From ba9aeda33520121aed1e03a52edf2011321a3129 Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Fri, 27 Dec 2024 23:39:49 +0100 Subject: [PATCH] Rename module sys_ioctl to sys_ioctl-h. * modules/sys_ioctl-h: Renamed from modules/sys_ioctl. * modules/sys_ioctl-h-tests: Renamed from modules/sys_ioctl-tests. * modules/sys_ioctl-h-c++-tests: Renamed from modules/sys_ioctl-c++-tests. * tests/test-sys_ioctl-h.c: Renamed from tests/test-sys_ioctl.c. * tests/test-sys_ioctl-h-c++.cc: Renamed from tests/test-sys_ioctl-c++.cc. * doc/glibc-headers/sys_ioctl.texi: Update. * modules/* (Depends-on): Update. * modules/sys_ioctl: New file. --- ChangeLog | 14 +++++ doc/glibc-headers/sys_ioctl.texi | 4 +- modules/ioctl | 2 +- modules/login_tty | 2 +- modules/poll-tests | 2 +- modules/posixcheck | 2 +- modules/pselect-tests | 2 +- modules/select-tests | 2 +- modules/sys_ioctl | 41 +++------------ modules/sys_ioctl-c++-tests | 19 ------- modules/sys_ioctl-h | 52 +++++++++++++++++++ modules/sys_ioctl-h-c++-tests | 19 +++++++ modules/sys_ioctl-h-tests | 11 ++++ modules/sys_ioctl-tests | 11 ---- modules/tcgetsid | 2 +- ...s_ioctl-c++.cc => test-sys_ioctl-h-c++.cc} | 0 .../{test-sys_ioctl.c => test-sys_ioctl-h.c} | 0 17 files changed, 112 insertions(+), 73 deletions(-) delete mode 100644 modules/sys_ioctl-c++-tests create mode 100644 modules/sys_ioctl-h create mode 100644 modules/sys_ioctl-h-c++-tests create mode 100644 modules/sys_ioctl-h-tests delete mode 100644 modules/sys_ioctl-tests rename tests/{test-sys_ioctl-c++.cc => test-sys_ioctl-h-c++.cc} (100%) rename tests/{test-sys_ioctl.c => test-sys_ioctl-h.c} (100%) diff --git a/ChangeLog b/ChangeLog index bb8d0ba787..ec7e2c105f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,17 @@ +2024-12-27 Bruno Haible + + Rename module sys_ioctl to sys_ioctl-h. + * modules/sys_ioctl-h: Renamed from modules/sys_ioctl. + * modules/sys_ioctl-h-tests: Renamed from modules/sys_ioctl-tests. + * modules/sys_ioctl-h-c++-tests: Renamed from + modules/sys_ioctl-c++-tests. + * tests/test-sys_ioctl-h.c: Renamed from tests/test-sys_ioctl.c. + * tests/test-sys_ioctl-h-c++.cc: Renamed from + tests/test-sys_ioctl-c++.cc. + * doc/glibc-headers/sys_ioctl.texi: Update. + * modules/* (Depends-on): Update. + * modules/sys_ioctl: New file. + 2024-12-27 Bruno Haible Rename module sys_file to sys_file-h. diff --git a/doc/glibc-headers/sys_ioctl.texi b/doc/glibc-headers/sys_ioctl.texi index 3f4380020b..fda5d41087 100644 --- a/doc/glibc-headers/sys_ioctl.texi +++ b/doc/glibc-headers/sys_ioctl.texi @@ -16,8 +16,8 @@ Documentation: @uref{https://www.kernel.org/doc/man-pages/online/pages/man2/ioctl.2.html,,man ioctl}. @end itemize -Gnulib module: sys_ioctl -@mindex sys_ioctl +Gnulib module: sys_ioctl-h +@mindex sys_ioctl-h Portability problems fixed by Gnulib: @itemize diff --git a/modules/ioctl b/modules/ioctl index 96b15e580b..eeb4d7089e 100644 --- a/modules/ioctl +++ b/modules/ioctl @@ -7,7 +7,7 @@ lib/w32sock.h m4/ioctl.m4 Depends-on: -sys_ioctl +sys_ioctl-h sys_socket [test $HAVE_IOCTL = 0 || test $REPLACE_IOCTL = 1] errno-h [test $HAVE_IOCTL = 0 || test $REPLACE_IOCTL = 1] fd-hook [test $HAVE_IOCTL = 0 || test $REPLACE_IOCTL = 1] diff --git a/modules/login_tty b/modules/login_tty index 7b09ec1bd2..15f3cc2698 100644 --- a/modules/login_tty +++ b/modules/login_tty @@ -9,7 +9,7 @@ m4/pty.m4 Depends-on: utmp -sys_ioctl +sys_ioctl-h open [test $HAVE_LOGIN_TTY = 0] configure.ac: diff --git a/modules/poll-tests b/modules/poll-tests index 950f395b78..e6663a09c4 100644 --- a/modules/poll-tests +++ b/modules/poll-tests @@ -8,7 +8,7 @@ stdbool-h sys_socket netinet_in-h arpa_inet-h -sys_ioctl +sys_ioctl-h extensions inet_pton errno-h diff --git a/modules/posixcheck b/modules/posixcheck index 98f560548e..a73443bbac 100644 --- a/modules/posixcheck +++ b/modules/posixcheck @@ -33,7 +33,7 @@ stdlib-h string-h strings-h sys_file-h -sys_ioctl +sys_ioctl-h sys_random sys_resource sys_select diff --git a/modules/pselect-tests b/modules/pselect-tests index 9483e06218..c90a5d12cd 100644 --- a/modules/pselect-tests +++ b/modules/pselect-tests @@ -9,7 +9,7 @@ stdbool-h netinet_in-h arpa_inet-h unistd -sys_ioctl +sys_ioctl-h extensions inet_pton errno-h diff --git a/modules/select-tests b/modules/select-tests index 903aedf397..77b26b7e73 100644 --- a/modules/select-tests +++ b/modules/select-tests @@ -14,7 +14,7 @@ sys_socket netinet_in-h arpa_inet-h unistd -sys_ioctl +sys_ioctl-h extensions inet_pton errno-h diff --git a/modules/sys_ioctl b/modules/sys_ioctl index cf99b56252..6607af2a7f 100644 --- a/modules/sys_ioctl +++ b/modules/sys_ioctl @@ -1,46 +1,20 @@ Description: A for systems with missing declarations. +Status: +deprecated + +Notice: +This module is deprecated. Use the module 'sys_ioctl-h' instead. + Files: -lib/sys_ioctl.in.h -m4/sys_ioctl_h.m4 Depends-on: -gen-header -include_next -snippet/c++defs -snippet/warn-on-use -unistd +sys_ioctl-h configure.ac: -gl_SYS_IOCTL_H -gl_SYS_IOCTL_H_REQUIRE_DEFAULTS -AC_PROG_MKDIR_P Makefile.am: -BUILT_SOURCES += sys/ioctl.h - -# We need the following in order to create when the system -# does not have a complete one. -sys/ioctl.h: sys_ioctl.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(WARN_ON_USE_H) - $(AM_V_GEN)$(MKDIR_P) '%reldir%/sys' - $(AM_V_at)$(SED_HEADER_STDOUT) \ - -e 's|@''GUARD_PREFIX''@|${gl_include_guard_prefix}|g' \ - -e 's|@''HAVE_SYS_IOCTL_H''@|$(HAVE_SYS_IOCTL_H)|g' \ - -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \ - -e 's|@''PRAGMA_SYSTEM_HEADER''@|@PRAGMA_SYSTEM_HEADER@|g' \ - -e 's|@''PRAGMA_COLUMNS''@|@PRAGMA_COLUMNS@|g' \ - -e 's|@''NEXT_SYS_IOCTL_H''@|$(NEXT_SYS_IOCTL_H)|g' \ - -e 's/@''GNULIB_IOCTL''@/$(GNULIB_IOCTL)/g' \ - -e 's|@''SYS_IOCTL_H_HAVE_WINSOCK2_H''@|$(SYS_IOCTL_H_HAVE_WINSOCK2_H)|g' \ - -e 's|@''SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS''@|$(SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS)|g' \ - -e 's|@''REPLACE_IOCTL''@|$(REPLACE_IOCTL)|g' \ - -e '/definitions of _GL_FUNCDECL_RPL/r $(CXXDEFS_H)' \ - -e '/definition of _GL_WARN_ON_USE/r $(WARN_ON_USE_H)' \ - $(srcdir)/sys_ioctl.in.h > $@-t - $(AM_V_at)mv $@-t $@ -MOSTLYCLEANFILES += sys/ioctl.h sys/ioctl.h-t -MOSTLYCLEANDIRS += sys Include: @@ -49,4 +23,3 @@ License: LGPLv2+ Maintainer: -all diff --git a/modules/sys_ioctl-c++-tests b/modules/sys_ioctl-c++-tests deleted file mode 100644 index 710c36051d..0000000000 --- a/modules/sys_ioctl-c++-tests +++ /dev/null @@ -1,19 +0,0 @@ -Files: -tests/test-sys_ioctl-c++.cc -tests/signature.h - -Status: -c++-test - -Depends-on: -ansi-c++-opt - -configure.ac: - -Makefile.am: -if ANSICXX -TESTS += test-sys_ioctl-c++ -check_PROGRAMS += test-sys_ioctl-c++ -test_sys_ioctl_c___SOURCES = test-sys_ioctl-c++.cc -test_sys_ioctl_c___LDADD = $(LDADD) $(LIBINTL) $(LIBSOCKET) $(CLOCK_TIME_LIB) $(EUIDACCESS_LIBGEN) -endif diff --git a/modules/sys_ioctl-h b/modules/sys_ioctl-h new file mode 100644 index 0000000000..cf99b56252 --- /dev/null +++ b/modules/sys_ioctl-h @@ -0,0 +1,52 @@ +Description: +A for systems with missing declarations. + +Files: +lib/sys_ioctl.in.h +m4/sys_ioctl_h.m4 + +Depends-on: +gen-header +include_next +snippet/c++defs +snippet/warn-on-use +unistd + +configure.ac: +gl_SYS_IOCTL_H +gl_SYS_IOCTL_H_REQUIRE_DEFAULTS +AC_PROG_MKDIR_P + +Makefile.am: +BUILT_SOURCES += sys/ioctl.h + +# We need the following in order to create when the system +# does not have a complete one. +sys/ioctl.h: sys_ioctl.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(WARN_ON_USE_H) + $(AM_V_GEN)$(MKDIR_P) '%reldir%/sys' + $(AM_V_at)$(SED_HEADER_STDOUT) \ + -e 's|@''GUARD_PREFIX''@|${gl_include_guard_prefix}|g' \ + -e 's|@''HAVE_SYS_IOCTL_H''@|$(HAVE_SYS_IOCTL_H)|g' \ + -e 's|@''INCLUDE_NEXT''@|$(INCLUDE_NEXT)|g' \ + -e 's|@''PRAGMA_SYSTEM_HEADER''@|@PRAGMA_SYSTEM_HEADER@|g' \ + -e 's|@''PRAGMA_COLUMNS''@|@PRAGMA_COLUMNS@|g' \ + -e 's|@''NEXT_SYS_IOCTL_H''@|$(NEXT_SYS_IOCTL_H)|g' \ + -e 's/@''GNULIB_IOCTL''@/$(GNULIB_IOCTL)/g' \ + -e 's|@''SYS_IOCTL_H_HAVE_WINSOCK2_H''@|$(SYS_IOCTL_H_HAVE_WINSOCK2_H)|g' \ + -e 's|@''SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS''@|$(SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS)|g' \ + -e 's|@''REPLACE_IOCTL''@|$(REPLACE_IOCTL)|g' \ + -e '/definitions of _GL_FUNCDECL_RPL/r $(CXXDEFS_H)' \ + -e '/definition of _GL_WARN_ON_USE/r $(WARN_ON_USE_H)' \ + $(srcdir)/sys_ioctl.in.h > $@-t + $(AM_V_at)mv $@-t $@ +MOSTLYCLEANFILES += sys/ioctl.h sys/ioctl.h-t +MOSTLYCLEANDIRS += sys + +Include: + + +License: +LGPLv2+ + +Maintainer: +all diff --git a/modules/sys_ioctl-h-c++-tests b/modules/sys_ioctl-h-c++-tests new file mode 100644 index 0000000000..dfd71b8bbd --- /dev/null +++ b/modules/sys_ioctl-h-c++-tests @@ -0,0 +1,19 @@ +Files: +tests/test-sys_ioctl-h-c++.cc +tests/signature.h + +Status: +c++-test + +Depends-on: +ansi-c++-opt + +configure.ac: + +Makefile.am: +if ANSICXX +TESTS += test-sys_ioctl-h-c++ +check_PROGRAMS += test-sys_ioctl-h-c++ +test_sys_ioctl_h_c___SOURCES = test-sys_ioctl-h-c++.cc +test_sys_ioctl_h_c___LDADD = $(LDADD) $(LIBINTL) $(LIBSOCKET) $(CLOCK_TIME_LIB) $(EUIDACCESS_LIBGEN) +endif diff --git a/modules/sys_ioctl-h-tests b/modules/sys_ioctl-h-tests new file mode 100644 index 0000000000..0fcadd6f75 --- /dev/null +++ b/modules/sys_ioctl-h-tests @@ -0,0 +1,11 @@ +Files: +tests/test-sys_ioctl-h.c + +Depends-on: +sys_ioctl-h-c++-tests + +configure.ac: + +Makefile.am: +TESTS += test-sys_ioctl-h +check_PROGRAMS += test-sys_ioctl-h diff --git a/modules/sys_ioctl-tests b/modules/sys_ioctl-tests deleted file mode 100644 index 8e85e638a7..0000000000 --- a/modules/sys_ioctl-tests +++ /dev/null @@ -1,11 +0,0 @@ -Files: -tests/test-sys_ioctl.c - -Depends-on: -sys_ioctl-c++-tests - -configure.ac: - -Makefile.am: -TESTS += test-sys_ioctl -check_PROGRAMS += test-sys_ioctl diff --git a/modules/tcgetsid b/modules/tcgetsid index 67e74cabf7..f5300c8d42 100644 --- a/modules/tcgetsid +++ b/modules/tcgetsid @@ -9,7 +9,7 @@ m4/tcgetsid.m4 Depends-on: termios extensions -sys_ioctl [test $HAVE_TCGETSID = 0] +sys_ioctl-h [test $HAVE_TCGETSID = 0] configure.ac: gl_FUNC_TCGETSID diff --git a/tests/test-sys_ioctl-c++.cc b/tests/test-sys_ioctl-h-c++.cc similarity index 100% rename from tests/test-sys_ioctl-c++.cc rename to tests/test-sys_ioctl-h-c++.cc diff --git a/tests/test-sys_ioctl.c b/tests/test-sys_ioctl-h.c similarity index 100% rename from tests/test-sys_ioctl.c rename to tests/test-sys_ioctl-h.c -- 2.39.5