changeset 429:67c767fc07c8

Timovj Lahde says this tweak fixes building on windows. (I wouldn't know.)
author Rob Landley <rob@landley.net>
date Thu, 05 Apr 2007 13:43:05 -0400
parents 346fbeed3612
children b331c8f04d55
files tcc.h
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/tcc.h	Wed Apr 04 14:48:49 2007 -0400
+++ b/tcc.h	Thu Apr 05 13:43:05 2007 -0400
@@ -40,9 +40,7 @@
 #include <time.h>
 #ifdef WIN32
 #include <sys/timeb.h>
-int __stdcall VirtualProtect(void *, int, int, int *);
-#endif
-#ifndef WIN32
+#else
 #include <sys/time.h>
 #include <sys/ucontext.h>
 #include <sys/mman.h>
@@ -736,6 +734,8 @@
 void *__stdcall GetModuleHandleA(const char *);
 void *__stdcall LoadLibraryA(const char *);
 int __stdcall FreeConsole(void);
+int __stdcall VirtualProtect(void*,int,int,int*);
+#define PAGE_EXECUTE_READWRITE 0x40
 
 #define snprintf _snprintf
 #define vsnprintf _vsnprintf