-
-
Notifications
You must be signed in to change notification settings - Fork 278
Build is unsupported by default #801
Copy link
Copy link
Closed
Labels
bugpreCICE does not behave the way we want and we should look into it (and fix it if possible)preCICE does not behave the way we want and we should look into it (and fix it if possible)usabilityThis issue will make preCICE easier for non-expert usersThis issue will make preCICE easier for non-expert users
Milestone
Description
Please describe the problem you are trying to solve.
When configuring preCICE, the resulting library will be static by default.
We currently do not support using preCICE as a static library as both the CMake config and the pkg-config files do not support the static library. ( The current CMake config is missing depending targets)
Thus our build system is unsupported by default.
Describe the solution you propose.
There are many solutions to this problem (ranked by workload):
- Always build a shared library and forget about static libraries altogether.
This obviously prevents to use preCICE as a static library, which is unreasonable. - Set
BUILD_SHARED_LIBStoONif not explicitly specified. PR: Set BUILD_SHARED_LIBS to True by default #796
This will change a CMake default and may surprise users. This could be regarded as a breaking change. - Always build both shared and static libraries and only directly support the shared case.
Requires to build preCICE internally as an object library first to prevent recompilation. This is required for hidden symbol visibility, so we should do it at some point anyhow. - Extend the CMake script to fully support static libraries.
This requires to export some internal dependencies and requires to propagate the dependencies to the dependant.
Additional context
- The solverdummy tests currently fail when building static. Due to the same issue as Install missing dependencies with CMake #716 .
- Static pkg-config pkg-config: Add Libs.private #313
- User running into problems with static CMake Install missing dependencies with CMake #716
- The default for xSDK is to build as a shared library. However, this requirement will be shifted from CMake to Spack in the future.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugpreCICE does not behave the way we want and we should look into it (and fix it if possible)preCICE does not behave the way we want and we should look into it (and fix it if possible)usabilityThis issue will make preCICE easier for non-expert usersThis issue will make preCICE easier for non-expert users