Hi Pierre-Yves,
I've heard of it from ICRA2019. It could be indeed interesting to add to repo. I was looking how they do that, currently they do a fork on the original projects and add a LIBRAYNAME_library.cpp file at the source. For example, I took a look at the orbslam2 fork here:
https://github.com/pamela-project/ORB_SLAM2/blob/master/orbslam2_library.cppIt could be possible to add a rtabmap_library.cpp file to official rtabmap repo, though I would like to call it rtabmap_slambench.cpp instead. I don't know yet how to pass cmake options to rtabmap when building from slambench (like don't build tools/examples/ui from rtabmap, just build librtabmap_core.so). One way could be that if I detect that SLAMBENCH_INCLUDE_DIRS is set, I disable everything else and build only librtabmap_core.so and rtabmap_slambench.cpp.
I don't have a lot of free time in the next week, but I'll try to keep it in mind!
cheers,
Mathieu