also make CMake scripts in unittest tree consistent

This commit is contained in:
Axel Kohlmeyer
2021-05-25 15:10:18 -04:00
parent bc063f2e88
commit 58625d800e
2 changed files with 5 additions and 5 deletions

View File

@ -1,6 +1,6 @@
# build LAMMPS plugins, but not on Windows # build LAMMPS plugins, but not on Windows
if(NOT ${CMAKE_SYSTEM_NAME} STREQUAL "Windows" AND PKG_PLUGIN) if((NOT (CMAKE_SYSTEM_NAME STREQUAL "Windows")) AND PKG_PLUGIN)
ExternalProject_Add(plugins ExternalProject_Add(plugins
SOURCE_DIR "${LAMMPS_DIR}/examples/plugins" SOURCE_DIR "${LAMMPS_DIR}/examples/plugins"
BINARY_DIR ${CMAKE_BINARY_DIR}/build-plugins BINARY_DIR ${CMAKE_BINARY_DIR}/build-plugins

View File

@ -33,7 +33,7 @@ else()
target_link_libraries(style_tests PUBLIC mpi_stubs) target_link_libraries(style_tests PUBLIC mpi_stubs)
endif() endif()
# propagate sanitizer options to test tools # propagate sanitizer options to test tools
if (ENABLE_SANITIZER AND (NOT ENABLE_SANITIZER STREQUAL "none")) if(ENABLE_SANITIZER AND (NOT (ENABLE_SANITIZER STREQUAL "none")))
if(CMAKE_VERSION VERSION_GREATER_EQUAL 3.13) if(CMAKE_VERSION VERSION_GREATER_EQUAL 3.13)
target_compile_options(style_tests PUBLIC -fsanitize=${ENABLE_SANITIZER}) target_compile_options(style_tests PUBLIC -fsanitize=${ENABLE_SANITIZER})
target_link_options(style_tests PUBLIC -fsanitize=${ENABLE_SANITIZER}) target_link_options(style_tests PUBLIC -fsanitize=${ENABLE_SANITIZER})