From 06526cac0c8a7e1a63fd187ce495e3b88522adff Mon Sep 17 00:00:00 2001 From: "Dustin L. Howett" Date: Tue, 4 Apr 2023 16:11:12 -0500 Subject: [PATCH] Remove our dependency on any CRT--AppX or forwarders (#15097) The upgrade to Microsoft.UI.Xaml 2.8 was the last piece we needed to break our dependency on the App CRT *and* any CRT whatsoever. --- build/scripts/Test-WindowsTerminalPackage.ps1 | 25 ++++++++++--------- dep/nuget/packages.config | 1 - .../WindowExe/WindowExe.vcxproj | 2 -- .../WindowExe/packages.config | 1 - .../CascadiaPackage/CascadiaPackage.wapproj | 4 +++ .../WindowsTerminal/WindowsTerminal.vcxproj | 1 - src/common.nugetversions.targets | 6 ----- 7 files changed, 17 insertions(+), 23 deletions(-) diff --git a/build/scripts/Test-WindowsTerminalPackage.ps1 b/build/scripts/Test-WindowsTerminalPackage.ps1 index a33329c26c..b405d98c21 100644 --- a/build/scripts/Test-WindowsTerminalPackage.ps1 +++ b/build/scripts/Test-WindowsTerminalPackage.ps1 @@ -70,23 +70,24 @@ Try { $dependencies = $Manifest.Package.Dependencies.PackageDependency.Name $depsHasVclibsDesktop = ("Microsoft.VCLibs.140.00.UWPDesktop" -in $dependencies) -or ("Microsoft.VCLibs.140.00.Debug.UWPDesktop" -in $dependencies) - $depsHasVcLibsAppX = ("Microsoft.VCLibs.140.00" -in $dependencies) -or ("Microsoft.VCLibs.140.00.Debug" -in $dependencies) + $depsHasVclibsAppX = ("Microsoft.VCLibs.140.00" -in $dependencies) -or ("Microsoft.VCLibs.140.00.Debug" -in $dependencies) $filesHasVclibsDesktop = ($null -ne (Get-Item "$AppxPackageRootPath\vcruntime140.dll" -EA:Ignore)) -or ($null -ne (Get-Item "$AppxPackageRootPath\vcruntime140d.dll" -EA:Ignore)) $filesHasVclibsAppX = ($null -ne (Get-Item "$AppxPackageRootPath\vcruntime140_app.dll" -EA:Ignore)) -or ($null -ne (Get-Item "$AppxPackageRootPath\vcruntime140d_app.dll" -EA:Ignore)) - If ($depsHasVclibsDesktop -Eq $filesHasVclibsDesktop) { - $eitherBoth = if ($depsHasVclibsDesktop) { "both" } else { "neither" } - $neitherNor = if ($depsHasVclibsDesktop) { "and" } else { "nor" } - Throw "Package has $eitherBoth Dependency $neitherNor Integrated Desktop VCLibs" + If ($filesHasVclibsDesktop) { + Throw "Package contains the desktop VCLibs" } - If ($depsHasVclibsAppx -Eq $filesHasVclibsAppx) { - if ($depsHasVclibsAppx) { - # We've shipped like this forever, so downgrade to warning. - Write-Warning "Package has both Dependency and Integrated AppX VCLibs" - } else { - Throw "Package has neither Dependency nor Integrated AppX VCLibs" - } + If ($depsHasVclibsDesktop) { + Throw "Package has a dependency on the desktop VCLibs" + } + + If ($filesHasVclibsAppX) { + Throw "Package contains the AppX VCLibs" + } + + If ($depsHasVclibsAppX) { + Throw "Package has a dependency on the AppX VCLibs" } ### Check that we have an App.xbf (which is a proxy for our resources having been merged) diff --git a/dep/nuget/packages.config b/dep/nuget/packages.config index 09a9c4935d..c39e95a3c8 100644 --- a/dep/nuget/packages.config +++ b/dep/nuget/packages.config @@ -5,7 +5,6 @@ - diff --git a/scratch/ScratchIslandApp/WindowExe/WindowExe.vcxproj b/scratch/ScratchIslandApp/WindowExe/WindowExe.vcxproj index de4c7a3435..fa14a3b19a 100644 --- a/scratch/ScratchIslandApp/WindowExe/WindowExe.vcxproj +++ b/scratch/ScratchIslandApp/WindowExe/WindowExe.vcxproj @@ -17,8 +17,6 @@ true - true - true true diff --git a/scratch/ScratchIslandApp/WindowExe/packages.config b/scratch/ScratchIslandApp/WindowExe/packages.config index 040e8f88be..3543aaf75b 100644 --- a/scratch/ScratchIslandApp/WindowExe/packages.config +++ b/scratch/ScratchIslandApp/WindowExe/packages.config @@ -3,5 +3,4 @@ - diff --git a/src/cascadia/CascadiaPackage/CascadiaPackage.wapproj b/src/cascadia/CascadiaPackage/CascadiaPackage.wapproj index 25c1b9c5f7..58be390d1c 100644 --- a/src/cascadia/CascadiaPackage/CascadiaPackage.wapproj +++ b/src/cascadia/CascadiaPackage/CascadiaPackage.wapproj @@ -153,6 +153,8 @@ + + @@ -161,6 +163,8 @@ + + diff --git a/src/cascadia/WindowsTerminal/WindowsTerminal.vcxproj b/src/cascadia/WindowsTerminal/WindowsTerminal.vcxproj index 2379a6430a..62875db2b6 100644 --- a/src/cascadia/WindowsTerminal/WindowsTerminal.vcxproj +++ b/src/cascadia/WindowsTerminal/WindowsTerminal.vcxproj @@ -18,7 +18,6 @@ true - true true true diff --git a/src/common.nugetversions.targets b/src/common.nugetversions.targets index e047b9931d..7cffff5ec8 100644 --- a/src/common.nugetversions.targets +++ b/src/common.nugetversions.targets @@ -44,9 +44,6 @@ - - - @@ -84,9 +81,6 @@ - - -