Add riscv64-linux-android support
Add barebones riscv64-linux-android support. This should be enough
to add riscv64-specific entries to Android.bp files, but can't
actually compile anything until there are riscv64 toolchains.
Test: arch_test.go
Change-Id: I0dcc7e797d9352dd38243be908a7f19004ff3db1
diff --git a/bp2build/cc_library_static_conversion_test.go b/bp2build/cc_library_static_conversion_test.go
index e3ea9a0..b47d1f1 100644
--- a/bp2build/cc_library_static_conversion_test.go
+++ b/bp2build/cc_library_static_conversion_test.go
@@ -836,6 +836,10 @@
"not-for-lib32.c",
"for-lib64.c",
],
+ "//build/bazel/platforms/arch:riscv64": [
+ "not-for-lib32.c",
+ "for-lib64.c",
+ ],
"//build/bazel/platforms/arch:x86": [
"not-for-lib64.c",
"for-lib32.c",
@@ -867,6 +871,7 @@
"for-lib64.c": "",
"not-for-arm.c": "",
"not-for-arm64.c": "",
+ "not-for-riscv64.c": "",
"not-for-x86.c": "",
"not-for-x86_64.c": "",
"not-for-lib32.c": "",
@@ -881,6 +886,7 @@
arch: {
arm: { srcs: ["for-arm.c"], exclude_srcs: ["not-for-arm.c"] },
arm64: { srcs: ["for-arm64.c"], exclude_srcs: ["not-for-arm64.c"] },
+ riscv64: { srcs: ["for-riscv64.c"], exclude_srcs: ["not-for-riscv64.c"] },
x86: { srcs: ["for-x86.c"], exclude_srcs: ["not-for-x86.c"] },
x86_64: { srcs: ["for-x86_64.c"], exclude_srcs: ["not-for-x86_64.c"] },
},
@@ -896,6 +902,7 @@
"//build/bazel/platforms/arch:arm": [
"not-for-arm64.c",
"not-for-lib64.c",
+ "not-for-riscv64.c",
"not-for-x86.c",
"not-for-x86_64.c",
"for-arm.c",
@@ -904,15 +911,26 @@
"//build/bazel/platforms/arch:arm64": [
"not-for-arm.c",
"not-for-lib32.c",
+ "not-for-riscv64.c",
"not-for-x86.c",
"not-for-x86_64.c",
"for-arm64.c",
"for-lib64.c",
],
+ "//build/bazel/platforms/arch:riscv64": [
+ "not-for-arm.c",
+ "not-for-arm64.c",
+ "not-for-lib32.c",
+ "not-for-x86.c",
+ "not-for-x86_64.c",
+ "for-riscv64.c",
+ "for-lib64.c",
+ ],
"//build/bazel/platforms/arch:x86": [
"not-for-arm.c",
"not-for-arm64.c",
"not-for-lib64.c",
+ "not-for-riscv64.c",
"not-for-x86_64.c",
"for-x86.c",
"for-lib32.c",
@@ -921,6 +939,7 @@
"not-for-arm.c",
"not-for-arm64.c",
"not-for-lib32.c",
+ "not-for-riscv64.c",
"not-for-x86.c",
"for-x86_64.c",
"for-lib64.c",
@@ -930,6 +949,7 @@
"not-for-arm64.c",
"not-for-lib32.c",
"not-for-lib64.c",
+ "not-for-riscv64.c",
"not-for-x86.c",
"not-for-x86_64.c",
],