Skip to content

[release/v7.6.6] Produce satellite assemblies in Windows release build and properly remove them when they are not required - #27943

Merged
Dongbo Wang (daxian-dbw) merged 2 commits into
PowerShell:release/v7.6.6from
daxian-dbw:7.62
Sep 1, 2026
Merged

[release/v7.6.6] Produce satellite assemblies in Windows release build and properly remove them when they are not required#27943
Dongbo Wang (daxian-dbw) merged 2 commits into
PowerShell:release/v7.6.6from
daxian-dbw:7.62

Conversation

@daxian-dbw

@daxian-dbw Dongbo Wang (daxian-dbw) commented Sep 1, 2026

Copy link
Copy Markdown
Member

Backport of #27938 to release/v7.6.6

Triggered by Dongbo Wang (@daxian-dbw) on behalf of Dongbo Wang (@daxian-dbw)

Original CL Label: CL-BuildPackaging

/cc @PowerShell/powershell-maintainers

Impact

REQUIRED: Choose either Tooling Impact or Customer Impact (or both). At least one checkbox must be selected.

Tooling Impact

  • Required tooling change
  • Optional tooling change (include reasoning)
  1. Setting DOTNET_SYSTEM_GLOBALIZATION_INVARIANT to 0 in Windows builds allow .NET SDK to produce satellite assemblies for PowerShell.
  2. Also updated the build.psm1 to remove PowerShell satellite assemblies properly when they are not required.

Customer Impact

  • Customer reported
  • Found internally

Regression

REQUIRED: Check exactly one box.

  • Yes
  • No

This is not a regression.

Testing

Cherry-picked cleanly with no conflicts. Original PR added tests validating LocProject.json content stays in sync with actual resource files in the repo.

Risk

REQUIRED: Check exactly one box.

  • High
  • Medium
  • Low

Copilot AI lite review requested due to automatic review settings September 1, 2026 18:01
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

@daxian-dbw Dongbo Wang (daxian-dbw) added the CL-BuildPackaging Indicates that a PR should be marked as a build or packaging change in the Change Log label Sep 1, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR (a backport to release/v7.6.6) adjusts the Windows build/publish flow to better control satellite assembly output and configures the Windows hosted pipeline to ensure .NET has access to culture data needed for localization-related build steps.

Changes:

  • Updates build.psm1 to conditionally restrict satellite resource languages during publish and remove resulting satellite assembly directories when they aren’t required.
  • Sets DOTNET_SYSTEM_GLOBALIZATION_INVARIANT=0 in the Windows hosted build template to ensure cultural data is available during the build.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
build.psm1 Adds conditional satellite-assembly cleanup and tweaks publish properties for satellite resource languages.
.pipelines/templates/windows-hosted-build.yml Ensures .NET globalization isn’t forced into invariant mode on Windows hosted builds.
Suppressed comments (1)

build.psm1:767

  • The comment about -SMAOnly is now inaccurate because the new satellite-assembly cleanup block runs before the if ($SMAOnly) { return } early-exit. Either move the cleanup below the -SMAOnly return, or update this comment so it matches the current control flow.
    Write-LogGroupEnd -Title "Build PowerShell"

    # No extra post-building task will run if '-SMAOnly' is specified, because its purpose is for a quick update of S.M.A.dll after full build.
    if ($SMAOnly) {
        return

💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.

Comment thread build.psm1
Comment thread build.psm1
Comment thread .pipelines/templates/windows-hosted-build.yml
@daxian-dbw
Dongbo Wang (daxian-dbw) merged commit 899d8c9 into PowerShell:release/v7.6.6 Sep 1, 2026
41 of 42 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CL-BuildPackaging Indicates that a PR should be marked as a build or packaging change in the Change Log

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants