Integrate win32 into ansiperl
[p5sagit/p5-mst-13.2.git] / perl.h
diff --git a/perl.h b/perl.h
index 4edbd0d..bec110c 100644 (file)
--- a/perl.h
+++ b/perl.h
@@ -113,7 +113,8 @@ register struct op *op asm(stringify(OP_IN_REGISTER));
 # define STANDARD_C 1
 #endif
 
-#if defined(__cplusplus) || defined(WIN32) || defined(__sgi) || defined(OS2)
+#if defined(__cplusplus) || defined(WIN32) || defined(__sgi) || defined(OS2) \
+       || defined(__DGUX)
 # define DONT_DECLARE_STD 1
 #endif
 
@@ -1299,19 +1300,21 @@ END_EXTERN_C
 #endif
 
 #ifndef __cplusplus
-#ifdef __NeXT__ /* or whatever catches all NeXTs */
+#  ifdef __NeXT__ /* or whatever catches all NeXTs */
 char *crypt ();       /* Maybe more hosts will need the unprototyped version */
-#else
+#  else
+#    if !defined(WIN32) || !defined(HAVE_DES_FCRYPT)
 char *crypt _((const char*, const char*));
-#endif
-#ifndef DONT_DECLARE_STD
-#ifndef getenv
+#    endif /* !WIN32 && !HAVE_CRYPT_SOURCE */
+#  endif /* !__NeXT__ */
+#  ifndef DONT_DECLARE_STD
+#    ifndef getenv
 char *getenv _((const char*));
-#endif
+#    endif /* !getenv */
 Off_t lseek _((int,Off_t,int));
-#endif
+#  endif /* !DONT_DECLARE_STD */
 char *getlogin _((void));
-#endif
+#endif /* !__cplusplus */
 
 #ifdef UNLINK_ALL_VERSIONS /* Currently only makes sense for VMS */
 #define UNLINK unlnk
@@ -1380,7 +1383,9 @@ int runops_debug _((void));
 
 /* VMS doesn't use environ array and NeXT has problems with crt0.o globals */
 #if !defined(VMS) && !(defined(NeXT) && defined(__DYNAMIC__))
-#if !defined(DONT_DECLARE_STD) || (defined(__svr4__) && defined(__GNUC__) && defined(sun)) || defined(__sgi)
+#if !defined(DONT_DECLARE_STD) \
+       || (defined(__svr4__) && defined(__GNUC__) && defined(sun)) \
+       || defined(__sgi) || defined(__DGUX)
 extern char ** environ;        /* environment variables supplied via exec */
 #endif
 #else
@@ -1664,6 +1669,10 @@ struct perl_thread {
 #include "thrdvar.h"
 };
 
+typedef struct perl_thread *Thread;
+
+#else
+typedef void *Thread;
 #endif
 
 /* Done with PERLVAR macros for now ... */
@@ -1671,8 +1680,6 @@ struct perl_thread {
 #undef PERLVARI
 #undef PERLVARIC
 
-typedef struct perl_thread *Thread;
-
 #include "thread.h"
 #include "pp.h"
 #include "proto.h"