On 7 September 2011 22:33, Bruno Haible <br...@clisp.org> wrote: > > For crypt() to be declared in <crypt.h>, you need nothing.
But neither crypt(3) nor crypt(3posix) documents accessing crypt via #include <crypt.h>, which suggests that's a non-standard way to get the function. > Note that <config.h> must be the first header file to be included in every > compilation unit. Gah, caught out by that one again; thanks. > Certainly the fact that crypt() is not defined by default could be mentioned > in doc/posix-functions/crypt.texi. Patch follows: diff --git a/ChangeLog b/ChangeLog index 79d9777..9a64036 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2011-09-07 Reuben Thomas <r...@sc3d.org> + + crypt: Document that the function is not defined by default in glibc. + 2011-09-07 Bruno Haible <br...@clisp.org> openat: Work around compilation error with OSF/1 5.1 DTK cc. diff --git a/doc/posix-functions/crypt.texi b/doc/posix-functions/crypt.texi index b7f1927..7651d3e 100644 --- a/doc/posix-functions/crypt.texi +++ b/doc/posix-functions/crypt.texi @@ -15,4 +15,7 @@ Portability problems not fixed by Gnulib: @item This function is missing on some platforms: FreeBSD 6.0, NetBSD 5.0, Cygwin, mingw. +@item +Crypt is not defined by default on some platforms: +glibc. @end itemize -- http://rrt.sc3d.org