odules:ty:compileJavaWARNING

modules:ty:compileJava WARNING: An illegal reflective access operation has occurred WARNING: Illegal reflective access by worker.org.gradle.internal.reflect.JavaMethod (file:/Users/---/.gradle/caches/3.0/workerMain/gradle-worker.jar) to method java.lang.ClassLoader.getPackages() WARNING: Please consider reporting this to the maintainers of worker.org.gradle.internal.reflect.JavaMethod WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations WARNING: All illegal access operations will be denied in a future release

Failed to execute goal org.codehaus.mojo:exec-maven-plugin


Error  :

Failed to execute goal org.codehaus.mojo:exec-maven-plugin:1.2.1:exec (unpack-dependencies) on project carMaven: Command execution failed. Cannot run program "/Library/Java/JavaVirtualMachines/jdk-9.jdk/Contents/Home/../bin/javafxpackager" (in directory "----"): error=2, No such file or directory -> [Help 1]

To see the full stack trace of the errors, re-run Maven with the -e switch.
Re-run Maven using the -X switch to enable full debug logging.

For more information about the errors and possible solutions, please read the following articles:
[Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

solution :

remove this part :

           <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>exec-maven-plugin</artifactId>
                <version>1.2.1</version>
                <executions>
                    <execution>
                        <id>unpack-dependencies</id>
                        
                        <phase>package</phase>
                        <goals>
                            <goal>exec</goal>
                        </goals>
                        <configuration>
                            <executable>${java.home}/../bin/javafxpackager</executable>
                            <arguments>
                                <argument>-createjar</argument>
                                <argument>-nocss2bin</argument>
                                <argument>-appclass</argument>
                                <argument>${mainClass}</argument>
                                <argument>-srcdir</argument>
                                <argument>${project.build.directory}/classes</argument>
                                <argument>-outdir</argument>
                                <argument>${project.build.directory}</argument>
                                <argument>-outfile</argument>
                                <argument>${project.build.finalName}.jar</argument>
                            </arguments>
                        </configuration>
                    </execution>
                    <execution>
                        <id>default-cli</id>
                        <goals>
                            <goal>exec</goal>                            
                        </goals>
                        <configuration>
                            <executable>${java.home}/bin/java</executable>
                            <commandlineArgs>${runfx.args}</commandlineArgs>
                        </configuration>
                    </execution>
                </executions>  
            </plugin>-->

or make sure you don't declare exec-maven-plugin twice.

Commentaires

Posts les plus consultés de ce blog

java.io.IOException: Cannot run program "C:\wamp\bin\mysql\mysql5.6.17\bin": CreateProcess error=5, Access is denied