[LLVMdev] llvm 2.2 install and ocaml bindings

Erick Tryzelaar idadesub at users.sourceforge.net
Wed Feb 20 19:27:01 PST 2008


I've run into a problem with the ocaml bindings and the jit. It builds
fine without the jit, but when I try to include it it tries to use the
c object files from the build location, instead of the install
location:

> llvm-config --libdir --libfiles engine
/opt/local/lib
/opt/local/lib/LLVMX86.o /opt/local/lib/libLLVMSelectionDAG.a
/opt/local/lib/libLLVMCodeGen.a /opt/local/lib/libLLVMScalarOpts.a
/opt/local/lib/libLLVMTransformUtils.a /opt/local/lib/libLLVMipa.a
/opt/local/lib/libLLVMAnalysis.a /opt/local/lib/LLVMExecutionEngine.o
/opt/local/lib/LLVMJIT.o /opt/local/lib/libLLVMTarget.a
/opt/local/lib/libLLVMCore.a /opt/local/lib/libLLVMSupport.a
/opt/local/lib/libLLVMSystem.a
> ocamlc -g -cc g++ -I `llvm-config --libdir --libfiles engine` -o toy llvm.cma llvm_analysis.cma llvm_executionengine.cma lexer.cmo parser.cmo codegen.cmo main.ml
i686-apple-darwin8-g++-4.0.1:
/opt/local/var/macports/build/_Users_Shared_erickt_Projects_macports_dports.git_lang_llvm/work/build/Release/lib/LLVMX86.o:
No such file or directory
i686-apple-darwin8-g++-4.0.1:
/opt/local/var/macports/build/_Users_Shared_erickt_Projects_macports_dports.git_lang_llvm/work/build/Release/lib/LLVMInterpreter.o:
No such file or directory
i686-apple-darwin8-g++-4.0.1:
/opt/local/var/macports/build/_Users_Shared_erickt_Projects_macports_dports.git_lang_llvm/work/build/Release/lib/LLVMExecutionEngine.o:
No such file or directory
i686-apple-darwin8-g++-4.0.1:
/opt/local/var/macports/build/_Users_Shared_erickt_Projects_macports_dports.git_lang_llvm/work/build/Release/lib/LLVMJIT.o:
No such file or directory
Error while building custom runtime system
make: *** [all] Error 2

Since it's just a temporary build, it obviously doesn't exist any more
:) Does anyone know how to fix this?

-e



More information about the llvm-dev mailing list