tags:

views:

291

answers:

3

I've just started using Eclipse for Python development since we can make use of a lovely plugin I've found to enable distributed pair-programming. Anyway, the next step to getting Eclipse to integrate properly with our existing environment, would be finding a way to drive our current build tool (Waf) from within the IDE.

So the question is, is there a way I can set up Eclipse to drive Waf in a Make-like fashion? I see for Make it has some quite advanced functionality, such as being able to work out what targets are available etc. Bonus points for telling me if there is a way I could go as far as this! (I suspect the answer is that this is all built in to the Make plugin for Ecplipse).

+2  A: 
VonC
A: 

As VonC says, the elegant way is to use a Custom builder.

Alternatively it is less work (in the short term) to hack together an ant script to do the heavy lifting and define an external builder to configure it onto the project. You may find the drawbacks of an external builder (e.g. no incremental support) mean it is worth investing the effort to do it "properly".

Rich Seller
+2  A: 

In eclipse CDT I run waf by simply changing the build program in ProjectPreferences->C/C++ Build->BuilderSettings Choose External builder and then put in the path to waf

for example I use /Users/mark/bin/waf -v -k -j2

Note that waf and make do not agree on the -j setting and you have to give i explicitly and not use the eclipse dialog.

You can use the Make targets view add the targets to call waf e.g. configure, build etc.

One issue I had is that Eclipse is hard coded to see the output from Make say Make when i changes directory so I had to patch waf see waf issue

Mark