Closed matheecs closed 1 year ago
Hello @matheecs ! I think it is useful to separate the two fixes: the second one (add array
include) is indeed a fix.
The first one is a bit tricky. Basically, at the moment meshcat-cpp
is meant to be used when installed, and only linking the installed library. It is not meant to work by linking the library in the build directory. This is because some resources are found by looking at the appropriate relative location w.r.t. the location of the library, via reloc-cpp. Your change make the library work when it is used from the build directory, but it breaks the use of the library when installed, so it is not desirable. Two possible fixes are either:
<install_prefix>/share/meshcat-cpp/misc
also in <build_directory>/share/meshcat-cpp/misc
. In this way, also the build library will work fine, as it will look in ../share/meshcat-cpp/misc
and find the required file. This is relativly simple, as it probably can be done by adding a few configure_file
in the CMake scriptfyi @GiulioRomualdi
Fix to find correct
misc
directory andmeshcat_example
. Now, run the example by