Browse Source

Fixes to cross compile to win32

mingodad 8 years ago
parent
commit
ff218543a0
1 changed files with 3 additions and 3 deletions
  1. 3 3
      SquiLu/sqstdlib/sqstdsystem.cpp

+ 3 - 3
SquiLu/sqstdlib/sqstdsystem.cpp

@@ -24,7 +24,7 @@ SQ_OPT_STRING_STRLEN();
 #ifdef WITH_UUID
 #ifdef WITH_UUID
 
 
 #ifdef _WIN32
 #ifdef _WIN32
-#include <Rpc.h> //uuid
+#include <rpc.h> //uuid
 #else
 #else
 #include <uuid/uuid.h>
 #include <uuid/uuid.h>
 #endif
 #endif
@@ -226,7 +226,7 @@ static SQRESULT _system_date(HSQUIRRELVM v)
     }
     }
     else
     else
     {
     {
-#ifdef SQ_USE_LOCALTIME_R
+#if !defined(_WIN32) && defined(SQ_USE_LOCALTIME_R)
         stm = localtime_r(&t, &ltm_r);
         stm = localtime_r(&t, &ltm_r);
 #else
 #else
         stm = localtime(&t);
         stm = localtime(&t);
@@ -285,7 +285,7 @@ static SQRESULT _system_exit (HSQUIRRELVM v) {
   exit(status);
   exit(status);
 }
 }
 
 
-#if defined(SQ_USE_MKSTEMP)
+#if !defined(_WIN32) && defined(SQ_USE_MKSTEMP)
 #include <unistd.h>
 #include <unistd.h>
 #define SQ_TMPNAMBUFSIZE	32
 #define SQ_TMPNAMBUFSIZE	32
 #define sq_tmpnam(b,e)	{ \
 #define sq_tmpnam(b,e)	{ \