Beginnings of an OCaml cross-compiler.
[fedora-mingw.git] / ocaml / mingw32-ocaml-3.11.0+beta1-i386-profiling.patch
diff --git a/ocaml/mingw32-ocaml-3.11.0+beta1-i386-profiling.patch b/ocaml/mingw32-ocaml-3.11.0+beta1-i386-profiling.patch
new file mode 100644 (file)
index 0000000..b889676
--- /dev/null
@@ -0,0 +1,16 @@
+Make sure that PROFILE_* macros are defined on MinGW.  Not sure
+what to put in them yet, so at the moment they are just empty.
+
+diff -urN ocaml-3.11.0+beta1.orig/asmrun/i386.S ocaml-3.11.0+beta1.mingw/asmrun/i386.S
+--- ocaml-3.11.0+beta1.orig/asmrun/i386.S      2008-08-01 09:04:57.000000000 +0100
++++ ocaml-3.11.0+beta1.mingw/asmrun/i386.S     2008-11-15 15:08:20.000000000 +0000
+@@ -64,6 +64,9 @@
+         popl %edx; popl %ecx; popl %eax; popl %ebp
+ #define PROFILE_C \
+         pushl %ebp; movl %esp, %ebp; call Lmcount$stub; popl %ebp
++#elif defined(SYS_mingw)
++#define PROFILE_CAML
++#define PROFILE_C
+ #endif
+ #else
+ #define PROFILE_CAML