[LLVMdev] Creating and building LLVM projects with Eclipse CDT on Windows?

Óscar Fuentes ofv at wanadoo.es
Sun Aug 1 22:03:50 PDT 2010

Trip Volpe <mraccident at gmail.com> writes:


> So what's the scoop? Is there any way I can conveniently create a project
> with Eclipse CDT that uses LLVM? What do I actually need to include and
> link? Any advice or guidance would be greatly appreciated.

On your Eclipse project:

1. Set the #include paths to where LLVM headers are installed.

2. Set the library paths to where LLVM libraries are installed.

3. On a command shell, run "llvm-config --libs component1 component2.."
replacing the names of the LLVM components you need on your project.

4. Copy the names of the libraries shown on the previous step to your
Eclipse project.

5. If you get weird errors while building or running your project, see
what the LLVM example projects do: run "make VERBOSE=1" to see the full
command line and watch for #define's, system libraries, etc.

6. If you keep having problems with the above, ask for help here
describing what the problem is and listing the output of "make
VERBOSE=1" for at least the compilation of one .cpp file and the link
phase of your project, plus copying&pasting whatever error messages you
see (if gcc outputs one of those enourmous and useless error message
list, reporting the first ten or so is enough.)

More information about the llvm-dev mailing list