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

[MU4] Switch to using Visual Studio 2022 #12086

Merged
merged 1 commit into from
Dec 27, 2022

Conversation

Jojo-Schmitz
Copy link
Contributor

Resolves: #12083

@Jojo-Schmitz
Copy link
Contributor Author

Jojo-Schmitz commented Jun 18, 2022

I wonder where to check whether GitHub CI used Visual Studio 2022?

Edit: apparently not:

2022-06-18T12:59:30.8265993Z "Setup VS Environment"
2022-06-18T12:59:31.3065543Z "VS_INSTALL_DIR: C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise"
2022-06-18T12:59:31.5739453Z **********************************************************************
2022-06-18T12:59:31.5739804Z ** Visual Studio 2019 Developer Command Prompt v16.11.16
2022-06-18T12:59:31.5744208Z ** Copyright (c) 2021 Microsoft Corporation

Lokking at build/cmake_wrapper.bat

echo "Setup VS Environment"
set VSWHERE="C:\Program Files (x86)\Microsoft Visual Studio\Installer\vswhere.exe"
for /f "usebackq tokens=*" %%i in (`%VSWHERE% -latest -products * -requires Microsoft.VisualStudio.Component.VC.Tools.x86.x64 -property installationPath`) do (
    set VS_INSTALL_DIR=%%i
)
echo "VS_INSTALL_DIR: %VS_INSTALL_DIR%"

seems to indicate that there's no VS 2022 found/available on GitHub CI

@cbjeukendrup
Copy link
Contributor

We use the "windows-2019" environment on CI:

runs-on: windows-2019

Which has Visual Studio 2019:
https://github.com/actions/virtual-environments/blob/main/images/win/Windows2019-Readme.md#visual-studio-enterprise-2019

@Jojo-Schmitz
Copy link
Contributor Author

Jojo-Schmitz commented Jun 18, 2022

Thanks, looks better using "windows-2022"

msvc_build.bat doesn't seem to recognize my parallel install of VS 2022, falls trough to using 2019

Edit: got it, wrong order, resp. missing check.

@Jojo-Schmitz Jojo-Schmitz force-pushed the vs2022 branch 2 times, most recently from bf1917a to dc43841 Compare June 18, 2022 16:19
@wizofaus
Copy link
Contributor

Is this going to force all contributors who use MSVC to upgrade to 2022? I agree we should encourage it and enforce say from a certain date, but just merging it and doing so with no warning seems a bit unfair...

@Jojo-Schmitz
Copy link
Contributor Author

Jojo-Schmitz commented Jun 19, 2022

As far as I can tell MSVC 2019 still works with that PR. msvc_build.bat uses VS 2022 if found, if not checks for VS 2019, if not found either uses VS 2017, while build.cmake defaults to VS 2022, but allows overriding with VS 2019. But better test it and report back ;-)
VS 2022 is available and stable since a while, hanging on to a 3 years old version shouldn't be the way forward, really.

@wizofaus
Copy link
Contributor

VS 2017 hasn't worked for a long time! But sure, I'll try it out tomorrow.
Are there any VS-2022-specific features that are likely to be useful in developing MuseScore?

@Jojo-Schmitz
Copy link
Contributor Author

Jojo-Schmitz commented Jun 19, 2022

VS 2017 most likely is a historical leftover in that script, let's remove it (we now do need a C++2017 compiler for master, so indeed VS 2017 will no longer work). Not sure about any VS 2022 specific features we'd benefit from, other than newer compilers.

Found in the web: "One of the main improvements in the new release addresses a recurring complaint about VS 2019—namely, its intense demand on memory.", Others are improved code-completion functionality, more powerful debugging capabilities, improved programming interface, improved accessibility, improved support for the latest build of C++ (C++2020), improved Windows app development (hot reload)

@cbjeukendrup cbjeukendrup merged commit 2ce8138 into musescore:master Dec 27, 2022
@Jojo-Schmitz Jojo-Schmitz deleted the vs2022 branch January 8, 2023 22:09
Jojo-Schmitz added a commit to Jojo-Schmitz/MuseScore that referenced this pull request Jan 12, 2023
Jojo-Schmitz added a commit to Jojo-Schmitz/MuseScore that referenced this pull request Mar 5, 2023
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.

4 participants