Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ensure the CMake build works on all platforms #1612

Merged
merged 8 commits into from
May 24, 2024
2 changes: 1 addition & 1 deletion .mvn/wrapper/maven-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,5 @@
# specific language governing permissions and limitations
# under the License.
#
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.5/apache-maven-3.9.5-bin.zip
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.6/apache-maven-3.9.6-bin.zip
wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar
140 changes: 0 additions & 140 deletions plc4c/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -374,146 +374,6 @@
</dependencies>
</profile>

<!--
In order to build on linux with aarch64 systems, we need to download and deploy
an artifact as the linux aarch64 version seems to be missing.
-->
<profile>
<id>.os-linux-aarch64</id>
<activation>
<os>
<family>linux</family>
<arch>aarch64</arch>
</os>
</activation>
<build>
<plugins>
<plugin>
<groupId>com.googlecode.maven-download-plugin</groupId>
<artifactId>download-maven-plugin</artifactId>
<executions>
<execution>
<id>download-aarch64-linux-binaries</id>
<phase>validate</phase>
<goals>
<goal>wget</goal>
</goals>
<configuration>
<url>https://cmake.org/files/v3.27/cmake-3.27.7-linux-aarch64.tar.gz</url>
<unpack>true</unpack>
<outputDirectory>${project.build.directory}/redeploy</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<executions>
<execution>
<id>package-aarch64-linux-binaries</id>
<phase>validate</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<classesDirectory>${project.build.directory}/redeploy/cmake-3.27.7-linux-aarch64</classesDirectory>
<includes>
<include>**</include>
</includes>
<finalName>cmake-binaries-${cmake.version}-linux-arm_64</finalName>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-install-plugin</artifactId>
<executions>
<execution>
<id>install-aarch64-linux-binaries</id>
<phase>validate</phase>
<goals>
<goal>install-file</goal>
</goals>
<configuration>
<file>${project.build.directory}/cmake-binaries-${cmake.version}-linux-arm_64.jar</file>
<groupId>com.googlecode.cmake-maven-project</groupId>
<artifactId>cmake-binaries</artifactId>
<version>${cmake.version}</version>
<classifier>linux-arm_64</classifier>
<packaging>jar</packaging>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>

<!--
In order to build on windows with aarch64 systems, we need to re-deploy an
artifact which was unfortunately deployed with the wrong classifier.
-->
<profile>
<id>.os-windows-aarch64</id>
<activation>
<os>
<family>windows</family>
<arch>aarch64</arch>
</os>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>download-aarch64-windows-binaries</id>
<phase>validate</phase>
<goals>
<goal>copy</goal>
</goals>
<configuration>
<outputDirectory>${project.build.directory}/redeploy</outputDirectory>
<artifactItems>
<artifactItem>
<groupId>com.googlecode.cmake-maven-project</groupId>
<artifactId>cmake-binaries</artifactId>
<version>${cmake.version}</version>
<classifier>windows-arm_64</classifier>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-install-plugin</artifactId>
<executions>
<execution>
<id>install-aarch64-windows-binaries</id>
<phase>validate</phase>
<goals>
<goal>install-file</goal>
</goals>
<configuration>
<file>${project.build.directory}/redeploy/cmake-binaries-${cmake.version}-windows-arm_64.jar</file>
<groupId>com.googlecode.cmake-maven-project</groupId>
<artifactId>cmake-binaries</artifactId>
<version>${cmake.version}</version>
<classifier>windows-arm64</classifier>
<packaging>jar</packaging>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>

<!-- When running on jenkins, download the sonar build-wrapper, so we can do a code analysis -->
<profile>
<id>jenkins-build</id>
Expand Down
3 changes: 1 addition & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,7 @@
<bit-io.version>1.4.3</bit-io.version>
<bouncycastle.version>1.78.1</bouncycastle.version>
<byte-buddy.version>1.14.14</byte-buddy.version>
<!-- Be sure to keep this version set to the version of the cmake-maven-plugin -->
<cmake.version>3.27.7-b1</cmake.version>
<cmake.version>3.29.3-b2</cmake.version>
<commons-beanutils.version>1.9.4</commons-beanutils.version>
<commons-cli.version>1.7.0</commons-cli.version>
<commons-codec.version>1.17.0</commons-codec.version>
Expand Down
Loading