8000 Delete libs directory as an entry in src to deal with the Multiple dex files error. by Honghe · Pull Request #1342 · androidannotations/androidannotations · GitHub
[go: up one dir, main page]

Skip to content
This repository was archived by the owner on Feb 26, 2023. It is now read-only.

Conversation

@Honghe
8000 Copy link
Contributor
@Honghe Honghe commented Mar 15, 2015

The libs directory added as entry of src in .classpath will cause Multiple dex files define error, such as Multiple dex files define Lorg/androidannotations/annotations/AfterExtras;.
The concrete reason is the Eclipse will copy jar file in the libs directory to the bin/classes directory, such as follows:

F:\workspace\HelloWorldEclipse\bin>tree /F
│  androidannotations.log
│  AndroidManifest.xml
│  R.txt
│  resources.ap_
│
├─classes
│  │  androidannotations-api-3.1.jar
│  │
│  ├─android
│  │  └─support
│  │      └─v7
│  └─org
│      └─androidannotations
├─dexedLibs
│      android-support-v4-259169c26135dabc8292fb369fe13d18.jar
│      android-support-v7-appcompat-fe8356d7d51ca5e59edf416a1b47d8dc.jar
│      androidannotations-api-3.1-4d54da3f520ba51cf94de9910532a000.jar
│      appcompat_v7-b77d366902bda690e3b92b10d6dba35c.jar
│
└─res
    └─crunch

So, delete the entry.

The `libs` directory added as entry of src in .classpath will cause `Multiple dex files define` error, such as `Multiple dex files define Lorg/androidannotations/annotations/AfterExtras;`.  
The concrete reason is Eclipse will copy `jar` file in the 'libs` directory to `bin/classes`dirrectory, such as follows:

	F:\workspace\HelloWorldEclipse\bin>tree /F
	│  androidannotations.log
	│  AndroidManifest.xml
	│  R.txt
	│  resources.ap_
	│
	├─classes
	│  │  androidannotations-api-3.1.jar
	│  │
	│  ├─android
	│  │  └─support
	│  │      └─v7
	│  └─org
	│      └─androidannotations
	├─dexedLibs
	│      android-support-v4-259169c26135dabc8292fb369fe13d18.jar
	│      android-support-v7-appcompat-fe8356d7d51ca5e59edf416a1b47d8dc.jar
	│      androidannotations-api-3.1-4d54da3f520ba51cf94de9910532a000.jar
	│      appcompat_v7-b77d366902bda690e3b92b10d6dba35c.jar
	│
	└─res
	    └─crunch
So, delete the entry.
WonderCsabo added a commit that referenced this pull request Mar 15, 2015
Delete libs directory as an entry in src to deal with the Multiple dex files error.
@WonderCsabo WonderCsabo merged commit 2c8a6ea into androidannotations:develop Mar 15, 2015
@WonderCsabo
Copy link
Member

You are totally right, thanks.

@WonderCsabo WonderCsabo added this to the 3.3 milestone Mar 15, 2015
@Honghe Honghe changed the title delete libs directory as an entry in src to deal with the Multiple dex files error. Delete libs directory as an entry in src to deal with the Multiple dex files error. Mar 15, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

0