Update To 11.40.268.0
[platform/framework/web/crosswalk.git] / src / native_client / src / trusted / service_runtime / include / sys / unistd.h
index 03c42e6..1e2157d 100644 (file)
@@ -20,7 +20,7 @@ extern "C" {
  * We need this file in the service_runtime only to agree on enum values,
  * therefore most of it should be compiled only for NaCl applications
  */
-#ifdef __native_client__
+#if defined(NACL_IN_TOOLCHAIN_HEADERS)
 #include <_ansi.h>
 #include <sys/types.h>
 #include <sys/_types.h>
@@ -218,14 +218,15 @@ int     _EXFUN(_execve, (const char *__path, char * const __argv[], char * const
 #endif
 
 #if defined(__CYGWIN__) || defined(__rtems__) || defined(__sh__) \
-    || defined(__SPU__) || defined(__native_client__)
+    || defined(__SPU__) || defined(NACL_IN_TOOLCHAIN_HEADERS)
 #if !defined(__INSIDE_CYGWIN__)
 int     _EXFUN(ftruncate, (int __fd, off_t __length));
 int     _EXFUN(truncate, (const char *, off_t __length));
 #endif
 #endif
 
-#if defined(__CYGWIN__) || defined(__rtems__) || defined(__native_client__)
+#if defined(__CYGWIN__) || defined(__rtems__) || \
+    defined(NACL_IN_TOOLCHAIN_HEADERS)
 int _EXFUN(getdtablesize, (void));
 int _EXFUN(setdtablesize, (int));
 useconds_t _EXFUN(ualarm, (useconds_t __useconds, useconds_t __interval));
@@ -255,7 +256,7 @@ int     _EXFUN(symlink, (const char *__name1, const char *__name2));
 #define STDOUT_FILENO   1       /* standard output file descriptor */
 #define STDERR_FILENO   2       /* standard error file descriptor */
 
-#endif  /* __native_client__ */
+#endif  /* defined(NACL_IN_TOOLCHAIN_HEADERS) */
 
 #define NACL_ABI_F_OK 0
 #define NACL_ABI_R_OK 4
@@ -295,7 +296,7 @@ enum {
     NACL_ABI__SC_NACL_PNACL_MODE
 };
 
-#ifdef __native_client__
+#if defined(NACL_IN_TOOLCHAIN_HEADERS)
 /*
  * TODO(gregoryd) pathconf and confstr are not supported on NaCl,
  * consider removing the definitions below.
@@ -364,7 +365,7 @@ enum {
 #define _CS_POSIX_V6_WIDTH_RESTRICTED_ENVS    17
 #endif
 
-#endif  /* __native_client__ */
+#endif  /* defined(NACL_IN_TOOLCHAIN_HEADERS) */
 
 #ifndef __CYGWIN__
 # define MAXPATHLEN 1024