0

I would like to evaluate Gluon to port an Eclipse JavaFX project to Android, so I tried to follow the Getting Started instructions from the Gluon web site.
But as was already mentioned in a quite old post (2016-12-14), the Getting Started instructions specify as a prerequisite the "Android Support Library”, which has been obsolete since even longer.

Hoping that this Support Library was no longer required with the current Gluon plugin and Android SDK, I tried to install the sample program on my phone, but got an error complaining that my SDK was missing the Android Support Repository. The error message suggest to install it manually from the command line using the program Sdk/tools/bin/sdkmanager, which is not present in the current Android SDK.

What should I make of all this? That Gluon has been abandoned and I should look for some other tool to port my JavaFX to Android? Or did I just miss the link/article that properly explains how to use Gluon in the year 2020?

If not Gluon, which tool would you suggest? Thank you all in advance!

Andrea
  • 1
  • There is a more updated guide [here](https://docs.gluonhq.com/getting-started/), however still for Java 1.8. You can find the latest plugin for iOS and Android with Java 11+/JavaFX 11+ [here](https://docs.gluonhq.com/client) and [samples](https://github.com/gluonhq/client-samples) (Note that this plugin is still under heavy development). – José Pereda Mar 04 '20 at 09:07
  • @JoséPereda Thank you very much! Java 8 is just fine with me, but… I am stuck again ☹. When I run the command `.\sdkmanager "platforms;android-27" "build-tools;27.0.3" "platform-tools"` I get the error message _Error: Could not find or load main class com.android.sdklib.tool.sdkmanager.SdkManagerCli_ – Andrea Mar 04 '20 at 22:29
  • @JoséPereda The missing class _com.android.sdklib.tool.sdkmanager.SdkManagerCli_ is present in the file `tools\lib\sdklib\sdklib.jar`, but the classpath used in the java command of `sdkmanager.bat` is just `%APP_HOME%\lib\/sdkmanager-classpath.jar` and `sdkmanager-classpath.jar` is not in %APP_HOME%\lib but in %APP_HOME%\lib\_ . How could that work? Could it be that `sdkmanager.bat` uses a mechanism supported only by newer versions of Java? – Andrea Mar 04 '20 at 22:32
  • What is your Java version? SDKManager doesn't work with Java 11+. Make sure you have JDK 1.8 in your PATH. – José Pereda Mar 04 '20 at 22:57
  • @JoséPereda the only Java I have installed is jdk1.8.0_241. My Path only includes `C:\Program Files (x86)\Common Files\Oracle\Java\javapath`, but `java -version` 1.8.0_241. Just to be safe i added `C:\Program Files\Java\jdk1.8.0_241` to the PATH, but it did not make any difference. – Andrea Mar 04 '20 at 23:18
  • @JoséPereda I was worried that I had messed up my system with my previous attempts to execute the Gluon's Getting Started instructions, so I repeated the steps of this new tutorial in a clean VM, but I did obtain exactly the same results. – Andrea Mar 04 '20 at 23:36
  • @JoséPereda you seem to be heavily involved with the Gluon projects, so you may be interested in the [answer](https://stackoverflow.com/a/60600600/12169802) that worked for me. I also wanted to thank you for your attempts to help me out. – Andrea Mar 13 '20 at 03:32
  • I finally found the quite recent [answer](https://stackoverflow.com/a/60600600/12169802) that worked for me! I tried to upvote and to comment on that answer, but I do not have enough reputations to do either. Hopefully, this may help others to find it. – Andrea Mar 13 '20 at 00:43

0 Answers0