#59268 - adapt xml schema changes to maven build and add apache staging repository temporarily
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1834257 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
2d046ec2ae
commit
f509d1deae
595
sonar/pom.xml
595
sonar/pom.xml
@ -1,301 +1,338 @@
|
|||||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
<modelVersion>4.0.0</modelVersion>
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
||||||
<groupId>org.apache.poi</groupId>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
<artifactId>poi-parent</artifactId>
|
<groupId>org.apache.poi</groupId>
|
||||||
<packaging>pom</packaging>
|
<artifactId>poi-parent</artifactId>
|
||||||
<version>4.0.0-SNAPSHOT</version>
|
<packaging>pom</packaging>
|
||||||
<name>Apache POI - the Java API for Microsoft Documents</name>
|
<version>4.0.0-SNAPSHOT</version>
|
||||||
<description>Maven build of Apache POI for Sonar checks</description>
|
<name>Apache POI - the Java API for Microsoft Documents</name>
|
||||||
<url>http://poi.apache.org/</url>
|
<description>Maven build of Apache POI for Sonar checks</description>
|
||||||
|
<url>http://poi.apache.org/</url>
|
||||||
|
|
||||||
<mailingLists>
|
<mailingLists>
|
||||||
<mailingList>
|
<mailingList>
|
||||||
<name>POI Users List</name>
|
<name>POI Users List</name>
|
||||||
<subscribe>user-subscribe@poi.apache.org</subscribe>
|
<subscribe>user-subscribe@poi.apache.org</subscribe>
|
||||||
<unsubscribe>user-unsubscribe@poi.apache.org</unsubscribe>
|
<unsubscribe>user-unsubscribe@poi.apache.org</unsubscribe>
|
||||||
<archive>http://mail-archives.apache.org/mod_mbox/poi-user/</archive>
|
<archive>http://mail-archives.apache.org/mod_mbox/poi-user/</archive>
|
||||||
</mailingList>
|
</mailingList>
|
||||||
<mailingList>
|
<mailingList>
|
||||||
<name>POI Developer List</name>
|
<name>POI Developer List</name>
|
||||||
<subscribe>dev-subscribe@poi.apache.org</subscribe>
|
<subscribe>dev-subscribe@poi.apache.org</subscribe>
|
||||||
<unsubscribe>dev-unsubscribe@poi.apache.org</unsubscribe>
|
<unsubscribe>dev-unsubscribe@poi.apache.org</unsubscribe>
|
||||||
<archive>http://mail-archives.apache.org/mod_mbox/poi-dev/</archive>
|
<archive>http://mail-archives.apache.org/mod_mbox/poi-dev/</archive>
|
||||||
</mailingList>
|
</mailingList>
|
||||||
</mailingLists>
|
</mailingLists>
|
||||||
|
|
||||||
<licenses>
|
<licenses>
|
||||||
<license>
|
<license>
|
||||||
<name>The Apache Software License, Version 2.0</name>
|
<name>The Apache Software License, Version 2.0</name>
|
||||||
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
|
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
|
||||||
</license>
|
</license>
|
||||||
</licenses>
|
</licenses>
|
||||||
|
|
||||||
<organization>
|
<organization>
|
||||||
<name>Apache Software Foundation</name>
|
<name>Apache Software Foundation</name>
|
||||||
<url>http://www.apache.org/</url>
|
<url>http://www.apache.org/</url>
|
||||||
</organization>
|
</organization>
|
||||||
|
|
||||||
<issueManagement>
|
<issueManagement>
|
||||||
<system>Bugzilla</system>
|
<system>Bugzilla</system>
|
||||||
<url>https://bz.apache.org/bugzilla/</url>
|
<url>https://bz.apache.org/bugzilla/</url>
|
||||||
</issueManagement>
|
</issueManagement>
|
||||||
|
|
||||||
<scm>
|
<scm>
|
||||||
<connection>scm:svn:http://svn.apache.org/repos/asf/poi/trunk</connection>
|
<connection>scm:svn:http://svn.apache.org/repos/asf/poi/trunk</connection>
|
||||||
<developerConnection>scm:svn:https://svn.apache.org/repos/asf/poi/trunk</developerConnection>
|
<developerConnection>scm:svn:https://svn.apache.org/repos/asf/poi/trunk</developerConnection>
|
||||||
<url>http://svn.apache.org/viewvc/poi</url>
|
<url>http://svn.apache.org/viewvc/poi</url>
|
||||||
</scm>
|
</scm>
|
||||||
|
|
||||||
<repositories>
|
<repositories>
|
||||||
<repository>
|
<repository>
|
||||||
<id>xmlbeans-snapshot-repo</id>
|
<id>xmlbeans-snapshot-repo</id>
|
||||||
<name>xmlbeans snapshot repo</name>
|
<name>xmlbeans snapshot repo</name>
|
||||||
<url>https://repository.apache.org/content/repositories/staging</url>
|
<url>https://repository.apache.org/content/repositories/staging</url>
|
||||||
</repository>
|
</repository>
|
||||||
</repositories>
|
</repositories>
|
||||||
|
|
||||||
<modules>
|
<modules>
|
||||||
<module>main</module>
|
<module>main</module>
|
||||||
<module>ooxml-schema</module>
|
<module>ooxml-schema</module>
|
||||||
<module>ooxml-schema-encryption</module>
|
<module>ooxml-schema-encryption</module>
|
||||||
<module>ooxml-schema-security</module>
|
<module>ooxml-schema-security</module>
|
||||||
<module>ooxml</module>
|
<module>ooxml</module>
|
||||||
<module>scratchpad</module>
|
<module>scratchpad</module>
|
||||||
<module>excelant</module>
|
<module>excelant</module>
|
||||||
<module>examples</module>
|
<module>examples</module>
|
||||||
</modules>
|
</modules>
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||||
<!-- Try to disable running SVN blame as it causes errors here because the source is copied from the actual SVN location here! -->
|
<!-- Try to disable running SVN blame as it causes errors here because the source is copied from the actual SVN location here! -->
|
||||||
<sonar.scm.disabled>true</sonar.scm.disabled>
|
<sonar.scm.disabled>true</sonar.scm.disabled>
|
||||||
|
|
||||||
<!-- define some of the third-party or plugin-versions globally to use the same in all modules -->
|
<!-- define some of the third-party or plugin-versions globally to use the same in all modules -->
|
||||||
<xmlbeans.version>3.0.0</xmlbeans.version>
|
<xmlbeans.version>3.0.0</xmlbeans.version>
|
||||||
<junit.version>4.12</junit.version>
|
<junit.version>4.12</junit.version>
|
||||||
<xmlunit.version>2.5.1</xmlunit.version>
|
<xmlunit.version>2.5.1</xmlunit.version>
|
||||||
<mockito.version>2.13.0</mockito.version>
|
<mockito.version>2.13.0</mockito.version>
|
||||||
<maven.plugin.resources.version>3.0.1</maven.plugin.resources.version>
|
<maven.plugin.resources.version>3.0.1</maven.plugin.resources.version>
|
||||||
<maven.plugin.jar.version>3.0.1</maven.plugin.jar.version>
|
<maven.plugin.jar.version>3.0.1</maven.plugin.jar.version>
|
||||||
<maven.plugin.clean.version>3.0.0</maven.plugin.clean.version>
|
<maven.plugin.clean.version>3.0.0</maven.plugin.clean.version>
|
||||||
<maven.plugin.download.version>1.1.0</maven.plugin.download.version>
|
<maven.plugin.download.version>1.1.0</maven.plugin.download.version>
|
||||||
<maven.plugin.antrun.version>1.8</maven.plugin.antrun.version>
|
<maven.plugin.antrun.version>1.8</maven.plugin.antrun.version>
|
||||||
<maven.plugin.surefire.version>2.19.1</maven.plugin.surefire.version>
|
<maven.plugin.surefire.version>2.19.1</maven.plugin.surefire.version>
|
||||||
</properties>
|
</properties>
|
||||||
|
|
||||||
<build>
|
<build>
|
||||||
<pluginManagement>
|
<pluginManagement>
|
||||||
<plugins>
|
<plugins>
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
<artifactId>maven-compiler-plugin</artifactId>
|
<artifactId>maven-compiler-plugin</artifactId>
|
||||||
<version>3.5.1</version>
|
<version>3.5.1</version>
|
||||||
<configuration>
|
<configuration>
|
||||||
<source>1.8</source>
|
<source>1.8</source>
|
||||||
<target>1.8</target>
|
<target>1.8</target>
|
||||||
</configuration>
|
</configuration>
|
||||||
</plugin>
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
</pluginManagement>
|
</pluginManagement>
|
||||||
<plugins>
|
<plugins>
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
<artifactId>maven-surefire-plugin</artifactId>
|
<artifactId>maven-surefire-plugin</artifactId>
|
||||||
<version>${maven.plugin.surefire.version}</version>
|
<version>${maven.plugin.surefire.version}</version>
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.apache.maven.surefire</groupId>
|
<groupId>org.apache.maven.surefire</groupId>
|
||||||
<artifactId>surefire-junit47</artifactId>
|
<artifactId>surefire-junit47</artifactId>
|
||||||
<version>${maven.plugin.surefire.version}</version>
|
<version>${maven.plugin.surefire.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
<configuration>
|
<configuration>
|
||||||
<systemPropertyVariables>
|
<systemPropertyVariables>
|
||||||
<POI.testdata.path>../../test-data</POI.testdata.path>
|
<POI.testdata.path>../../test-data</POI.testdata.path>
|
||||||
<java.awt.headless>true</java.awt.headless>
|
<java.awt.headless>true</java.awt.headless>
|
||||||
<org.apache.poi.util.POILogger>org.apache.poi.util.NullLogger</org.apache.poi.util.POILogger>
|
<org.apache.poi.util.POILogger>org.apache.poi.util.NullLogger</org.apache.poi.util.POILogger>
|
||||||
</systemPropertyVariables>
|
</systemPropertyVariables>
|
||||||
<!-- use to following to analyze OOM issues: -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/tmp -->
|
<!-- use to following to analyze OOM issues: -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/tmp -->
|
||||||
<argLine>@{argLine} -Duser.language=en -Duser.country=US -Xmx1024m -Djava.io.tmpdir=target/tmp</argLine>
|
<argLine>@{argLine} -Duser.language=en -Duser.country=US -Xmx1024m -Djava.io.tmpdir=target/tmp
|
||||||
<excludes>
|
</argLine>
|
||||||
<exclude>**/All*Tests.java</exclude>
|
<excludes>
|
||||||
<exclude>**/TestUnfixedBugs.java</exclude>
|
<exclude>**/All*Tests.java</exclude>
|
||||||
<exclude>**/TestcaseRecordInputStream.java</exclude>
|
<exclude>**/TestUnfixedBugs.java</exclude>
|
||||||
<exclude>**/POITestCase.java</exclude>
|
<exclude>**/TestcaseRecordInputStream.java</exclude>
|
||||||
<!-- TODO: error about no public construct, seems to run with JUnit 3.8... -->
|
<exclude>**/POITestCase.java</exclude>
|
||||||
<exclude>**/TestWordToConverterSuite*.java</exclude>
|
<!-- TODO: error about no public construct, seems to run with JUnit 3.8... -->
|
||||||
<exclude>**/TestExcelConverterSuite*.java</exclude>
|
<exclude>**/TestWordToConverterSuite*.java</exclude>
|
||||||
</excludes>
|
<exclude>**/TestExcelConverterSuite*.java</exclude>
|
||||||
<!--test>TestPPTX2PNG</test-->
|
</excludes>
|
||||||
<!--parallel>both</parallel>
|
<!--test>TestPPTX2PNG</test-->
|
||||||
<threadCount>10</threadCount-->
|
<!--parallel>both</parallel>
|
||||||
</configuration>
|
<threadCount>10</threadCount-->
|
||||||
</plugin>
|
</configuration>
|
||||||
<plugin>
|
</plugin>
|
||||||
<groupId>org.jacoco</groupId>
|
<plugin>
|
||||||
<artifactId>jacoco-maven-plugin</artifactId>
|
<groupId>org.jacoco</groupId>
|
||||||
<version>0.7.8</version>
|
<artifactId>jacoco-maven-plugin</artifactId>
|
||||||
</plugin>
|
<version>0.7.8</version>
|
||||||
</plugins>
|
</plugin>
|
||||||
</build>
|
</plugins>
|
||||||
|
</build>
|
||||||
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>junit</groupId>
|
<groupId>junit</groupId>
|
||||||
<artifactId>junit</artifactId>
|
<artifactId>junit</artifactId>
|
||||||
<version>${junit.version}</version>
|
<version>${junit.version}</version>
|
||||||
<scope>test</scope>
|
<scope>test</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.xmlunit</groupId>
|
<groupId>org.xmlunit</groupId>
|
||||||
<artifactId>xmlunit-core</artifactId>
|
<artifactId>xmlunit-core</artifactId>
|
||||||
<version>${xmlunit.version}</version>
|
<version>${xmlunit.version}</version>
|
||||||
<scope>test</scope>
|
<scope>test</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.mockito</groupId>
|
<groupId>org.mockito</groupId>
|
||||||
<artifactId>mockito-core</artifactId>
|
<artifactId>mockito-core</artifactId>
|
||||||
<version>${mockito.version}</version>
|
<version>${mockito.version}</version>
|
||||||
<scope>test</scope>
|
<scope>test</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
<profiles>
|
<profiles>
|
||||||
<!-- We need a fair amount of memory to compile the xml schema, -->
|
<!-- We need a fair amount of memory to compile the xml schema, -->
|
||||||
<!-- but limit it in case it goes wrong! -->
|
<!-- but limit it in case it goes wrong! -->
|
||||||
<!-- Pick the right amount based on 32 vs 64 bit jvm -->
|
<!-- Pick the right amount based on 32 vs 64 bit jvm -->
|
||||||
<!-- ********************************************************** -->
|
<!-- ********************************************************** -->
|
||||||
<!-- If you are using IntelliJ, you might want to check -->
|
<!-- If you are using IntelliJ, you might want to check -->
|
||||||
<!-- http://stackoverflow.com/questions/24115142 -->
|
<!-- http://stackoverflow.com/questions/24115142 -->
|
||||||
<!-- ********************************************************** -->
|
<!-- ********************************************************** -->
|
||||||
<profile>
|
<profile>
|
||||||
<id>32bitstuff</id>
|
<id>32bitstuff</id>
|
||||||
<activation>
|
<activation>
|
||||||
<property>
|
<property>
|
||||||
<name>sun.arch.data.model</name>
|
<name>sun.arch.data.model</name>
|
||||||
<value>32</value>
|
<value>32</value>
|
||||||
</property>
|
</property>
|
||||||
</activation>
|
</activation>
|
||||||
<properties>
|
<properties>
|
||||||
<maven.compiler.maxmem>512m</maven.compiler.maxmem>
|
<maven.compiler.maxmem>512m</maven.compiler.maxmem>
|
||||||
<argLine>-Xmx768m</argLine>
|
<argLine>-Xmx768m</argLine>
|
||||||
</properties>
|
</properties>
|
||||||
</profile>
|
</profile>
|
||||||
|
|
||||||
<profile>
|
<profile>
|
||||||
<id>64bitstuff</id>
|
<id>64bitstuff</id>
|
||||||
<activation>
|
<activation>
|
||||||
<property>
|
<property>
|
||||||
<name>sun.arch.data.model</name>
|
<name>sun.arch.data.model</name>
|
||||||
<value>64</value>
|
<value>64</value>
|
||||||
</property>
|
</property>
|
||||||
</activation>
|
</activation>
|
||||||
<properties>
|
<properties>
|
||||||
<maven.compiler.maxmem>768m</maven.compiler.maxmem>
|
<maven.compiler.maxmem>768m</maven.compiler.maxmem>
|
||||||
<argLine>-Xmx1024m</argLine>
|
<argLine>-Xmx1024m</argLine>
|
||||||
</properties>
|
</properties>
|
||||||
</profile>
|
</profile>
|
||||||
|
|
||||||
<profile>
|
<profile>
|
||||||
<id>xmlbean</id>
|
<id>xmlbean</id>
|
||||||
<activation>
|
<activation>
|
||||||
<file><exists>xmlbeans.marker</exists></file>
|
<file>
|
||||||
</activation>
|
<exists>xmlbeans.marker</exists>
|
||||||
<build>
|
</file>
|
||||||
<plugins>
|
</activation>
|
||||||
<plugin>
|
<build>
|
||||||
<groupId>org.codehaus.mojo</groupId>
|
<plugins>
|
||||||
<artifactId>xmlbeans-maven-plugin</artifactId>
|
<plugin>
|
||||||
<version>2.3.3</version>
|
<groupId>org.codehaus.mojo</groupId>
|
||||||
<executions>
|
<artifactId>xmlbeans-maven-plugin</artifactId>
|
||||||
<execution>
|
<version>2.3.3</version>
|
||||||
<phase>process-sources</phase>
|
<executions>
|
||||||
<goals>
|
<execution>
|
||||||
<goal>xmlbeans</goal>
|
<phase>process-sources</phase>
|
||||||
</goals>
|
<goals>
|
||||||
<configuration>
|
<goal>xmlbeans</goal>
|
||||||
<schemaDirectory>${basedir}/target/schemas</schemaDirectory>
|
</goals>
|
||||||
<javaSource>1.5</javaSource>
|
<configuration>
|
||||||
<noJavac>true</noJavac>
|
<schemaDirectory>${basedir}/target/schemas</schemaDirectory>
|
||||||
<noUpa>${xmlbeans.noUpa}</noUpa>
|
<javaSource>1.5</javaSource>
|
||||||
<noPvr>${xmlbeans.noPvr}</noPvr>
|
<noJavac>true</noJavac>
|
||||||
<xmlConfigs>
|
<noUpa>${xmlbeans.noUpa}</noUpa>
|
||||||
<xmlConfig implementation="java.io.File">${basedir}/../../src/ooxml/resources/org/apache/poi/poifs/crypt/encryptionCertificate.xsdconfig</xmlConfig>
|
<noPvr>${xmlbeans.noPvr}</noPvr>
|
||||||
<xmlConfig implementation="java.io.File">${basedir}/../../src/ooxml/resources/org/apache/poi/poifs/crypt/encryptionInfo.xsdconfig</xmlConfig>
|
<xmlConfigs>
|
||||||
<xmlConfig implementation="java.io.File">${basedir}/../../src/ooxml/resources/org/apache/poi/poifs/crypt/encryptionPassword.xsdconfig</xmlConfig>
|
<xmlConfig implementation="java.io.File">
|
||||||
<xmlConfig implementation="java.io.File">${basedir}/../../src/ooxml/resources/org/apache/poi/schemas/ooxmlSchemas.xsdconfig</xmlConfig>
|
${basedir}/../../src/ooxml/resources/org/apache/poi/poifs/crypt/encryptionCertificate.xsdconfig
|
||||||
</xmlConfigs>
|
</xmlConfig>
|
||||||
</configuration>
|
<xmlConfig implementation="java.io.File">
|
||||||
</execution>
|
${basedir}/../../src/ooxml/resources/org/apache/poi/poifs/crypt/encryptionInfo.xsdconfig
|
||||||
</executions>
|
</xmlConfig>
|
||||||
</plugin>
|
<xmlConfig implementation="java.io.File">
|
||||||
|
${basedir}/../../src/ooxml/resources/org/apache/poi/poifs/crypt/encryptionPassword.xsdconfig
|
||||||
|
</xmlConfig>
|
||||||
|
<xmlConfig implementation="java.io.File">
|
||||||
|
${basedir}/../../src/ooxml/resources/org/apache/poi/schemas/ooxmlSchemas.xsdconfig
|
||||||
|
</xmlConfig>
|
||||||
|
</xmlConfigs>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
<plugin>
|
<plugin>
|
||||||
<artifactId>maven-antrun-plugin</artifactId>
|
<artifactId>maven-antrun-plugin</artifactId>
|
||||||
<version>${maven.plugin.antrun.version}</version>
|
<version>${maven.plugin.antrun.version}</version>
|
||||||
<executions>
|
<executions>
|
||||||
<execution>
|
<execution>
|
||||||
<id>copy-xmltype-and-xsdconfig</id>
|
<id>copy-xmltype-and-xsdconfig</id>
|
||||||
<phase>generate-sources</phase>
|
<phase>generate-sources</phase>
|
||||||
<goals><goal>run</goal></goals>
|
<goals>
|
||||||
<configuration>
|
<goal>run</goal>
|
||||||
<target>
|
</goals>
|
||||||
<copy todir="${basedir}/target/generated-sources/xmlbeans">
|
<configuration>
|
||||||
<fileset dir="${basedir}/../../src/ooxml/java">
|
<target>
|
||||||
<include name="org/apache/poi/ooxml/POIXMLTypeLoader.java"/>
|
<copy todir="${basedir}/target/schemas">
|
||||||
<include name="org/apache/poi/ooxml/util/DocumentHelper.java"/>
|
<fileset dir="${basedir}/../../src/ooxml/resources/org/apache/poi/schemas"/>
|
||||||
<include name="org/apache/poi/ooxml/util/SAXHelper.java"/>
|
</copy>
|
||||||
<include name="org/apache/poi/openxml4j/opc/PackageNamespaces.java"/>
|
</target>
|
||||||
</fileset>
|
</configuration>
|
||||||
<fileset dir="${basedir}/../../src/java">
|
</execution>
|
||||||
<include name="org/apache/poi/util/POILogFactory.java"/>
|
<execution>
|
||||||
<include name="org/apache/poi/util/POILogger.java"/>
|
<id>replace-xmltypeloader</id>
|
||||||
<include name="org/apache/poi/util/NullLogger.java"/>
|
<phase>process-sources</phase>
|
||||||
<include name="org/apache/poi/util/Internal.java"/>
|
<goals>
|
||||||
<include name="org/apache/poi/util/Removal.java"/>
|
<goal>run</goal>
|
||||||
</fileset>
|
</goals>
|
||||||
</copy>
|
<configuration>
|
||||||
<copy todir="${basedir}/target/schemas">
|
<target>
|
||||||
<fileset dir="${basedir}/../../src/ooxml/resources/org/apache/poi/schemas"/>
|
<property name="xmlbean.sources.dir"
|
||||||
</copy>
|
location="${basedir}/target/generated-sources/xmlbeans"/>
|
||||||
</target>
|
|
||||||
</configuration>
|
<property name="loaderMethod"><![CDATA[
|
||||||
</execution>
|
private static java.lang.ref.SoftReference<org.apache.xmlbeans.SchemaTypeLoader> typeLoader;
|
||||||
<execution>
|
|
||||||
<id>replace-xmltypeloader</id>
|
private static synchronized org.apache.xmlbeans.SchemaTypeLoader getTypeLoader() {
|
||||||
<phase>process-sources</phase>
|
org.apache.xmlbeans.SchemaTypeLoader stl = (typeLoader == null) ? null : typeLoader.get();
|
||||||
<goals><goal>run</goal></goals>
|
if (stl == null) {
|
||||||
<configuration>
|
stl = org.apache.xmlbeans.XmlBeans.typeLoaderForClassLoader(\2.class.getClassLoader());
|
||||||
<target>
|
typeLoader = new java.lang.ref.SoftReference(stl);
|
||||||
<replace dir="${basedir}/target/generated-sources/xmlbeans" includes="**/*.java" excludes="**/impl/**">
|
}
|
||||||
<replacetoken>org.apache.xmlbeans.XmlBeans.getContextTypeLoader()</replacetoken>
|
return stl;
|
||||||
<replacevalue>org.apache.poi.ooxml.POIXMLTypeLoader</replacevalue>
|
}
|
||||||
</replace>
|
|
||||||
</target>
|
public static \2 newInstance\(\) \{]]></property>
|
||||||
</configuration>
|
|
||||||
</execution>
|
<replaceregexp byline="true"
|
||||||
<execution>
|
match="(\s*)public static ([^ ]+) newInstance\(\) \{"
|
||||||
<id>remove-xmltypeloader-from-schema-jar</id>
|
replace="${loaderMethod}">
|
||||||
<phase>prepare-package</phase>
|
<fileset dir="${xmlbean.sources.dir}" includes="**/*.java"
|
||||||
<goals><goal>run</goal></goals>
|
excludes="**/impl/**"/>
|
||||||
<configuration>
|
</replaceregexp>
|
||||||
<target>
|
|
||||||
<touch file="${basedir}/target/generated-sources/xmlbeans/.staleFlag"/>
|
<replace dir="${xmlbean.sources.dir}" includes="**/*.java"
|
||||||
<delete dir="${basedir}/target/classes/org/apache"/>
|
excludes="**/impl/**">
|
||||||
</target>
|
<replacetoken>org.apache.xmlbeans.XmlBeans.getContextTypeLoader
|
||||||
</configuration>
|
</replacetoken>
|
||||||
</execution>
|
<replacevalue>getTypeLoader</replacevalue>
|
||||||
</executions>
|
</replace>
|
||||||
</plugin>
|
|
||||||
</plugins>
|
<!-- remove deprecated warnings, as we prefer the array methods - see #56854 -->
|
||||||
</build>
|
<replace dir="${xmlbean.sources.dir}" includes="**/*.java"
|
||||||
<dependencies>
|
excludes="**/impl/**">
|
||||||
<dependency>
|
<replacetoken><![CDATA[ * @deprecated
|
||||||
<groupId>org.apache.xmlbeans</groupId>
|
]]></replacetoken>
|
||||||
<artifactId>xmlbeans</artifactId>
|
</replace>
|
||||||
<version>${xmlbeans.version}</version>
|
</target>
|
||||||
</dependency>
|
</configuration>
|
||||||
</dependencies>
|
</execution>
|
||||||
</profile>
|
<execution>
|
||||||
</profiles>
|
<id>remove-xmltypeloader-from-schema-jar</id>
|
||||||
|
<phase>prepare-package</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>run</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<target>
|
||||||
|
<touch file="${basedir}/target/generated-sources/xmlbeans/.staleFlag"/>
|
||||||
|
<delete dir="${basedir}/target/classes/org/apache"/>
|
||||||
|
</target>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
</build>
|
||||||
|
|
||||||
|
<dependencies>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.apache.xmlbeans</groupId>
|
||||||
|
<artifactId>xmlbeans</artifactId>
|
||||||
|
<version>${xmlbeans.version}</version>
|
||||||
|
</dependency>
|
||||||
|
</dependencies>
|
||||||
|
</profile>
|
||||||
|
</profiles>
|
||||||
</project>
|
</project>
|
||||||
|
Loading…
Reference in New Issue
Block a user