Maven Compiler Help

Discussion in 'Plugin Development' started by DeteoReborn, Nov 5, 2014.

Thread Status:
Not open for further replies.
  1. Offline

    DeteoReborn

    Hey guys, So I'm fairly new to Plugin Dev and I'm in need of some help. I've been trying to create a plugin similar to factions for my prison server except its like gangs and stuff. Now I'm trying to test what I have so far to make sure everything is working properly before I continue but everytime I try to 'Maven Install' I get Warnings and such that say:


    Code:java
    1. [INFO] Scanning for projects...
    2. [WARNING]
    3. [WARNING] Some problems were encountered while building the effective model for my.first.plugin:FirstPlugin:jar:0.0.1-SNAPSHOT
    4. [WARNING] 'build.plugins.plugin.version' for org.apache.maven.plugins:maven-compiler-plugin is missing. @ line 8, column 19
    5. [WARNING]
    6. [WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
    7. [WARNING]
    8. [WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
    9. [WARNING]
    10. [INFO]
    11. [INFO] Using the builder org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder with a thread count of 1
    12. [INFO]
    13. [INFO] ------------------------------------------------------------------------
    14. [INFO] Building FirstPlugin 0.0.1-SNAPSHOT
    15. [INFO] ------------------------------------------------------------------------
    16. [INFO]
    17. [INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ FirstPlugin ---
    18. [WARNING] Using platform encoding (Cp1252 actually) to copy filtered resources, i.e. build is platform dependent!
    19. [INFO] Copying 2 resources
    20. [INFO]
    21. [INFO] --- maven-compiler-plugin:2.5.1:compile (default-compile) @ FirstPlugin ---
    22. [WARNING] File encoding has not been set, using platform encoding Cp1252, i.e. build is platform dependent!
    23. [INFO] Compiling 1 source file to C:\Users\Blake\Desktop\Plugins\FirstPlugin\target\classes
    24. [INFO] ------------------------------------------------------------------------
    25. [INFO] BUILD FAILURE
    26. [INFO] ------------------------------------------------------------------------
    27. [INFO] Total time: 1.623 s
    28. [INFO] Finished at: 2014-11-06T00:34:55-05:00
    29. [INFO] Final Memory: 7M/145M
    30. [INFO] ------------------------------------------------------------------------
    31. [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.5.1:compile (default-compile) on project FirstPlugin: Fatal error compiling: tools.jar not found: C:\Program Files\Java\jre1.8.0_25\..\lib\tools.jar -> [Help 1]
    32. [ERROR]
    33. [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
    34. [ERROR] Re-run Maven using the -X switch to enable full debug logging.
    35. [ERROR]
    36. [ERROR] For more information about the errors and possible solutions, please read the following articles:
    37. [ERROR] [Help 1] [url]http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException[/url]
    38.  


    Any help on what I might be doing wrong would be great q-q
    I've been using this page as reference since I started learning along with lots of googling, Can't seem to find anything on this though.
     
  2. Offline

    Syd

    DeteoReborn
    1. define a version of the maven-compiler-plugin
    2. set a file encoding
    Code:text
    1. <properties>
    2. <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    3. </properties>

    3. it looks like you installed only an JRE and not an JDK -> install a JDK
     
  3. Offline

    DeteoReborn


    Alright thank you for the reply, I will try this out and check if I have a Jdk installed. Thought I already did.
     
Thread Status:
Not open for further replies.

Share This Page