1 parent 6e9e34e commit 882796eCopy full SHA for 882796e
1 file changed
CMakeLists.txt
@@ -173,13 +173,17 @@ else()
173
set(INNOEXTRACT_HAVE_LZMA 0)
174
endif()
175
176
-find_package(Boost REQUIRED COMPONENTS
+set(BOOST_REQUIRED_COMPONENTS
177
iostreams
178
filesystem
179
date_time
180
- system
181
program_options
182
)
+find_package(Boost REQUIRED COMPONENTS ${BOOST_REQUIRED_COMPONENTS})
183
+if(Boost_MAJOR_VERSION EQUAL 1 AND Boost_MINOR_VERSION LESS 69)
184
+ list(APPEND BOOST_REQUIRED_COMPONENTS system)
185
+ find_package(Boost REQUIRED COMPONENTS ${BOOST_REQUIRED_COMPONENTS})
186
+endif()
187
list(APPEND LIBRARIES ${Boost_LIBRARIES})
188
link_directories(${Boost_LIBRARY_DIRS})
189
include_directories(SYSTEM ${Boost_INCLUDE_DIR})
0 commit comments