Closed aminabs closed 8 years ago
If you want to use maven the correct plugin is: <plugin> <groupId>com.messapix.ftatr.jfxmobile</groupId> <artifactId>jfxmobile-maven-plugin</artifactId> <version>1.0.0-b2</version> ... </plugin>
Remove <execution> element from the plugin configuration.
If you want to build for android simply type: mvn clean package android
Thanks for your reply, If you look at my previous comment, I did mention the details about both the plugin I've used and the error message I've got. Please take a second look at the latest part of my previous comment (after the exception messages). The way of reporting the issue is probably confusing; sorry for that.
I used the above plugin as you stated, the same version, with&without putting the
<plugin>
<groupId>com.messapix.ftatr.jfxmobile</groupId>
<artifactId>jfxmobile-maven-plugin</artifactId>
<version>1.0.0-b2</version>
<extensions>true</extensions>
<configuration>
<mainClass>com.rayanova.test.Main</mainClass>
<android>
<manifest>src/android/AndroidManifest.xml</manifest>
</android>
<desktop>
</desktop>
</configuration>
</plugin>
I would say the exception raises because of a required dependency which I've forgotten to put inside the pom or something like this. It seems the plugin requires an implementation for org.apache.maven.execution.MavenSession to be injected somewhere inside the plugin.
Can you give me a sample maven project which demonstrates the usage of the plugin? I need to know if there are some dependencies/settings which I should add/set to the pom/project.
You can use the archetype: com.messapix.ftatr.jfxmobile:jfxmobile-archetype:1.0.0-b1
this archetype creates a new jfxmobile project that uses 1.0.0-b1 version of the plugin. Change plugin version to 1.0.0-b2 and run mvn clean package android
Which version of maven are you using?
Hi, I gave the archetype a try exactly as you guided, and unfortunately the same exception occurs.
i.e., mvn clean package android results in:
[INFO] --- jfxmobile-maven-plugin:1.0.0-b2:android-configure (default-android-configure) @ mavenarchetypeJfxmobile ---
[WARNING] Error injecting: com.messapix.ftatr.jfxmobile.maven.plugin.android.lifecycle.ConfigureMojo
com.google.inject.ProvisionException: Guice provision errors:
1) No implementation for org.apache.maven.execution.MavenSession was bound.
at ClassRealm[plugin>com.messapix.ftatr.jfxmobile:jfxmobile-maven-plugin:1.0.0-b2, parent: sun.misc.Launcher$AppClassLoader@70dea4e]
while locating com.messapix.ftatr.jfxmobile.maven.plugin.MobileExpressionEvaluator
at ClassRealm[plugin>com.messapix.ftatr.jfxmobile:jfxmobile-maven-plugin:1.0.0-b2, parent: sun.misc.Launcher$AppClassLoader@70dea4e]
while locating com.messapix.ftatr.jfxmobile.maven.plugin.MobileConf
while locating com.messapix.ftatr.jfxmobile.maven.plugin.android.lifecycle.ConfigureMojo
...
To answer you second question: I am using maven version 3.1.1 (netbeans 8.0.2); the maven-compiler-plugin was however, pretty old: 2.3.1. Hence, I did update the maven-compiler-plugin as follows, but the problem still remains the same as above:
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.3</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
Problem solved! It seems something is wrong with the plugin while running on top of maven version 3.1.1. I simply downloaded and installed the latest maven release (version 3.3.9) and now it's working like a charm.
Thanks.
Hi there, I'm trying to compile a simple fx application for android. Up to now, I've found two different plugins and want to know what the difference is. The first one is the jfxmobile-maven-plugin (from this website) and the second one is jfxmobile-plugin as follows:
Another question I have is about the usage of the two plugins. I've followed the example for the jfxmobile-maven-plugin and created a pom exactly as mentioned there. However, I've faced the following error while executing 'mvn package':
and here is the pom's: