summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDaiki Ueno <ueno@gnu.org>2014-12-11 16:07:31 +0900
committerPaul Eggert <eggert@cs.ucla.edu>2014-12-12 10:15:26 -0800
commit73991ca4ba667724ea90f5603ba2161c7382b902 (patch)
tree662ef80376d5c613429fc54c9af10de7a88d4c2f /lib
parent89db07c7c6927dcd5e59dcd5fa0bdad7e40f8269 (diff)
downloadgnulib-73991ca4ba667724ea90f5603ba2161c7382b902.tar.gz
unistd: fix iOS check conditional
On Mac OS X 10.8, the TARGET_* macros are unconditonally defined as 0 or 1 in <TargetConditionals.h>, and the previous check always yielded true on non-iOS environment. * lib/unistd.in.h (environ) [__APPLE__]: Check the values of TARGET_OS_IPHONE and TARGET_IPHONE_SIMULATOR, instead of whether they are defined.
Diffstat (limited to 'lib')
-rw-r--r--lib/unistd.in.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/unistd.in.h b/lib/unistd.in.h
index b4a3f5b312..7907f832c9 100644
--- a/lib/unistd.in.h
+++ b/lib/unistd.in.h
@@ -402,7 +402,7 @@ _GL_WARN_ON_USE (dup3, "dup3 is unportable - "
"VARIABLE=VALUE", terminated with a NULL. */
# if defined __APPLE__ && defined __MACH__
# include <TargetConditionals.h>
-# if !defined TARGET_OS_IPHONE && !defined TARGET_IPHONE_SIMULATOR
+# if !TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
# define _GL_USE_CRT_EXTERNS
# endif
# endif