- edited description
I recently ran into an issue where trying to import gtsam in python gave:
ImportError: libgtsam.so.4: cannot open shared object file: No such file or directory
I eventually found that this was because the shared library at gtsam/build/install/gtsam/libgtsam.so*
was being used when loading into python. I had expected the gtsam.so
in gtsam/build/cython/gtsam
to be stand-alone and therefore thought that doing make install
with -DCMAKE_INSTALL_PREFIX=./install
didn't affect anything system-wide. However after deleting gtsam/build/install/gtsam
I was no longer able to load the python wrapper (with the above error).
The instructions I have given elsewhere to use -DCMAKE_INSTALL_PREFIX=./install
was based on the assumption that no system-wide changes to the PATH or anything else was taking place.
would there be a way to have a 'portable' install where everything that the python wrapper needs can be kept in cython/gtsam
. that way it would be easier to keep track of what versions of GTSAM (built against what libraries, eg MKL vs no MKL) are being used at any given moment.