Make libvixl dependency optional since it only exists on some architectures.

Bug: 124293228
Test: art/build/apex/runtests.sh (on cuttlefish)
Test: m droid (on aosp_x86_64)
Change-Id: Id167f7dbb2e723593890979aece7ab602b4f941d
diff --git a/build/apex/art_apex_test.py b/build/apex/art_apex_test.py
index f3b95e2..5e9e08b 100755
--- a/build/apex/art_apex_test.py
+++ b/build/apex/art_apex_test.py
@@ -275,6 +275,9 @@
   def check_library(self, filename):
     raise NotImplementedError
 
+  def check_optional_library(self, filename):
+    raise NotImplementedError
+
   def check_first_library(self, filename):
     raise NotImplementedError
 
@@ -296,6 +299,9 @@
     # the precision of this test?
     self.check_file('lib/%s' % filename)
 
+  def check_optional_library(self, filename):
+    self.ignore_superfluous_path('lib/%s' % filename)
+
   def check_first_library(self, filename):
     self.check_library(filename)
 
@@ -317,6 +323,9 @@
     # the precision of this test?
     self.check_file('lib64/%s' % filename)
 
+  def check_optional_library(self, filename):
+    self.ignore_superfluous_path('lib64/%s' % filename)
+
   def check_first_library(self, filename):
     self.check_library(filename)
 
@@ -341,6 +350,10 @@
     self.check_file('lib/%s' % filename)
     self.check_file('lib64/%s' % filename)
 
+  def check_optional_library(self, filename):
+    self.ignore_superfluous_path('lib/%s' % filename)
+    self.ignore_superfluous_path('lib64/%s' % filename)
+
   def check_first_library(self, filename):
     self.check_file('lib64/%s' % filename)
 
@@ -410,7 +423,7 @@
     self._checker.check_library('liblzma.so')
     self._checker.check_library('libsigchain.so')
     self._checker.check_library('libunwindstack.so')
-    self._checker.check_library('libvixl.so')
+    self._checker.check_optional_library('libvixl.so')  # Only on ARM/ARM64
 
     # TODO(b/124293228): Figure out why we get this.
     self._checker.check_library('libcutils.so')
@@ -555,7 +568,7 @@
     # double_loadable:true, cf. go/double_loadable). Also, like in the release
     # package we need to look out for dependencies that should go through
     # exported library stubs (until b/128708192 is fixed).
-    self._checker.check_library('libvixld.so')
+    self._checker.check_optional_library('libvixld.so')  # Only on ARM/ARM64
 
 
 class NoSuperfluousBinariesChecker: