Skip to content

Commit

Permalink
Support for riscv64
Browse files Browse the repository at this point in the history
  • Loading branch information
ixgbe00 committed Oct 10, 2024
1 parent 2fd35c6 commit 5c95c85
Show file tree
Hide file tree
Showing 3 changed files with 134 additions and 1 deletion.
95 changes: 94 additions & 1 deletion platform/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@
<javacpp.platform.ios-x86_64>ios-x86_64${javacpp.platform.extension}</javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf>linux-armhf${javacpp.platform.extension}</javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64>linux-arm64${javacpp.platform.extension}</javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64>linux-riscv64${javacpp.platform.extension}</javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le>linux-ppc64le${javacpp.platform.extension}</javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86>linux-x86${javacpp.platform.extension}</javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64>linux-x86_64${javacpp.platform.extension}</javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -128,6 +129,12 @@
<artifactId>javacpp</artifactId>
<version>${project.version}</version>
<classifier>${javacpp.platform.linux-arm64}</classifier>
</dependency>
<dependency>
<groupId>org.bytedeco</groupId>
<artifactId>javacpp</artifactId>
<version>${project.version}</version>
<classifier>${javacpp.platform.linux-riscv64}</classifier>
</dependency>
<dependency>
<groupId>org.bytedeco</groupId>
Expand Down Expand Up @@ -240,7 +247,7 @@
<configuration>
<archive>
<manifestEntries>
<Class-Path>javacpp.jar javacpp-linux-armhf.jar javacpp-linux-arm64.jar javacpp-linux-ppc64le.jar javacpp-linux-x86.jar javacpp-linux-x86_64.jar javacpp-macosx-arm64.jar javacpp-macosx-x86_64.jar javacpp-windows-x86.jar javacpp-windows-x86_64.jar</Class-Path>
<Class-Path>javacpp.jar javacpp-linux-armhf.jar javacpp-linux-arm64.jar javacpp-linux-riscv64.jar javacpp-linux-ppc64le.jar javacpp-linux-x86.jar javacpp-linux-x86_64.jar javacpp-macosx-arm64.jar javacpp-macosx-x86_64.jar javacpp-windows-x86.jar javacpp-windows-x86_64.jar</Class-Path>
</manifestEntries>
</archive>
</configuration>
Expand Down Expand Up @@ -300,6 +307,7 @@
requires static org.bytedeco.javacpp.ios.x86_64;
requires static org.bytedeco.javacpp.linux.armhf;
requires static org.bytedeco.javacpp.linux.arm64;
requires static org.bytedeco.javacpp.linux.riscv64;
requires static org.bytedeco.javacpp.linux.ppc64le;
requires static org.bytedeco.javacpp.linux.x86;
requires static org.bytedeco.javacpp.linux.x86_64;
Expand Down Expand Up @@ -424,6 +432,7 @@
<javacpp.platform.ios-x86_64>${javacpp.platform}${javacpp.platform.extension}</javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf>${javacpp.platform}${javacpp.platform.extension}</javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64>${javacpp.platform}${javacpp.platform.extension}</javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64>${javacpp.platform}${javacpp.platform.extension}</javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le>${javacpp.platform}${javacpp.platform.extension}</javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86>${javacpp.platform}${javacpp.platform.extension}</javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64>${javacpp.platform}${javacpp.platform.extension}</javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -453,6 +462,7 @@
<javacpp.platform.ios-x86_64>${os.name}-${os.arch}${javacpp.platform.extension}</javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf>${os.name}-${os.arch}${javacpp.platform.extension}</javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64>${os.name}-${os.arch}${javacpp.platform.extension}</javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64>${os.name}-${os.arch}${javacpp.platform.extension}</javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le>${os.name}-${os.arch}${javacpp.platform.extension}</javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86>${os.name}-${os.arch}${javacpp.platform.extension}</javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64>${os.name}-${os.arch}${javacpp.platform.extension}</javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -482,6 +492,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -511,6 +522,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -541,6 +553,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -570,6 +583,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -599,6 +613,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -628,6 +643,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -657,6 +673,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -686,6 +703,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -715,6 +733,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -744,6 +763,7 @@
<javacpp.platform.ios-x86_64>${javacpp.platform}${javacpp.platform.extension}</javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -773,6 +793,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf>${javacpp.platform}${javacpp.platform.extension}</javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -802,6 +823,37 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64>${javacpp.platform}${javacpp.platform.extension}</javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
<javacpp.platform.macosx-arm64></javacpp.platform.macosx-arm64>
<javacpp.platform.macosx-x86_64></javacpp.platform.macosx-x86_64>
<javacpp.platform.windows-x86></javacpp.platform.windows-x86>
<javacpp.platform.windows-x86_64></javacpp.platform.windows-x86_64>
</properties>
</profile>

<profile>
<id>javacpp-platform-linux-riscv64</id>
<activation>
<property>
<name>javacpp.platform</name>
<value>linux-riscv64</value>
</property>
</activation>
<properties>
<javacpp.platform.android-arm></javacpp.platform.android-arm>
<javacpp.platform.android-arm64></javacpp.platform.android-arm64>
<javacpp.platform.android-x86></javacpp.platform.android-x86>
<javacpp.platform.android-x86_64></javacpp.platform.android-x86_64>
<javacpp.platform.ios-arm></javacpp.platform.ios-arm>
<javacpp.platform.ios-arm64></javacpp.platform.ios-arm64>
<javacpp.platform.ios-x86></javacpp.platform.ios-x86>
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64>${javacpp.platform}${javacpp.platform.extension}</javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -831,6 +883,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le>${javacpp.platform}${javacpp.platform.extension}</javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -860,6 +913,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86>${javacpp.platform}${javacpp.platform.extension}</javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -889,6 +943,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64>${javacpp.platform}${javacpp.platform.extension}</javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -918,6 +973,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -947,6 +1003,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -976,6 +1033,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -1005,6 +1063,7 @@
<javacpp.platform.ios-x86_64></javacpp.platform.ios-x86_64>
<javacpp.platform.linux-armhf></javacpp.platform.linux-armhf>
<javacpp.platform.linux-arm64></javacpp.platform.linux-arm64>
<javacpp.platform.linux-riscv64></javacpp.platform.linux-riscv64>
<javacpp.platform.linux-ppc64le></javacpp.platform.linux-ppc64le>
<javacpp.platform.linux-x86></javacpp.platform.linux-x86>
<javacpp.platform.linux-x86_64></javacpp.platform.linux-x86_64>
Expand Down Expand Up @@ -1136,6 +1195,18 @@
<javacpp.platform.linux-arm64>linux-arm64${javacpp.platform.extension}</javacpp.platform.linux-arm64>
</properties>
</profile>

<profile>
<id>javacpp.platform.linux-riscv64-true</id>
<activation>
<property>
<name>javacpp.platform.linux-riscv64</name>
</property>
</activation>
<properties>
<javacpp.platform.linux-riscv64>linux-riscv64${javacpp.platform.extension}</javacpp.platform.linux-riscv64>
</properties>
</profile>

<profile>
<id>javacpp.platform.linux-ppc64le-true</id>
Expand Down Expand Up @@ -1285,6 +1356,19 @@
<javacpp.platform.linux-arm64>linux-arm64${javacpp.platform.extension}</javacpp.platform.linux-arm64>
</properties>
</profile>

<profile>
<id>javacpp.platform.custom-linux-riscv64</id>
<activation>
<property>
<name>javacpp.platform.host</name>
</property>
<os><name>linux</name><arch>riscv64</arch></os>
</activation>
<properties>
<javacpp.platform.linux-riscv64>linux-riscv64${javacpp.platform.extension}</javacpp.platform.linux-riscv64>
</properties>
</profile>

<profile>
<id>javacpp.platform.custom-linux-ppc64le</id>
Expand Down Expand Up @@ -1504,6 +1588,15 @@
<os.arch>arm64</os.arch>
</properties>
</profile>
<profile>
<id>riscv64</id>
<activation>
<os><arch>riscv64</arch></os>
</activation>
<properties>
<os.arch>riscv64</os.arch>
</properties>
</profile>
<profile>
<id>armv8</id>
<activation>
Expand Down
9 changes: 9 additions & 0 deletions src/it/osgi/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,15 @@
<os.arch>arm64</os.arch>
</properties>
</profile>
<profile>
<id>riscv64</id>
<activation>
<os><arch>riscv64</arch></os>
</activation>
<properties>
<os.arch>riscv64</os.arch>
</properties>
</profile>
<profile>
<id>armv8</id>
<activation>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
platform=linux-riscv64
platform.path.separator=:
platform.source.suffix=.cpp
platform.includepath.prefix=-I
platform.includepath=
platform.compiler=g++
platform.compiler.cpp98=-std=c++98
platform.compiler.cpp03=-std=c++03
platform.compiler.cpp11=-std=c++11
platform.compiler.cpp14=-std=c++14
platform.compiler.cpp17=-std=c++17
platform.compiler.debug=-O0 -g
platform.compiler.default=-O3 -s
platform.compiler.fastfpu=-ffast-math
platform.compiler.nodeprecated=-Wno-deprecated-declarations
platform.compiler.noexceptions=-fno-exceptions -fno-rtti
platform.compiler.nowarnings=-w
platform.compiler.output=-Wl,-rpath,$ORIGIN/ -Wl,-z,noexecstack -Wl,-Bsymbolic -Wall -fPIC -pthread -shared -o\u0020
platform.linkpath.prefix=-L
platform.linkpath.prefix2=-Wl,-rpath,
platform.linkpath=
platform.link.prefix=-l
platform.link.suffix=
platform.link=
platform.framework.prefix=-F
platform.framework.suffix=
platform.framework=
platform.executable.prefix=
platform.executable.suffix=
platform.library.prefix=lib
platform.library.suffix=.so

0 comments on commit 5c95c85

Please sign in to comment.