Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CMake: AMReX_BUILD_SHARED_LIBS #3013

Merged
merged 1 commit into from
Nov 9, 2022

Conversation

ax3l
Copy link
Member

@ax3l ax3l commented Nov 4, 2022

Summary

Add a new variable AMReX_BUILD_SHARED_LIBS for per-project control of shared lib builds.

This variable is more specific (AMReX project) than BUILD_SHARED_LIBS (whole build, defaults) and USE_XSDK_DEFAULTS (whole build, changed defaults).

We need this variable so we can control the AMReX library build in superbuilds without changing all other libraries we build in other projects of the superbuild.

Additional background

Checklist

The proposed changes:

  • fix a bug or incorrect behavior in AMReX
  • add new capabilities to AMReX
  • changes answers in the test suite to more than roundoff level
  • are likely to significantly affect the results of downstream AMReX users
  • include documentation in the code and/or rst files, if appropriate

@ax3l ax3l added the install label Nov 4, 2022
@ax3l ax3l requested review from sayerhs, WeiqunZhang and mic84 November 4, 2022 02:48
@ax3l ax3l force-pushed the cmake-build-shared branch 3 times, most recently from 9e67ff3 to 0c573a6 Compare November 4, 2022 02:51
Add a new variable `AMReX_BUILD_SHARED_LIBS` for per-project
control of shared lib builds.

This variable is more specific (AMReX project) than
`BUILD_SHARED_LIBS` (whole build, defaults) and
`USE_XSDK_DEFAULTS` (whole build, changed defaults).

We need this variable so we can control the AMReX library build
in superbuilds without changing all other libraries we build in
other projects of the superbuild.
@WeiqunZhang WeiqunZhang merged commit e0afc82 into AMReX-Codes:development Nov 9, 2022
@ax3l ax3l deleted the cmake-build-shared branch November 15, 2022 05:43
@ax3l
Copy link
Member Author

ax3l commented Dec 8, 2022

Ouch, forgot to update the actual add_library call. Fix in #3057

WeiqunZhang pushed a commit that referenced this pull request Dec 13, 2022
Forgot to honor the new option. All builds that did not set
`BUILD_SHARED_LIBS` were static now.

Introduced in #3013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants