make sure we compile and link against mpi_stubs when BUILD_MPI is disabled
This commit is contained in:
@ -8,7 +8,12 @@ endif()
|
||||
set(TEST_INPUT_FOLDER ${CMAKE_CURRENT_SOURCE_DIR}/tests)
|
||||
add_library(style_tests STATIC yaml_writer.cpp error_stats.cpp test_config_reader.cpp test_main.cpp)
|
||||
target_compile_definitions(style_tests PRIVATE TEST_INPUT_FOLDER=${TEST_INPUT_FOLDER})
|
||||
target_link_libraries(style_tests PUBLIC GTest::GTest GTest::GMock MPI::MPI_CXX Yaml::Yaml)
|
||||
target_link_libraries(style_tests PUBLIC GTest::GTest GTest::GMock Yaml::Yaml)
|
||||
if(BUILD_MPI)
|
||||
target_link_libraries(style_tests PUBLIC MPI::MPI_CXX)
|
||||
else()
|
||||
target_link_libraries(style_tests PUBLIC mpi_stubs)
|
||||
endif()
|
||||
|
||||
# pair style tester
|
||||
add_executable(pair_style pair_style.cpp)
|
||||
|
||||
Reference in New Issue
Block a user