Giter Site home page Giter Site logo

Comments (6)

JojoIce avatar JojoIce commented on May 20, 2024

Two related links:
https://mail.openjdk.org/pipermail/jigsaw-dev/2018-December/014077.html
https://stackoverflow.com/a/53824670

from gdx-liftoff.

tommyettinger avatar tommyettinger commented on May 20, 2024

I would suggest asking about this in the RoboVM/MobiVM Gitter (you typically just log in with GitHub credentials, so it's pretty easy if you haven't used Gitter already). If they don't already know about this, they probably should... They may have a way around this issue already.

from gdx-liftoff.

JojoIce avatar JojoIce commented on May 20, 2024

I am afraid that it really is a question of how to set up the project and not really related to RoboVM itself. Sure, it is a bit unusual that a different dependency other than JVM RT should be used and that is specific for iOS but, really I think that it only is a matter of not depending on the JVM RT and instead only depend on the robovm-rt for the standard rt libs.

How to do that, I don't know. Maybe the iOS project cannot be a java project or something, so that the JVM RT is not pulled in. Then everything seems to work, or possibly use the module voodoo to select only the things needed so that not multiple implementations of the same class is pulled in. I did not get gdx-setup to work on macos after having been spoiled by liftoff, but it would be interesting to see how that handles the same thing... Still it could be good to ask if someone is using liftoff and java >8 and Eclipse over there to see how it is solved maybe.

from gdx-liftoff.

tommyettinger avatar tommyettinger commented on May 20, 2024

I think RoboVM only supports Java language level 8 anyway, unless you use one of the early releases with the updated libcore (and those are now quite old). I'm not sure if any part of it is aware of modules. I think using Java 8, or at least language level 8, is going to be required even if this were fixed.

from gdx-liftoff.

JojoIce avatar JojoIce commented on May 20, 2024

Ah, OK I recalled some mentioning of robovm java 8+ and desugar stuff some time ago, and thought I was just behind times when liftoff defaulted to java 12. That is probably good for everything but iOS then? Android handles (most?) Java 12 or is it only 8 plus maybe a small subset of 8+ things? I guess what really is needed is a "Compiler compliance level" in the IDEs and only a lib that is the smallest common denominator of the JVM, Android, and robovm, but that will probably never happen. So maybe the solution is to default to Java 8 if iOS is selected or if that is tricky, just add a comment in the troubleshooting. However, it seems logical that there should only be one implementation of each class so the complaint from Eclipse is still valid I think, but can maybe be ignored as long as things anyway works... Especially if it is tricky to remove the JVM from the iOS project.

from gdx-liftoff.

tommyettinger avatar tommyettinger commented on May 20, 2024

Liftoff defaults to 11 currently, because all platforms except iOS support it (and because TeaVM, which more and more people are using Liftoff to try, absolutely requires 11). I think I can force the language level down to 8 for projects that include iOS, which really means that most developers just shouldn't select iOS, even as a "just in case I get a Mac" situation (and no one can check both iOS and TeaVM). Android has supported at least some Java 11 features for a while on many (not sure if most) devices, and more devices support Java 11 by the day. Unfortunately, the branch/fork of MobiVM that supports a more recent Android core has stagnated for years.

Neither Java 8 nor 11 are supported by Oracle unless you have an "extended support" plan ( https://www.oracle.com/java/technologies/java-se-support-roadmap.html ), though that extended support goes through at least 2030, and it only applies to Java obtained from Oracle (which seems like a really bad idea given Oracle's track record, and you should use some form of OpenJDK with a clear license). Everyone seems to be updating to at least Java 11, except MobiVM; GWT can use Java 11, TeaVM requires it, Android can use it, all desktop varieties can use it. It's frustrating, but while MobiVM cannot understand the concept of JPMS, you really can't use any JPMS concepts in conjunction with the iOS backend. That seems to include forcing language level 8.

from gdx-liftoff.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.