About Store Forum Documentation Contact
Donations:
166$/mo



Post Reply 
[Android] Cannot build after today's update
Author Message
cat555 Offline
Member

Post: #1
[Android] Cannot build after today's update
Hi, after today's update, i cannot build for Android platform. Here's the exception:

Code:
[buildconfig] Generating BuildConfig class.
-pre-compile:
-compile:
    [javac] Compiling 3 source files to /home/cvieira/gamedev/Esenthel/Projects/_Build_/Plane test/Android/bin/classes
-post-compile:
-obfuscate:
-dex:
      [dex] input: /home/cvieira/gamedev/Esenthel/Projects/_Build_/Plane test/Android/bin/classes
      [dex] input: /home/cvieira/gamedev/adt-bundle-linux-x86_64-20131030/sdk/tools/support/annotations.jar
      [dex] input: /home/cvieira/gamedev/Esenthel/Projects/_Build_/Plane test/Android/libs/GoogleAdMobAds.jar
      [dex] Pre-Dexing /home/cvieira/gamedev/adt-bundle-linux-x86_64-20131030/sdk/tools/support/annotations.jar -> annotations-2d8eb2c9c071e4f9e04549f352a2a184.jar
      [dex] Pre-Dexing /home/cvieira/gamedev/Esenthel/Projects/_Build_/Plane test/Android/libs/GoogleAdMobAds.jar -> GoogleAdMobAds-f19f450f2cd3a6028e6bbcf948813a80.jar
      [dex] Converting compiled files and external libraries into /home/cvieira/gamedev/Esenthel/Projects/_Build_/Plane test/Android/bin/classes.dex...
       [dx]
       [dx] UNEXPECTED TOP-LEVEL EXCEPTION:
       [dx] java.nio.BufferOverflowException
       [dx]    at java.nio.Buffer.nextPutIndex(Buffer.java:501)
       [dx]    at java.nio.HeapByteBuffer.putShort(HeapByteBuffer.java:296)
       [dx]    at com.android.dex.Dex$Section.writeShort(Dex.java:818)
       [dx]    at com.android.dex.Dex$Section.writeTypeList(Dex.java:870)
       [dx]    at com.android.dx.merge.DexMerger$3.write(DexMerger.java:437)
       [dx]    at com.android.dx.merge.DexMerger$3.write(DexMerger.java:423)
       [dx]    at com.android.dx.merge.DexMerger$IdMerger.mergeUnsorted(DexMerger.java:317)
       [dx]    at com.android.dx.merge.DexMerger.mergeTypeLists(DexMerger.java:423)
       [dx]    at com.android.dx.merge.DexMerger.mergeDexes(DexMerger.java:163)
       [dx]    at com.android.dx.merge.DexMerger.merge(DexMerger.java:187)
       [dx]    at com.android.dx.command.dexer.Main.mergeLibraryDexBuffers(Main.java:439)
       [dx]    at com.android.dx.command.dexer.Main.runMonoDex(Main.java:287)
       [dx]    at com.android.dx.command.dexer.Main.run(Main.java:230)
       [dx]    at com.android.dx.command.dexer.Main.main(Main.java:199)
       [dx]    at com.android.dx.command.Main.main(Main.java:103)
BUILD FAILED
/home/cvieira/gamedev/adt-bundle-linux-x86_64-20131030/sdk/tools/ant/build.xml:892: The following error occurred while executing this line:
/home/cvieira/gamedev/adt-bundle-linux-x86_64-20131030/sdk/tools/ant/build.xml:894: The following error occurred while executing this line:
/home/cvieira/gamedev/adt-bundle-linux-x86_64-20131030/sdk/tools/ant/build.xml:906: The following error occurred while executing this line:
/home/cvieira/gamedev/adt-bundle-linux-x86_64-20131030/sdk/tools/ant/build.xml:284: null returned: 2
01-29-2014 12:14 PM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #2
RE: [Android] Cannot build after today's update
Hi,

I've just tried compiling Android project on Windows, Linux and Mac and all went well.
Can you make sure that you have latest Android SDK, NDK, and Java JDK installed?

http://stackoverflow.com/questions/19727...n-building
Possibly you need to upgrade your Android SDK
01-29-2014 11:11 PM
Find all posts by this user Quote this message in a reply
cat555 Offline
Member

Post: #3
RE: [Android] Cannot build after today's update
Hi, i've updated NDK from r9b to r9c... and updated SDK, which included updates to Android SDK build tools, platform tools and Android support library, all of them to 19.0.1.

But the problem is the same (it was working Ok just 2 days ago... the only change i've made was the Esenthel update)... i've checked AndroidManifest.xml and project.properties... i wanted to make some tests here, but those are overwritten everytime i build project, so no tests i can do here...

I have this in AndroidManifest.xml:

Code:
<uses-sdk android:minSdkVersion="9" android:targetSdkVersion="14"/>

and this in project.properties:

Code:
target=android-10

Shouldn't both point to the same target? Shouldn't we be able to modify these files also? Esenthel users may feel the need to add/remove permissions for example? I saw that you included googleadmob jar, but what if we don't to use it? How can we remove it?
01-30-2014 12:34 PM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #4
RE: [Android] Cannot build after today's update
Hi, this issue is related to Java/Google Android SDK, not with EE.
https://code.google.com/p/android/issues...l?id=61710
I recommend that you try fiddling around with your versions of the Java/Google SDK's.
01-30-2014 08:17 PM
Find all posts by this user Quote this message in a reply
cat555 Offline
Member

Post: #5
RE: [Android] Cannot build after today's update
Yes, i know, but i was trying to understand if any modifications on EE, lead to a android sdk bug to show up...

It's weird, but the simple reinstallation of android sdk build tools 19.0.1 solved the problem.

Thanks!
01-31-2014 11:51 AM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #6
RE: [Android] Cannot build after today's update
Hi, yes the problem appeared because I had to include some basic Java code.
Glad that it started working, thanks for the info.
01-31-2014 10:12 PM
Find all posts by this user Quote this message in a reply
Post Reply