File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -107,7 +107,7 @@ target_include_directories(samurai INTERFACE "$<BUILD_INTERFACE:${CMAKE_CURRENT_
107107 "$<INSTALL_INTERFACE :${CMAKE_INSTALL_INCLUDEDIR} >" )
108108
109109# Find dependencies:
110- set (DEPENDENCIES_CONFIGURED HighFive pugixml fmt CLI11)
110+ set (DEPENDENCIES_CONFIGURED xtensor HighFive pugixml fmt CLI11)
111111
112112if (${ENABLE_VCPKG} )
113113 list (APPEND DEPENDENCIES_CONFIGURED hdf5)
@@ -120,32 +120,21 @@ foreach(DEPENDENCY ${DEPENDENCIES_CONFIGURED})
120120 find_package (${DEPENDENCY} CONFIG REQUIRED )
121121endforeach ()
122122
123+ if (xtensor_VERSION VERSION_LESS_EQUAL "0.25.0" )
124+ message (FATAL_ERROR "xtensor version ${xtensor_VERSION} is too old. Minimum allowed version is 0.26." )
125+ endif ()
126+
123127# Link dependencies:
124128target_link_system_libraries (
125129 samurai
126130 INTERFACE
131+ xtensor
127132 HighFive
128133 pugixml::pugixml
129134 fmt::fmt
130135 CLI11::CLI11
131136)
132137
133- if (SAMURAI_FIELD_CONTAINER MATCHES xtensor)
134- message (STATUS "Using xtensor as field container" )
135- list (APPEND DEPENDENCIES_CONFIGURED xtensor)
136- find_package (xtensor CONFIG REQUIRED )
137-
138- if (xtensor_VERSION VERSION_LESS_EQUAL "0.25.0" )
139- message (FATAL_ERROR "xtensor version ${xtensor_VERSION} is too old. Minimum allowed version is 0.26." )
140- endif ()
141-
142- target_link_system_libraries (
143- samurai
144- INTERFACE
145- xtensor
146- )
147-
148- endif ()
149138if (SAMURAI_FIELD_CONTAINER MATCHES eigen3)
150139 message (STATUS "Using Eigen3 as field container" )
151140endif ()
You can’t perform that action at this time.
0 commit comments