From 8d55a1e7807d9bb5933c461cfe4d4335c89dfd36 Mon Sep 17 00:00:00 2001 From: Vitaliy Filippov Date: Thu, 29 Dec 2022 01:43:42 +0300 Subject: [PATCH] Build osd_rmw_test both with and without ISA-L --- src/CMakeLists.txt | 7 +++++++ src/osd_rmw_test.cpp | 4 ++++ 2 files changed, 11 insertions(+) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 22f57409..3676ca70 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -235,9 +235,16 @@ add_executable(osd_test osd_test.cpp rw_blocking.cpp addr_util.cpp) target_link_libraries(osd_test tcmalloc_minimal) # osd_rmw_test +# FIXME: Move to tests add_executable(osd_rmw_test osd_rmw_test.cpp allocator.cpp) target_link_libraries(osd_rmw_test Jerasure ${ISAL_LIBRARIES} tcmalloc_minimal) +if (ISAL_LIBRARIES) + add_executable(osd_rmw_test_je osd_rmw_test.cpp allocator.cpp) + target_compile_definitions(osd_rmw_test_je PUBLIC -DNO_ISAL) + target_link_libraries(osd_rmw_test_je Jerasure tcmalloc_minimal) +endif (ISAL_LIBRARIES) + # stub_uring_osd add_executable(stub_uring_osd stub_uring_osd.cpp diff --git a/src/osd_rmw_test.cpp b/src/osd_rmw_test.cpp index e9ab89a8..bc0b0043 100644 --- a/src/osd_rmw_test.cpp +++ b/src/osd_rmw_test.cpp @@ -3,6 +3,10 @@ #define RMW_DEBUG +#ifdef NO_ISAL +#undef WITH_ISAL +#endif + #include #include "osd_rmw.cpp" #include "test_pattern.h"