summaryrefslogtreecommitdiffstats
path: root/tests/Android.mk
diff options
context:
space:
mode:
authorTao Bao <tbao@google.com>2016-10-26 02:07:09 +0200
committerandroid-build-merger <android-build-merger@google.com>2016-10-26 02:07:09 +0200
commiteb9905b851f9da2427e62b62b3abe788c6273c5d (patch)
tree01a0d3c321d48b0a109ace335bb2911d7d8dc7b1 /tests/Android.mk
parentMerge "applypatch: Fix the bug when constructing VAL_BLOB." am: e1991428ba am: 565273839e am: 6d9f8993b0 (diff)
parentMerge "tests: Generate testdata for 2nd arch." am: 16e88679dc am: 8f9672c0db (diff)
downloadandroid_bootable_recovery-eb9905b851f9da2427e62b62b3abe788c6273c5d.tar
android_bootable_recovery-eb9905b851f9da2427e62b62b3abe788c6273c5d.tar.gz
android_bootable_recovery-eb9905b851f9da2427e62b62b3abe788c6273c5d.tar.bz2
android_bootable_recovery-eb9905b851f9da2427e62b62b3abe788c6273c5d.tar.lz
android_bootable_recovery-eb9905b851f9da2427e62b62b3abe788c6273c5d.tar.xz
android_bootable_recovery-eb9905b851f9da2427e62b62b3abe788c6273c5d.tar.zst
android_bootable_recovery-eb9905b851f9da2427e62b62b3abe788c6273c5d.zip
Diffstat (limited to 'tests/Android.mk')
-rw-r--r--tests/Android.mk13
1 files changed, 12 insertions, 1 deletions
diff --git a/tests/Android.mk b/tests/Android.mk
index abe6b6d68..3d05386b0 100644
--- a/tests/Android.mk
+++ b/tests/Android.mk
@@ -84,13 +84,24 @@ LOCAL_STATIC_LIBRARIES := \
libtune2fs \
$(tune2fs_static_libraries)
-testdata_out_path := $(TARGET_OUT_DATA_NATIVE_TESTS)/recovery
testdata_files := $(call find-subdir-files, testdata/*)
+testdata_out_path := $(TARGET_OUT_DATA_NATIVE_TESTS)/recovery
GEN := $(addprefix $(testdata_out_path)/, $(testdata_files))
$(GEN): PRIVATE_PATH := $(LOCAL_PATH)
$(GEN): PRIVATE_CUSTOM_TOOL = cp $< $@
$(GEN): $(testdata_out_path)/% : $(LOCAL_PATH)/%
$(transform-generated-source)
LOCAL_GENERATED_SOURCES += $(GEN)
+
+ifdef TARGET_2ND_ARCH
+testdata_out_path_2nd_arch := $($(TARGET_2ND_ARCH_VAR_PREFIX)TARGET_OUT_DATA_NATIVE_TESTS)/recovery
+GEN_2ND_ARCH := $(addprefix $(testdata_out_path_2nd_arch)/, $(testdata_files))
+$(GEN_2ND_ARCH): PRIVATE_PATH := $(LOCAL_PATH)
+$(GEN_2ND_ARCH): PRIVATE_CUSTOM_TOOL = cp $< $@
+$(GEN_2ND_ARCH): $(testdata_out_path_2nd_arch)/% : $(LOCAL_PATH)/%
+ $(transform-generated-source)
+LOCAL_GENERATED_SOURCES += $(GEN_2ND_ARCH)
+endif # TARGET_2ND_ARCH
+
include $(BUILD_NATIVE_TEST)