JuliaHubOSS / llvm-cbe

resurrected LLVM "C Backend", with improvements
Other
832 stars 141 forks source link

Unable to build llvm-cbe #56

Closed Abhiroop closed 3 years ago

Abhiroop commented 4 years ago

After pretty much following Step 1 mentioned in README, in Step 2 when I try to do

make llvm-cbe

I get the following:

[100%] Linking CXX executable ../../../../bin/llvm-cbe
collect2: error: ld returned 1 exit status
projects/llvm-cbe/tools/llvm-cbe/CMakeFiles/llvm-cbe.dir/build.make:255: recipe for target 'bin/llvm-cbe' failed
make[3]: *** [bin/llvm-cbe] Error 1
CMakeFiles/Makefile2:20783: recipe for target 'projects/llvm-cbe/tools/llvm-cbe/CMakeFiles/llvm-cbe.dir/all' failed
make[2]: *** [projects/llvm-cbe/tools/llvm-cbe/CMakeFiles/llvm-cbe.dir/all] Error 2
CMakeFiles/Makefile2:20795: recipe for target 'projects/llvm-cbe/tools/llvm-cbe/CMakeFiles/llvm-cbe.dir/rule' failed
make[1]: *** [projects/llvm-cbe/tools/llvm-cbe/CMakeFiles/llvm-cbe.dir/rule] Error 2
Makefile:6465: recipe for target 'llvm-cbe' failed
make: *** [llvm-cbe] Error 2

This is on an Ubuntu 16.04 virtual machine running on Virtual Box in Mac.

cesss commented 4 years ago

My advice is that you run CMake in verbose mode. The error seems to be that the linker failed, but you are not seeing the actual error because Makefiles are running in the default silent mode that CMake uses, and so the linker error is silenced (I always run CMake in verbose mode, because I need to know what's happening when I build code).

Once you know what the linker error is, you should be able to find a solution for it.