From f9609f93b2ad905df1b32e9718d4459a15888a1f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Yoann=20Rodi=C3=A8re?= Date: Mon, 15 Oct 2018 11:10:39 +0200 Subject: [PATCH] HHH-12946 Add explicit dependencies to JAXB APIs where relevant --- gradle/java-module.gradle | 9 ++++++--- gradle/libraries.gradle | 4 +++- hibernate-core/hibernate-core.gradle | 2 +- tooling/metamodel-generator/hibernate-jpamodelgen.gradle | 2 +- 4 files changed, 11 insertions(+), 6 deletions(-) diff --git a/gradle/java-module.gradle b/gradle/java-module.gradle index 8eefbfd494..5a4de5532b 100644 --- a/gradle/java-module.gradle +++ b/gradle/java-module.gradle @@ -114,19 +114,22 @@ dependencies { if ( JavaVersion.current().isJava9Compatible() ) { // The JDK used to run Gradle is Java 9+, and we assume that that is the same // JDK for executing tasks - compile( libraries.jaxb ) + compile( libraries.jaxb_api ) + compile( libraries.jaxb_runtime ) compile( libraries.jaxb_xjc ) compile( libraries.jaxb2_basics ) compile( libraries.jaxb2_basics_ant ) compile( libraries.jsr250_api ) - testCompile( libraries.jaxb ) + testCompile( libraries.jaxb_api ) + testCompile( libraries.jaxb_runtime ) testCompile( libraries.jaxb_xjc ) testCompile( libraries.jaxb2_basics ) testCompile( libraries.jaxb2_basics_ant ) testCompile( libraries.jsr250_api ) - testRuntime( libraries.jaxb ) + testRuntime( libraries.jaxb_api ) + testRuntime( libraries.jaxb_runtime ) testRuntime( libraries.jaxb_xjc ) testRuntime( libraries.jaxb2_basics ) testRuntime( libraries.jaxb2_basics_ant ) diff --git a/gradle/libraries.gradle b/gradle/libraries.gradle index 83feb7ae07..e7ccc1e5b9 100644 --- a/gradle/libraries.gradle +++ b/gradle/libraries.gradle @@ -76,7 +76,9 @@ ext { logging_processor: 'org.jboss.logging:jboss-logging-processor:2.1.0.Final', // jaxb task - jaxb: 'org.glassfish.jaxb:jaxb-runtime:2.2.11', + // Strangely, jaxb-runtime 2.2.11 depends on jaxb-api 2.2.12-b140109.1041 + jaxb_api: 'javax.xml.bind:jaxb-api:2.2.12-b140109.1041', + jaxb_runtime: 'org.glassfish.jaxb:jaxb-runtime:2.2.11', jaxb_xjc: 'org.glassfish.jaxb:jaxb-xjc:2.2.11', // Note that jaxb2_basics is a set of tools on *top* of JAXB. // See https://github.com/highsource/jaxb2-basics diff --git a/hibernate-core/hibernate-core.gradle b/hibernate-core/hibernate-core.gradle index 000015a2f4..ae31a5d673 100644 --- a/hibernate-core/hibernate-core.gradle +++ b/hibernate-core/hibernate-core.gradle @@ -27,7 +27,7 @@ dependencies { // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // Java 9 ftw! if ( JavaVersion.current().isJava9Compatible() ) { - xjc( libraries.jaxb ) + xjc( libraries.jaxb_runtime ) xjc( libraries.jaxb_xjc ) xjc( libraries.jaxb2_basics ) xjc( libraries.jaxb2_basics_ant ) diff --git a/tooling/metamodel-generator/hibernate-jpamodelgen.gradle b/tooling/metamodel-generator/hibernate-jpamodelgen.gradle index 91f86b9595..ee68543071 100644 --- a/tooling/metamodel-generator/hibernate-jpamodelgen.gradle +++ b/tooling/metamodel-generator/hibernate-jpamodelgen.gradle @@ -24,7 +24,7 @@ dependencies { // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // Java 9 ftw! if ( JavaVersion.current().isJava9Compatible() ) { - xjc( libraries.jaxb ) + xjc( libraries.jaxb_runtime ) xjc( libraries.jaxb_xjc ) xjc( libraries.jaxb2_basics ) xjc( libraries.jaxb2_basics_ant )