Index: llvm/trunk/bindings/ocaml/analysis/analysis_ocaml.c =================================================================== --- llvm/trunk/bindings/ocaml/analysis/analysis_ocaml.c +++ llvm/trunk/bindings/ocaml/analysis/analysis_ocaml.c @@ -15,8 +15,8 @@ |* *| \*===----------------------------------------------------------------------===*/ -#include "llvm-c/Core.h" #include "llvm-c/Analysis.h" +#include "llvm-c/Core.h" #include "caml/alloc.h" #include "caml/mlvalues.h" #include "caml/memory.h" Index: llvm/trunk/bindings/ocaml/bitreader/bitreader_ocaml.c =================================================================== --- llvm/trunk/bindings/ocaml/bitreader/bitreader_ocaml.c +++ llvm/trunk/bindings/ocaml/bitreader/bitreader_ocaml.c @@ -13,6 +13,7 @@ \*===----------------------------------------------------------------------===*/ #include "llvm-c/BitReader.h" +#include "llvm-c/Core.h" #include "caml/alloc.h" #include "caml/fail.h" #include "caml/memory.h" @@ -25,7 +26,7 @@ LLVMModuleRef M; if (LLVMGetBitcodeModuleInContext2(C, MemBuf, &M)) - llvm_raise(*caml_named_value("Llvm_bitreader.Error"), ""); + llvm_raise(*caml_named_value("Llvm_bitreader.Error"), LLVMCreateMessage("")); return M; } @@ -35,7 +36,7 @@ LLVMModuleRef M; if (LLVMParseBitcodeInContext2(C, MemBuf, &M)) - llvm_raise(*caml_named_value("Llvm_bitreader.Error"), ""); + llvm_raise(*caml_named_value("Llvm_bitreader.Error"), LLVMCreateMessage("")); return M; } Index: llvm/trunk/bindings/ocaml/linker/linker_ocaml.c =================================================================== --- llvm/trunk/bindings/ocaml/linker/linker_ocaml.c +++ llvm/trunk/bindings/ocaml/linker/linker_ocaml.c @@ -15,6 +15,7 @@ |* *| \*===----------------------------------------------------------------------===*/ +#include "llvm-c/Core.h" #include "llvm-c/Linker.h" #include "caml/alloc.h" #include "caml/memory.h" @@ -26,7 +27,7 @@ /* llmodule -> llmodule -> unit */ CAMLprim value llvm_link_modules(LLVMModuleRef Dst, LLVMModuleRef Src) { if (LLVMLinkModules2(Dst, Src)) - llvm_raise(*caml_named_value("Llvm_linker.Error"), "Linking failed"); + llvm_raise(*caml_named_value("Llvm_linker.Error"), LLVMCreateMessage("Linking failed")); return Val_unit; } Index: llvm/trunk/bindings/ocaml/llvm/llvm_ocaml.c =================================================================== --- llvm/trunk/bindings/ocaml/llvm/llvm_ocaml.c +++ llvm/trunk/bindings/ocaml/llvm/llvm_ocaml.c @@ -19,6 +19,7 @@ #include #include #include "llvm-c/Core.h" +#include "llvm-c/Support.h" #include "caml/alloc.h" #include "caml/custom.h" #include "caml/memory.h"