#include <winsock2.h>
#include <windows.h>
#include <winbase.h>
+/*
+ * The mingw version says:
+ * /usr/i686-pc-mingw32/sys-root/mingw/include/ws2tcpip.h:38:2: error: #error "ws2tcpip.h is not compatible with winsock.h. Include winsock2.h instead."
+ */
+#ifdef _MSC_VER
#include <ws2tcpip.h>
+#endif
#include <psapi.h>
#include <shlobj.h>
#include <mswsock.h>
static __inline__ __attribute__((always_inline))
/* This is not defined by gcc */
unsigned long long
-__readfsdword (unsigned long long offset)
+__readfsdword (unsigned long offset)
{
- unsigned long long value;
- __asm__("movl %%fs:%a[offset], %k[value]" : [value] "=q" (value) : [offset] "irm" (offset));
+ unsigned long value;
+ // __asm__("movl %%fs:%a[offset], %k[value]" : [value] "=q" (value) : [offset] "irm" (offset));
+ __asm__ volatile ("movl %%fs:%1,%0"
+ : "=r" (value) ,"=m" ((*(volatile long *) offset)));
return value;
}
#endif
mono: mono-$(mono_bin_suffix)
ln -sf $< $@
+mono.exe: mono-$(mono_bin_suffix).exe
+ ln -sf $< $@
+
install-exec-hook:
(cd $(DESTDIR)$(bindir) && ln -sf mono-$(mono_bin_suffix) mono)
(cd $(DESTDIR)$(libdir); for i in libmono$(libmono_suffix)*; do ln -sf $$i `echo $$i | sed s/$(libmono_suffix)//` ; done)
MONO_SGEN_LIB=$(sgen_static_libraries)
else
MONO_LIB=libmonoboehm-2.0.la
-MONO_LIBLIB=libmonosgen-2.0.la
+MONO_SGEN_LIB=libmonosgen-2.0.la
endif
if LOADED_LLVM
gboolean res;
g_assert (tls->info);
+#ifdef TARGET_WIN32
+ return;
+#else
res = mono_thread_state_init_from_handle (&tls->unwind_state, (MonoNativeThreadId)tls->tid, tls->info->native_handle);
+#endif
} else {
tls->unwind_state.unwind_data [MONO_UNWIND_DATA_LMF] = mono_get_lmf ();
if (sigctx) {