File tree Expand file tree Collapse file tree 7 files changed +19
-2
lines changed Expand file tree Collapse file tree 7 files changed +19
-2
lines changed Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
9
9
curl \
10
10
g++-aarch64-linux-gnu \
11
11
g++-powerpc64le-linux-gnu \
12
+ g++-riscv64-linux-gnu \
12
13
openjdk-8-jdk \
13
14
pkg-config \
14
15
&& \
Original file line number Diff line number Diff line change @@ -21,3 +21,5 @@ trap spongify_logs EXIT
21
21
# internal compiler error: output_operand: invalid %-code
22
22
" $GRPC_JAVA_DIR " /buildscripts/run_in_docker.sh grpc-java-artifacts-ubuntu2004 env \
23
23
SKIP_TESTS=true ARCH=s390_64 /grpc-java/buildscripts/kokoro/unix.sh
24
+ " $GRPC_JAVA_DIR " /buildscripts/run_in_docker.sh grpc-java-artifacts-ubuntu2004 env \
25
+ SKIP_TESTS=true ARCH=riscv64 /grpc-java/buildscripts/kokoro/unix.sh
Original file line number Diff line number Diff line change 13
13
# ARCH=ppcle_64 ./buildscripts/kokoro/unix.sh
14
14
# For s390x arch:
15
15
# ARCH=s390_64 ./buildscripts/kokoro/unix.sh
16
+ # For riscv64 arch:
17
+ # ARCH=riscv_64 ./buildscripts/kokoro/unix.sh
16
18
17
19
# This script assumes `set -e`. Removing it may lead to undefined behavior.
18
20
set -exu -o pipefail
89
91
LOCAL_MVN_TEMP=$( mktemp -d)
90
92
# Note that this disables parallel=true from GRADLE_FLAGS
91
93
if [[ -z " ${ALL_ARTIFACTS:- } " ]]; then
92
- if [[ " $ARCH " = " aarch_64" || " $ARCH " = " ppcle_64" || " $ARCH " = " s390_64" ]]; then
94
+ if [[ " $ARCH " = " aarch_64" || " $ARCH " = " ppcle_64" || " $ARCH " = " s390_64" || " $ARCH " = " riscv64 " ]]; then
93
95
GRADLE_FLAGS+=" -x grpc-compiler:generateTestProto -x grpc-compiler:generateTestLiteProto"
94
96
GRADLE_FLAGS+=" -x grpc-compiler:testGolden -x grpc-compiler:testLiteGolden"
95
97
GRADLE_FLAGS+=" -x grpc-compiler:testDeprecatedGolden -x grpc-compiler:testDeprecatedLiteGolden"
Original file line number Diff line number Diff line change @@ -40,6 +40,9 @@ LOCAL_OTHER_ARTIFACTS="$KOKORO_GFILE_DIR"/github/grpc-java/artifacts/
40
40
# for linux s390x platform
41
41
[[ " $( find " $LOCAL_MVN_ARTIFACTS " -type f -iname ' protoc-gen-grpc-java-*-linux-s390_64.exe' | wc -l) " != ' 0' ]]
42
42
43
+ # for linux riscv64 platform
44
+ [[ " $( find " $LOCAL_MVN_ARTIFACTS " -type f -iname ' protoc-gen-grpc-java-*-linux-riscv64.exe' | wc -l) " != ' 0' ]]
45
+
43
46
# from macos job:
44
47
[[ " $( find " $LOCAL_MVN_ARTIFACTS " -type f -iname ' protoc-gen-grpc-java-*-osx-x86_64.exe' | wc -l) " != ' 0' ]]
45
48
# copy all x86 artifacts to aarch until native artifacts are built
Original file line number Diff line number Diff line change 55
55
GCC_ARCH=s390x-linux-gnu
56
56
elif [[ " $ARCH " == loongarch_64 ]]; then
57
57
GCC_ARCH=loongarch64-unknown-linux-gnu
58
+ elif [[ " $ARCH " == riscv* ]]; then
59
+ GCC_ARCH=riscv64-unknown-linux-gnu
58
60
else
59
61
echo " Unknown architecture: $ARCH "
60
62
exit 1
Original file line number Diff line number Diff line change @@ -63,6 +63,7 @@ model {
63
63
linker. executable = ' s390x-linux-gnu-g++'
64
64
}
65
65
target(" loongarch_64" )
66
+ target(" riscv64" )
66
67
}
67
68
clang(Clang ) {
68
69
target(" aarch_64" ) {}
@@ -76,6 +77,7 @@ model {
76
77
aarch_64 { architecture " aarch_64" }
77
78
s390_64 { architecture " s390_64" }
78
79
loongarch_64 { architecture " loongarch_64" }
80
+ riscv64 { architecture " riscv64" }
79
81
}
80
82
81
83
components {
@@ -86,7 +88,8 @@ model {
86
88
' ppcle_64' ,
87
89
' aarch_64' ,
88
90
' s390_64' ,
89
- ' loongarch_64'
91
+ ' loongarch_64' ,
92
+ ' riscv64'
90
93
]) {
91
94
// If arch is not within the defined platforms, we do not specify the
92
95
// targetPlatform so that Gradle will choose what is appropriate.
Original file line number Diff line number Diff line change @@ -63,6 +63,8 @@ checkArch ()
63
63
assertEq " $format " " elf64-little" $LINENO
64
64
elif [[ " $ARCH " == loongarch_64 ]]; then
65
65
echo $format
66
+ elif [[ " $ARCH " == riscv64 ]]; then
67
+ assertEq " $format " " elf64-littleriscv" $LINENO
66
68
assertEq " $format " " elf64-loongarch" $LINENO
67
69
elif [[ " $ARCH " == ppcle_64 ]]; then
68
70
format=" $( powerpc64le-linux-gnu-objdump -f " $1 " | grep -o " file format .*$" | grep -o " [^ ]*$" ) "
@@ -121,6 +123,8 @@ checkDependencies ()
121
123
white_list=" ${white_list} \|libm\.so\.6"
122
124
elif [[ " $ARCH " == aarch_64 ]]; then
123
125
white_list=" ${white_list} \|ld-linux-aarch64\.so\.1"
126
+ elif [[ " $ARCH " == riscv64 ]]; then
127
+ white_list=" libm\.so\.6\|libc\.so\.6\|ld-linux-riscv64-lp64d\.so\.1"
124
128
fi
125
129
elif [[ " $OS " == osx ]]; then
126
130
dump_cmd=' otool -L ' " $1 " ' | fgrep dylib'
You can’t perform that action at this time.
0 commit comments