* doc/glibc-functions/timespec_get.texi: Add reference to ISO C.
* doc/posix-functions/_tolower.texi: Recommend use of tolower.
* doc/posix-functions/_toupper.texi: Recommend use of toupper.
* doc/posix-functions/asctime.texi: Recommend use of strftime.
* doc/posix-functions/asctime_r.texi: Likewise.
* doc/posix-functions/ctime.texi: Recommend use of localtime_r and
strftime.
* doc/posix-functions/ctime_r.texi: Likewise.
* doc/posix-functions/ftw.texi: Recommend use of fts.
* doc/posix-functions/getitimer.texi: Recommend use of timer_gettime.
* doc/posix-functions/gets.texi: Recommend use of fgets.
* doc/posix-functions/gettimeofday.texi: Recommend use of gettime or
timespec_get.
* doc/posix-functions/inet_addr.texi: Recommend use of inet_pton.
* doc/posix-functions/inet_ntoa.texi: Recommend use of inet_ntop.
* doc/posix-functions/pthread_getconcurrency.texi: Recommend no-op.
* doc/posix-functions/pthread_setconcurrency.texi: Recommend no-op.
* doc/posix-functions/rand_r.texi: Recommend use of random_r.
* doc/posix-functions/setitimer.texi: Recommend use of timer_create and
timer_settime.
* doc/posix-functions/setpgrp.texi: Recommend use of setpgid or setsid.
* doc/posix-functions/sighold.texi: Recommend use of sigprocmask.
* doc/posix-functions/sigignore.texi: Recommend use of sigaction.
* doc/posix-functions/siginterrupt.texi: Recommend use of sigaction.
* doc/posix-functions/sigpause.texi: Recommend use of sigsuspend.
* doc/posix-functions/sigrelse.texi: Recommend use of sigprocmask.
* doc/posix-functions/sigset.texi: Recommend use of sigaction.
* doc/posix-functions/tempnam.texi: Recommend use of mkstemp.
* doc/posix-functions/ulimit.texi: Recommend use of getrlimit and
setrlimit.
* doc/posix-functions/utime.texi: Recommend use of utimens.
+2023-07-19 Bruno Haible <bruno@clisp.org>
+
+ Document migration path for obsolescent functions.
+ * doc/glibc-functions/timespec_get.texi: Add reference to ISO C.
+ * doc/posix-functions/_tolower.texi: Recommend use of tolower.
+ * doc/posix-functions/_toupper.texi: Recommend use of toupper.
+ * doc/posix-functions/asctime.texi: Recommend use of strftime.
+ * doc/posix-functions/asctime_r.texi: Likewise.
+ * doc/posix-functions/ctime.texi: Recommend use of localtime_r and
+ strftime.
+ * doc/posix-functions/ctime_r.texi: Likewise.
+ * doc/posix-functions/ftw.texi: Recommend use of fts.
+ * doc/posix-functions/getitimer.texi: Recommend use of timer_gettime.
+ * doc/posix-functions/gets.texi: Recommend use of fgets.
+ * doc/posix-functions/gettimeofday.texi: Recommend use of gettime or
+ timespec_get.
+ * doc/posix-functions/inet_addr.texi: Recommend use of inet_pton.
+ * doc/posix-functions/inet_ntoa.texi: Recommend use of inet_ntop.
+ * doc/posix-functions/pthread_getconcurrency.texi: Recommend no-op.
+ * doc/posix-functions/pthread_setconcurrency.texi: Recommend no-op.
+ * doc/posix-functions/rand_r.texi: Recommend use of random_r.
+ * doc/posix-functions/setitimer.texi: Recommend use of timer_create and
+ timer_settime.
+ * doc/posix-functions/setpgrp.texi: Recommend use of setpgid or setsid.
+ * doc/posix-functions/sighold.texi: Recommend use of sigprocmask.
+ * doc/posix-functions/sigignore.texi: Recommend use of sigaction.
+ * doc/posix-functions/siginterrupt.texi: Recommend use of sigaction.
+ * doc/posix-functions/sigpause.texi: Recommend use of sigsuspend.
+ * doc/posix-functions/sigrelse.texi: Recommend use of sigprocmask.
+ * doc/posix-functions/sigset.texi: Recommend use of sigaction.
+ * doc/posix-functions/tempnam.texi: Recommend use of mkstemp.
+ * doc/posix-functions/ulimit.texi: Recommend use of getrlimit and
+ setrlimit.
+ * doc/posix-functions/utime.texi: Recommend use of utimens.
+
2023-07-19 Paul Eggert <eggert@cs.ucla.edu>
Document POSIX obsolescence
@subsection @code{timespec_get}
@findex timespec_get
+ISO C23 specification:@* @url{http://www.open-std.org/jtc1/sc22/wg14/www/docs/n3047.pdf} section 7.29.2.6
+
Gnulib module: timespec_get
Portability problems fixed by Gnulib:
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the function @code{tolower} instead.
@end itemize
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the function @code{toupper} instead.
@end itemize
@itemize
@item
This function is deprecated in C23.
-Portable applications can use @code{strftime} (or even @code{sprintf}) instead.
-@item
-POSIX says this function is obsolescent and it is planned to be
+Likewise, POSIX says this function is obsolescent and it is planned to be
removed in a future version.
+Portable applications can use @code{strftime} (or even @code{sprintf}) instead.
@item
This function may overflow its internal buffer if an invalid year is passed.
@end itemize
@item
POSIX says this function is obsolescent and it is planned to be
removed in a future version.
+Use the function @code{strftime} (or even @code{sprintf}) instead.
@item
This function may put more than 26 bytes into the argument buffer if an
invalid year is passed.
@itemize
@item
This function is deprecated in C23.
+Likewise, POSIX says this function is obsolescent and it is planned to be
+removed in a future version.
Portable applications can use @code{localtime_r} and @code{strftime}
(or even @code{sprintf}) instead.
@item
-POSIX says this function is obsolescent and it is planned to be
-removed in a future version.
-@item
This function may overflow its internal buffer if an invalid year is passed.
@item
The @code{ctime} function need not be reentrant, and consequently is
@item
POSIX says this function is obsolescent and it is planned to be
removed in a future version.
+Use the functions @code{localtime_r} and @code{strftime}
+(or even @code{sprintf}) instead.
@item
This function may put more than 26 bytes into the argument buffer if an
invalid year is passed.
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the Gnulib module @code{fts} instead.
@end itemize
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the function @code{timer_gettime} instead.
@end itemize
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the function @code{fgets} instead.
@item
When reading from a non-blocking pipe whose buffer is empty, this function
fails with @code{errno} being set to @code{EINVAL} instead of @code{EAGAIN} on
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the Gnulib module @code{gettime} or @code{timespec_get} instead.
+(POSIX recommends to use the function @code{clock_gettime}, but there is
+no corresponding Gnulib module for it yet.)
@end itemize
@item
POSIX 202x says this function is obsolescent and it is planned to be
removed in a future version.
+Use the function @code{inet_pton} instead.
@item
On some old platforms, this function returns a @samp{struct in_addr} rather
than a scalar type such as @samp{unsigned int} or @samp{unsigned long}.
@item
POSIX 202x says this function is obsolescent and it is planned to be
removed in a future version.
+Use the function @code{inet_ntop} instead.
@item
The @code{inet_ntoa} function need not be reentrant, and consequently
is not required to be thread safe. Implementations of
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+You can remove calls to this function.
@end itemize
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+You can remove calls to this function.
@end itemize
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the function @code{random_r} from Gnulib module @code{random_r} instead.
@end itemize
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the functions @code{timer_create} and @code{timer_settime} instead.
@end itemize
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the function @code{setpgid} or @code{setsid} instead, as appropriate.
@end itemize
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the function @code{sigprocmask} instead.
@end itemize
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the function @code{sigaction} instead.
@end itemize
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the function @code{sigaction} instead.
@end itemize
Note: POSIX recommends using @code{sigaction} with SA_RESTART instead of
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the function @code{sigsuspend} instead.
@end itemize
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the function @code{sigprocmask} instead.
@end itemize
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the function @code{sigaction} instead.
@end itemize
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the function @code{mkstemp} instead.
@item
This function is not appropriate for creating temporary files. (It has
security risks.) Better use @code{mkstemp} instead.
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+Use the functions @code{getrlimit} and @code{setrlimit} instead.
@end itemize
@item
POSIX says this function is obsolescent and it is planned to be
removed in POSIX 202x.
+You can use Gnulib module @code{utimens} instead.
@end itemize