Skip to content

Commit

Permalink
If not found, compile ortools by source, with more options
Browse files Browse the repository at this point in the history
  • Loading branch information
Gonzalo-Mier committed May 2, 2024
1 parent 0c2132a commit 912de2b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
8 changes: 6 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ option(BUILD_TESTS "Build tests" ON)
option(BUILD_PYTHON "Build Python SWIG module" OFF)
option(BUILD_DOC "Build Documentation" OFF)
option(BUILD_SHARED_LIBS "Build shared library(.so)" ON)
option(USE_ORTOOLS_RELEASE_IF_NOT_FOUND "If or-tools is not found, use the release" ON)
option(USE_ORTOOLS_RELEASE_IF_NOT_FOUND "If or-tools is not found, use the release" OFF)



Expand Down Expand Up @@ -133,7 +133,11 @@ if(NOT ortools_vendor_FOUND)
FetchContent_Declare(ortools FETCHCONTENT_UPDATES_DISCONNECTED
GIT_REPOSITORY https://github.com/google/or-tools.git
GIT_TAG v9.9
CMAKE_ARGS -DBUILD_DEPS=ON
CMAKE_ARGS
"-DCMAKE_CXX_FLAGS=${CMAKE_CXX_FLAGS}"
-DBUILD_DEPS:BOOL=ON
-DBUILD_SAMPLES:BOOL=OFF
-DBUILD_EXAMPLES:BOOL=OFF
)
FetchContent_MakeAvailable(ortools)

Expand Down
2 changes: 0 additions & 2 deletions package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,6 @@
<depend>python3</depend>
<depend>python3-dev</depend>
<depend>tinyxml2</depend>
<depend>libabsl-dev</depend>
<depend>protobuf-dev</depend>
<exec_depend>python3-matplotlib</exec_depend>
<exec_depend>python3-tk</exec_depend>
<test_depend>gtest</test_depend>
Expand Down

0 comments on commit 912de2b

Please sign in to comment.