-
-
Notifications
You must be signed in to change notification settings - Fork 93
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
Add CXX version to precompiled header name #1171
Conversation
Note: to really have this work well, we need stan-dev/math#2922 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approving but lets way until we have the math PR in. Really hoping this works.
Great idea!!
@rok-cesnovar - CI passed for this. Is there any more testing we can do? Maybe try building with a system that has multiple versions of clang installed? |
I ran this on a system that has both clang-11 and clang-12:
Cleaning up works great as well. The only question I have is:
|
One question which might help answer that is "Can you run that same experiment against There's a related question which is "could/should we be doing more?", which I'm less confident about. If we really wanted to we could try to put the compiler patch version (e.g. 12.0.x) in there as well |
On develop it failed with:
So I agree, this is an improvement and lets merge it as is. We will see if a patch version is needed once this fix is out in the wild. |
This idea was discussed with @rok-cesnovar here: roualdes/bridgestan#151 (comment)
Submisison Checklist
./runCmdStanTests.py src/test
Summary:
This adds
CXX_MAJOR
andCXX_MINOR
to the name of the precompiled header file when it is enabled. The goal is to prevent the annoying errors from clang updates etc.Intended Effect:
Prevent clang updates from breaking PCH builds, see cmdstanpy issues
How to Verify:
Side Effects:
This could lead to several PCHs being made over time if the user doesn't run a
make clean-all
every now and then. This could cause the directory size to increase over time for an installation.Documentation:
None
Copyright and Licensing
Please list the copyright holder for the work you are submitting (this will be you or your assignee, such as a university or company):
Simons Foundation
By submitting this pull request, the copyright holder is agreeing to license the submitted work under the following licenses: