My favorites | Sign in
Project Home Issues
New issue   Search
  Advanced search   Search tips   Subscriptions
Issue 8431: Create Android project in Eclipse from existing sources does not work
49 people starred this issue and may be notified of changes. Back to list
Reported by, May 20, 2010
Host OS: Mac OS X 10.6.3
SDK tools version: Rev 6
Eclipse version: 3.5.2 (Carbon)
ADT plug-in version: 0.9.7
Platform targeted by your project: Api 7
Version of the platform running in the emulator: n/a

After updating my config to 0.9.7, Eclipse would always hang on start. I re-installed everything 
(Eclipse / ADT) to fix. I also deleted my workspace .metadata directory (~/Projects/.metadata) 
and project's Eclipse-specific files (~/Projects/foo/.project, ~/Projects/foo/.classpath), intending 
to start with a new workspace and create a new project from my existing sources.

I now have an empty workspace in ~/Projects/
I have Android source code and manifest (with regular tree structure, but no eclipse .project or 
.classpath files) in ~/Projects/foo
I want to create a new Eclipse Android project from existing sources in ~/Projects/foo

1.File -> New -> Android Project
2. Select "Create project from existing source"
3. Enter "location": ~/Projects/foo

A new Eclipse project in ~/Projects/foo, using my existing source code and manifest.

Error Dialog: Invalid project Description. Reason: Invalid Project Description. Details: 
/user/xxx/Projects/foo overlaps the location of another project: /user/xxx/Projects/foo


May 20, 2010
This is because inside ~/Projects/foo there are project files that eclipse detect.
Instead of creating project from existing source, import an existing project and point the dialog to the 
~/projects/ folder and it'll find all the projects under it.
Status: WorkingAsIntended
Aug 2, 2010
I don't think this is caused by project files under ~/Projects/foo. The original post says that there are no Eclipse .project or .classpath files there. The error message suggests the directory structure.

I can reproduce this in Ubuntu 10.04, Eclipse 3.5.2, ADT 0.9.7. ~/Projects is a new Eclipse workspace with no .metadata directory when Eclipse is started. ~/Projects/foo is checked out from source control and does not contain any Eclipse files.

"ls -a" in ~/Projects/foo gives:
.  ..  AndroidManifest.xml  assets  res  src  .svn

If I check out foo into ~/Projects and follow the steps above, I see the error, but if I check out into another directory, I don't.

I'd expect to be able to work with ~/Projects as both Eclipse workspace and source directory. It's possible to do this for other Eclipse project types, including Java.
Sep 23, 2010
I can reproduce this also in Ubuntu 10.04, Eclipse 3.5.2, ADT 0.9.8 using, for instance, any of the SDK samples. These do not contain .project, .classpath or other Eclipse files.
Sep 24, 2010
(No comment was entered for this change.)
Status: Assigned
Labels: Target-r8
Oct 6, 2010
For the Notepad examples, the 2 problems I hit when trying to "Create a project from existing source" are
1) the "overlap" as noted above, and 
2) AndroidManifest.xml missing when that was NOT missing, just eclipse couldn't see it.
The consistent procedure that works for me (as mentioned by amaquaran) is to 
a) put your source dir in your workspace
b) from an existing functioning android project copy 3 files to your new source dir
file1  --
file2  --  .classpath
file3  --  .project
c) in the .project file, toward the top you will see the name of the project that you copied from, change this to your new project name
d) file>new>android project>Create a project from existing source
Nov 23, 2010
Reproducible in Win7 Eclipse Java EE Helios Service Release 1 (Build id: 20100917-0705), ADT 0.9.9.v201009221007-60953
Feb 2, 2011
Reproducible in WinXP, 
Eclipse Pulsar, Helios Service Release 1, Build id: 20100917-0705
Android Development Tools 8.0.1.v201012062107-82219	
Feb 8, 2011
Reproducible in Mac OS X 10.6.6, 
Eclipse Version: Helios Release Build id: 20100617-1415
Android Development Tools 9.0.0.v201101191456-93220
Feb 17, 2011
(No comment was entered for this change.)
Labels: -Target-r8 Target-r11 Subcomponent-Tools-adt
Feb 27, 2011
Reproduced Ubuntu 10.10 64-bit
Version: Helios Service Release 2
Build id: 20110218-0911
java version "1.6.0_20"
OpenJDK Runtime Environment (IcedTea6 1.9.5) (6b20-1.9.5-0ubuntu1)
OpenJDK 64-Bit Server VM (build 19.0-b09, mixed mode)

Mar 4, 2011
I had this problem when the source files I was importing were in my Eclipse Projects directory. I avoided the "overlap" error by moving the source files to another director and following the same procedure "File -> New -> Android Project -> Create project from existing source"
Mar 8, 2011
I was able to create a project from an existing source following the directions of Comment 11. However, this should only be a temporary fix. I defined a workspace already, and I would like all project files to reside there. Another alternative would be to create a new project with the same properties as the existing source project, and then copy the existing files over before building.
Mar 10, 2011
Reproducible in Ubuntu 10.10 64-bit

Eclipse SDK
Version: 3.6.1
Build id: M20100909-0800

Android Development Toolkit
Version: 10.0.0.v201102162101-104271

java version "1.6.0_24"
Java(TM) SE Runtime Environment (build 1.6.0_24-b07)
Java HotSpot(TM) 64-Bit Server VM (build 19.1-b02, mixed mode)

Mar 22, 2011
same problem
helios 3.6.2, build id: M20110210-1200
on windows 7 64 bit with jdk1.6.0_24

Was able to get around by copying the files mentioned in comment 5;
however, after doing this you must *import* the project, not 'create from existing
Mar 28, 2011
(No comment was entered for this change.)
Labels: -target-r11 target-r12
Apr 8, 2011
even I'm facing the same problem.
May 10, 2011
eclipse: 3.6.2, Build id: M20110210-1200
adt: 10.0.0

for notepad which is android tutorial
i can create existing project in directory workspace/notepadsolution/notepadv1
but can not in workspace/notepadv1.

the exception msg is invalid project desciption, overlaps the location of another project: 'notepadv1'

my workmate's eclipse is Galileo.
he can import this project in anywhere

May 30, 2011
Reproductable on :
Windows 7 Home Premium 64-bit
Eclipse SDK Version: 3.6.2 Build id: M20110210-1200 x86_64

Android Development Toolkit Version: 10.0.1.v201103111512-110841
Dalvik Debug Monitor Service Version: 10.0.1.v201103111512-110841
Hierarchy Viewer Version: 10.0.1.v201103111512-110841

Please fix

May 30, 2011
Comments 5 and 14 really helps. Thank you guys :)
Jun 23, 2011
I found that using right click cut and paste inside of the Eclipse Package Explorer works for duplicating a project... but only when the project you are copying is 'open'.  A window will appear that allows you to specify the name of the new project.
Jul 13, 2011
(No comment was entered for this change.)
Status: Unassigned
Labels: -target-r12
Aug 3, 2011
Project Member #23
(No comment was entered for this change.)
Aug 31, 2011
Here's another possible round-about way to work around it:
Jun 15, 2012
+1 - Been struggling with this issue for a year or so and only just found this issue. Any news on a fix for this?
Jul 24, 2012
Same problem on OSX with eclipse 3.7 and 4.2.
Aug 7, 2012

1. Switch to Window//Show View >> Project Explorer.

2. Right-Click in that View

3. Left-Click Refresh

Helped me to remove Workspace Project wich were not in File-System any more and also deleted in Package Explorer. And can't been opened there aggain cause of eroors.

Hope that will help you guys too

Oct 22, 2012
Not a fix per se but works:

1 ) Move the offending project folder to another directory (command run from workspace folder)
 > mv project-folder/ ..

2) Create a new Android Project from Existing Source (or whatever it's called), and CHECK copy files.

3) Move offending project back  (command run from workspace folder)
> mv ../project-folder .

Ta dah. (facepalm)
Feb 5, 2013
Any chance of an actual fix for this? Almost three years now and still nothing!
Feb 26, 2013
POST #1 has the correct answer!

"This is because inside ~/Projects/foo there are project files that eclipse detect.
Instead of creating project from existing source, import an existing project and point the dialog to the 
~/projects/ folder and it'll find all the projects under it."
Jun 18, 2013
(No comment was entered for this change.)
Status: Assigned
Aug 21, 2013
Initially I was trying to import an android project from github and encountered the above problem 

 - cannot configure build path 

 - unable to get system libraries

> Package Explorer -> Right click the project -> “Properties” ->
> "Android" -> "Project Build Target" = 2.3.3

found the solution from this [link]

Note: Also try Clean (On Windows: Project -> Clean) then Refresh (F5) at random.  There's a good chance this will magically solve all your problems.
Feb 16, 2014
confirming against ADT v22.3.0.v201310242005-887826

Jul 21, 2014
Project Member #34
(No comment was entered for this change.)
Labels: Triaged-yes
Jul 21, 2014
Project Member #35
(No comment was entered for this change.)
Status: Unassigned
Sign in to add a comment

Powered by Google Project Hosting