]> source.dussan.org Git - poi.git/commitdiff
Specify more granular Batik dependencies
authorMarius Volkhart <mariusvolkhart@apache.org>
Sun, 14 Mar 2021 18:51:12 +0000 (18:51 +0000)
committerMarius Volkhart <mariusvolkhart@apache.org>
Sun, 14 Mar 2021 18:51:12 +0000 (18:51 +0000)
Batik-all is a strange artifact. It's POM declares dependencies on all the sub-JARs, but its JAR has all of the sub-jars repackaged. This results in multiple JARs with the same packages being added to consuming applications. This leads to problems for JPMS users. See [bug-65183].

The Ant build does not use batik-all, so the Maven and Gradle builds should not either.

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1887642 13f79535-47bb-0310-9956-ffa450edef68

build.gradle
maven/poi-ooxml.pom
sonar/ooxml/pom.xml

index cd7d8a4b3a2bf407897d81d6d8b11cbcb9f8f7eb..6b7b5cb2e0e6653b702699b2adfa1136df148e6a 100644 (file)
@@ -103,6 +103,7 @@ subprojects {
         mockitoVersion = '3.6.0'
         hamcrestVersion = '2.2'
         xmlbeansVersion = '5.0.0'
+        batikVersion = '1.14'
     }
 
     tasks.withType(JavaCompile) {
@@ -309,7 +310,9 @@ project('ooxml') {
         compile "org.apache.logging.log4j:log4j-api:${log4jVersion}"
 
         // compile only, don't add it to our dist as it blows up the size
-        compile 'org.apache.xmlgraphics:batik-all:1.14'
+        compile "org.apache.xmlgraphics:batik-svggen:${batikVersion}"
+        compile "org.apache.xmlgraphics:batik-bridge:${batikVersion}"
+        compile "org.apache.xmlgraphics:batik-codec:${batikVersion}"
         compile 'xml-apis:xml-apis-ext:1.3.04'
         compile 'org.apache.xmlgraphics:xmlgraphics-commons:2.4'
 
index 4f8f7ff40ba5c8db0bb90fd9bfb5b8b3ee72ff23..c445b1e373361507af3491eec3ab646f032982ec 100644 (file)
         </dependency>
         <dependency>
             <groupId>org.apache.xmlgraphics</groupId>
-            <artifactId>batik-all</artifactId>
+            <artifactId>batik-svggen</artifactId>
+            <version>1.14</version>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.xmlgraphics</groupId>
+            <artifactId>batik-bridge</artifactId>
+            <version>1.14</version>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.xmlgraphics</groupId>
+            <artifactId>batik-codec</artifactId>
             <version>1.14</version>
-            <exclusions>
-                <exclusion>
-                    <groupId>commons-logging</groupId>
-                    <artifactId>commons-logging</artifactId>
-                </exclusion>
-            </exclusions>
         </dependency>
         <dependency>
             <groupId>de.rototor.pdfbox</groupId>
index 454f46b8b4d3383b91a5676321e10ed680879fc3..6248a47d7a110ab8f266a1346dfcf49d2bb27493 100644 (file)
         </dependency>
         <dependency>
             <groupId>org.apache.xmlgraphics</groupId>
-            <artifactId>batik-all</artifactId>
+            <artifactId>batik-svggen</artifactId>
+            <version>1.14</version>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.xmlgraphics</groupId>
+            <artifactId>batik-bridge</artifactId>
+            <version>1.14</version>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.xmlgraphics</groupId>
+            <artifactId>batik-codec</artifactId>
             <version>1.14</version>
         </dependency>
         <dependency>