12

I'm trying package my kivy app (python3) but when i run the command buildozer -v android debug see this error

# Cwd /home/javier/.buildozer/android/platform/android-sdk
Error occurred during initialization of boot layer
java.lang.module.FindException: Module java.se.ee not found
# Command failed: /home/javier/.buildozer/android/platform/android-sdk/tools/bin/sdkmanager tools platform-tools
# 
# Buildozer failed to execute the last command
# The error might be hidden in the log above this error
# Please read the full log, and search for it before
# raising an issue with buildozer itself.
# In case of a bug report, please add a full log with log_level = 2

I have this Java version

$ java --version
openjdk 11.0.2 2019-01-15
OpenJDK Runtime Environment (build 11.0.2+9-Ubuntu-3ubuntu118.04.3)
OpenJDK 64-Bit Server VM (build 11.0.2+9-Ubuntu-3ubuntu118.04.3, mixed mode, sharing)

I downloaded only sdkmanager Command line tools from here and put it in my root path but i don't had success.

I Saw in this post a solution and i did it but i don't solve the error.

I has a virtualenv with all dependencies installed. Also i edited the buildozer.spec and i was custom it

The Virtualenv is:

(envAppSinapsis)~/AppSin$ pip freeze
certifi==2019.3.9
chardet==3.0.4
Cython==0.28.2
docutils==0.14
idna==2.8
Kivy==1.10.1
Kivy-Garden==0.1.4
psycopg2==2.7.6.1
psycopg2-binary==2.7.6.1
pygame==1.9.4.dev0
Pygments==2.3.1
requests==2.21.0
urllib3==1.24.1

I think that error is related to something related to JAVA but I do not know what. I would appreciate your helps, and please, excuse my bad English.

I am working in Ubuntu 18

UPDATE Print Screen Error

3
  • It looks like you're using OpenJDK 11, could you try using 8 instead? Commented Apr 17, 2019 at 20:35
  • Since JDK 9, The se.ee packages marked as deprecated so you need to include EE packages accordingly. Or just downgrade your JAVA to 9 or 8 Commented Apr 17, 2019 at 20:38
  • docs.oracle.com/javase/10/docs/api/java.se.ee-summary.html Commented Apr 17, 2019 at 20:43

3 Answers 3

22

Up until a few days ago if you had installed openjdk-11-jdk/jre from the Ubuntu repos you would have found it was actually a version of Java 10 (https://askubuntu.com/questions/1037646/why-is-openjdk-10-packaged-as-openjdk-11).

java.se.ee has been deprecated in Java 9, 10 and removed in Java 11 (https://www.oracle.com/technetwork/java/javase/11-relnote-issues-5012449.html)

Unfortunately there is no simple way to get the Android tools like sdkmanager or avdmanager running with Java 11 yet.

I was able to get buildozer running on Ubuntu again with Java 10:

  • Download Java 10 Linux x64 JDK (.tar.gz) from http://jdk.java.net/java-se-ri/10
  • Untar: tar -xzvf jdk-10_linux-x64_bin_ri.tar.gz
  • Set PATH: export PATH=/path/to/inflated/jdk-10/bin:$PATH
Sign up to request clarification or add additional context in comments.

Comments

13

was getting error License not accepted for SDK Build tools etc

solved by Installing

  1. SDK Command Line Tools
  2. Google Play licensing services

in SDK Manager > SDK Tools

helped me after getting frustrated for 2 hours, and hearing from everyone that only way is to downgrade Java

2 Comments

It should be mentioned that if you previously edited JAVA_OPTS using 'export JAVA_OPTS='-XX:+IgnoreUnrecognizedVMOptions --add-modules java.se.ee'' Then you need to set it back to: export JAVA_OPTS = ''
Of all the answers. Yours was the one that worked. There was no option to accept the lisense without the license server apparently
-6

You can solve this error by downgrading Java or by executing the below command in your terminal.

export JAVA_OPTS='-XX:+IgnoreUnrecognizedVMOptions --add-modules java.se.ee'

Also, don't download the platform tools yourself, let buildozer take care of that.

If the above command doesn't work try deleting the buildozer files from your app and rebuilding your application.

4 Comments

I executed the command indicated above but does not work. I'm downloading the Java 10 Linux x64 JDK (.tar.gz) how indicated me @steve in the first answer and i wait thats work... I will actualizate the question, showing more information in a printscreen
Error occurred during initialization of boot layer java.lang.module.FindException: Module java.se.ee not found
I made the mistake of executing your answer and now when I execute: (flutter doctor --android-licenses),.. I have this error: Error occurred during initialization of boot layer java.lang.module.FindException: Module java.se.ee not found. How can I revert this?
If somebody ends up here, just unset JAVA_OPTS to revert the exported variable

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.