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

Set MSVC_VERSION #5597

Merged
merged 1 commit into from
Dec 20, 2023
Merged

Conversation

ericmehl
Copy link
Collaborator

This explicitly sets the MSVC_VERSION we're building with. After installing MSVC 2022 to start updating our builds to the VFX Reference platform expectation I found current builds were failing because SCons defaults to the latest compiler it finds. That was attempting to mix compiler versions between newly compiled files and cached builds which it was not happy about.

Hopefully this is benign on Linux and will also formalize which compiler version we're targeting via code rather than only in documentation.

Checklist

  • I have read the contribution guidelines.
  • I have updated the documentation, if applicable.
  • I have tested my change(s) in the test suite, and added new test cases where necessary.
  • My code follows the Gaffer project's prevailing coding style and conventions.

SCons will use the latest installed MSVC version by default. We are
currently using MSVC 2019 (or for this purpose, toolset 14.2, see
https://devblogs.microsoft.com/oldnewthing/20221219-00/?p=107601 for a
valiant attempt at explaining MSVC version numbering) so building with
a newer compiler installed will fail with "unexpected compiler version"
errors. This mismatch will go away when we update to MSVC 2022, but will
almost certainly come up again, so it's worth codifying the version we
use.
@johnhaddon johnhaddon merged commit 7651c43 into GafferHQ:1.3_maintenance Dec 20, 2023
4 checks passed
@ericmehl ericmehl mentioned this pull request Feb 2, 2024
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants