Filter out renderscript libraries for riscv

As a temporary measure while renderscript is still packaged into the
generic system, filter out loading these libraries for riscv.

Bug: 206676167
Test: Verified on aosp_cf_riscv64_slim that ART does not load libRS,
even though it is present in public.libraries.txt.

Change-Id: I433039688907cac75468ae8403d94aab7cc430a8
diff --git a/libnativeloader/public_libraries.cpp b/libnativeloader/public_libraries.cpp
index fae4d76..896c5c7 100644
--- a/libnativeloader/public_libraries.cpp
+++ b/libnativeloader/public_libraries.cpp
@@ -458,6 +458,12 @@
     if (entry.bitness == ONLY_64) continue;
 #endif
 
+    // TODO(b/206676167): Remove this check when renderscript is officially removed.
+#if defined(__riscv)
+    // skip renderscript lib on riscv target
+    if (entry.soname == "libRS.so") continue;
+#endif
+
     Result<bool> ret = filter_fn(entry);
     if (!ret.ok()) {
       return ret.error();