Skip to content

Commit e512900

Browse files
authored
Merge pull request #108 from geomechanics/compile/boost-build-1.89
[Compile] Fix build with boost 1.89
2 parents ba3185f + 0721857 commit e512900

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

CMakeLists.txt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,10 @@ option(USE_PETSC "Use PETSC solver library" OFF)
4848
set(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake" ${CMAKE_MODULE_PATH})
4949

5050
# Boost Archive
51-
find_package(Boost REQUIRED COMPONENTS filesystem system)
51+
find_package(Boost REQUIRED COMPONENTS filesystem)
52+
if(Boost_MAJOR_VERSION EQUAL 1 AND Boost_MINOR_VERSION LESS 69)
53+
find_package(Boost REQUIRED COMPONENTS filesystem system)
54+
endif()
5255
include_directories(${BOOST_INCLUDE_DIRS})
5356
link_libraries(${Boost_FILESYSTEM_LIBRARY} ${Boost_SYSTEM_LIBRARY})
5457

0 commit comments

Comments
 (0)