Open haxpor opened 7 years ago
This Gradle plugin is unofficial, TeaVM does not provide Gradle support yet. I'm an author of TeaVM, but I'm not an author of this plugin, so I can't help you. You can ask me personally (info@teavm.org), or publish your question on forum.
Let my try to help with your problem. First, have you tried teavm-libgdx? It's outdated and no more maintained, but you can try to build it and learn it. It's in Maven, but it should not be a problem. I guess it's not that hard to invoke Maven from Gradle, right?
Execution failed for task ':teavmc'. > Can't provide name for method as it was not found: io.wasin.asteroids.desktop.DesktopLauncher.main([Ljava/lang/String;)V
Obviously, this means that there's no such class in your project ;-)
This plugin was incorrectly setting the classpath, that's why it was not finding the main class (it can't see it).
I fixed that in this PR: https://github.com/edibleday/teavm-gradle-plugin/pull/5
Hope that the maintainer @n3o59hf will respond (if you don't want to work on this project anymore, let me know and I can take over - I have quite some experience maintaining Gradle plugins, so I can do it for you).
@renatoathaydes I think you can publish it under your own maven group ID?
@renatoathaydes I suggest to redirect everyone to your fork, and make it the maintained version.
Thus I would approve @sriharshachilakapati's suggestion to publish it under your own maven group id.
@renatoathaydes do you mind enabling people to open issues on your fork?
@vic-cw done. I will try to find time to do this.
@renatoathaydes Awesome!!
Hi, could you guide me on how to use this with libgdx-based project?
As libgdx project might have several sub-module targeting different platform:
desktop
,android
,ios-moe
, etc. Should I put thosebuild.gradle
setting underdesktop
one?The following is what I've tried.
build.gradle
setting at the top level.Configured with
mainClassName = "io.wasin.asteroids.desktop.DesktopLauncher"
. I got the following error after executing./gradlew teavmc
desktop
.With same
mainClassName
. I got the following error after executing./gradlew desktop:teavmc
.Any suggestion on how to solve this?