Open alsora opened 4 years ago
Yeah, deduplication has been a long standing todo: https://github.com/ament/ament_cmake/blob/37ed0dcde921f4f0dd29e0e6cf64c55f85e193f0/ament_cmake_export_libraries/cmake/ament_cmake_export_libraries-extras.cmake.in#L137-L138
I am not sure it makes sense to still implement it. It would be far better to move forward to use more modern CMake and export targets instead which will avoid these.
Maybe adding something like
list (REMOVE_DUPLICATES rcl_LIBRARIES)
somewhere in this package is enough to fix the issue
That won't be sufficient since the order is critical and the proposed function isn't maintaining stability (at least when I tested it last a few years ago).
I am not sure it makes sense to still implement it. It would be far better to move forward to use more modern CMake and export targets instead which will avoid these.
Oh, this would be great! Is there already some roadmap for that?
Is is mentioned on the roadmap but there is no timeline / concrete plan when to work on this.
Doing the following in a CMakeFile:
Results in printing:
It would be nice to don't have so many duplicated or triplicated entities here.
Maybe adding something like
list (REMOVE_DUPLICATES rcl_LIBRARIES)
somewhere in this package is enough to fix the issue