Error due to Maven, unable to build and install strongbox from code
I am looking to do some OSS work in order to get hands-on in Software Engineering. I want to contribute to the strongbox.
Problem faced:
I am not able to build strongbox with the build steps given here:
git clone https://github.com/strongbox/strongbox
cd strongbox
mvn clean install
Output:
After running the command mvn clean install
the output that I receive is:
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by com.google.inject.internal.cglib.core.$ReflectUtils$1 (file:/usr/share/maven/lib/guice.jar) to method java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int,java.security.ProtectionDomain)
WARNING: Please consider reporting this to the maintainers of com.google.inject.internal.cglib.core.$ReflectUtils$1
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
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Build Order:
[INFO]
[INFO] Strongbox: Resources [Common] [jar]
[INFO] Strongbox: Resources [Storage API] [jar]
[INFO] Strongbox: Resources [pom]
[INFO] Strongbox: Commons [jar]
[INFO] Strongbox: Configuration [jar]
[INFO] Strongbox: Data Service [jar]
[INFO] Strongbox: Client [jar]
[INFO] Strongbox: Metadata [Maven API] [jar]
[INFO] Strongbox: Testing [Core] [jar]
[INFO] Strongbox: Security API [jar]
[INFO] Strongbox: Storage [Core] [jar]
[INFO] Strongbox: Event API [jar]
[INFO] Strongbox: Authentication API [jar]
[INFO] Strongbox: User Management [jar]
[INFO] Strongbox: Authentication Provider [Default] [jar]
[INFO] Strongbox: Authentication Support [jar]
[INFO] Strongbox: Authentication Provider [LDAP] [jar]
[INFO] Strongbox: Authentication Providers [pom]
[INFO] Strongbox: Authentication Registry [jar]
[INFO] Strongbox: Security [pom]
[INFO] Strongbox: Storage [API] [jar]
[INFO] Strongbox: Cron [API] [jar]
[INFO] Strongbox: Cron [Tasks] [jar]
[INFO] Strongbox: Storage [Maven Layout Provider] [jar]
[INFO] Strongbox: Storage [Nuget Layout Provider] [jar]
[INFO] Strongbox: Storage [NPM Layout Provider] [jar]
[INFO] Strongbox: Storage [PyPi Layout Provider] [jar]
[INFO] Strongbox: Storage [Raw Layout Provider] [jar]
[INFO] Strongbox: Storage Layout Providers [pom]
[INFO] strongbox-storage-rpm-layout-provider [jar]
[INFO] Strongbox: Web Forms [jar]
[INFO] Strongbox: REST Client [jar]
[INFO] Strongbox: Testing [Web] [jar]
[INFO] Strongbox: Testing [pom]
[INFO] Strongbox: Cron [pom]
[INFO] Strongbox: Storage [P2 Layout Provider] [jar]
[INFO] Strongbox: Storage Maven Layout [pom]
[INFO] Strongbox: Storage [pom]
[INFO] Strongbox: AQL [jar]
[INFO] Strongbox: Web Core [jar]
[INFO] Strongbox: Distribution [pom]
[INFO] Strongbox: Masterbuild [pom]
[INFO]
[INFO] --------< org.carlspring.strongbox:strongbox-common-resources >---------
[INFO] Building Strongbox: Resources [Common] 1.0-SNAPSHOT [1/42]
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-clean-plugin:3.1.0:clean (default-clean) @ strongbox-common-resources ---
[INFO]
[INFO] --- maven-enforcer-plugin:3.0.0-M3:enforce (enforce-jdk-and-maven-versions) @ strongbox-common-resources ---
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary for Strongbox: Masterbuild 1.0-SNAPSHOT:
[INFO]
[INFO] Strongbox: Resources [Common] ...................... FAILURE [ 0.865 s]
[INFO] Strongbox: Resources [Storage API] ................. SKIPPED
[INFO] Strongbox: Resources ............................... SKIPPED
[INFO] Strongbox: Commons ................................. SKIPPED
[INFO] Strongbox: Configuration ........................... SKIPPED
[INFO] Strongbox: Data Service ............................ SKIPPED
[INFO] Strongbox: Client .................................. SKIPPED
[INFO] Strongbox: Metadata [Maven API] .................... SKIPPED
[INFO] Strongbox: Testing [Core] .......................... SKIPPED
[INFO] Strongbox: Security API ............................ SKIPPED
[INFO] Strongbox: Storage [Core] .......................... SKIPPED
[INFO] Strongbox: Event API ............................... SKIPPED
[INFO] Strongbox: Authentication API ...................... SKIPPED
[INFO] Strongbox: User Management ......................... SKIPPED
[INFO] Strongbox: Authentication Provider [Default] ....... SKIPPED
[INFO] Strongbox: Authentication Support .................. SKIPPED
[INFO] Strongbox: Authentication Provider [LDAP] .......... SKIPPED
[INFO] Strongbox: Authentication Providers ................ SKIPPED
[INFO] Strongbox: Authentication Registry ................. SKIPPED
[INFO] Strongbox: Security ................................ SKIPPED
[INFO] Strongbox: Storage [API] ........................... SKIPPED
[INFO] Strongbox: Cron [API] .............................. SKIPPED
[INFO] Strongbox: Cron [Tasks] ............................ SKIPPED
[INFO] Strongbox: Storage [Maven Layout Provider] ......... SKIPPED
[INFO] Strongbox: Storage [Nuget Layout Provider] ......... SKIPPED
[INFO] Strongbox: Storage [NPM Layout Provider] ........... SKIPPED
[INFO] Strongbox: Storage [PyPi Layout Provider] .......... SKIPPED
[INFO] Strongbox: Storage [Raw Layout Provider] ........... SKIPPED
[INFO] Strongbox: Storage Layout Providers ................ SKIPPED
[INFO] strongbox-storage-rpm-layout-provider .............. SKIPPED
[INFO] Strongbox: Web Forms ............................... SKIPPED
[INFO] Strongbox: REST Client ............................. SKIPPED
[INFO] Strongbox: Testing [Web] ........................... SKIPPED
[INFO] Strongbox: Testing ................................. SKIPPED
[INFO] Strongbox: Cron .................................... SKIPPED
[INFO] Strongbox: Storage [P2 Layout Provider] ............ SKIPPED
[INFO] Strongbox: Storage Maven Layout .................... SKIPPED
[INFO] Strongbox: Storage ................................. SKIPPED
[INFO] Strongbox: AQL ..................................... SKIPPED
[INFO] Strongbox: Web Core ................................ SKIPPED
[INFO] Strongbox: Distribution ............................ SKIPPED
[INFO] Strongbox: Masterbuild ............................. SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.941 s
[INFO] Finished at: 2021-09-28T22:50:20+05:30
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-enforcer-plugin:3.0.0-M3:enforce (enforce-jdk-and-maven-versions) on project strongbox-common-resources: org.apache.maven.plugins.enforcer.RequireJavaVersion failed with message:
[ERROR]
[ERROR] Ubuntu 11.0.11+9-Ubuntu-0ubuntu2.20.04 is not a supported JDK version!
[ERROR] See https://strongbox.github.io/developer-guide/getting-started.html
[ERROR]
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
From what I could deduce from the info in the Error message here, it is that there is an issue with the supported JDK version, as in the following line-
[ERROR] Ubuntu 11.0.11+9-Ubuntu-0ubuntu2.20.04 is not a supported JDK version!
Questions:
- What should I do to rectify this?
- Also, is this the best (time-efficient) way to build java software?
- And if I were to use IntelliJ IDEA, is it better to use it?
- The error message also suggests that the issue can be due to the maven plugin itself. Not sure though, I would appreciate it if someone points in the correct direction.
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-enforcer-plugin:3.0.0-M3:enforce (enforce-jdk-and-maven-versions) on project strongbox-common-resources: org.apache.maven.plugins.enforcer.RequireJavaVersion failed with message:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
- Also, how to get rid of warnings at the starting of the output.
My system configs are:
- OS: Ubuntu 20.04
- Java version: 11.0.11 (installed from steps described here)
- Maven version: 3.6.3 (installed from steps described here)
Other Info:
- I have
settings.xml
file in~/.m2/
Thanks in advance
from Recent Questions - Stack Overflow https://ift.tt/3CVLjFa
https://ift.tt/eA8V8J
Comments
Post a Comment