Skip to content

Commit

Permalink
Maven build issue with Maven 3.8.2 fix (#1244)
Browse files Browse the repository at this point in the history
Signed-off-by: Radek Felcman <radek.felcman@oracle.com>
  • Loading branch information
rfelcman committed Sep 3, 2021
1 parent ed8460e commit f514879
Show file tree
Hide file tree
Showing 11 changed files with 229 additions and 56 deletions.
8 changes: 8 additions & 0 deletions bundles/eclipselink/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,14 @@
</dependency>

<!-- included artifacts -->
<dependency>
<groupId>org.eclipse.persistence</groupId>
<artifactId>org.eclipse.persistence.parent</artifactId>
<version>${project.version}</version>
<type>zip</type>
<classifier>common-license</classifier>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.eclipse.persistence</groupId>
<artifactId>org.eclipse.persistence.asm</artifactId>
Expand Down
27 changes: 16 additions & 11 deletions bundles/eclipselink/src/main/assembly/eclipselink.zip.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2019, 2020 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2019, 2021 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0 which is available at
Expand All @@ -22,6 +22,21 @@
</formats>
<includeBaseDirectory>false</includeBaseDirectory>
<dependencySets>
<!--License files-->
<dependencySet>
<useProjectArtifact>false</useProjectArtifact>
<scope>provided</scope>
<outputDirectory>eclipselink/</outputDirectory>
<includes>
<include>${project.groupId}:org.eclipse.persistence.parent:zip:common-license</include>
</includes>
<unpack>true</unpack>
<unpackOptions>
<includes>
<include>*.html</include>
</includes>
</unpackOptions>
</dependencySet>
<dependencySet>
<useProjectAttachments>true</useProjectAttachments>
<outputDirectory>eclipselink/jlib/</outputDirectory>
Expand Down Expand Up @@ -113,16 +128,6 @@
</dependencySet>
</dependencySets>
<fileSets>
<!--License files-->
<fileSet>
<directory>${project.root.location}</directory>
<outputDirectory>eclipselink/</outputDirectory>
<includes>
<include>about.html</include>
<include>license.html</include>
<include>readme.html</include>
</includes>
</fileSet>
<!--Scripts to bin directory-->
<fileSet>
<directory>${project.build.scriptSourceDirectory}</directory>
Expand Down
8 changes: 8 additions & 0 deletions bundles/moxy-standalone/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,14 @@
</properties>

<dependencies>
<dependency>
<groupId>org.eclipse.persistence</groupId>
<artifactId>org.eclipse.persistence.parent</artifactId>
<version>${project.version}</version>
<type>zip</type>
<classifier>common-license</classifier>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.eclipse.persistence</groupId>
<artifactId>org.eclipse.persistence.moxy</artifactId>
Expand Down
27 changes: 16 additions & 11 deletions bundles/moxy-standalone/src/main/assembly/moxy.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2020 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2020, 2021 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0 which is available at
Expand All @@ -22,23 +22,28 @@
</formats>
<includeBaseDirectory>false</includeBaseDirectory>
<dependencySets>
<!--License files-->
<dependencySet>
<useProjectArtifact>false</useProjectArtifact>
<scope>provided</scope>
<outputDirectory>moxy</outputDirectory>
<includes>
<include>${project.groupId}:org.eclipse.persistence.parent:zip:common-license</include>
</includes>
<unpack>true</unpack>
<unpackOptions>
<includes>
<include>*.html</include>
</includes>
</unpackOptions>
</dependencySet>
<dependencySet>
<useProjectArtifact>false</useProjectArtifact>
<outputDirectory>moxy/jlib/</outputDirectory>
<outputFileNameMapping>${artifact.artifactId}.${artifact.extension}</outputFileNameMapping>
</dependencySet>
</dependencySets>
<fileSets>
<!--License files-->
<fileSet>
<directory>${project.root.location}</directory>
<outputDirectory>moxy/</outputDirectory>
<includes>
<include>about.html</include>
<include>license.html</include>
<include>readme.html</include>
</includes>
</fileSet>
<!--Scripts to bin directory-->
<fileSet>
<directory>${generated.res.dir}/xsds</directory>
Expand Down
8 changes: 8 additions & 0 deletions bundles/others/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,14 @@
<dependencies>
<!--Binary dependencies-->
<!--Other modules-->
<dependency>
<groupId>org.eclipse.persistence</groupId>
<artifactId>org.eclipse.persistence.parent</artifactId>
<version>${project.version}</version>
<type>zip</type>
<classifier>common-license</classifier>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.eclipse.persistence</groupId>
<artifactId>eclipselink</artifactId>
Expand Down
18 changes: 15 additions & 3 deletions bundles/others/src/main/assembly/eclipselink-plugins-nosql.zip.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,22 @@
<format>zip</format>
</formats>
<includeBaseDirectory>false</includeBaseDirectory>
<componentDescriptors>
<componentDescriptor>src/main/assembly/common-license.xml</componentDescriptor>
</componentDescriptors>
<dependencySets>
<!--License files-->
<dependencySet>
<useProjectArtifact>false</useProjectArtifact>
<scope>provided</scope>
<outputDirectory>.</outputDirectory>
<includes>
<include>${project.groupId}:org.eclipse.persistence.parent:zip:common-license</include>
</includes>
<unpack>true</unpack>
<unpackOptions>
<includes>
<include>*.html</include>
</includes>
</unpackOptions>
</dependencySet>
<dependencySet>
<includes>
<include>org.eclipse.persistence:org.eclipse.persistence.nosql</include>
Expand Down
18 changes: 15 additions & 3 deletions bundles/others/src/main/assembly/eclipselink-plugins.zip.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,22 @@
<format>zip</format>
</formats>
<includeBaseDirectory>false</includeBaseDirectory>
<componentDescriptors>
<componentDescriptor>src/main/assembly/common-license.xml</componentDescriptor>
</componentDescriptors>
<dependencySets>
<!--License files-->
<dependencySet>
<useProjectArtifact>false</useProjectArtifact>
<scope>provided</scope>
<outputDirectory>.</outputDirectory>
<includes>
<include>${project.groupId}:org.eclipse.persistence.parent:zip:common-license</include>
</includes>
<unpack>true</unpack>
<unpackOptions>
<includes>
<include>*.html</include>
</includes>
</unpackOptions>
</dependencySet>
<dependencySet>
<outputFileNameMapping>${artifact.artifactId}_${release.version}.${build.qualifier}.${artifact.extension}</outputFileNameMapping>
<includes>
Expand Down
22 changes: 18 additions & 4 deletions bundles/others/src/main/assembly/eclipselink-test-src.zip.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2019 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2019, 2021 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0 which is available at
Expand All @@ -21,9 +21,23 @@
<format>zip</format>
</formats>
<includeBaseDirectory>false</includeBaseDirectory>
<componentDescriptors>
<componentDescriptor>src/main/assembly/common-license.xml</componentDescriptor>
</componentDescriptors>
<dependencySets>
<!--License files-->
<dependencySet>
<useProjectArtifact>false</useProjectArtifact>
<scope>provided</scope>
<outputDirectory>.</outputDirectory>
<includes>
<include>${project.groupId}:org.eclipse.persistence.parent:zip:common-license</include>
</includes>
<unpack>true</unpack>
<unpackOptions>
<includes>
<include>*.html</include>
</includes>
</unpackOptions>
</dependencySet>
</dependencySets>
<fileSets>
<!--Ant build files from resources-->
<fileSet>
Expand Down
86 changes: 70 additions & 16 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -111,9 +111,8 @@
<bundle.version>${project.version}.${build.qualifier}</bundle.version>
<project.build.testReports.subdirectory>test-reports</project.build.testReports.subdirectory>
<project.build.testReports.summaryFile>test-summary</project.build.testReports.summaryFile>
<project.build.licenceResourceDirectory>${project.build.directory}/license</project.build.licenceResourceDirectory>

<!--Common properties-->
<common.licenceFiles>LICENSE.md, NOTICE.md</common.licenceFiles>
<!--Integration test sources/resources directory. Relative directory to ${project.basedir}
!!!Can't start with / character!!!-->
<integration.test.directory>src/it/</integration.test.directory>
Expand All @@ -137,7 +136,7 @@
<!--Default test DB is Derby-->
<test.properties.file>${user.home}/${test.derby.properties.file}</test.properties.file>
<test.properties.fileName>${test.derby.properties.file}</test.properties.fileName>
<test.properties.default.directory>${project.root.location}/etc</test.properties.default.directory>
<test.properties.default.directory>${project.build.directory}/test-default-properties</test.properties.default.directory>
<test.database>derby</test.database>
<!--false: to start In-Memory database, true: not start (MySQL, Oracle)-->
<test.skip.in-memory.db>false</test.skip.in-memory.db>
Expand Down Expand Up @@ -1126,11 +1125,6 @@
<artifactId>xml-maven-plugin</artifactId>
<version>1.0.2</version>
</plugin>
<plugin>
<groupId>org.commonjava.maven.plugins</groupId>
<artifactId>directory-maven-plugin</artifactId>
<version>0.3.1</version>
</plugin>
<!--This plugin (g:org.kuali.maven.plugins) is used instead typical org.codehaus.mojo:properties-maven-plugin:1.0.0
due bug: "Circular property definition" if expression like this is used in the Maven pom
"<server.testrunner.prefix>${modelname}/${modelname}_ejb/</server.testrunner.prefix>"
Expand Down Expand Up @@ -1211,17 +1205,77 @@
</configuration>
</plugin>
<plugin>
<groupId>org.commonjava.maven.plugins</groupId>
<artifactId>directory-maven-plugin</artifactId>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
<executions>
<execution>
<id>find-project-root</id>
<phase>validate</phase>
<id>common-license</id>
<phase>generate-resources</phase>
<goals>
<goal>single</goal>
</goals>
<inherited>false</inherited>
<configuration>
<descriptors>
<descriptor>src/main/assembly/common-license.xml</descriptor>
</descriptors>
</configuration>
</execution>
<execution>
<id>test-defaults</id>
<phase>initialize</phase>
<goals>
<goal>single</goal>
</goals>
<inherited>false</inherited>
<configuration>
<descriptors>
<descriptor>src/main/assembly/test-defaults.xml</descriptor>
</descriptors>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>unpack-legal-resource</id>
<phase>generate-resources</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<groupId>${project.groupId}</groupId>
<artifactId>org.eclipse.persistence.parent</artifactId>
<version>${project.version}</version>
<classifier>common-license</classifier>
<type>zip</type>
<outputDirectory>${project.build.licenceResourceDirectory}</outputDirectory>
</artifactItem>
</artifactItems>
</configuration>
</execution>
<execution>
<id>unpack-test-properties</id>
<phase>initialize</phase>
<goals>
<goal>highest-basedir</goal>
<goal>unpack</goal>
</goals>
<configuration>
<property>project.root.location</property>
<artifactItems>
<artifactItem>
<groupId>${project.groupId}</groupId>
<artifactId>org.eclipse.persistence.parent</artifactId>
<version>${project.version}</version>
<classifier>test-defaults</classifier>
<type>zip</type>
<outputDirectory>${test.properties.default.directory}</outputDirectory>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
Expand Down Expand Up @@ -1278,8 +1332,8 @@
<configuration>
<resources>
<resource>
<directory>${project.root.location}</directory>
<includes>${common.licenceFiles}</includes>
<directory>${project.build.licenceResourceDirectory}/md</directory>
<includes>*</includes>
<targetPath>META-INF</targetPath>
</resource>
</resources>
Expand Down

0 comments on commit f514879

Please sign in to comment.