* lib/unistd.in.h (getrandom): Remove declaration.
* m4/unistd_h.m4 (gl_UNISTD_H): Don't test whether getrandom is
declared.
(gl_UNISTD_H_DEFAULTS): Don't initialize GNULIB_GETRANDOM,
HAVE_GETRANDOM.
* modules/unistd (Makefile.am): Don't substitute GNULIB_GETRANDOM,
HAVE_GETRANDOM.
+2020-05-30 Bruno Haible <bruno@clisp.org>
+
+ unistd: Remove conflicting declaration of getrandom().
+ * lib/unistd.in.h (getrandom): Remove declaration.
+ * m4/unistd_h.m4 (gl_UNISTD_H): Don't test whether getrandom is
+ declared.
+ (gl_UNISTD_H_DEFAULTS): Don't initialize GNULIB_GETRANDOM,
+ HAVE_GETRANDOM.
+ * modules/unistd (Makefile.am): Don't substitute GNULIB_GETRANDOM,
+ HAVE_GETRANDOM.
+
2020-05-30 Bruno Haible <bruno@clisp.org>
getrandom: Add tests.
#endif
-#if @GNULIB_GETRANDOM@
-/* Fill a buffer with random bytes. */
-# if !@HAVE_GETRANDOM@
-_GL_FUNCDECL_SYS (getrandom, int, (void *buffer, size_t length,
- unsigned int flags));
-# endif
-_GL_CXXALIAS_SYS (getrandom, int, (void *buffer, size_t length,
- unsigned int flags));
-_GL_CXXALIASWARN (getrandom);
-#elif defined GNULIB_POSIXCHECK
-# undef getrandom
-# if HAVE_RAW_DECL_GETRANDOM
-_GL_WARN_ON_USE (getrandom, "getrandom is unportable - "
- "use gnulib module getrandom for portability");
-# endif
-#endif
-
-
#if @GNULIB_GETUSERSHELL@
/* Return the next valid login shell on the system, or NULL when the end of
the list has been reached. */
-# unistd_h.m4 serial 78
+# unistd_h.m4 serial 79
dnl Copyright (C) 2006-2020 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
]], [access chdir chown dup dup2 dup3 environ euidaccess faccessat fchdir
fchownat fdatasync fsync ftruncate getcwd getdomainname getdtablesize
getentropy getgroups gethostname getlogin getlogin_r getpagesize getpass
- getrandom getusershell setusershell endusershell
+ getusershell setusershell endusershell
group_member isatty lchown link linkat lseek pipe pipe2 pread pwrite
readlink readlinkat rmdir sethostname sleep symlink symlinkat
truncate ttyname_r unlink unlinkat usleep])
GNULIB_GETOPT_POSIX=0; AC_SUBST([GNULIB_GETOPT_POSIX])
GNULIB_GETPAGESIZE=0; AC_SUBST([GNULIB_GETPAGESIZE])
GNULIB_GETPASS=0; AC_SUBST([GNULIB_GETPASS])
- GNULIB_GETRANDOM=0; AC_SUBST([GNULIB_GETRANDOM])
GNULIB_GETUSERSHELL=0; AC_SUBST([GNULIB_GETUSERSHELL])
GNULIB_GROUP_MEMBER=0; AC_SUBST([GNULIB_GROUP_MEMBER])
GNULIB_ISATTY=0; AC_SUBST([GNULIB_ISATTY])
HAVE_GETLOGIN=1; AC_SUBST([HAVE_GETLOGIN])
HAVE_GETPAGESIZE=1; AC_SUBST([HAVE_GETPAGESIZE])
HAVE_GETPASS=1; AC_SUBST([HAVE_GETPASS])
- HAVE_GETRANDOM=1; AC_SUBST([HAVE_GETRANDOM])
HAVE_GROUP_MEMBER=1; AC_SUBST([HAVE_GROUP_MEMBER])
HAVE_LCHOWN=1; AC_SUBST([HAVE_LCHOWN])
HAVE_LINK=1; AC_SUBST([HAVE_LINK])
-e 's/@''GNULIB_GETOPT_POSIX''@/$(GNULIB_GETOPT_POSIX)/g' \
-e 's/@''GNULIB_GETPAGESIZE''@/$(GNULIB_GETPAGESIZE)/g' \
-e 's/@''GNULIB_GETPASS''@/$(GNULIB_GETPASS)/g' \
- -e 's/@''GNULIB_GETRANDOM''@/$(GNULIB_GETRANDOM)/g' \
-e 's/@''GNULIB_GETUSERSHELL''@/$(GNULIB_GETUSERSHELL)/g' \
-e 's/@''GNULIB_GROUP_MEMBER''@/$(GNULIB_GROUP_MEMBER)/g' \
-e 's/@''GNULIB_ISATTY''@/$(GNULIB_ISATTY)/g' \
-e 's|@''HAVE_GETHOSTNAME''@|$(HAVE_GETHOSTNAME)|g' \
-e 's|@''HAVE_GETPAGESIZE''@|$(HAVE_GETPAGESIZE)|g' \
-e 's|@''HAVE_GETPASS''@|$(HAVE_GETPASS)|g' \
- -e 's|@''HAVE_GETRANDOM''@|$(HAVE_GETRANDOM)|g' \
-e 's|@''HAVE_GROUP_MEMBER''@|$(HAVE_GROUP_MEMBER)|g' \
-e 's|@''HAVE_LCHOWN''@|$(HAVE_LCHOWN)|g' \
-e 's|@''HAVE_LINK''@|$(HAVE_LINK)|g' \