File tree Expand file tree Collapse file tree
applications/TrilinosApplication Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -116,6 +116,18 @@ ENDIF(CMAKE_UNITY_BUILD MATCHES ON)
116116
117117# Exclude from unity build
118118set_source_files_properties (${CMAKE_CURRENT_SOURCE_DIR} /custom_utilities/linear_solver_trilinos.cpp PROPERTIES SKIP_UNITY_BUILD_INCLUSION TRUE )
119+ # The experimental (Tpetra) files include MatrixMarket_Tpetra.hpp → mmio_Tpetra.h, which shares the
120+ # same MM_IO_H include guard as Kratos' mmio.h but declares mm_read_mtx_crd_size with size_t*
121+ # instead of int*. When merged into a unity unit with Epetra-based files that have already pulled
122+ # in Kratos' mmio.h, the guard prevents mmio_Tpetra.h from being re-included, leaving the wrong
123+ # signature in scope. Compiling the experimental files as separate translation units ensures the
124+ # correct include order and avoids free-function name conflicts with the Epetra equivalents.
125+ set_source_files_properties (${CMAKE_CURRENT_SOURCE_DIR} /custom_python/add_trilinos_space_experimental_to_python.cpp PROPERTIES SKIP_UNITY_BUILD_INCLUSION TRUE )
126+ if (${KRATOS_BUILD_TESTING} MATCHES ON )
127+ set_source_files_properties (${CMAKE_CURRENT_SOURCE_DIR} /tests/cpp_tests/test_trilinos_space_experimental.cpp PROPERTIES SKIP_UNITY_BUILD_INCLUSION TRUE )
128+ set_source_files_properties (${CMAKE_CURRENT_SOURCE_DIR} /tests/cpp_tests/trilinos_cpp_test_experimental_utilities.cpp PROPERTIES SKIP_UNITY_BUILD_INCLUSION TRUE )
129+ set_source_files_properties (${CMAKE_CURRENT_SOURCE_DIR} /tests/cpp_tests/utilities/test_cpp_test_utilities_experimental.cpp PROPERTIES SKIP_UNITY_BUILD_INCLUSION TRUE )
130+ endif ()
119131
120132# Changing the .dll suffix to .pyd
121133if (${CMAKE_SYSTEM_NAME} MATCHES "Windows" )
You can’t perform that action at this time.
0 commit comments