aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests
diff options
context:
space:
mode:
authorMerry <[email protected]>2023-01-06 14:27:06 +0000
committerMerry <[email protected]>2023-01-06 14:27:06 +0000
commit6b41b5be07d51d8b1e2103782bb28d4873a3ebfa (patch)
tree929e8fe32f0e68657fc1fea9e392afccfe2e66a4 /tests
parentc72ee5473b5b11ac110e86cc9544cab5159ccce8 (diff)
downloaddynarmic-6b41b5be07d51d8b1e2103782bb28d4873a3ebfa.tar.gz
dynarmic-6b41b5be07d51d8b1e2103782bb28d4873a3ebfa.zip
CMakeLists: Support multi-architecture builds
Diffstat (limited to 'tests')
-rw-r--r--tests/CMakeLists.txt8
1 files changed, 5 insertions, 3 deletions
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
index 20f96588..e52f4da4 100644
--- a/tests/CMakeLists.txt
+++ b/tests/CMakeLists.txt
@@ -1,3 +1,5 @@
+include(TargetArchitectureSpecificSources)
+
add_executable(dynarmic_tests
fp/FPToFixed.cpp
fp/FPValue.cpp
@@ -55,14 +57,14 @@ if (DYNARMIC_TESTS_USE_UNICORN)
endif()
endif()
-if (ARCHITECTURE STREQUAL "x86_64")
+if ("x86_64" IN_LIST ARCHITECTURE)
target_link_libraries(dynarmic_tests PRIVATE xbyak::xbyak)
- target_sources(dynarmic_tests PRIVATE
+ target_architecture_specific_sources(dynarmic_tests "x86_64"
x64_cpu_info.cpp
)
- if (NOT MSVC)
+ if (NOT MSVC AND NOT DYNARMIC_MULTIARCH_BUILD)
target_sources(dynarmic_tests PRIVATE
rsqrt_test.cpp
rsqrt_test_fn.s