Skip to content

Commit

Permalink
Merge pull request #1818 from borglab/frank/cmake
Browse files Browse the repository at this point in the history
Update cmake
  • Loading branch information
dellaert authored Aug 29, 2024
2 parents 3aca281 + 7b96d1e commit 508b5fd
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
6 changes: 5 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
cmake_minimum_required(VERSION 3.0)
cmake_minimum_required(VERSION 3.5)
cmake_policy(SET CMP0082 NEW) # install from sub-directories immediately
cmake_policy(SET CMP0102 NEW) # set policy on advanced variables and cmake cache
cmake_policy(SET CMP0156 NEW) # new linker strategies
cmake_policy(SET CMP0167 OLD) # Don't complain about boost

# Set the version number for the library
set (GTSAM_VERSION_MAJOR 4)
Expand Down
2 changes: 1 addition & 1 deletion cmake/HandleBoost.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ endif()
set(BOOST_FIND_MINIMUM_VERSION 1.65)
set(BOOST_FIND_MINIMUM_COMPONENTS serialization system filesystem thread program_options date_time timer chrono regex)

find_package(Boost ${BOOST_FIND_MINIMUM_VERSION} COMPONENTS ${BOOST_FIND_MINIMUM_COMPONENTS})
find_package(Boost ${BOOST_FIND_MINIMUM_VERSION} COMPONENTS ${BOOST_FIND_MINIMUM_COMPONENTS} REQUIRED)

# Required components
if(NOT Boost_SERIALIZATION_LIBRARY OR NOT Boost_SYSTEM_LIBRARY OR NOT Boost_FILESYSTEM_LIBRARY OR
Expand Down
2 changes: 1 addition & 1 deletion cmake/example_cmake_find_gtsam/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# This file shows how to build and link a user project against GTSAM using CMake
###################################################################################
# To create your own project, replace "example" with the actual name of your project
cmake_minimum_required(VERSION 3.0)
cmake_minimum_required(VERSION 3.5)
project(example CXX)

# Find GTSAM, either from a local build, or from a Debian/Ubuntu package.
Expand Down

0 comments on commit 508b5fd

Please sign in to comment.