Build both .so and .a files #3426
-
Hello ADIOS2 community and Happy new year! I need to provide ADIOS2 both as dynamic and static libraries to the users. I.e. the users will decide whether to use it as a dynamic or static library depending on their needs. I know that I can control that with the My question is: I can install them at two different locations but it would be cool if both types of users use the same location to find the dependency. Gracias! |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments 4 replies
-
Hi Emilio! IMHO This is really as much a CMake question as it is an ADIOS question, though certainly the ADIOS CMake configuration is involved here. As such, I'll punt it to our Kitware team @caitlinross and @vicentebolea. |
Beta Was this translation helpful? Give feedback.
-
I don't think there's a way to build both shared and static in one step, without us making changes to the CMake files, but I don't think it should be a problem to do the two builds like you say and have them installed to the same location. |
Beta Was this translation helpful? Give feedback.
-
@emiliofernandes hola, the way to tackle these conflicting scenarios is by building separate variants as mentioned by others. See conda packaging separating openmpi and mpich (not the same, but similar solution to two incompatible dependencies). I'd keep consumption when linking with apps completely separated as well to avoid errors. Hope it helps. |
Beta Was this translation helpful? Give feedback.
-
Thank you all for the comments! |
Beta Was this translation helpful? Give feedback.
-
An alternative suggestion is to create a Cmake project that is a composite of two ADIOS2 builds using the |
Beta Was this translation helpful? Give feedback.
@emiliofernandes hola, the way to tackle these conflicting scenarios is by building separate variants as mentioned by others. See conda packaging separating openmpi and mpich (not the same, but similar solution to two incompatible dependencies). I'd keep consumption when linking with apps completely separated as well to avoid errors. Hope it helps.