mq_benchmark_client/fmq_test deps TARGET_2ND_ARCH

Specifying required dependencies exactly using
TARGET_2ND_ARCH. Before, using
LOCAL_REQUIRED_MODULES_<arch> broke down on archs
which only have 64-bit.

Bug: 7456955
Test: mq_benchmark_client/fmq_test

Change-Id: If0c08646086d4cbe7bf88e45e76e653c459b3192
diff --git a/benchmarks/Android.mk b/benchmarks/Android.mk
index 3f481cb..6b94f04 100644
--- a/benchmarks/Android.mk
+++ b/benchmarks/Android.mk
@@ -30,9 +30,11 @@
     libhidlbase \
     libhidltransport
 
-LOCAL_REQUIRED_MODULES := \
-    android.hardware.tests.msgq@1.0-impl_32 \
-    android.hardware.tests.msgq@1.0-impl
+LOCAL_REQUIRED_MODULES := android.hardware.tests.msgq@1.0-impl
+
+ifneq ($(TARGET_2ND_ARCH),)
+LOCAL_REQUIRED_MODULES += android.hardware.tests.msgq@1.0-impl$(TARGET_2ND_ARCH_MODULE_SUFFIX)
+endif
 
 LOCAL_SHARED_LIBRARIES += android.hardware.tests.msgq@1.0 libfmq
 LOCAL_MODULE := mq_benchmark_client
diff --git a/tests/Android.mk b/tests/Android.mk
index 36258d9..1d246a4 100644
--- a/tests/Android.mk
+++ b/tests/Android.mk
@@ -24,9 +24,10 @@
     android.hardware.tests.msgq@1.0-service-test    \
     hidl_test_helper
 
-LOCAL_REQUIRED_MODULES_arm64 := android.hardware.tests.msgq@1.0-service-test_32 mq_test_client_32
-LOCAL_REQUIRED_MODULES_mips64 := android.hardware.tests.msgq@1.0-service-test_32 mq_test_client_32
-LOCAL_REQUIRED_MODULES_x86_64 := android.hardware.tests.msgq@1.0-service-test_32 mq_test_client_32
+ifneq ($(TARGET_2ND_ARCH),)
+LOCAL_REQUIRED_MODULES += android.hardware.tests.msgq@1.0-service-test$(TARGET_2ND_ARCH_MODULE_SUFFIX)
+LOCAL_REQUIRED_MODULES += mq_test_client$(TARGET_2ND_ARCH_MODULE_SUFFIX)
+endif
 
 include $(BUILD_PREBUILT)