Eliminate remaining calls to stat in apps/apps.c and unify WIN32_rename for
[openssl.git] / e_os.h
diff --git a/e_os.h b/e_os.h
index 965d1aa8d77136529149e147a7930219ee316058..d064525ee00f5c1e5a403d304a8eb5266c851b30 100644 (file)
--- a/e_os.h
+++ b/e_os.h
@@ -245,7 +245,7 @@ extern "C" {
 #  define NO_DIRENT
 
 #  ifdef WINDOWS
-#    ifndef _WIN32_WINNT
+#    if !defined(_WIN32_WCE) && !defined(_WIN32_WINNT)
        /*
        * Defining _WIN32_WINNT here in e_os.h implies certain "discipline."
        * Most notably we ought to check for availability of each specific
@@ -282,6 +282,7 @@ static unsigned int _strlen31(const char *str)
 #  include <fcntl.h>
 
 #  ifdef OPENSSL_SYS_WINCE
+#    define OPENSSL_NO_POSIX_IO
 #    include <winsock_extras.h>
 #  endif
 
@@ -408,6 +409,10 @@ static unsigned int _strlen31(const char *str)
 #      define setvbuf(a, b, c, d) setbuffer((a), (b), (d))
        typedef unsigned long clock_t;
 #    endif
+#    ifdef OPENSSL_SYS_WIN32_CYGWIN
+#      include <io.h>
+#      include <fcntl.h>
+#    endif
 
 #    define OPENSSL_CONF       "openssl.cnf"
 #    define SSLEAY_CONF                OPENSSL_CONF
@@ -565,6 +570,9 @@ extern HINSTANCE _hInstance;
 extern char *sys_errlist[]; extern int sys_nerr;
 # define strerror(errnum) \
        (((errnum)<0 || (errnum)>=sys_nerr) ? NULL : sys_errlist[errnum])
+  /* Being signed SunOS 4.x memcpy breaks ASN1_OBJECT table lookup */
+#include "crypto/o_str.h"
+# define memcmp OPENSSL_memcmp
 #endif
 
 #ifndef OPENSSL_EXIT