Jump to content
Chris Pim

Java version used for bundle tool (Android 64 aab) and error

Recommended Posts

Hi,

I've successfully built and tested my app on Android 64 with Rio 10.3.3 and now trying to build the .aab file.

The project is configured to build this, but I'm getting an error at Deployment time:

 

[PAClient Error] Error: E6408 java.lang.UnsupportedClassVersionError: com/android/tools/build/bundletool/BundleToolMain : Unsupported major.minor version 52.0

 

I've always used JDK1.8.0_60 and that's what the paths are in my SDK Manager for Android 32 and 64 targets. The odd thing is that the command Delphi is running is:

 

[PAClient Error] Error: E6408 Unable to execute '"C:\Program Files\Java\jdk1.7.0_25\bin\java.exe" -jar "c:\program files (x86)\embarcadero\studio\20.0\bin\android\bundletool-all-0.10.3.jar" build-bundle --modules="C:\Development\Project\Android64\Release\Project\base.zip" --output="C:\Development\Project\Android64\Release\myShiftPlanner\bin\Project-unsigned.aab" --config="C:\Development\Project\Android64\Release\Project\buildconfig.json"' (Error 1)

 

Where is it determining that it needs to use JDK1.7.0_25? I can't see this anywhere in my Tools > Options? Surely it should be using the one I defined in my SDK Manager?

 

If I manually run the above command but use the 1.8.0_60\bin\java.exe instead, it complains about a missing buildconfig.json file - which is missing from the release folder.

 

It sounds like I may be missing a configuration or something similar? I followed EMBs instructions on the DocWiki to configure my project.

 

Has anyone else had a problem with this or know if there are issues with the bundle tool?

Share this post


Link to post

Pretty sure it uses the JDKPath entry at HKEY_CURRENT_USER\Software\Embarcadero\BDS\20.0\PlatformSDKs\AndroidSDK25.2.5_64bit.sdk

 

Which is reflected in the "Java" tab of the Android SDK settings in SDK manager.

Share this post


Link to post

Thanks Dave. Have you ever had problems with it generating the buildconfig.json file? It doesn’t seem to have created one in my release folder so wonder if I need to turn something on in my project config?

Share this post


Link to post

I’ve checked and there’s an extra key in the registry location you mentioned called JDKPath which isn’t published into the IDE. Changing this seems to have fixed the problem and I can now build an aab file! Thanks again Dave

Edited by Chris Pim

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×