Documentation about problem on MacOS X 10.
[pspp] / doc / posix-functions / environ.texi
1 @node environ
2 @section @code{environ}
3 @findex environ
4
5 POSIX specification: @url{http://www.opengroup.org/susv3xsh/environ.html}
6
7 Gnulib module: ---
8
9 Portability problems fixed by Gnulib:
10 @itemize
11 @end itemize
12
13 Portability problems not fixed by Gnulib:
14 @itemize
15 @item
16 This variable is missing on some platforms:
17 MacOS X 10.3, FreeBSD 6.0, NetBSD 3.0, OpenBSD 3.8, IRIX 6.5, OSF/1 5.1, Cygwin.
18 @item
19 On MacOS X 10, this variable is not declared.  Up to MacOS X 10.4, one can use
20 @smallexample
21 extern char **environ;
22 @end smallexample
23 to get the variable declared.  This does not work any more, however, in
24 shared libraries on MacOS X 10.5.  Here is a workaround: Instead, one can use
25 @smallexample
26 #include <crt_externs.h>
27 #define environ (*_NSGetEnviron())
28 @end smallexample
29 This works at least on MacOS X 10.3 and newer.
30 @item
31 The address of this variable is not a compile-time constant on some platforms:
32 mingw.
33 @end itemize