Shell64 / llvm-lua

Exported from code.google.com/p/llvm-lua ; Just a mirror.
Other
0 stars 0 forks source link

/usr/bin/ld: cannot find -lffi (64bit linux) #9

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I do have llvm and clang, and it's satisfied when running cmake - but the 
make itself fails:

vadi@vadi-laptop:~/Programs/llvm_lua-1.2.0$ cd build
vadi@vadi-laptop:~/Programs/llvm_lua-1.2.0/build$ cmake .. -
DCMAKE_BUILD_TYPE=Release
llvm jit libs: -lLLVMipo -lLLVMBitWriter -lLLVMLinker -lLLVMArchive -
lLLVMBitReader -lLLVMX86Disassembler -lLLVMX86AsmParser -lLLVMMCParser -
lLLVMX86AsmPrinter -lLLVMX86CodeGen -lLLVMSelectionDAG -lLLVMAsmPrinter -
lLLVMX86Info -lLLVMJIT -lLLVMExecutionEngine -lLLVMCodeGen -lLLVMScalarOpts 
-lLLVMInstCombine -lLLVMTransformUtils -lLLVMipa -lLLVMAnalysis -
lLLVMTarget -lLLVMMC -lLLVMCore -lLLVMSupport -lLLVMSystem -
L/usr/lib/llvm/lib
llvm all libs: -lLLVMXCoreCodeGen -lLLVMXCoreAsmPrinter -lLLVMXCoreInfo -
lLLVMSystemZCodeGen -lLLVMSystemZAsmPrinter -lLLVMSystemZInfo -
lLLVMSparcCodeGen -lLLVMSparcAsmPrinter -lLLVMSparcInfo -
lLLVMPowerPCCodeGen -lLLVMPowerPCAsmPrinter -lLLVMPowerPCInfo -
lLLVMpic16passes -lLLVMPIC16AsmPrinter -lLLVMPIC16CodeGen -lLLVMPIC16Info -
lLLVMMSP430CodeGen -lLLVMMSP430AsmPrinter -lLLVMMSP430Info -lLLVMMSIL -
lLLVMMSILInfo -lLLVMMipsAsmPrinter -lLLVMMipsCodeGen -lLLVMMipsInfo -
lLLVMMBlazeAsmPrinter -lLLVMMBlazeCodeGen -lLLVMMBlazeInfo -lLLVMLinker -
lLLVMipo -lLLVMInterpreter -lLLVMInstrumentation -lLLVMJIT -
lLLVMExecutionEngine -lLLVMCppBackend -lLLVMCppBackendInfo -
lLLVMCellSPUCodeGen -lLLVMCellSPUAsmPrinter -lLLVMCellSPUInfo -
lLLVMCBackend -lLLVMCBackendInfo -lLLVMBlackfinCodeGen -
lLLVMBlackfinAsmPrinter -lLLVMBlackfinInfo -lLLVMBitWriter -
lLLVMX86Disassembler -lLLVMX86AsmParser -lLLVMX86AsmPrinter -
lLLVMX86CodeGen -lLLVMX86Info -lLLVMAsmParser -lLLVMARMAsmParser -
lLLVMMCParser -lLLVMARMAsmPrinter -lLLVMARMCodeGen -lLLVMARMInfo -
lLLVMArchive -lLLVMBitReader -lLLVMAlphaCodeGen -lLLVMSelectionDAG -
lLLVMAlphaAsmPrinter -lLLVMAsmPrinter -lLLVMCodeGen -lLLVMScalarOpts -
lLLVMInstCombine -lLLVMTransformUtils -lLLVMipa -lLLVMAnalysis -lLLVMTarget 
-lLLVMMC -lLLVMCore -lLLVMAlphaInfo -lLLVMSupport -lLLVMSystem -
L/usr/lib/llvm/lib
-- Configuring done
-- Generating done
-- Build files have been written to: /home/vadi/Programs/llvm_lua-1.2.0
vadi@vadi-laptop:~/Programs/llvm_lua-1.2.0/build$ make
[  2%] Building C object build/CMakeFiles/bin2c.dir/bin2c.o
Linking C executable bin2c
[  2%] Built target bin2c
[  4%] Generating lua_vm_ops_bc.h
Scanning dependencies of target llvm-lua_dynamic
[  6%] Building C object build/CMakeFiles/llvm-
lua_dynamic.dir/lua_interpreter.o
[  8%] Building CXX object build/CMakeFiles/llvm-
lua_dynamic.dir/LLVMCompiler.o
[ 10%] Building CXX object build/CMakeFiles/llvm-
lua_dynamic.dir/llvm_compiler.o
[ 12%] Building CXX object build/CMakeFiles/llvm-
lua_dynamic.dir/load_embedded_bc.o
[ 14%] Building CXX object build/CMakeFiles/llvm-
lua_dynamic.dir/load_vm_ops.o
[ 16%] Building C object build/CMakeFiles/llvm-lua_dynamic.dir/lua_core.o
[ 18%] Building C object build/CMakeFiles/llvm-
lua_dynamic.dir/lua_vm_ops_static.o
[ 20%] Building C object build/CMakeFiles/llvm-
lua_dynamic.dir/load_jit_proto.o
Linking CXX shared library libllvm-lua.so
[ 22%] Built target llvm-lua_dynamic
[ 25%] Building CXX object build/CMakeFiles/llvm-lua_binary.dir/llvm-lua.o
[ 27%] Building C object build/CMakeFiles/llvm-
lua_binary.dir/lua_interpreter.o
Linking CXX executable llvm-lua
/usr/bin/ld: cannot find -lffi
collect2: ld returned 1 exit status
make[2]: *** [build/llvm-lua] Error 1
make[1]: *** [build/CMakeFiles/llvm-lua_binary.dir/all] Error 2
make: *** [all] Error 2
vadi@vadi-laptop:~/Programs/llvm_lua-1.2.0/build$ 

Original issue reported on code.google.com by vpereto...@gmail.com on 27 May 2010 at 12:58

GoogleCodeExporter commented 9 years ago
Note that installing libffi-dev fixed it; it should be included in the readme.

Original comment by vpereto...@gmail.com on 27 May 2010 at 1:01

GoogleCodeExporter commented 9 years ago
libffi is not a direct dependency of llvm-lua.

Original comment by rjakabo...@gmail.com on 31 May 2012 at 6:08