Eclipse puts binaries in "project folder/bin/" by default. I'd like to have Eclipse put generated binaries etc in another folder (outside the project folder). Doing Android development.
-
why do you want to do like this? – Bhavesh Patadiya Oct 29 '12 at 13:58
-
1It makes project folder cleaner and easier to share, copy and so on. Especially using Dropbox and using several workstations for the same projects. This is default setting in Xcode, which I guess at one point was based on Eclipse. – Jonny Oct 29 '12 at 14:02
-
Hmm can't find any backup sources for that so I guess Xcode is not based on Eclipse at all. – Jonny Nov 06 '12 at 03:30
2 Answers
You can change the "output folder" (by default bin) for a Java project (see "How do I change a Java project's bin folder in Eclipse?")
But for Android projects, as detailed in "Can't change default output folder", you need to modify the build.properties
as well.
That can be dangerous though, as commented:
Just to note that changing the output folders doesn't work when dealing with library projects - there's part of the Ant script that is hardcoded to look in the bin folder of libs anyway.
So maybe using the exclude option of Dropbox is preferable here?
-
1Ok, I'm checking this right - there seems to be no other easy way. Maybe I should try something else than Eclipse some day... – Jonny Nov 06 '12 at 03:29
I would like to describe an approach below.
First, create a new empty project locally in eclipse work space for storing generated output files say output_bin.
As mentioned in above steps, now from Default Output Folder we need a new Variable to link to our project output folder.
- Default Output Folder -> Browse -> Create New Folder...
- -> Advance -> check "Link to folder in the file system" ->
- Variables -> New.. -> Name = PROJECT_OUT, Location = "CHOOSE_PATH_TO\output_bin\bin\Project1bin" -> Ok
Note: Project1bin is a new directory which stores the bin folder. output_bin is an empty project and you can have multiple bin folder for various projects.

- 101
- 8