6
votes

My Project -> Builders list looks like this:

  • Ant
  • Android resource manager
  • Android pre compiler
  • Java builder
  • Android Package manager

"Build Automatically" option is turned off

If I run ant target from Ant view or as external tool then Eclipse makes this:

  1. It builds my project (it runs all builders from the builders list)
  2. Executes selected target

If I remove Ant from builders list it executes only selected ant target (that's what I want).

How can I make Eclipse launch only selected ant target without running other builders and without removing ant builder from the builders list?

2
not sure i really understand what you are after here. if you want to just run one (or a subset) of your and task you can always use the external run and configure your ant task there. the you can run it anytime you want by selecting it from the external run men. - Newtopian
@Newtopian , I tried to make an "external tool" configuration but result is the same: before running ant target Eclipse builds entire project. - Dmitry
@AlexK, Thank you for the links. In the first one it's described how to make a separate configuration for ant target but I've tried it. When I run this configuration Eclipse runs ant builder from builders list and only after that it runs selected target. - Dmitry

2 Answers

7
votes
  1. Go to Run > External Tools > External Tool Configurations...
  2. Choose the Ant build configuration for your project.
  3. Click on the Build tab
  4. Uncheck the "Build before launch" box.
  5. Press "Apply" and "Close" buttons.
0
votes

You can turn off "build before launch"

You have turned rebuild off for resource modification but I believe you have

not turned off "Build before launch"

Window>Preferences>Run/Debug>Build (if required) before launching