I installed Gurobi 5.6.3 as explained in the doc: extract it, then set GUROBI_HOME, then build/install Numberjack. I also had to set LD_LIBRARY_PATH at runtime so that the lib is found:
GUROBI_HOME="$HOME/tmp/gurobi/gurobi563/linux64"
LD_LIBRARY_PATH=$GUROBI_HOME/lib
However, when trying to solve a problem with Numberjack using Gurobi, I still get
ImportError: /usr/local/lib/python3.5/dist-packages/_Gurobi.cpython-35m-x86_64-linux-gnu.so: undefined symbol: _ZNK12GRBException10getMessageB5cxx11Ev
Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/Numberjack/solvers/Gurobi.py", line 18, in swig_import_helper
return importlib.import_module(mname)
File "/usr/lib/python3.5/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 986, in _gcd_import
File "<frozen importlib._bootstrap>", line 969, in _find_and_load
File "<frozen importlib._bootstrap>", line 956, in _find_and_load_unlocked
ImportError: No module named 'Numberjack.solvers._Gurobi'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/Numberjack/__init__.py", line 910, in load
lib = __import__(solverstring, fromlist=[solverspkg])
File "/usr/local/lib/python3.5/dist-packages/Numberjack/solvers/Gurobi.py", line 21, in <module>
_Gurobi = swig_import_helper()
File "/usr/local/lib/python3.5/dist-packages/Numberjack/solvers/Gurobi.py", line 20, in swig_import_helper
return importlib.import_module('_Gurobi')
File "/usr/lib/python3.5/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
ImportError: /usr/local/lib/python3.5/dist-packages/_Gurobi.cpython-35m-x86_64-linux-gnu.so: undefined symbol: _ZNK12GRBException10getMessageB5cxx11Ev
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "optimalsolver2.py", line 312, in <module>
solve(param)
File "optimalsolver2.py", line 281, in solve
solver = model.load(param['solver'])
File "/usr/local/lib/python3.5/dist-packages/Numberjack/__init__.py", line 915, in load
solvername)
ImportError: ERROR: Failed during import, wrong module name? (Gurobi)
I installed Gurobi 5.6.3 as explained in the doc: extract it, then set GUROBI_HOME, then build/install Numberjack. I also had to set LD_LIBRARY_PATH at runtime so that the lib is found:
However, when trying to solve a problem with Numberjack using Gurobi, I still get
Full error log: