I have a project that builds ok in Eclipse but throws a ZipException when executing "ant debug". The output is the following (paths and project name excluded)
-dex:
[dex] Converting compiled files and external libraries into /home/.../Android/[folder]/bin/classes.dex...
[dx]
[dx] UNEXPECTED TOP-LEVEL EXCEPTION:
[dx] java.util.zip.ZipException: error in opening zip file
[dx] at java.util.zip.ZipFile.open(Native Method)
[dx] at java.util.zip.ZipFile.<init>(ZipFile.java:131)
[dx] at java.util.zip.ZipFile.<init>(ZipFile.java:148)
[dx] at com.android.dx.cf.direct.ClassPathOpener.processArchive(ClassPathOpener.java:206)
[dx] at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:131)
[dx] at com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:109)
[dx] at com.android.dx.command.dexer.Main.processOne(Main.java:418)
[dx] at com.android.dx.command.dexer.Main.processAllFiles(Main.java:329)
[dx] at com.android.dx.command.dexer.Main.run(Main.java:206)
[dx] at com.android.dx.command.dexer.Main.main(Main.java:174)
[dx] at com.android.dx.command.Main.main(Main.java:95)
[dx] 1 error; aborting
BUILD FAILED
/home/.../android-sdk-linux_x86/tools/ant/build.xml:818: The following error occurred while executing this line:
/home/.../android-sdk-linux_x86/tools/ant/build.xml:820: The following error occurred while executing this line:
/home/.../android-sdk-linux_x86/tools/ant/build.xml:832: The following error occurred while executing this line:
/home/.../android-sdk-linux_x86/tools/ant/build.xml:278: null returned: 1
This project references a library project which references another library project. So
Project A -> Project B -> Project C
To me, the weird part is that installing from eclipse everything works perfectly, but I need to be able to build the project from Ant.
I've googled for answers without success. Similar questions in SO that didn't help
How do I fix this ZipException while compiling an Android project on Jenkins?