Move to netcoreapp2.2 as TFM
authorWes Haggard <Wes.Haggard@microsoft.com>
Mon, 23 Apr 2018 22:51:51 +0000 (15:51 -0700)
committerWes Haggard <Wes.Haggard@microsoft.com>
Tue, 24 Apr 2018 19:08:35 +0000 (12:08 -0700)
Commit migrated from https://github.com/dotnet/core-setup/commit/1e7f4e8de9f57a45c3f5eac8d1ac327544498e13

15 files changed:
src/installer/config.json
src/installer/pkg/projects/Microsoft.NETCore.App/Microsoft.NETCore.App.pkgproj
src/installer/pkg/projects/Microsoft.NETCore.App/src/Microsoft.NETCore.App.depproj
src/installer/sharedFramework/sharedFramework.proj
src/installer/test/Assets/TestProjects/HostApiInvokerApp/HostApiInvokerApp.csproj
src/installer/test/Assets/TestProjects/LightupClient/LightupClient.csproj
src/installer/test/Assets/TestProjects/LightupLib/LightupLib.csproj
src/installer/test/Assets/TestProjects/PortableApp/PortableApp.csproj
src/installer/test/Assets/TestProjects/PortableTestApp/PortableTestApp.csproj
src/installer/test/Assets/TestProjects/ResourceLookup/ResourceLookup.csproj
src/installer/test/Assets/TestProjects/SharedFxLookupPortableApp/SharedFxLookupPortableApp.csproj
src/installer/test/Assets/TestProjects/StandaloneApp/StandaloneApp.csproj
src/installer/test/Assets/TestProjects/StandaloneTestApp/StandaloneTestApp.csproj
src/installer/test/TestUtils/TestProjectFixture.cs
src/installer/test/dir.proj

index f20b4d5..8773691 100644 (file)
       "values": ["x64", "x86", "arm", "arm64", "armel"],
       "defaultValue": "x64"
     },
-    "Framework":{
-      "description": "Build the specified framework (netcoreapp1.0, netcoreapp1.1, netcoreapp2.0, or netcoreapp2.1 default: netcoreapp2.1)",
-      "valueType": "property",
-      "values": ["netcoreapp1.0", "netcoreapp1.1", "netcoreapp2.0", "netcoreapp2.1"],
-      "defaultValue": "netcoreapp2.1"
-    },    
     "ConfigurationGroup": {
       "description": "Sets the configuration group as Release or Debug.",
       "valueType": "property",
@@ -65,7 +59,7 @@
       "valueType": "property",
       "values": ["true", "false"],
       "defaultValue": false
-    },    
+    },
     "Project": {
       "description": "Project where the commands are going to be applied.",
       "valueType": "passThrough",
           "settings": {
             "PortableBuild":"true"
           }
-        }        
+        }
       },
       "defaultValues":{
         "toolName": "msbuild",
         "settings": {
            "TargetArchitecture": "default",
-           "Framework": "default",
            "OSGroup": "default",
            "MsBuildLogging":"/flp:v=n;LogFile=msbuild-cmake.log"
         }
       "defaultValues":{
         "toolName": "msbuild",
         "settings": {
-          "Architecture": "default", 
+          "Architecture": "default",
            "TargetArchitecture": "default",
-           "Framework": "default",
            "OSGroup": "default",
            "MsBuildLogging":"/flp:v=n;LogFile=msbuild.log"
         }
index d2077df..b206c6e 100644 (file)
@@ -6,10 +6,6 @@
 
   <PropertyGroup>
     <Version>$(SharedFrameworkNugetVersion)</Version>
-
-    <!-- This corresponds to TFM we want the SharedFX to target and should be updated when needed. -->
-
-    <NETCoreAppFramework>netcoreapp2.1</NETCoreAppFramework>
     <OmitDependencies>true</OmitDependencies>
     <SkipValidatePackage>true</SkipValidatePackage>
     <ShouldCreateLayout>false</ShouldCreateLayout>
@@ -43,7 +39,7 @@
     <Dependency Include="_._">
       <TargetFramework>.NETCoreApp2.0</TargetFramework>
     </Dependency>
-    
+
     <!-- references the host packages -->
     <Dependency Include="Microsoft.NETCore.DotNetHostPolicy">
        <Version>$(HostPolicyVersion)</Version>
@@ -55,7 +51,7 @@
     <File Include="$(PlaceHolderFile)">
       <TargetPath>ref/netcoreapp</TargetPath>
     </File>
-    
+
     <File Include="$(PropsFile)">
       <TargetPath>build/$(NETCoreAppFramework)</TargetPath>
     </File>
       <AdditionalProperties Condition="'$(PackageTargetRuntime)' != ''">NuGetRuntimeIdentifier=$(PackageTargetRuntime)</AdditionalProperties>
     </ProjectReference>
   </ItemGroup>
-  
+
   <Target Name="GenerateFileVersionProps" BeforeTargets="GenerateNuSpec" Condition="'$(PackageTargetRuntime)' == ''">
     <MSBuild Projects="@(ProjectReference)"
-             Condition="'%(ProjectReference.PackageTargetRuntime)' == '$(PackageRID)' OR 
-                        '%(ProjectReference.BuidOnRID)' == '$(PackageRID)' OR 
+             Condition="'%(ProjectReference.PackageTargetRuntime)' == '$(PackageRID)' OR
+                        '%(ProjectReference.BuidOnRID)' == '$(PackageRID)' OR
                         ('$(IncludeAllRuntimePackagesInPlatformManifest)' == 'true' AND
-                         '%(ProjectReference.PackageTargetRuntime)' != '' AND 
+                         '%(ProjectReference.PackageTargetRuntime)' != '' AND
                          '%(ProjectReference.ExcludeFromPlatformManifest)' != 'true')"
              Targets="GetPackageFiles">
       <Output TaskParameter="TargetOutputs" ItemName="SharedFrameworkRuntimeFiles" />
     </MSBuild>
-    
+
     <GenerateFileVersionProps Files="@(SharedFrameworkRuntimeFiles)"
                               PackageId="$(Id)"
                               PackageVersion="$(Version)"
index 98ebd62..fa8a320 100644 (file)
@@ -7,9 +7,9 @@
     <!-- we don't want any analyzers by ResolveNuGetPackageAssets
          null-refs when this isn't set and an analyzer is in the packages -->
     <Language>unused</Language>
-    <NuGetTargetMoniker>.NETCoreApp,Version=v2.1</NuGetTargetMoniker>
-    <NuGetTargetMonikerShort>netcoreapp2.1</NuGetTargetMonikerShort>
-    <PackageTargetFramework>netcoreapp2.1</PackageTargetFramework>
+    <NuGetTargetMoniker>$(NETCoreAppFrameworkMoniker)</NuGetTargetMoniker>
+    <NuGetTargetMonikerShort>$(NETCoreAppFramework)</NuGetTargetMonikerShort>
+    <PackageTargetFramework>$(NETCoreAppFramework)</PackageTargetFramework>
     <PrimaryPackage>Microsoft.Private.CoreFx.NETCoreApp</PrimaryPackage>
     <CrossGenOutputPath>$(CrossGenRootPath)/$(MSBuildProjectName)/$(NuGetRuntimeIdentifier)</CrossGenOutputPath>
     <ContainsPackageReferences>true</ContainsPackageReferences>
index 082c193..34a39c8 100644 (file)
@@ -17,7 +17,7 @@
   </PropertyGroup>
 
   <PropertyGroup>
-    <CommonProjectArgs>$(MSBuildPassThroughPropertyList) /p:TargetFramework=$(Framework) /p:RuntimeIdentifier=$(PackageTargetRid)</CommonProjectArgs>
+    <CommonProjectArgs>$(MSBuildPassThroughPropertyList) /p:TargetFramework=$(NETCoreAppFramework) /p:RuntimeIdentifier=$(PackageTargetRid)</CommonProjectArgs>
 
     <!-- SFP is short for SharedFrameworkPublish. Using an abreviation to prevent long path issues. -->
     <SharedFrameworkIntermediatePackagesDir>$(IntermediateOutputRootPath)SFP.packages\</SharedFrameworkIntermediatePackagesDir>
 
   <Target Name="PublishSharedFrameworkAndSharedHost"
           DependsOnTargets="RestoreLockedCoreHost">
-    
+
     <PropertyGroup>
       <SharedFrameworkSourceRoot>$(MSBuildThisFileDirectory)framework</SharedFrameworkSourceRoot>
       <CommonSharedFrameworkArgs>$(CommonProjectArgs) /p:RuntimeFrameworkVersion=$(SharedFrameworkNugetVersion)</CommonSharedFrameworkArgs>
-    </PropertyGroup>  
+    </PropertyGroup>
 
     <RemoveDir Directories="$(SharedFrameworkNameAndVersionRoot)" />
 
@@ -64,9 +64,9 @@
     <Delete Files="@(ToDelete)" />
 
     <!-- Rename deps file -->
-    <Move SourceFiles="$(SharedFrameworkNameAndVersionRoot)\framework.deps.json" 
+    <Move SourceFiles="$(SharedFrameworkNameAndVersionRoot)\framework.deps.json"
           DestinationFiles="$(SharedFrameworkNameAndVersionRoot)\$(SharedFrameworkName).deps.json" />
-    
+
     <!-- Use the muxer we intended to consume (either restored a shipped version or the one we built) -->
     <!-- Ensure the host is executable.  See https://github.com/NuGet/Home/issues/4424 -->
     <Exec Command="chmod u+x $(CoreHostLockedDir)dotnet$(ExeSuffix)"
@@ -80,7 +80,7 @@
     <ItemGroup>
       <SharedFrameworkSymbols Include="$(PackageSymbolsBinDir)Microsoft.NETCore.App/**/*.pdb" />
       <SharedFrameworkSymbols Include="$(PackageSymbolsBinDir)Microsoft.NETCore.App/**/*$(SymbolFileExtension)" />
-      <SharedFrameworkSymbols Include="$(PackageSymbolsBinDir)Microsoft.NETCore.App/**/*$(CrossGenSymbolExtension)" 
+      <SharedFrameworkSymbols Include="$(PackageSymbolsBinDir)Microsoft.NETCore.App/**/*$(CrossGenSymbolExtension)"
                               Condition="'$(CrossGenSymbolExtension)' != ''" />
     </ItemGroup>
     <RemoveDir Directories="$(SharedFrameworkPublishSymbolsDir)"
       <RuntimeGraphGeneratorRuntime Condition="'$(OSGroup)'=='Windows_NT'">win</RuntimeGraphGeneratorRuntime>
       <RuntimeGraphGeneratorRuntime Condition="'$(OSGroup)'=='OSX'">osx</RuntimeGraphGeneratorRuntime>
       <RuntimeGraphGeneratorRuntime Condition="$(OutputRID.StartsWith('alpine'))">alpine</RuntimeGraphGeneratorRuntime>
-      <RuntimeGraphGeneratorRuntime Condition="'$(RuntimeGraphGeneratorRuntime)'==''">linux</RuntimeGraphGeneratorRuntime>      
+      <RuntimeGraphGeneratorRuntime Condition="'$(RuntimeGraphGeneratorRuntime)'==''">linux</RuntimeGraphGeneratorRuntime>
     </PropertyGroup>
 
     <ItemGroup>
       <TrimPkgsFromDeps Include="microsoft.netcore.dotnetapphost" />
       <TrimPkgsFromDeps Include="microsoft.netcore.dotnethostresolver" />
     </ItemGroup>
-    
+
     <ProcessSharedFrameworkDeps AssetsFilePath="$(SharedFrameworkAssetsFile)"
                                 DepsFilePath="$(SharedFrameworkDepsFile)"
                                 PackagesToRemove="@(TrimPkgsFromDeps)"
index 3072b5c..83efdd4 100644 (file)
@@ -1,7 +1,7 @@
 <Project Sdk="Microsoft.NET.Sdk">
 
   <PropertyGroup>
-    <TargetFramework>netcoreapp2.1</TargetFramework>
+    <TargetFramework>$(NETCoreAppFramework)</TargetFramework>
     <OutputType>Exe</OutputType>
     <RuntimeFrameworkVersion>$(MNAVersion)</RuntimeFrameworkVersion>
   </PropertyGroup>
index 59fdabf..80f4310 100644 (file)
@@ -1,7 +1,7 @@
 <Project Sdk="Microsoft.NET.Sdk">
 
   <PropertyGroup>
-    <TargetFramework>netcoreapp2.1</TargetFramework>
+    <TargetFramework>$(NETCoreAppFramework)</TargetFramework>
     <OutputType>Exe</OutputType>
     <RuntimeFrameworkVersion>$(MNAVersion)</RuntimeFrameworkVersion>
   </PropertyGroup>
index e5a0ba7..ccdbc07 100644 (file)
@@ -1,7 +1,7 @@
 <Project Sdk="Microsoft.NET.Sdk">
 
   <PropertyGroup>
-    <TargetFramework>netcoreapp2.1</TargetFramework>
+    <TargetFramework>$(NETCoreAppFramework)</TargetFramework>
     <OutputType>Library</OutputType>
     <RuntimeFrameworkVersion>$(MNAVersion)</RuntimeFrameworkVersion>
   </PropertyGroup>
index 3072b5c..83efdd4 100644 (file)
@@ -1,7 +1,7 @@
 <Project Sdk="Microsoft.NET.Sdk">
 
   <PropertyGroup>
-    <TargetFramework>netcoreapp2.1</TargetFramework>
+    <TargetFramework>$(NETCoreAppFramework)</TargetFramework>
     <OutputType>Exe</OutputType>
     <RuntimeFrameworkVersion>$(MNAVersion)</RuntimeFrameworkVersion>
   </PropertyGroup>
index d86c31d..d5f0f6c 100644 (file)
@@ -1,7 +1,7 @@
 <Project Sdk="Microsoft.NET.Sdk">
 
   <PropertyGroup>
-    <TargetFramework>netcoreapp2.1</TargetFramework>
+    <TargetFramework>$(NETCoreAppFramework)</TargetFramework>
     <GenerateRuntimeConfigurationFiles>true</GenerateRuntimeConfigurationFiles>
     <PackageTargetFallback>$(PackageTargetFallback);dotnet5.4;portable-net451+win8</PackageTargetFallback>
     <RuntimeFrameworkVersion>$(MNAVersion)</RuntimeFrameworkVersion>
index 060f77f..554c740 100644 (file)
@@ -1,7 +1,7 @@
 <Project Sdk="Microsoft.NET.Sdk">
 
   <PropertyGroup>
-    <TargetFramework>netcoreapp2.1</TargetFramework>
+    <TargetFramework>$(NETCoreAppFramework)</TargetFramework>
     <OutputType>Exe</OutputType>
     <RuntimeFrameworkVersion>$(MNAVersion)</RuntimeFrameworkVersion>
   </PropertyGroup>
index 3072b5c..83efdd4 100644 (file)
@@ -1,7 +1,7 @@
 <Project Sdk="Microsoft.NET.Sdk">
 
   <PropertyGroup>
-    <TargetFramework>netcoreapp2.1</TargetFramework>
+    <TargetFramework>$(NETCoreAppFramework)</TargetFramework>
     <OutputType>Exe</OutputType>
     <RuntimeFrameworkVersion>$(MNAVersion)</RuntimeFrameworkVersion>
   </PropertyGroup>
index bdd2084..6c7f3f3 100644 (file)
@@ -1,7 +1,7 @@
 <Project Sdk="Microsoft.NET.Sdk">
 
   <PropertyGroup>
-    <TargetFramework>netcoreapp2.1</TargetFramework>
+    <TargetFramework>$(NETCoreAppFramework)</TargetFramework>
     <OutputType>Exe</OutputType>
     <RuntimeIdentifier>$(TestTargetRid)</RuntimeIdentifier>
     <RuntimeFrameworkVersion>$(MNAVersion)</RuntimeFrameworkVersion>
index 3df01e5..613a84e 100644 (file)
@@ -1,7 +1,7 @@
 <Project Sdk="Microsoft.NET.Sdk">
 
   <PropertyGroup>
-    <TargetFramework>netcoreapp2.1</TargetFramework>
+    <TargetFramework>$(NETCoreAppFramework)</TargetFramework>
     <OutputType>Exe</OutputType>
     <GenerateRuntimeConfigurationFiles>true</GenerateRuntimeConfigurationFiles>
     <PackageTargetFallback>$(PackageTargetFallback);dotnet5.4;portable-net451+win8</PackageTargetFallback>
index ddc8d5f..a549511 100644 (file)
@@ -53,11 +53,12 @@ namespace Microsoft.DotNet.CoreSetup.Test
             string dotnetInstallPath = null,
             string currentRid = null,
             string builtDotnetOutputPath = null,
-            string framework = "netcoreapp2.1")
+            string framework = null)
         {
             ValidateRequiredDirectories(repoDirectoriesProvider);
 
             _testProjectName = testProjectName;
+            _framework = framework ?? Environment.GetEnvironmentVariable("MNA_TFM");
 
             _exeExtension = exeExtension ?? RuntimeInformationExtensions.GetExeExtensionForCurrentOSPlatform();
             _sharedLibraryExtension = sharedLibraryExtension
@@ -77,7 +78,6 @@ namespace Microsoft.DotNet.CoreSetup.Test
             _currentRid = currentRid ?? repoDirectoriesProvider.TargetRID;
 
             _builtDotnet = new DotNetCli(repoDirectoriesProvider.BuiltDotnet);
-            _framework = framework;
             InitializeTestProject(
                 _testProjectName,
                 _testProjectSourceDirectory,
@@ -297,6 +297,7 @@ namespace Microsoft.DotNet.CoreSetup.Test
             }
 
             storeArgs.Add($"/p:MNAVersion={_repoDirectoriesProvider.MicrosoftNETCoreAppVersion}");
+            storeArgs.Add($"/p:NETCoreAppFramework={_framework}");
 
             // Ensure the project's OutputType isn't 'Exe', since that causes issues with 'dotnet store'
             storeArgs.Add("/p:OutputType=Library");
@@ -371,6 +372,7 @@ namespace Microsoft.DotNet.CoreSetup.Test
             restoreArgs.Add("--disable-parallel");
 
             restoreArgs.Add($"/p:MNAVersion={_repoDirectoriesProvider.MicrosoftNETCoreAppVersion}");
+            restoreArgs.Add($"/p:NETCoreAppFramework={_framework}");
 
             if (extraMSBuildProperties != null)
             {
index e1d0626..274985d 100644 (file)
@@ -90,7 +90,7 @@
     </PropertyGroup>
     <Exec Command="$(DotnetToolCommand) test $(TestArgs) --logger &quot;trx;LogFileName=$(TestResultsXml)&quot;"
           WorkingDirectory="$(TestWorkingDirectory)"
-          EnvironmentVariables="NUGET_PACKAGES=$(PackagesDir);TEST_ARTIFACTS=$(SystemPathTestsOutputDir);TEST_TARGETRID=$(TestTargetRid);BUILDRID=$(OutputRid);BUILD_ARCHITECTURE=$(TargetArchitecture);BUILD_CONFIGURATION=$(ConfigurationGroup);MNA_VERSION=$(ProductVersion);DOTNET_SDK_PATH=$(DotnetCliPath)"
+          EnvironmentVariables="NUGET_PACKAGES=$(PackagesDir);TEST_ARTIFACTS=$(SystemPathTestsOutputDir);TEST_TARGETRID=$(TestTargetRid);BUILDRID=$(OutputRid);BUILD_ARCHITECTURE=$(TargetArchitecture);BUILD_CONFIGURATION=$(ConfigurationGroup);MNA_VERSION=$(ProductVersion);MNA_TFM=$(NETCoreAppFramework);DOTNET_SDK_PATH=$(DotnetCliPath)"
           Condition="'$(TestProjectFilename)' != 'HostActivationTests' or '$(IsCrossArch)' != 'true'"
           ContinueOnError="true"
           IgnoreStandardErrorWarningFormat="true"