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

Build installers on Windows in aspnetcore. #44828

Merged
merged 19 commits into from
Nov 25, 2024

Conversation

jkoritzinsky
Copy link
Member

Contributes to dotnet/source-build#4692

@jkoritzinsky jkoritzinsky requested review from a team as code owners November 12, 2024 22:20
@dotnet-issue-labeler dotnet-issue-labeler bot added the untriaged Request triage from a team member label Nov 12, 2024
@ViktorHofer
Copy link
Member

@jkoritzinsky there are some failures in the build

@jkoritzinsky
Copy link
Member Author

It looks like this whole folder is missing from the VMR. I'll check the source mapping and see if there's anything going on there.

@jkoritzinsky
Copy link
Member Author

So this folder is excluded from the VMR because some of the components have a non-OSS license. See dotnet/source-build#3537

@MichaelSimons do you have any suggestions on how we can re-enable this folder while still keeping our distro partners happy? We need it for the VMR build (it continues to not be necessary for source-build scenarios).

@MichaelSimons
Copy link
Member

@MichaelSimons do you have any suggestions on how we can re-enable this folder while still keeping our distro partners happy? We need it for the VMR build (it continues to not be necessary for source-build scenarios).

non-oss licensed content is a blocker from a source-build perspective. I don't see a description in the issue/pr trail (e.g. dotnet/aspnetcore#49512) that describes the purpose of license.rtf file which prompted this cloaking. @wtgodbe or @jkoritzinsky can you help me understand? If truly needed, can this be brought in via some other mechanism?

@wtgodbe
Copy link
Member

wtgodbe commented Nov 13, 2024

non-oss licensed content is a blocker from a source-build perspective. I don't see a description in the issue/pr trail (e.g. dotnet/aspnetcore#49512) that describes the purpose of license.rtf file which prompted this cloaking. @wtgodbe or @jkoritzinsky can you help me understand? If truly needed, can this be brought in via some other mechanism?

I just forwarded you & Jeremy a mail thread from last year about this

@ViktorHofer
Copy link
Member

Please forward the mail to me as well.

@MichaelSimons
Copy link
Member

@mthalman
Copy link
Member

@mthalman - would it be acceptable to add license.rtf file as an excluded non-source-build installer license similar to https://github.com/dotnet/sdk/blob/main/src/SourceBuild/content/test/Microsoft.DotNet.SourceBuild.Tests/assets/LicenseScanTests/LicenseExclusions.txt#L141?

Does the license only apply to the installer?

@MichaelSimons
Copy link
Member

@mthalman - would it be acceptable to add license.rtf file as an excluded non-source-build installer license similar to https://github.com/dotnet/sdk/blob/main/src/SourceBuild/content/test/Microsoft.DotNet.SourceBuild.Tests/assets/LicenseScanTests/LicenseExclusions.txt#L141?

Additionally, would it make sense to strip these types of licenses for distro maintainers similarly to how we strip binaries? That would help eliminate them having to "deal" with these via whatever their exclusion process is.

@mthalman
Copy link
Member

would it be acceptable to add license.rtf file as an excluded non-source-build installer license similar to https://github.com/dotnet/sdk/blob/main/src/SourceBuild/content/test/Microsoft.DotNet.SourceBuild.Tests/assets/LicenseScanTests/LicenseExclusions.txt#L141?

Temporarily, I think it makes sense to do this.

Additionally, would it make sense to strip these types of licenses for distro maintainers similarly to how we strip binaries? That would help eliminate them having to "deal" with these via whatever their exclusion process is.

Maybe? I'm concerned about the optics of that. Stripping binaries are fine because maintainers don't want them. Licenses have a real purpose though. I imagine there might be some suspicion of just yanking out licenses from the source. IMO, what would be better is to strip all the source associated with the license (in the same dynamic way as the stripping of binaries).

@MichaelSimons
Copy link
Member

IMO, what would be better is to strip all the source associated with the license (in the same dynamic way as the stripping of binaries).

I agree.

@MichaelSimons
Copy link
Member

@jkoritzinsky - to unblock, let's remove the cloak. You will need to add an exclusion to the license scan as I eluded to in #44828 (comment). I will open a follow-up issue on what the appropriate was is to handle these types of situations from a source build perspective.

@jkoritzinsky
Copy link
Member Author

I'll split out the source-mapping change to a separate PR. Looks like that's required.

@jkoritzinsky
Copy link
Member Author

Extracted the source-mapping change to #44857

@ViktorHofer
Copy link
Member

Blocked on dotnet/dotnet#110

@ViktorHofer
Copy link
Member

    D:\a\_work\1\vmr\src\aspnetcore\src\Installers\Windows\TargetingPack\TargetingPack.wixproj(72,5): error MSB3932: Failed to unzip file "D:\a\_work\1\vmr\src\aspnetcore\artifacts\installers\Release\aspnetcore-targeting-pack-10.0.0-alpha.2.24563.16-win-x64.zip" because the file does not exist or is inaccessible.
    D:\a\_work\1\vmr\src\aspnetcore\src\Installers\Windows\SharedFramework\SharedFramework.wixproj(76,5): error MSB3932: Failed to unzip file "D:\a\_work\1\vmr\src\aspnetcore\artifacts\installers\Release\aspnetcore-runtime-10.0.0-alpha.2.24563.16-win-x64.zip" because the file does not exist or is inaccessible.
    D:\a\_work\1\vmr\src\aspnetcore\src\Installers\Windows\SharedFramework\SharedFramework.wixproj(78,5): error MSB3932: Failed to unzip file "D:\a\_work\1\vmr\src\aspnetcore\artifacts\installers\Release\aspnetcore-runtime-10.0.0-alpha.2.24563.16-win-x86.zip" because the file does not exist or is inaccessible.
    D:\a\_work\1\vmr\src\aspnetcore\src\Installers\Windows\AspNetCoreModule-Setup\ANCMIISExpressV2\AncmIISExpressV2.wixproj : error MSB4057: The target "Pack" does not exist in the project.
    D:\a\_work\1\vmr\src\aspnetcore\src\Installers\Windows\AspNetCoreModule-Setup\ANCMV2\ANCMV2.wixproj : error MSB4057: The target "Pack" does not exist in the project.
        0 Warning(s)
        5 Error(s)

The problem is that the wixprojs build too soon. They need to build after everything else is finished.

ViktorHofer added a commit to dotnet/aspnetcore that referenced this pull request Nov 15, 2024
Build the Installer projects after everythign else
got built by adding a new Traversal project that
builds all P2Ps in it in parallel.

Fixes #58984
Unblocks dotnet/sdk#44828
ViktorHofer added a commit to dotnet/aspnetcore that referenced this pull request Nov 15, 2024
Build the Installer projects after everythign else
got built by adding a new Traversal project that
builds all P2Ps in it in parallel.

Fixes #58984
Unblocks dotnet/sdk#44828
ViktorHofer added a commit to dotnet/aspnetcore that referenced this pull request Nov 20, 2024
Build the Installer projects after everythign else
got built by adding a new Traversal project that
builds all P2Ps in it in parallel.

Fixes #58984
Unblocks dotnet/sdk#44828
ViktorHofer added a commit to dotnet/aspnetcore that referenced this pull request Nov 21, 2024
Build the Installer projects after everythign else
got built by adding a new Traversal project that
builds all P2Ps in it in parallel.

Fixes #58984
Unblocks dotnet/sdk#44828
@ViktorHofer
Copy link
Member

One step closer. New errors that I don't see offline:

    D:\a\_work\1\vmr\src\aspnetcore\src\Assets\Microsoft.AspNetCore.App.Internal.Assets.csproj(46,5): error : 'D:\a\_work\1\vmr\src\aspnetcore\src\Components\Web.JS\dist\Release\blazor.web.js' does not exist. Run 'npm run build' in the repo root to generate the file.
    D:\a\_work\1\vmr\src\aspnetcore\src\Components\WebView\WebView\src\Microsoft.AspNetCore.Components.WebView.csproj(68,5): error : '..\..\..\Web.JS\dist\Release\blazor.webview.js' does not exist. Falling back to checked-in copy.
    CSC : error CS1566: Error reading resource '_framework/blazor.webview.js' -- 'Could not find a part of the path 'D:\a\_work\1\vmr\src\aspnetcore\src\Components\Web.JS\dist\Release\blazor.webview.js'.' [D:\a\_work\1\vmr\src\aspnetcore\src\Components\WebView\WebView\src\Microsoft.AspNetCore.Components.WebView.csproj]

ViktorHofer added a commit to dotnet/arcade that referenced this pull request Nov 25, 2024
Enables building the aspnetcore repo with a single eng\build.cmd invocation (when using desktop msbuild).

Unblocks dotnet/sdk#44828 & dotnet/aspnetcore#58987
@ViktorHofer ViktorHofer merged commit db9961e into dotnet:main Nov 25, 2024
38 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-VMR untriaged Request triage from a team member
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants