Skip to content

Commit 7920db8

Browse files
authored
Integrate dotnet/fsharp from 4f5f083 to 7b25d7f (#918)
Integrate dotnet/fsharp from 4f5f083 to 7b25d7f
2 parents 3acf6df + 09154cc commit 7920db8

File tree

107 files changed

+2709
-3385
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

107 files changed

+2709
-3385
lines changed

Diff for: .travis.yml

+5-25
Original file line numberDiff line numberDiff line change
@@ -4,40 +4,20 @@ os:
44
- linux
55
- osx
66

7-
osx_image: xcode9
7+
osx_image: xcode11.2
88

99
mono:
1010
- weekly
1111
- latest
12-
- 5.8.0
12+
- 6.0.0
1313

14-
dotnet: 2.1.4
14+
dotnet: 3.0.100
1515

1616
sudo: false
1717

1818
install:
1919

2020
script:
21-
- ./fcs/build.sh Build
22-
23-
# Woes with doing more build/test on linux
24-
#
25-
# This fails because NUnit gives an exception (!!!!)
26-
# - ./fcs/build.sh Test.NetFx
27-
#
28-
# System.IO.FileNotFoundException: Could not load file or assembly 'nunit.engine.api, Version=3.0.0.0, Culture=neutral, PublicKeyToken=2638cd05610744eb' or one of its dependencies.
29-
#
30-
# This fails because Nuget packaging doesn't like backslashes in the package file, but Windows does
31-
# - ./fcs/build.sh NuGet
32-
33-
# Fails on Travis OSX too often because there are network outages on that configuration getting the Mono MDK
34-
# Fails on Travis Linux with Mono latest do to a trust issue with certs on package restore?
35-
matrix:
36-
exclude:
37-
- os: osx
38-
mono: 4.4.2
39-
- os: osx
40-
mono: 4.8.0
41-
- os: linux
42-
mono: latest
21+
- ./fcs/build.sh
22+
4323

Diff for: FSharp.Profiles.props

-4
Original file line numberDiff line numberDiff line change
@@ -5,16 +5,12 @@
55
<PropertyGroup Condition="$(TargetFramework.StartsWith('net4'))">
66
<DefineConstants Condition="'$(MonoPackaging)' == 'true'">$(DefineConstants);CROSS_PLATFORM_COMPILER</DefineConstants>
77
<DefineConstants>$(DefineConstants);ENABLE_MONO_SUPPORT</DefineConstants>
8-
<DefineConstants>$(DefineConstants);BE_SECURITY_TRANSPARENT</DefineConstants>
98
</PropertyGroup>
109

1110
<PropertyGroup Condition="$(TargetFramework.StartsWith('netstandard')) OR $(TargetFramework.StartsWith('netcoreapp'))">
1211
<DefineConstants>$(DefineConstants);NETSTANDARD</DefineConstants>
1312
<DefineConstants>$(DefineConstants);FX_NO_APP_DOMAINS</DefineConstants>
1413
<DefineConstants>$(DefineConstants);FX_NO_CORHOST_SIGNER</DefineConstants>
15-
<DefineConstants>$(DefineConstants);FX_NO_EVENTWAITHANDLE_IDISPOSABLE</DefineConstants>
16-
<DefineConstants>$(DefineConstants);FX_NO_EXIT_CONTEXT_FLAGS</DefineConstants>
17-
<DefineConstants>$(DefineConstants);FX_NO_PARAMETERIZED_THREAD_START</DefineConstants>
1814
<DefineConstants>$(DefineConstants);FX_NO_PDB_READER</DefineConstants>
1915
<DefineConstants>$(DefineConstants);FX_NO_PDB_WRITER</DefineConstants>
2016
<DefineConstants>$(DefineConstants);FX_NO_SYMBOLSTORE</DefineConstants>

Diff for: appveyor.yml

+2-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
os: Visual Studio 2017
1+
os: Visual Studio 2019
22

33
init:
44
- git config --global core.autocrlf input
@@ -9,5 +9,4 @@ build_script:
99
test: off
1010
version: '{build}'
1111
artifacts:
12-
- path: release\fcs\*.nupkg
13-
type: NuGetPackage
12+
- path: artifacts\bin\fcs\Release\*.nupkg

Diff for: eng/Version.Details.xml

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
<ProductDependencies>
44
</ProductDependencies>
55
<ToolsetDependencies>
6-
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="5.0.0-beta.19557.20">
6+
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="5.0.0-beta.19603.17">
77
<Uri>https://github.com/dotnet/arcade</Uri>
8-
<Sha>b62f1617f2c453497fd55697c04dd8021a38dc17</Sha>
8+
<Sha>b902fd6b6948e689a5128fa6d94dc7de13e6af84</Sha>
99
</Dependency>
1010
</ToolsetDependencies>
1111
</Dependencies>

Diff for: eng/Versions.props

+3-3
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,14 @@
2323
<FSharpCorePreviewPackageVersion>$(FSCorePackageVersion)-$(PreReleaseVersionLabel).*</FSharpCorePreviewPackageVersion>
2424
</PropertyGroup>
2525
<PropertyGroup>
26-
<FSPackageMajorVersion>10.6</FSPackageMajorVersion>
26+
<FSPackageMajorVersion>10.7</FSPackageMajorVersion>
2727
<FSPackageVersion>$(FSPackageMajorVersion).0</FSPackageVersion>
2828
<FSProductVersionPrefix>$(FSPackageVersion)</FSProductVersionPrefix>
2929
<FSProductVersion>$(FSPackageVersion).0</FSProductVersion>
3030
</PropertyGroup>
3131
<PropertyGroup>
3232
<VSMajorVersion>16</VSMajorVersion>
33-
<VSMinorVersion>3</VSMinorVersion>
33+
<VSMinorVersion>4</VSMinorVersion>
3434
<VSGeneralVersion>$(VSMajorVersion).0</VSGeneralVersion>
3535
<VSAssemblyVersionPrefix>$(VSMajorVersion).$(VSMinorVersion).0</VSAssemblyVersionPrefix>
3636
<VSAssemblyVersion>$(VSAssemblyVersionPrefix).0</VSAssemblyVersion>
@@ -155,7 +155,7 @@
155155
<MicrosoftVisualStudioUtilitiesVersion>16.1.28917.181</MicrosoftVisualStudioUtilitiesVersion>
156156
<MicrosoftVisualStudioValidationVersion>15.3.58</MicrosoftVisualStudioValidationVersion>
157157
<MicrosoftVisualStudioWCFReferenceInteropVersion>9.0.30729</MicrosoftVisualStudioWCFReferenceInteropVersion>
158-
<MicrosoftVSSDKBuildToolsVersion>16.0.2264</MicrosoftVSSDKBuildToolsVersion>
158+
<MicrosoftVSSDKBuildToolsVersion>16.3.2099</MicrosoftVSSDKBuildToolsVersion>
159159
<VSSDKDebuggerVisualizersVersion>12.0.4</VSSDKDebuggerVisualizersVersion>
160160
<VSSDKVSLangProjVersion>7.0.4</VSSDKVSLangProjVersion>
161161
<VSSDKVSLangProj8Version>8.0.4</VSSDKVSLangProj8Version>

Diff for: eng/build-utils.ps1

+2-2
Original file line numberDiff line numberDiff line change
@@ -237,14 +237,14 @@ function Make-BootstrapBuild() {
237237
Create-Directory $dir
238238

239239
# prepare FsLex and Fsyacc and AssemblyCheck
240-
Run-MSBuild "$RepoRoot\src\buildtools\buildtools.proj" "/restore /t:Publish" -logFileName "BuildTools" -configuration $bootstrapConfiguration
240+
Run-MSBuild "$RepoRoot\src\buildtools\buildtools.proj" "/restore /t:Publish /p:PublishWindowsPdb=false" -logFileName "BuildTools" -configuration $bootstrapConfiguration
241241
Copy-Item "$ArtifactsDir\bin\fslex\$bootstrapConfiguration\netcoreapp2.1\publish" -Destination "$dir\fslex" -Force -Recurse
242242
Copy-Item "$ArtifactsDir\bin\fsyacc\$bootstrapConfiguration\netcoreapp2.1\publish" -Destination "$dir\fsyacc" -Force -Recurse
243243
Copy-Item "$ArtifactsDir\bin\AssemblyCheck\$bootstrapConfiguration\netcoreapp2.1\publish" -Destination "$dir\AssemblyCheck" -Force -Recurse
244244

245245
# prepare compiler
246246
$projectPath = "$RepoRoot\proto.proj"
247-
Run-MSBuild $projectPath "/restore /t:Publish /p:TargetFramework=$bootstrapTfm;ProtoTargetFramework=$bootstrapTfm" -logFileName "Bootstrap" -configuration $bootstrapConfiguration
247+
Run-MSBuild $projectPath "/restore /t:Publish /p:TargetFramework=$bootstrapTfm;ProtoTargetFramework=$bootstrapTfm /p:PublishWindowsPdb=false" -logFileName "Bootstrap" -configuration $bootstrapConfiguration
248248
Copy-Item "$ArtifactsDir\bin\fsc\$bootstrapConfiguration\$bootstrapTfm\publish" -Destination "$dir\fsc" -Force -Recurse
249249
Copy-Item "$ArtifactsDir\bin\fsi\$bootstrapConfiguration\$bootstrapTfm\publish" -Destination "$dir\fsi" -Force -Recurse
250250

Diff for: eng/common/CheckSymbols.ps1

+27-26
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,12 @@ param(
55
)
66

77
Add-Type -AssemblyName System.IO.Compression.FileSystem
8+
. $PSScriptRoot\pipeline-logging-functions.ps1
89

910
function FirstMatchingSymbolDescriptionOrDefault {
1011
param(
1112
[string] $FullPath, # Full path to the module that has to be checked
12-
[string] $TargetServerParam, # Parameter to pass to `Symbol Tool` indicating the server to lookup for symbols
13+
[string] $TargetServerParameter, # Parameter to pass to `Symbol Tool` indicating the server to lookup for symbols
1314
[string] $SymbolsPath
1415
)
1516

@@ -21,36 +22,36 @@ function FirstMatchingSymbolDescriptionOrDefault {
2122
# checking and which type of file was uploaded.
2223

2324
# The file itself is returned
24-
$SymbolPath = $SymbolsPath + "\" + $FileName
25+
$SymbolPath = $SymbolsPath + '\' + $FileName
2526

2627
# PDB file for the module
27-
$PdbPath = $SymbolPath.Replace($Extension, ".pdb")
28+
$PdbPath = $SymbolPath.Replace($Extension, '.pdb')
2829

2930
# PDB file for R2R module (created by crossgen)
30-
$NGenPdb = $SymbolPath.Replace($Extension, ".ni.pdb")
31+
$NGenPdb = $SymbolPath.Replace($Extension, '.ni.pdb')
3132

3233
# DBG file for a .so library
33-
$SODbg = $SymbolPath.Replace($Extension, ".so.dbg")
34+
$SODbg = $SymbolPath.Replace($Extension, '.so.dbg')
3435

3536
# DWARF file for a .dylib
36-
$DylibDwarf = $SymbolPath.Replace($Extension, ".dylib.dwarf")
37+
$DylibDwarf = $SymbolPath.Replace($Extension, '.dylib.dwarf')
3738

38-
.\dotnet-symbol.exe --symbols --modules --windows-pdbs $TargetServerParam $FullPath -o $SymbolsPath | Out-Null
39+
.\dotnet-symbol.exe --symbols --modules --windows-pdbs $TargetServerParameter $FullPath -o $SymbolsPath | Out-Null
3940

4041
if (Test-Path $PdbPath) {
41-
return "PDB"
42+
return 'PDB'
4243
}
4344
elseif (Test-Path $NGenPdb) {
44-
return "NGen PDB"
45+
return 'NGen PDB'
4546
}
4647
elseif (Test-Path $SODbg) {
47-
return "DBG for SO"
48+
return 'DBG for SO'
4849
}
4950
elseif (Test-Path $DylibDwarf) {
50-
return "Dwarf for Dylib"
51+
return 'Dwarf for Dylib'
5152
}
5253
elseif (Test-Path $SymbolPath) {
53-
return "Module"
54+
return 'Module'
5455
}
5556
else {
5657
return $null
@@ -68,15 +69,15 @@ function CountMissingSymbols {
6869
}
6970

7071
# Extensions for which we'll look for symbols
71-
$RelevantExtensions = @(".dll", ".exe", ".so", ".dylib")
72+
$RelevantExtensions = @('.dll', '.exe', '.so', '.dylib')
7273

7374
# How many files are missing symbol information
7475
$MissingSymbols = 0
7576

7677
$PackageId = [System.IO.Path]::GetFileNameWithoutExtension($PackagePath)
7778
$PackageGuid = New-Guid
7879
$ExtractPath = Join-Path -Path $ExtractPath -ChildPath $PackageGuid
79-
$SymbolsPath = Join-Path -Path $ExtractPath -ChildPath "Symbols"
80+
$SymbolsPath = Join-Path -Path $ExtractPath -ChildPath 'Symbols'
8081

8182
[System.IO.Compression.ZipFile]::ExtractToDirectory($PackagePath, $ExtractPath)
8283

@@ -86,31 +87,31 @@ function CountMissingSymbols {
8687
Get-ChildItem -Recurse $ExtractPath |
8788
Where-Object {$RelevantExtensions -contains $_.Extension} |
8889
ForEach-Object {
89-
if ($_.FullName -Match "\\ref\\") {
90+
if ($_.FullName -Match '\\ref\\') {
9091
Write-Host "`t Ignoring reference assembly file" $_.FullName
9192
return
9293
}
9394

94-
$SymbolsOnMSDL = FirstMatchingSymbolDescriptionOrDefault $_.FullName "--microsoft-symbol-server" $SymbolsPath
95-
$SymbolsOnSymWeb = FirstMatchingSymbolDescriptionOrDefault $_.FullName "--internal-server" $SymbolsPath
95+
$SymbolsOnMSDL = FirstMatchingSymbolDescriptionOrDefault -FullPath $_.FullName -TargetServerParameter '--microsoft-symbol-server' -SymbolsPath $SymbolsPath
96+
$SymbolsOnSymWeb = FirstMatchingSymbolDescriptionOrDefault -FullPath $_.FullName -TargetServerParameter '--internal-server' -SymbolsPath $SymbolsPath
9697

9798
Write-Host -NoNewLine "`t Checking file" $_.FullName "... "
9899

99100
if ($SymbolsOnMSDL -ne $null -and $SymbolsOnSymWeb -ne $null) {
100-
Write-Host "Symbols found on MSDL (" $SymbolsOnMSDL ") and SymWeb (" $SymbolsOnSymWeb ")"
101+
Write-Host "Symbols found on MSDL (${$SymbolsOnMSDL}) and SymWeb (${$SymbolsOnSymWeb})"
101102
}
102103
else {
103104
$MissingSymbols++
104105

105106
if ($SymbolsOnMSDL -eq $null -and $SymbolsOnSymWeb -eq $null) {
106-
Write-Host "No symbols found on MSDL or SymWeb!"
107+
Write-Host 'No symbols found on MSDL or SymWeb!'
107108
}
108109
else {
109110
if ($SymbolsOnMSDL -eq $null) {
110-
Write-Host "No symbols found on MSDL!"
111+
Write-Host 'No symbols found on MSDL!'
111112
}
112113
else {
113-
Write-Host "No symbols found on SymWeb!"
114+
Write-Host 'No symbols found on SymWeb!'
114115
}
115116
}
116117
}
@@ -129,26 +130,26 @@ function CheckSymbolsAvailable {
129130
Get-ChildItem "$InputPath\*.nupkg" |
130131
ForEach-Object {
131132
$FileName = $_.Name
132-
133+
133134
# These packages from Arcade-Services include some native libraries that
134135
# our current symbol uploader can't handle. Below is a workaround until
135136
# we get issue: https://github.com/dotnet/arcade/issues/2457 sorted.
136-
if ($FileName -Match "Microsoft\.DotNet\.Darc\.") {
137+
if ($FileName -Match 'Microsoft\.DotNet\.Darc\.') {
137138
Write-Host "Ignoring Arcade-services file: $FileName"
138139
Write-Host
139140
return
140141
}
141-
elseif ($FileName -Match "Microsoft\.DotNet\.Maestro\.Tasks\.") {
142+
elseif ($FileName -Match 'Microsoft\.DotNet\.Maestro\.Tasks\.') {
142143
Write-Host "Ignoring Arcade-services file: $FileName"
143144
Write-Host
144145
return
145146
}
146-
147+
147148
Write-Host "Validating $FileName "
148149
$Status = CountMissingSymbols "$InputPath\$FileName"
149150

150151
if ($Status -ne 0) {
151-
Write-Error "Missing symbols for $Status modules in the package $FileName"
152+
Write-PipelineTelemetryError -Category 'CheckSymbols' -Message "Missing symbols for $Status modules in the package $FileName"
152153
}
153154

154155
Write-Host

Diff for: eng/common/SetupNugetSources.ps1

+18-4
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
# condition: eq(variables['Agent.OS'], 'Windows_NT')
1717
# inputs:
1818
# filePath: $(Build.SourcesDirectory)/eng/common/SetupNugetSources.ps1
19-
# arguments: -ConfigFile ${Env:BUILD_SOURCESDIRECTORY}/NuGet.config -Password $Env:Token
19+
# arguments: -ConfigFile $(Build.SourcesDirectory)/NuGet.config -Password $Env:Token
2020
# env:
2121
# Token: $(dn-bot-dnceng-artifact-feeds-rw)
2222

@@ -95,10 +95,15 @@ function InsertMaestroPrivateFeedCredentials($Sources, $Creds, $Password) {
9595
}
9696

9797
if (!(Test-Path $ConfigFile -PathType Leaf)) {
98-
Write-Host "Couldn't find the file NuGet config file: $ConfigFile"
98+
Write-PipelineTelemetryError -Category 'Build' -Message "Eng/common/SetupNugetSources.ps1 returned a non-zero exit code. Couldn't find the NuGet config file: $ConfigFile"
9999
ExitWithExitCode 1
100100
}
101101

102+
if (!$Password) {
103+
Write-PipelineTelemetryError -Category 'Build' -Message 'Eng/common/SetupNugetSources.ps1 returned a non-zero exit code. Please supply a valid PAT'
104+
ExitWithExitCode 1
105+
}
106+
102107
# Load NuGet.config
103108
$doc = New-Object System.Xml.XmlDocument
104109
$filename = (Get-Item $ConfigFile).FullName
@@ -121,7 +126,16 @@ if ($creds -eq $null) {
121126
# Insert credential nodes for Maestro's private feeds
122127
InsertMaestroPrivateFeedCredentials -Sources $sources -Creds $creds -Password $Password
123128

124-
AddPackageSource -Sources $sources -SourceName "dotnet3-internal" -SourceEndPoint "https://pkgs.dev.azure.com/dnceng/_packaging/dotnet3-internal/nuget/v2" -Creds $creds -Username "dn-bot" -Password $Password
125-
AddPackageSource -Sources $sources -SourceName "dotnet3-internal-transport" -SourceEndPoint "https://pkgs.dev.azure.com/dnceng/_packaging/dotnet3-internal-transport/nuget/v2" -Creds $creds -Username "dn-bot" -Password $Password
129+
$dotnet3Source = $sources.SelectSingleNode("add[@key='dotnet3']")
130+
if ($dotnet3Source -ne $null) {
131+
AddPackageSource -Sources $sources -SourceName "dotnet3-internal" -SourceEndPoint "https://pkgs.dev.azure.com/dnceng/_packaging/dotnet3-internal/nuget/v2" -Creds $creds -Username "dn-bot" -Password $Password
132+
AddPackageSource -Sources $sources -SourceName "dotnet3-internal-transport" -SourceEndPoint "https://pkgs.dev.azure.com/dnceng/_packaging/dotnet3-internal-transport/nuget/v2" -Creds $creds -Username "dn-bot" -Password $Password
133+
}
134+
135+
$dotnet31Source = $sources.SelectSingleNode("add[@key='dotnet3.1']")
136+
if ($dotnet31Source -ne $null) {
137+
AddPackageSource -Sources $sources -SourceName "dotnet3.1-internal" -SourceEndPoint "https://pkgs.dev.azure.com/dnceng/_packaging/dotnet3.1-internal/nuget/v2" -Creds $creds -Username "dn-bot" -Password $Password
138+
AddPackageSource -Sources $sources -SourceName "dotnet3.1-internal-transport" -SourceEndPoint "https://pkgs.dev.azure.com/dnceng/_packaging/dotnet3.1-internal-transport/nuget/v2" -Creds $creds -Username "dn-bot" -Password $Password
139+
}
126140

127141
$doc.Save($filename)

0 commit comments

Comments
 (0)