enable exceptions by default when testing is enabled, so we can test for failures

This commit is contained in:
Axel Kohlmeyer 2020-07-02 09:50:15 -04:00
parent c3fe0e77c2
commit 8929ba42cd
No known key found for this signature in database
GPG Key ID: D9B44E93BF0C375A
1 changed files with 1 additions and 1 deletions

View File

@ -193,7 +193,7 @@ if(NOT ${LAMMPS_MEMALIGN} STREQUAL "0")
target_compile_definitions(lammps PRIVATE -DLAMMPS_MEMALIGN=${LAMMPS_MEMALIGN})
endif()
option(LAMMPS_EXCEPTIONS "enable the use of C++ exceptions for error messages (useful for library interface)" OFF)
option(LAMMPS_EXCEPTIONS "enable the use of C++ exceptions for error messages (useful for library interface)" ${ENABLE_TESTING})
if(LAMMPS_EXCEPTIONS)
target_compile_definitions(lammps PUBLIC -DLAMMPS_EXCEPTIONS)
endif()