Search code examples
c++cmakegurobidrake

Drake cmake Could NOT find Gurobi


I use ubuntu 20.04 and I trying install Drake software. I have got error while making with cmake cmake -DWITH_GUROBI=ON -DWITH_MOSEK=ON ../drake:

CMake Error at cmake/modules/FindGurobi.cmake:13 (file):
  file STRINGS file
  "/home/dmitriy/git/drake/Gurobi_INCLUDE_DIR-NOTFOUND/gurobi_c.h" cannot be
  read.
Call Stack (most recent call first):
  CMakeLists.txt:450 (find_package)


CMake Error at /usr/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:146 (message):
  Could NOT find Gurobi: Found unsuitable version ".;.", but required is
  exact version "9.5.1" (found Gurobi_INCLUDE_DIR-NOTFOUND)
Call Stack (most recent call first):
  /usr/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:391 (_FPHSA_FAILURE_MESSAGE)
  cmake/modules/FindGurobi.cmake:52 (find_package_handle_standard_args)
  CMakeLists.txt:450 (find_package)


-- Configuring incomplete, errors occurred!
See also "/home/dmitriy/git/drake-build/CMakeFiles/CMakeOutput.log".

Solution

  • I installed Gurobi and error dosappeared.