From: Bruno Haible <bruno@clisp.org>
Date: Fri, 27 Dec 2024 22:39:42 +0000 (+0100)
Subject: Rename module strings to strings-h.
X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=93b331de6b9783e1344f593e7687a19cdb21062b;p=gnulib.git

Rename module strings to strings-h.

* modules/strings-h: Renamed from modules/strings.
* modules/strings-h-tests: Renamed from modules/strings-tests.
* modules/strings-h-c++-tests: Renamed from modules/strings-c++-tests.
* tests/test-strings-h.c: Renamed from tests/test-strings.c.
* tests/test-strings-h-c++.cc: Renamed from tests/test-strings-c++.cc.
* doc/posix-headers/strings.texi: Update.
* modules/* (Depends-on): Update.
* modules/strings: New file.
---

diff --git a/ChangeLog b/ChangeLog
index 21666360ba..57d7d1e99f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,15 @@
+2024-12-27  Bruno Haible  <bruno@clisp.org>
+
+	Rename module strings to strings-h.
+	* modules/strings-h: Renamed from modules/strings.
+	* modules/strings-h-tests: Renamed from modules/strings-tests.
+	* modules/strings-h-c++-tests: Renamed from modules/strings-c++-tests.
+	* tests/test-strings-h.c: Renamed from tests/test-strings.c.
+	* tests/test-strings-h-c++.cc: Renamed from tests/test-strings-c++.cc.
+	* doc/posix-headers/strings.texi: Update.
+	* modules/* (Depends-on): Update.
+	* modules/strings: New file.
+
 2024-12-27  Bruno Haible  <bruno@clisp.org>
 
 	Rename module string to string-h.
diff --git a/doc/posix-headers/strings.texi b/doc/posix-headers/strings.texi
index 279f812a6f..b9190b4368 100644
--- a/doc/posix-headers/strings.texi
+++ b/doc/posix-headers/strings.texi
@@ -3,8 +3,8 @@
 
 POSIX specification:@* @url{https://pubs.opengroup.org/onlinepubs/9799919799/basedefs/strings.h.html}
 
-Gnulib module: strings
-@mindex strings
+Gnulib module: strings-h
+@mindex strings-h
 
 Portability problems fixed by Gnulib:
 @itemize
diff --git a/modules/bcopy b/modules/bcopy
index 146fb90c6a..124b3be7c3 100644
--- a/modules/bcopy
+++ b/modules/bcopy
@@ -11,7 +11,7 @@ Files:
 lib/bcopy.c
 
 Depends-on:
-strings
+strings-h
 
 configure.ac:
 AC_REPLACE_FUNCS(bcopy)
diff --git a/modules/ffs b/modules/ffs
index 90980fd728..e8bb9b3e44 100644
--- a/modules/ffs
+++ b/modules/ffs
@@ -6,7 +6,7 @@ lib/ffs.c
 m4/ffs.m4
 
 Depends-on:
-strings
+strings-h
 
 configure.ac:
 gl_FUNC_FFS
diff --git a/modules/posixcheck b/modules/posixcheck
index 8394ede762..2371aaf0e4 100644
--- a/modules/posixcheck
+++ b/modules/posixcheck
@@ -31,7 +31,7 @@ spawn-h
 stdio-h
 stdlib-h
 string-h
-strings
+strings-h
 sys_file
 sys_ioctl
 sys_random
diff --git a/modules/strcase b/modules/strcase
index faf40578e7..4d90a042a5 100644
--- a/modules/strcase
+++ b/modules/strcase
@@ -7,7 +7,7 @@ lib/strncasecmp.c
 m4/strcase.m4
 
 Depends-on:
-strings
+strings-h
 
 configure.ac:
 gl_STRCASE
diff --git a/modules/strings b/modules/strings
index 6e8ef48684..689e1dcf18 100644
--- a/modules/strings
+++ b/modules/strings
@@ -1,47 +1,20 @@
 Description:
 A substitute <strings.h>.
 
+Status:
+deprecated
+
+Notice:
+This module is deprecated. Use the module 'strings-h' instead.
+
 Files:
-lib/strings.in.h
-m4/strings_h.m4
 
 Depends-on:
-gen-header
-include_next
-snippet/arg-nonnull
-snippet/c++defs
-snippet/warn-on-use
-sys_types
+strings-h
 
 configure.ac:
-gl_STRINGS_H
-gl_STRINGS_H_REQUIRE_DEFAULTS
-AC_PROG_MKDIR_P
 
 Makefile.am:
-BUILT_SOURCES += strings.h
-
-# We need the following in order to create <strings.h> when the system
-# doesn't have one that works with the given compiler.
-strings.h: strings.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(WARN_ON_USE_H) $(ARG_NONNULL_H)
-@NMD@	$(AM_V_GEN)$(MKDIR_P) '%reldir%'
-	$(gl_V_at)$(SED_HEADER_STDOUT) \
-	      -e 's|@''GUARD_PREFIX''@|${gl_include_guard_prefix}|g' \
-	      -e 's|@''HAVE_STRINGS_H''@|$(HAVE_STRINGS_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_STRINGS_H''@|$(NEXT_STRINGS_H)|g' \
-	      -e 's/@''GNULIB_FFS''@/$(GNULIB_FFS)/g' \
-	      -e 's|@''HAVE_FFS''@|$(HAVE_FFS)|g' \
-	      -e 's|@''HAVE_STRCASECMP''@|$(HAVE_STRCASECMP)|g' \
-	      -e 's|@''HAVE_DECL_STRNCASECMP''@|$(HAVE_DECL_STRNCASECMP)|g' \
-	      -e '/definitions of _GL_FUNCDECL_RPL/r $(CXXDEFS_H)' \
-	      -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \
-	      -e '/definition of _GL_WARN_ON_USE/r $(WARN_ON_USE_H)' \
-	      $(srcdir)/strings.in.h > $@-t
-	$(AM_V_at)mv $@-t $@
-MOSTLYCLEANFILES += strings.h strings.h-t
 
 Include:
 <strings.h>
@@ -50,4 +23,3 @@ License:
 LGPLv2+
 
 Maintainer:
-all
diff --git a/modules/strings-c++-tests b/modules/strings-c++-tests
deleted file mode 100644
index 485b701a44..0000000000
--- a/modules/strings-c++-tests
+++ /dev/null
@@ -1,18 +0,0 @@
-Files:
-tests/test-strings-c++.cc
-tests/signature.h
-
-Status:
-c++-test
-
-Depends-on:
-ansi-c++-opt
-
-configure.ac:
-
-Makefile.am:
-if ANSICXX
-TESTS += test-strings-c++
-check_PROGRAMS += test-strings-c++
-test_strings_c___SOURCES = test-strings-c++.cc
-endif
diff --git a/modules/strings-h b/modules/strings-h
new file mode 100644
index 0000000000..6e8ef48684
--- /dev/null
+++ b/modules/strings-h
@@ -0,0 +1,53 @@
+Description:
+A substitute <strings.h>.
+
+Files:
+lib/strings.in.h
+m4/strings_h.m4
+
+Depends-on:
+gen-header
+include_next
+snippet/arg-nonnull
+snippet/c++defs
+snippet/warn-on-use
+sys_types
+
+configure.ac:
+gl_STRINGS_H
+gl_STRINGS_H_REQUIRE_DEFAULTS
+AC_PROG_MKDIR_P
+
+Makefile.am:
+BUILT_SOURCES += strings.h
+
+# We need the following in order to create <strings.h> when the system
+# doesn't have one that works with the given compiler.
+strings.h: strings.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(WARN_ON_USE_H) $(ARG_NONNULL_H)
+@NMD@	$(AM_V_GEN)$(MKDIR_P) '%reldir%'
+	$(gl_V_at)$(SED_HEADER_STDOUT) \
+	      -e 's|@''GUARD_PREFIX''@|${gl_include_guard_prefix}|g' \
+	      -e 's|@''HAVE_STRINGS_H''@|$(HAVE_STRINGS_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_STRINGS_H''@|$(NEXT_STRINGS_H)|g' \
+	      -e 's/@''GNULIB_FFS''@/$(GNULIB_FFS)/g' \
+	      -e 's|@''HAVE_FFS''@|$(HAVE_FFS)|g' \
+	      -e 's|@''HAVE_STRCASECMP''@|$(HAVE_STRCASECMP)|g' \
+	      -e 's|@''HAVE_DECL_STRNCASECMP''@|$(HAVE_DECL_STRNCASECMP)|g' \
+	      -e '/definitions of _GL_FUNCDECL_RPL/r $(CXXDEFS_H)' \
+	      -e '/definition of _GL_ARG_NONNULL/r $(ARG_NONNULL_H)' \
+	      -e '/definition of _GL_WARN_ON_USE/r $(WARN_ON_USE_H)' \
+	      $(srcdir)/strings.in.h > $@-t
+	$(AM_V_at)mv $@-t $@
+MOSTLYCLEANFILES += strings.h strings.h-t
+
+Include:
+<strings.h>
+
+License:
+LGPLv2+
+
+Maintainer:
+all
diff --git a/modules/strings-h-c++-tests b/modules/strings-h-c++-tests
new file mode 100644
index 0000000000..4e212c07ed
--- /dev/null
+++ b/modules/strings-h-c++-tests
@@ -0,0 +1,18 @@
+Files:
+tests/test-strings-h-c++.cc
+tests/signature.h
+
+Status:
+c++-test
+
+Depends-on:
+ansi-c++-opt
+
+configure.ac:
+
+Makefile.am:
+if ANSICXX
+TESTS += test-strings-h-c++
+check_PROGRAMS += test-strings-h-c++
+test_strings_h_c___SOURCES = test-strings-h-c++.cc
+endif
diff --git a/modules/strings-h-tests b/modules/strings-h-tests
new file mode 100644
index 0000000000..c4dc6054f5
--- /dev/null
+++ b/modules/strings-h-tests
@@ -0,0 +1,11 @@
+Files:
+tests/test-strings-h.c
+
+Depends-on:
+strings-h-c++-tests
+
+configure.ac:
+
+Makefile.am:
+TESTS += test-strings-h
+check_PROGRAMS += test-strings-h
diff --git a/modules/strings-tests b/modules/strings-tests
deleted file mode 100644
index ad66af4661..0000000000
--- a/modules/strings-tests
+++ /dev/null
@@ -1,11 +0,0 @@
-Files:
-tests/test-strings.c
-
-Depends-on:
-strings-c++-tests
-
-configure.ac:
-
-Makefile.am:
-TESTS += test-strings
-check_PROGRAMS += test-strings
diff --git a/tests/test-strings-c++.cc b/tests/test-strings-c++.cc
deleted file mode 100644
index e9084d5b54..0000000000
--- a/tests/test-strings-c++.cc
+++ /dev/null
@@ -1,35 +0,0 @@
-/* Test of <strings.h> substitute in C++ mode.
-   Copyright (C) 2010-2024 Free Software Foundation, Inc.
-
-   This program is free software: you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation, either version 3 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program.  If not, see <https://www.gnu.org/licenses/>.  */
-
-/* Written by Bruno Haible <bruno@clisp.org>, 2017.  */
-
-#define GNULIB_NAMESPACE gnulib
-#include <config.h>
-
-#include <strings.h>
-
-#include "signature.h"
-
-
-#if GNULIB_TEST_FFS
-SIGNATURE_CHECK (GNULIB_NAMESPACE::ffs, int, (int));
-#endif
-
-
-int
-main ()
-{
-}
diff --git a/tests/test-strings-h-c++.cc b/tests/test-strings-h-c++.cc
new file mode 100644
index 0000000000..e9084d5b54
--- /dev/null
+++ b/tests/test-strings-h-c++.cc
@@ -0,0 +1,35 @@
+/* Test of <strings.h> substitute in C++ mode.
+   Copyright (C) 2010-2024 Free Software Foundation, Inc.
+
+   This program is free software: you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
+
+   This program is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU General Public License for more details.
+
+   You should have received a copy of the GNU General Public License
+   along with this program.  If not, see <https://www.gnu.org/licenses/>.  */
+
+/* Written by Bruno Haible <bruno@clisp.org>, 2017.  */
+
+#define GNULIB_NAMESPACE gnulib
+#include <config.h>
+
+#include <strings.h>
+
+#include "signature.h"
+
+
+#if GNULIB_TEST_FFS
+SIGNATURE_CHECK (GNULIB_NAMESPACE::ffs, int, (int));
+#endif
+
+
+int
+main ()
+{
+}
diff --git a/tests/test-strings-h.c b/tests/test-strings-h.c
new file mode 100644
index 0000000000..942e41c20a
--- /dev/null
+++ b/tests/test-strings-h.c
@@ -0,0 +1,27 @@
+/* Test of <strings.h> substitute.
+   Copyright (C) 2007, 2009-2024 Free Software Foundation, Inc.
+
+   This program is free software: you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
+
+   This program is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU General Public License for more details.
+
+   You should have received a copy of the GNU General Public License
+   along with this program.  If not, see <https://www.gnu.org/licenses/>.  */
+
+/* Written by Bruno Haible <bruno@clisp.org>, 2007.  */
+
+#include <config.h>
+
+#include <strings.h>
+
+int
+main ()
+{
+  return 0;
+}
diff --git a/tests/test-strings.c b/tests/test-strings.c
deleted file mode 100644
index 942e41c20a..0000000000
--- a/tests/test-strings.c
+++ /dev/null
@@ -1,27 +0,0 @@
-/* Test of <strings.h> substitute.
-   Copyright (C) 2007, 2009-2024 Free Software Foundation, Inc.
-
-   This program is free software: you can redistribute it and/or modify
-   it under the terms of the GNU General Public License as published by
-   the Free Software Foundation, either version 3 of the License, or
-   (at your option) any later version.
-
-   This program is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-   GNU General Public License for more details.
-
-   You should have received a copy of the GNU General Public License
-   along with this program.  If not, see <https://www.gnu.org/licenses/>.  */
-
-/* Written by Bruno Haible <bruno@clisp.org>, 2007.  */
-
-#include <config.h>
-
-#include <strings.h>
-
-int
-main ()
-{
-  return 0;
-}