gradle / gradle-native

The home of Gradle's support for natively compiled languages
https://blog.gradle.org/introducing-the-new-cpp-plugins
Apache License 2.0
92 stars 8 forks source link

Investigate Visual Studio 2019 support effort #976

Closed lacasseio closed 5 years ago

lacasseio commented 5 years ago

Visual Studio 2019 IDE preview is available and support should be added to Gradle. A quick read through the release note doesn't show anything surprising and it should be pretty trivial to detect the new tool chain.

lacasseio commented 5 years ago

According to the preview image on Appveyor, Visual Studio 2019 Preview can be used without any change to Gradle by configuring the VisualCpp tool chain installDir directly:

model {
    toolChains {
        vs2019(VisualCpp) {
            installDir "C:/Program Files (x86)/Microsoft Visual Studio/2019/Preview"
        }
    }
}

Gradle could find the preview version automatically if we pass the -prerelease flag to vswhere.exe. I don't suggest making this the default. Instead, I feel that manually configuring the tool chain is perfectly acceptable due to the preview nature of the tool chain.

The next step would be to install Visual Studio 2019 preview and add code coverage to Gradle making sure we still use 2017 in the quick feedback and 2019 preview in the full coverage.

big-guy commented 5 years ago

We should find out when we expect VS2019 to be released.

lacasseio commented 5 years ago

Visual Studio 2019 is expected to be released in March or April.

ThadHouse commented 5 years ago

It was announced that 2019 would be release on April 2.

https://visualstudio.microsoft.com/vs2019-launch/

It would be nice to have this ready pretty quickly after that.

big-guy commented 5 years ago

I think what Daniel found was if VS2019 was a "final" release, we would just automatically find it and use it. Is that right @lacasseio ?

lacasseio commented 5 years ago

Yes, we will see if we can set up some sort of automation to test against the preview version. On first try, it seems to be working properly.

lacasseio commented 5 years ago

As expected, because we now use the vswhere tool, VS2019 is properly detected: https://ci.appveyor.com/project/lacasseio/gradle-vs2019/builds/27231954

lacasseio commented 5 years ago

Let's focus on installing VS2019 on CI.