[LLVMdev] LLVM in Eclipse

Csaba Raduly rcsaba at gmail.com
Wed Feb 9 05:39:12 PST 2011


Hi Abhirup,

On Wed, Feb 9, 2011 at 9:26 AM, Abhirup Ghosh  wrote:
> Hi,
>      I am new to Eclipse IDE. I am working with LLVM using command line for
> some time. Now I want to integrate it with eclipse IDE. Can anyone please
> give layman instructions how to import the llvm source project, install it
> and built it in the eclipse IDE.

You will need the Eclipse CDT plugin. Optionally, you could install
one of the Subversion plugins (Subclipse ot Subversive).

Plan A: all-in-one
File->New/Other, Checkout Projects from SVN
Create new repository location
Url: http://llvm.org/svn/llvm-project/llvm/trunk
select the root folder for checkout
In the "Check Out As" page, select "Check out as a project configured
using the New Project Wizard"
Click Finish

In the "New Project" wizard, under C/C++ select "C++ Project"
Give the project a name, e.g. LLVM
In the Project type, select Makefile project/Empty project
Select the appropriate toolchain
Click Next then Finish

Eclipse will check out the sources. After it finished, you need to run
configure manually.
Now you should be able to build the LLVM project from Eclipse, and use
Eclipse's svn integration to update it.
Note that this will not fully work if you also want the clang
frontend, because it resides in a different SVN tree.

Plan B: manual checkout
Use a Subversion client to check out LLVM (inside your workspace is
best, e.g. $HOME/workspace/LLVM)
Then create a new C++ project and name it LLVM. Eclipse would
automagically set the location to the above and warn that the
directory already exists.
In Project type, select Makefile project/empty project
Select the appropriate toolchain
Click Next then Finish

Again, you need to run configure manually, then you can build from Eclipse.

P.S. Your question is probably off-topic for the llvm mailing list.

Csaba
-- 
GCS a+ e++ d- C++ ULS$ L+$ !E- W++ P+++$ w++$ tv+ b++ DI D++ 5++
Life is complex, with real and imaginary parts.
"Ok, it boots. Which means it must be bug-free and perfect. " -- Linus Torvalds
"People disagree with me. I just ignore them." -- Linus Torvalds




More information about the llvm-dev mailing list