Can I have the same submodule multiples time in the same repository?
I want to use spdlog open source submodule in my project, but my project has some personal submodules integrated. Some of those submodules also use spdlog. It is possible to use the same submodule multiple times without having conflicts?
This is how my project is structured:
MY_PROJECT
INCLUDES
SRC
LIBS
spdlog
submod_1
submod_2
includes
src
libs
spdlog
When I try to build my project, I get an error from Cmake.
The path that is not shown is the path from submod_2/libs/spdlog. From what I understand, when I build the project, both instances of spdlog are being built and the error is generated by the fact that submod_2 has already built spdlog with the same target name. The thing is that submod_2 is can also be used a standalone project and I can't remove spdlog from it.
Is there a way to make changes in my submodules and not in spdlog ?