JDKMissionControl / jmc

This mirror is deprecated - please start using https://github.com/openjdk/jmc
197 stars 46 forks source link

Unable to build releng/third-party #13

Closed arbitrary-dev closed 5 years ago

arbitrary-dev commented 5 years ago

Java used

$ java -version; $JAVA_HOME/bin/java -version
java version "1.8.0_131"
Java(TM) SE Runtime Environment (build 1.8.0_131-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.131-b11, mixed mode)
java version "1.8.0_131"
Java(TM) SE Runtime Environment (build 1.8.0_131-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.131-b11, mixed mode)

Error received

Failure to find javax.mail:dsn:jar:1.4 in http://repo.maven.apache.org/maven2

$ mvn clean p2:site
...
[info] Resolving artifact=[javax.mail:dsn:1.4] transitive=[true] source=[false]
[WARNING] The POM for javax.mail:dsn:jar:1.4 is missing, no dependency information available
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.245 s
[INFO] Finished at: 2019-09-02T11:52:13+03:00
[INFO] Final Memory: 26M/321M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.reficio:p2-maven-plugin:1.3.0:site (default-cli) on project external-dependencies: Execution default-cli of goal org.reficio:p2-maven-plugin:1.3.0:site failed: java.lang.RuntimeException: org.eclipse.aether.resolution.DependencyResolutionException: Failure to find javax.mail:dsn:jar:1.4 in http://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of external has elapsed or updates are forced -> [Help 1]
klaraward commented 5 years ago

I had similar problems because of settings in my ~/.m2/settings.xml, running mvn clean p2:site --settings <path to empty settings.xml> works for me.

RoySunnySean007 commented 4 years ago

Regarding to "https://stackoverflow.com/questions/53687816/dependency-javax-mailmail1-4-not-found", "javax.mail:dsn:jar:1.4" is not in maven public repo due to license restrictions. Workaround, download "javax.mail:dsn:jar:1.4" from https://www.oracle.com/technetwork/java/javamail/index-138643.html and then install it to ur local repo via:

mvn install:install-file -Dfile= -DgroupId=javax.mail -DartifactId=dsn -Dpackaging=jar -Dversion=1.4