From 290d5f0400113a2f4547cc171af8aba6887dfc1f Mon Sep 17 00:00:00 2001 From: Don Syme Date: Sat, 24 Feb 2018 00:00:10 +0000 Subject: [PATCH 01/11] re-enable mono build on CI --- fcs/build.fsx | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/fcs/build.fsx b/fcs/build.fsx index 58b56e99319..f6c24aa9f08 100644 --- a/fcs/build.fsx +++ b/fcs/build.fsx @@ -71,8 +71,7 @@ let buildVersion = else if isAppVeyorBuild then sprintf "%s-b%s" assemblyVersion AppVeyorEnvironment.BuildNumber else assemblyVersion -// Skipping build of FCS on Jenkins Mono for now until we knoow how to get an updated version of Mono installed -let skipBuild = isJenkinsBuild && isMono +let skipBuild = false // isJenkinsBuild && isMono Target "Clean" (fun _ -> if not skipBuild then From d44678da5076cced48adbdf25c6944d82a4eceaf Mon Sep 17 00:00:00 2001 From: Don Syme Date: Sat, 24 Feb 2018 00:56:45 +0000 Subject: [PATCH 02/11] do it right --- fcs/cibuild.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fcs/cibuild.sh b/fcs/cibuild.sh index 77f614b6b24..ddc49d8ff34 100755 --- a/fcs/cibuild.sh +++ b/fcs/cibuild.sh @@ -2,4 +2,4 @@ # note: expects to run from top directory ./mono/latest-mono-stable.sh -./build.sh NuGet +./fcs/build.sh NuGet From bd04caa77f515db3199801a62d817e5838899cc0 Mon Sep 17 00:00:00 2001 From: Don Syme Date: Mon, 26 Feb 2018 18:23:45 +0000 Subject: [PATCH 03/11] simplify fcs samples --- .../FSharp.Compiler.Service.Tests.fsproj | 17 +++-- .../FSharp.Compiler.Service.fsproj | 1 + fcs/build.fsx | 11 +-- fcs/fcs.props | 8 --- .../EditorService/EditorService.fsproj | 59 ++------------- fcs/samples/EditorService/paket.references | 0 fcs/samples/FscExe/FscExe.fsproj | 72 ++----------------- fcs/samples/FscExe/FscMain.fs | 20 ++---- fcs/samples/FscExe/paket.references | 0 fcs/samples/FsiExe/FsiExe.fsproj | 70 ++---------------- fcs/samples/FsiExe/paket.references | 0 .../InteractiveService.fsproj | 63 ++-------------- .../InteractiveService/paket.references | 0 fcs/samples/Tokenizer/Tokenizer.fsproj | 66 ++--------------- fcs/samples/Tokenizer/paket.references | 0 fcs/samples/UntypedTree/UntypedTree.fsproj | 66 ++--------------- fcs/samples/UntypedTree/UntypedTree.sln | 20 ------ fcs/samples/UntypedTree/paket.references | 0 src/scripts/fssrgen.targets | 2 +- 19 files changed, 45 insertions(+), 430 deletions(-) delete mode 100644 fcs/samples/EditorService/paket.references delete mode 100644 fcs/samples/FscExe/paket.references delete mode 100644 fcs/samples/FsiExe/paket.references delete mode 100644 fcs/samples/InteractiveService/paket.references delete mode 100644 fcs/samples/Tokenizer/paket.references delete mode 100644 fcs/samples/UntypedTree/UntypedTree.sln delete mode 100644 fcs/samples/UntypedTree/paket.references diff --git a/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj b/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj index 1f109c29ee7..b1188a181e6 100644 --- a/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj +++ b/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj @@ -5,10 +5,9 @@ net46;netcoreapp2.0 - $(NoWarn);44; true - true + portable true ..\..\$(Configuration.ToLower())\fcs @@ -65,17 +64,17 @@ Program.fs + + Program.fs + - - + - - - + @@ -91,7 +90,7 @@ - - + + \ No newline at end of file diff --git a/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj b/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj index 16f6efe9450..30fd8ec4a36 100644 --- a/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj +++ b/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj @@ -18,6 +18,7 @@ true true true + The F# compiler as library. For editors, for tools, for scripting. For you. diff --git a/fcs/build.fsx b/fcs/build.fsx index f6c24aa9f08..1920ea051c1 100644 --- a/fcs/build.fsx +++ b/fcs/build.fsx @@ -63,8 +63,6 @@ let isJenkinsBuild = buildServer = BuildServer.Jenkins let isVersionTag tag = Version.TryParse tag |> fst let hasRepoVersionTag = isAppVeyorBuild && AppVeyorEnvironment.RepoTag && isVersionTag AppVeyorEnvironment.RepoTagName let assemblyVersion = if hasRepoVersionTag then AppVeyorEnvironment.RepoTagName else release.NugetVersion -let nugetVersion = release.NugetVersion -open SemVerHelper let buildVersion = if hasRepoVersionTag then assemblyVersion @@ -80,11 +78,8 @@ Target "Clean" (fun _ -> Target "Restore" (fun _ -> if not skipBuild then - runDotnet __SOURCE_DIRECTORY__ "restore FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj -v n" - runDotnet __SOURCE_DIRECTORY__ "restore FSharp.Compiler.Service.ProjectCrackerTool/FSharp.Compiler.Service.ProjectCrackerTool.fsproj -v n" - runDotnet __SOURCE_DIRECTORY__ "restore FSharp.Compiler.Service.ProjectCracker/FSharp.Compiler.Service.ProjectCracker.fsproj -v n" - runDotnet __SOURCE_DIRECTORY__ "restore FSharp.Compiler.Service.MSBuild.v12/FSharp.Compiler.Service.MSBuild.v12.fsproj -v n" - for p in (!! "./../**/packages.config") do + runDotnet __SOURCE_DIRECTORY__ "restore FSharp.Compiler.Service/FSharp.Compiler.Service.sln -v n" + for p in (!! "./../packages.config") do let result = ExecProcess (fun info -> info.FileName <- FullName @"./../.nuget/NuGet.exe" @@ -103,7 +98,7 @@ Target "Build" (fun _ -> try Directory.CreateDirectory("../Release/") |> ignore with _ -> () File.WriteAllText("../Release/nichts.txt", "nothing to see here, build was skipped until we knoow how to get an updated version of Mono installed on Jenkins") else - runDotnet __SOURCE_DIRECTORY__ "build FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj -v n -c Release /maxcpucount:1" + runDotnet __SOURCE_DIRECTORY__ "build FSharp.Compiler.Service/FSharp.Compiler.Service.sln -v n -c Release /maxcpucount:1" ) Target "Test" (fun _ -> diff --git a/fcs/fcs.props b/fcs/fcs.props index eee47b6040e..c3e2198b38f 100644 --- a/fcs/fcs.props +++ b/fcs/fcs.props @@ -8,13 +8,5 @@ $(FSharpSourcesRoot)\..\packages\FSharp.Compiler.Tools.4.1.27\tools fsi.exe - - - $(FSharpSourcesRoot)\..\packages\FSharp.Compiler.Tools.4.1.27\tools - fsc.exe - $(FscToolPath)\$(FsiToolExe) - - {HintPathFromItem};{TargetFrameworkDirectory};{RawFileName} - \ No newline at end of file diff --git a/fcs/samples/EditorService/EditorService.fsproj b/fcs/samples/EditorService/EditorService.fsproj index 1f684a07fdf..f6e695448a4 100644 --- a/fcs/samples/EditorService/EditorService.fsproj +++ b/fcs/samples/EditorService/EditorService.fsproj @@ -1,64 +1,13 @@ - - - + - Debug - AnyCPU - $(MSBuildProjectDirectory)\..\..\ - 2.0 - a40507d6-fa48-43d3-b18a-ae3daace4020 + net46;netcoreapp2.0 Exe - EditorService - EditorService - v4.5 - EditorService - - true - - true - full - false - false - bin\Debug\ - DEBUG;TRACE - 3 - AnyCPU - bin\Debug\EditorService.xml - true - - - pdbonly - true - true - bin\Release\ - TRACE - 3 - AnyCPU - bin\Release\EditorService.xml - true - - - - - $(SolutionDir)\..\packages\Microsoft.Portable.FSharp.Core.4.1.20\lib\profiles\net40\FSharp.Core.dll - false - - - - - - - - FSharp.Compiler.Service - {2e4d67b4-522d-4cf7-97e4-ba940f0b18f3} - True - + - - \ No newline at end of file + diff --git a/fcs/samples/EditorService/paket.references b/fcs/samples/EditorService/paket.references deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/fcs/samples/FscExe/FscExe.fsproj b/fcs/samples/FscExe/FscExe.fsproj index 4434ddb30a7..781767220d8 100644 --- a/fcs/samples/FscExe/FscExe.fsproj +++ b/fcs/samples/FscExe/FscExe.fsproj @@ -1,75 +1,15 @@ - - - - + - $(MSBuildProjectDirectory)\..\..\..\src - - - Debug - AnyCPU - $(MSBuildProjectDirectory)\..\..\ - x86 - {C94C257C-3C0A-4858-B5D8-D746498D1F08} + net46 Exe - $(NoWarn);62;44 - FscExe - FscExe - FX_RESIDENT_COMPILER;$(DefineConstants) - true - $(OtherFlags) --warnon:1182 - true - 4.4.0.0 - v4.5 - - - - true - full - false - false - bin\Debug\ - TRACE;DEBUG;$(DefineConstants) - 3 - AnyCPU - bin\Debug\FsiExe.xml - true - - - - - pdbonly - true - true - bin\Release\ - TRACE;$(DefineConstants) - 3 - AnyCPU - bin\Release\FsiExe.xml - true + $(DefineConstants);RESIDENT_COMPILER - - Driver/FscMain.fs - + - - - $(FSharpSourcesRoot)\..\packages\FSharp.Compiler.Tools.4.1.27\tools\FSharp.Core.dll - true - - - + - - - FSharp.Compiler.Service - {2e4d67b4-522d-4cf7-97e4-ba940f0b18f3} - True - - - - \ No newline at end of file + diff --git a/fcs/samples/FscExe/FscMain.fs b/fcs/samples/FscExe/FscMain.fs index 6a639ea678d..af8f290df78 100644 --- a/fcs/samples/FscExe/FscMain.fs +++ b/fcs/samples/FscExe/FscMain.fs @@ -14,11 +14,7 @@ open Microsoft.FSharp.Compiler.AbstractIL.Internal.Library open Microsoft.FSharp.Compiler.ErrorLogger open Microsoft.FSharp.Compiler.Range -#if FX_RESHAPED_REFLECTION -open Microsoft.FSharp.Core.ReflectionAdapters -#endif - -#if FX_RESIDENT_COMPILER +#if RESIDENT_COMPILER type TypeInThisAssembly() = member x.Dummy = 1 let progress = ref false @@ -58,19 +54,15 @@ module FSharpResidentCompiler = // Use different base channel names on mono and CLR as a CLR remoting process can't talk // to a mono server static let baseChannelName = -#if ENABLE_MONO_SUPPORT if runningOnMono then "FSCChannelMono" else -#endif "FSCChannel" static let channelName = baseChannelName + "_" + domainName + "_" + userName static let serverName = -#if ENABLE_MONO_SUPPORT if runningOnMono then "FSCServerMono" else -#endif "FSCSever" static let mutable serverExists = true @@ -131,7 +123,6 @@ module FSharpResidentCompiler = // On Unix, the file permissions of the implicit socket need to be set correctly to make this // private to the user. -#if ENABLE_MONO_SUPPORT if runningOnMono then try let monoPosix = System.Reflection.Assembly.Load(new System.Reflection.AssemblyName("Mono.Posix, Version=2.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756")) @@ -152,7 +143,6 @@ module FSharpResidentCompiler = #endif () // Fail silently -#endif server.Run() static member private ConnectToServer() = @@ -177,7 +167,6 @@ module FSharpResidentCompiler = with _ -> if !progress then printfn "client: error while creating client, starting client instead" let procInfo = -#if ENABLE_MONO_SUPPORT if runningOnMono then let shellName, useShellExecute = match System.Environment.GetEnvironmentVariable("FSC_MONO") with @@ -194,7 +183,6 @@ module FSharpResidentCompiler = CreateNoWindow = true, UseShellExecute = useShellExecute) else -#endif ProcessStartInfo(FileName=fscServerExe, Arguments = "/server", CreateNoWindow = true, @@ -274,6 +262,7 @@ module Driver = System.Console.WriteLine("Press any key to continue...") System.Console.ReadKey() |> ignore +#if RESIDENT_COMPILER if runningOnMono && hasArgument "resident" argv then let argv = stripArgument "resident" argv @@ -293,14 +282,13 @@ module Driver = elif runningOnMono && hasArgument "server" argv then FSharpResidentCompiler.FSharpCompilationServer.RunServer() 0 - +#endif else let errors, exitCode = FSharpChecker.Create().Compile (argv) |> Async.RunSynchronously for error in errors do eprintfn "%s" (error.ToString()) exitCode -#if FX_NO_DEFAULT_DEPENDENCY_TYPE -#else +#if !FX_NO_DEFAULT_DEPENDENCY_TYPE [] #endif do () diff --git a/fcs/samples/FscExe/paket.references b/fcs/samples/FscExe/paket.references deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/fcs/samples/FsiExe/FsiExe.fsproj b/fcs/samples/FsiExe/FsiExe.fsproj index 1e13ce613b6..2825037e7bc 100644 --- a/fcs/samples/FsiExe/FsiExe.fsproj +++ b/fcs/samples/FsiExe/FsiExe.fsproj @@ -1,63 +1,8 @@ - - - + - $(MSBuildProjectDirectory)\..\..\..\src - - - Debug - AnyCPU - $(MSBuildProjectDirectory)\..\..\ - 2.0 - {f9540ca8-1ce0-4546-a23a-a461e416e95b} + net46 Exe - FsiExe - FsiExe - v4.5 - FsiExe - 40 - - true - - - true - full - false - false - bin\Debug\ - TRACE;DEBUG - 3 - AnyCPU - bin\Debug\FsiExe.xml - true - - - - pdbonly - true - true - bin\Release\ - TRACE - 3 - AnyCPU - bin\Release\FsiExe.xml - true - - - - - $(FSharpSourcesRoot)\..\packages\FSharp.Compiler.Tools.4.1.27\tools\FSharp.Core.dll - true - - - - - - - - - @@ -65,11 +10,8 @@ - - FSharp.Compiler.Service - {2e4d67b4-522d-4cf7-97e4-ba940f0b18f3} - True - + + + - - \ No newline at end of file + diff --git a/fcs/samples/FsiExe/paket.references b/fcs/samples/FsiExe/paket.references deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/fcs/samples/InteractiveService/InteractiveService.fsproj b/fcs/samples/InteractiveService/InteractiveService.fsproj index 91f16cf41fc..43c9c8ab1c4 100644 --- a/fcs/samples/InteractiveService/InteractiveService.fsproj +++ b/fcs/samples/InteractiveService/InteractiveService.fsproj @@ -1,68 +1,13 @@ - - - + - $(MSBuildProjectDirectory)\..\..\..\src - - - Debug - AnyCPU - $(MSBuildProjectDirectory)\..\..\ - 2.0 - 067e95e5-e3dc-4ca7-813a-4d1e277d2d52 + net46 Exe - InteractiveService - InteractiveService - v4.5 - InteractiveService - 4.4.0.0 - - true - - - true - full - false - false - bin\Debug\ - DEBUG;TRACE - 3 - AnyCPU - bin\Debug\InteractiveService.xml - true - - pdbonly - true - true - bin\Release\ - TRACE - 3 - AnyCPU - bin\Release\InteractiveService.xml - true - - - - - $(FSharpSourcesRoot)\..\packages\FSharp.Compiler.Tools.4.1.27\tools\FSharp.Core.dll - true - - - - - - - - FSharp.Compiler.Service - {2e4d67b4-522d-4cf7-97e4-ba940f0b18f3} - True - + - - \ No newline at end of file + diff --git a/fcs/samples/InteractiveService/paket.references b/fcs/samples/InteractiveService/paket.references deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/fcs/samples/Tokenizer/Tokenizer.fsproj b/fcs/samples/Tokenizer/Tokenizer.fsproj index 72f0cba2961..43c9c8ab1c4 100644 --- a/fcs/samples/Tokenizer/Tokenizer.fsproj +++ b/fcs/samples/Tokenizer/Tokenizer.fsproj @@ -1,71 +1,13 @@ - - - + - $(MSBuildProjectDirectory)\..\..\..\src - - - Debug - AnyCPU - $(MSBuildProjectDirectory)\..\..\ - 2.0 - 92793069-816f-4f69-84ac-0966f8275e65 + net46 Exe - Tokenizer - Tokenizer - v4.5 - Tokenizer - 4.4.0.0 - - true - - - true - full - false - false - bin\Debug\ - DEBUG;TRACE - 3 - AnyCPU - bin\Debug\Tokenizer.xml - true - - - pdbonly - true - true - bin\Release\ - TRACE - 3 - AnyCPU - bin\Release\Tokenizer.xml - true - - - - $(FSharpSourcesRoot)\..\packages\FSharp.Compiler.Tools.4.1.27\tools\FSharp.Core.dll - true - - - - - - - - FSharp.Compiler.Service - {2e4d67b4-522d-4cf7-97e4-ba940f0b18f3} - True - + - - 11 - - - \ No newline at end of file + diff --git a/fcs/samples/Tokenizer/paket.references b/fcs/samples/Tokenizer/paket.references deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/fcs/samples/UntypedTree/UntypedTree.fsproj b/fcs/samples/UntypedTree/UntypedTree.fsproj index c9faade7af0..43c9c8ab1c4 100644 --- a/fcs/samples/UntypedTree/UntypedTree.fsproj +++ b/fcs/samples/UntypedTree/UntypedTree.fsproj @@ -1,71 +1,13 @@ - - - + - $(MSBuildProjectDirectory)\..\..\..\src - - - Debug - AnyCPU - 2.0 - c816728d-bbea-472d-9f6c-e8913957a673 + net46 Exe - UntypedTree - UntypedTree - v4.5 - UntypedTree - 4.4.0.0 - - true - $(MSBuildProjectDirectory)\..\..\ - - - true - full - false - false - bin\Debug\ - DEBUG;TRACE - 3 - AnyCPU - bin\Debug\UntypedTree.xml - true - - - pdbonly - true - true - bin\Release\ - TRACE - 3 - AnyCPU - bin\Release\UntypedTree.xml - true - - - - $(FSharpSourcesRoot)\..\packages\FSharp.Compiler.Tools.4.1.27\tools\FSharp.Core.dll - true - - - - - - - - FSharp.Compiler.Service - {2e4d67b4-522d-4cf7-97e4-ba940f0b18f3} - True - + - - 11 - - - \ No newline at end of file + diff --git a/fcs/samples/UntypedTree/UntypedTree.sln b/fcs/samples/UntypedTree/UntypedTree.sln deleted file mode 100644 index a7b50130754..00000000000 --- a/fcs/samples/UntypedTree/UntypedTree.sln +++ /dev/null @@ -1,20 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 2012 -Project("{F2A71F9B-5D33-465A-A702-920D77279786}") = "UntypedTree", "UntypedTree.fsproj", "{C816728D-BBEA-472D-9F6C-E8913957A673}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Any CPU = Debug|Any CPU - Release|Any CPU = Release|Any CPU - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {C816728D-BBEA-472D-9F6C-E8913957A673}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {C816728D-BBEA-472D-9F6C-E8913957A673}.Debug|Any CPU.Build.0 = Debug|Any CPU - {C816728D-BBEA-472D-9F6C-E8913957A673}.Release|Any CPU.ActiveCfg = Release|Any CPU - {C816728D-BBEA-472D-9F6C-E8913957A673}.Release|Any CPU.Build.0 = Release|Any CPU - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection -EndGlobal diff --git a/fcs/samples/UntypedTree/paket.references b/fcs/samples/UntypedTree/paket.references deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/src/scripts/fssrgen.targets b/src/scripts/fssrgen.targets index 220a971bbdb..ab7bf40eb68 100644 --- a/src/scripts/fssrgen.targets +++ b/src/scripts/fssrgen.targets @@ -13,7 +13,7 @@ Copyright (C) Microsoft Corporation. All Rights Reserved. - ProcessFsSrGen;$(PrepareForBuildDependsOn) + ProcessFsSrGen;$(ResGenDependsOn) From a55c8a02a1887dc0927cbe28ad56bf17cfb09d58 Mon Sep 17 00:00:00 2001 From: Don Syme Date: Mon, 26 Feb 2018 19:51:01 +0000 Subject: [PATCH 04/11] build nugets and test on mono --- ...FSharp.Compiler.Service.MSBuild.v12.fsproj | 5 +- ...arp.Compiler.Service.ProjectCracker.fsproj | 7 +-- ...Compiler.Service.ProjectCrackerTool.fsproj | 6 +- .../paket.references | 4 -- .../CSharp_Analysis/CSharp_Analysis.csproj | 9 +++ .../FSharp.Compiler.Service.Tests.fsproj | 2 +- fcs/FSharp.Compiler.Service.sln | 2 +- .../FSharp.Compiler.Service.fsproj | 2 - fcs/build.fsx | 59 +++++++++---------- fcs/paket.dependencies | 6 -- tests/service/ProjectOptionsTests.fs | 14 ++++- 11 files changed, 57 insertions(+), 59 deletions(-) delete mode 100644 fcs/FSharp.Compiler.Service.ProjectCrackerTool/paket.references create mode 100644 fcs/FSharp.Compiler.Service.Tests/CSharp_Analysis/CSharp_Analysis.csproj diff --git a/fcs/FSharp.Compiler.Service.MSBuild.v12/FSharp.Compiler.Service.MSBuild.v12.fsproj b/fcs/FSharp.Compiler.Service.MSBuild.v12/FSharp.Compiler.Service.MSBuild.v12.fsproj index 4a919e3bbda..fa208a44036 100644 --- a/fcs/FSharp.Compiler.Service.MSBuild.v12/FSharp.Compiler.Service.MSBuild.v12.fsproj +++ b/fcs/FSharp.Compiler.Service.MSBuild.v12/FSharp.Compiler.Service.MSBuild.v12.fsproj @@ -23,10 +23,7 @@ Service/MSBuildReferenceResolver.fs - - $(FSharpSourcesRoot)\..\packages\Microsoft.Portable.FSharp.Core.4.1.20\lib\profiles\net40\FSharp.Core.dll - false - + $(FSharpSourcesRoot)\..\fcs\dependencies\MSBuild.v12.0\Microsoft.Build.Framework.dll false diff --git a/fcs/FSharp.Compiler.Service.ProjectCracker/FSharp.Compiler.Service.ProjectCracker.fsproj b/fcs/FSharp.Compiler.Service.ProjectCracker/FSharp.Compiler.Service.ProjectCracker.fsproj index 96a0923814d..506dccf4cfc 100644 --- a/fcs/FSharp.Compiler.Service.ProjectCracker/FSharp.Compiler.Service.ProjectCracker.fsproj +++ b/fcs/FSharp.Compiler.Service.ProjectCracker/FSharp.Compiler.Service.ProjectCracker.fsproj @@ -26,11 +26,8 @@ - - - $(FSharpSourcesRoot)\..\packages\Microsoft.Portable.FSharp.Core.4.1.20\lib\profiles\net40\FSharp.Core.dll - false - + + \ No newline at end of file diff --git a/fcs/FSharp.Compiler.Service.ProjectCrackerTool/FSharp.Compiler.Service.ProjectCrackerTool.fsproj b/fcs/FSharp.Compiler.Service.ProjectCrackerTool/FSharp.Compiler.Service.ProjectCrackerTool.fsproj index 555ac872bc2..ffd4566ee67 100644 --- a/fcs/FSharp.Compiler.Service.ProjectCrackerTool/FSharp.Compiler.Service.ProjectCrackerTool.fsproj +++ b/fcs/FSharp.Compiler.Service.ProjectCrackerTool/FSharp.Compiler.Service.ProjectCrackerTool.fsproj @@ -19,11 +19,7 @@ - - - $(FSharpSourcesRoot)\..\packages\Microsoft.Portable.FSharp.Core.4.1.20\lib\profiles\net40\FSharp.Core.dll - false - + $(FSharpSourcesRoot)\..\fcs\dependencies\MSBuild.v12.0\Microsoft.Build.Framework.dll false diff --git a/fcs/FSharp.Compiler.Service.ProjectCrackerTool/paket.references b/fcs/FSharp.Compiler.Service.ProjectCrackerTool/paket.references deleted file mode 100644 index 3ad1f9662c7..00000000000 --- a/fcs/FSharp.Compiler.Service.ProjectCrackerTool/paket.references +++ /dev/null @@ -1,4 +0,0 @@ -Microsoft.Build.Utilities.Core -Microsoft.Build.Engine -Microsoft.Build -System.Threading.Tasks.Dataflow \ No newline at end of file diff --git a/fcs/FSharp.Compiler.Service.Tests/CSharp_Analysis/CSharp_Analysis.csproj b/fcs/FSharp.Compiler.Service.Tests/CSharp_Analysis/CSharp_Analysis.csproj new file mode 100644 index 00000000000..2e44f48f9ea --- /dev/null +++ b/fcs/FSharp.Compiler.Service.Tests/CSharp_Analysis/CSharp_Analysis.csproj @@ -0,0 +1,9 @@ + + + net45;netstandard2.0 + false + + + + + \ No newline at end of file diff --git a/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj b/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj index b1188a181e6..92097280161 100644 --- a/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj +++ b/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj @@ -90,7 +90,7 @@ - + \ No newline at end of file diff --git a/fcs/FSharp.Compiler.Service.sln b/fcs/FSharp.Compiler.Service.sln index 2fe403a3e36..192f8bd6242 100644 --- a/fcs/FSharp.Compiler.Service.sln +++ b/fcs/FSharp.Compiler.Service.sln @@ -51,7 +51,7 @@ Project("{F2A71F9B-5D33-465A-A702-920D77279786}") = "UntypedTree", "samples\Unty EndProject Project("{F2A71F9B-5D33-465A-A702-920D77279786}") = "FscExe", "samples\FscExe\FscExe.fsproj", "{C94C257C-3C0A-4858-B5D8-D746498D1F08}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CSharp_Analysis", "..\tests\service\data\CSharp_Analysis\CSharp_Analysis.csproj", "{887630A3-4B1D-40EA-B8B3-2D842E9C40DB}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CSharp_Analysis", "FSharp.Compiler.Service.Tests\CSharp_Analysis\CSharp_Analysis.csproj", "{887630A3-4B1D-40EA-B8B3-2D842E9C40DB}" EndProject Project("{F2A71F9B-5D33-465A-A702-920D77279786}") = "FsiExe", "samples\FsiExe\FsiExe.fsproj", "{F9540CA8-1CE0-4546-A23A-A461E416E95B}" EndProject diff --git a/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj b/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj index 30fd8ec4a36..4b3148b9c8c 100644 --- a/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj +++ b/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj @@ -18,7 +18,6 @@ true true true - The F# compiler as library. For editors, for tools, for scripting. For you. @@ -31,7 +30,6 @@ F#, fsharp, interactive, compiler, editor - $(DefineConstants);FX_NO_PDB_READER $(DefineConstants);FX_NO_PDB_WRITER $(DefineConstants);FX_NO_SYMBOLSTORE diff --git a/fcs/build.fsx b/fcs/build.fsx index 1920ea051c1..fe17781d556 100644 --- a/fcs/build.fsx +++ b/fcs/build.fsx @@ -69,66 +69,65 @@ let buildVersion = else if isAppVeyorBuild then sprintf "%s-b%s" assemblyVersion AppVeyorEnvironment.BuildNumber else assemblyVersion -let skipBuild = false // isJenkinsBuild && isMono - Target "Clean" (fun _ -> - if not skipBuild then - CleanDir releaseDir + () + //CleanDir releaseDir ) Target "Restore" (fun _ -> - if not skipBuild then - runDotnet __SOURCE_DIRECTORY__ "restore FSharp.Compiler.Service/FSharp.Compiler.Service.sln -v n" - for p in (!! "./../packages.config") do - let result = - ExecProcess (fun info -> - info.FileName <- FullName @"./../.nuget/NuGet.exe" - info.WorkingDirectory <- FullName @"./.." - info.Arguments <- sprintf "restore %s -PackagesDirectory \"%s\" -ConfigFile \"%s\"" (FullName p) (FullName "./../packages") (FullName "./../NuGet.Config")) TimeSpan.MaxValue - if result <> 0 then failwithf "nuget restore %s failed" p + // We assume a paket restore has already been run + runDotnet __SOURCE_DIRECTORY__ "restore FSharp.Compiler.Service.sln -v n" + for p in [ "../packages.config" ] do + ExecProcess (fun info -> + info.FileName <- FullName @"./../.nuget/NuGet.exe" + info.WorkingDirectory <- FullName @"./.." + info.Arguments <- sprintf "restore %s -PackagesDirectory \"%s\" -ConfigFile \"%s\"" (FullName p) (FullName "./../packages") (FullName "./../NuGet.Config")) TimeSpan.MaxValue + |> assertExitCodeZero ) Target "BuildVersion" (fun _ -> - if not skipBuild then Shell.Exec("appveyor", sprintf "UpdateBuild -Version \"%s\"" buildVersion) |> ignore ) Target "Build" (fun _ -> - if skipBuild then - try Directory.CreateDirectory("../Release/") |> ignore with _ -> () - File.WriteAllText("../Release/nichts.txt", "nothing to see here, build was skipped until we knoow how to get an updated version of Mono installed on Jenkins") - else - runDotnet __SOURCE_DIRECTORY__ "build FSharp.Compiler.Service/FSharp.Compiler.Service.sln -v n -c Release /maxcpucount:1" + // Currently needs to use 'msbuild' on Mono, because 'dotnet' doesn't know about Mono's copy of the reference assemblies for .NET Framework + if isMono then + Shell.Exec("msbuild", "FSharp.Compiler.Service.sln /v:n /p:Configuration=Release") |> assertExitCodeZero + else + runDotnet __SOURCE_DIRECTORY__ "build FSharp.Compiler.Service.sln -v n -c Release" ) Target "Test" (fun _ -> - if not skipBuild then + // Test on net46. Currently needs to use 'msbuild' on Mono because 'dotnet' doesn't know about Mono's copy of the reference assemblies for .NET Framework + if isMono then + runCmdIn __SOURCE_DIRECTORY__ "../packages/NUnit.Console.3.0.0/tools/nunit3-console.exe" "../release/fcs/net46/FSharp.Compiler.Service.Tests.dll" + else + runDotnet __SOURCE_DIRECTORY__ "test FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj -v n -c Release -f net46" + + // This project file is used for the netcoreapp2.0 tests to work out reference sets runDotnet __SOURCE_DIRECTORY__ "restore ../tests/projects/Sample_NETCoreSDK_FSharp_Library_netstandard2_0/Sample_NETCoreSDK_FSharp_Library_netstandard2_0.fsproj -v n" runDotnet __SOURCE_DIRECTORY__ "build ../tests/projects/Sample_NETCoreSDK_FSharp_Library_netstandard2_0/Sample_NETCoreSDK_FSharp_Library_netstandard2_0.fsproj -v n" - runDotnet __SOURCE_DIRECTORY__ "test FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj -v n -c Release /maxcpucount:1" -) + // Test on netcoreapp2.0 + runDotnet __SOURCE_DIRECTORY__ "test FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj -v n -c Release -f netcoreapp2.0" +) Target "NuGet" (fun _ -> - if not skipBuild then - runDotnet __SOURCE_DIRECTORY__ "build FSharp.Compiler.Service.ProjectCrackerTool/FSharp.Compiler.Service.ProjectCrackerTool.fsproj -v n -c Release /maxcpucount:1" - runDotnet __SOURCE_DIRECTORY__ "pack FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj -v n -c Release /maxcpucount:1" - runDotnet __SOURCE_DIRECTORY__ "pack FSharp.Compiler.Service.ProjectCracker/FSharp.Compiler.Service.ProjectCracker.fsproj -v n -c Release /maxcpucount:1" - runDotnet __SOURCE_DIRECTORY__ "pack FSharp.Compiler.Service.MSBuild.v12/FSharp.Compiler.Service.MSBuild.v12.fsproj -v n -c Release /maxcpucount:1" + if isMono then + Shell.Exec("msbuild", "FSharp.Compiler.Service.sln /v:n /p:Configuration=Release /t:Pack") |> assertExitCodeZero + else + runDotnet __SOURCE_DIRECTORY__ "pack FSharp.Compiler.Service.sln -v n -c Release" ) Target "GenerateDocsEn" (fun _ -> - if not skipBuild then executeFSIWithArgs "docsrc/tools" "generate.fsx" [] [] |> ignore ) Target "GenerateDocsJa" (fun _ -> - if not skipBuild then executeFSIWithArgs "docsrc/tools" "generate.ja.fsx" [] [] |> ignore ) Target "PublishNuGet" (fun _ -> - if not skipBuild then Paket.Push (fun p -> let apikey = match getBuildParam "nuget-apikey" with diff --git a/fcs/paket.dependencies b/fcs/paket.dependencies index 39535eedd9d..ccaead9f031 100644 --- a/fcs/paket.dependencies +++ b/fcs/paket.dependencies @@ -4,9 +4,3 @@ source https://www.nuget.org/api/v2/ nuget FAKE nuget FSharp.Formatting - -nuget Microsoft.Build.Utilities.Core 14.3.0 -nuget Microsoft.Build.Framework 14.3.0 -nuget Microsoft.Build.Engine 14.3.0 -nuget Microsoft.Build 14.3.0 -nuget System.Threading.Tasks.Dataflow 4.5.24.0 \ No newline at end of file diff --git a/tests/service/ProjectOptionsTests.fs b/tests/service/ProjectOptionsTests.fs index 07bf18f86ca..3ab2e1c2dab 100644 --- a/tests/service/ProjectOptionsTests.fs +++ b/tests/service/ProjectOptionsTests.fs @@ -543,10 +543,15 @@ ImplFile.x File.WriteAllText(fileName1, fileSource1) File.WriteAllText(fileName2, fileSource2) + printfn "------Starting Script load closure project----" + printfn "Getting project options..." let projectOptions, diagnostics = - checker.GetProjectOptionsFromScript(fileName2, fileSource2) |> Async.RunSynchronously + checker.GetProjectOptionsFromScript(fileName2, fileSource2, useFsiAuxLib=false) |> Async.RunSynchronously + for d in diagnostics do + printfn "ERROR: %A" d diagnostics.IsEmpty |> shouldEqual true + printfn "Parse and check..." let _, checkResults = checker.ParseAndCheckFileInProject(fileName2, 0, fileSource2, projectOptions) |> Async.RunSynchronously @@ -555,13 +560,20 @@ ImplFile.x results.Errors |> shouldEqual [| |] | _ -> failwith "type check was aborted" + printfn "Getting parsing options..." let parsingOptions, diagnostics = checker.GetParsingOptionsFromProjectOptions(projectOptions) + for d in diagnostics do + printfn "ERROR: %A" d diagnostics.IsEmpty |> shouldEqual true + printfn "Parsing file..." let parseResults = checker.ParseFile(fileName1, fileSource1, parsingOptions) |> Async.RunSynchronously + printfn "Checking parsetree..." parseResults.ParseTree.IsSome |> shouldEqual true + printfn "Checking decls..." match parseResults.ParseTree.Value with | ParsedInput.ImplFile (ParsedImplFileInput (_, _, _, _, _, modules, _)) -> let (SynModuleOrNamespace (_, _, _, decls, _, _, _, _)) = modules.Head decls.Length |> shouldEqual 1 | _ -> failwith "got sig file" + printfn "------Finished Script load closure project----" From a274dcd34d60cbe4267c0ad9d9d28484bfe4175c Mon Sep 17 00:00:00 2001 From: Don Syme Date: Mon, 26 Feb 2018 21:05:08 +0000 Subject: [PATCH 05/11] fix proto build --- fcs/paket.lock | 16 +--------------- src/scripts/fssrgen.targets | 2 +- 2 files changed, 2 insertions(+), 16 deletions(-) diff --git a/fcs/paket.lock b/fcs/paket.lock index 947bfc412b7..1ead25b452a 100644 --- a/fcs/paket.lock +++ b/fcs/paket.lock @@ -1,24 +1,10 @@ RESTRICTION: || (== net45) (== net46) NUGET remote: https://www.nuget.org/api/v2 - FAKE (4.63.2) + FAKE (4.64.6) FSharp.Compiler.Service (2.0.0.6) FSharp.Formatting (2.14.4) FSharp.Compiler.Service (2.0.0.6) FSharpVSPowerTools.Core (>= 2.3 < 2.4) FSharpVSPowerTools.Core (2.3) FSharp.Compiler.Service (>= 2.0.0.3) - Microsoft.Build (14.3) - Microsoft.Build.Framework (14.3) - Microsoft.Build.Engine (14.3) - Microsoft.Build.Framework (14.3) - Microsoft.Build.Framework (14.3) - System.Collections (>= 4.0.11) - restriction: || (&& (== net45) (>= netstandard1.3)) (== net46) - System.Runtime (>= 4.1) - restriction: || (&& (== net45) (>= netstandard1.3)) (== net46) - System.Runtime.InteropServices (>= 4.1) - restriction: || (&& (== net45) (>= netstandard1.3)) (== net46) - Microsoft.Build.Utilities.Core (14.3) - Microsoft.Build.Framework (14.3) - System.Collections (4.3) - restriction: || (&& (== net45) (>= netstandard1.3)) (== net46) - System.Runtime (4.3) - restriction: || (&& (== net45) (>= netstandard1.3)) (== net46) - System.Runtime.InteropServices (4.3) - restriction: || (&& (== net45) (>= netstandard1.3)) (== net46) - System.Threading.Tasks.Dataflow (4.5.24) diff --git a/src/scripts/fssrgen.targets b/src/scripts/fssrgen.targets index ab7bf40eb68..3458dd5bff5 100644 --- a/src/scripts/fssrgen.targets +++ b/src/scripts/fssrgen.targets @@ -13,7 +13,7 @@ Copyright (C) Microsoft Corporation. All Rights Reserved. - ProcessFsSrGen;$(ResGenDependsOn) + ProcessFsSrGen;$(BuildDependsOn) From 03d9c719cbd1b501980afce1ea477ce93ee9003a Mon Sep 17 00:00:00 2001 From: Don Syme Date: Mon, 26 Feb 2018 23:22:24 +0000 Subject: [PATCH 06/11] remove mono workarounds using msbuild, use dotnet instead --- ...FSharp.Compiler.Service.MSBuild.v12.fsproj | 2 +- ...arp.Compiler.Service.ProjectCracker.fsproj | 1 + ...Compiler.Service.ProjectCrackerTool.fsproj | 1 + .../CSharp_Analysis/CSharp_Analysis.csproj | 1 + .../FSharp.Compiler.Service.Tests.fsproj | 5 +++- .../FSharp.Compiler.Service.fsproj | 3 +++ fcs/build.fsx | 27 +++++-------------- .../EditorService/EditorService.fsproj | 3 +++ fcs/samples/FscExe/FscExe.fsproj | 3 +++ fcs/samples/FsiExe/FsiExe.fsproj | 3 +++ .../InteractiveService.fsproj | 3 +++ fcs/samples/Tokenizer/Tokenizer.fsproj | 3 +++ fcs/samples/UntypedTree/UntypedTree.fsproj | 3 +++ 13 files changed, 36 insertions(+), 22 deletions(-) diff --git a/fcs/FSharp.Compiler.Service.MSBuild.v12/FSharp.Compiler.Service.MSBuild.v12.fsproj b/fcs/FSharp.Compiler.Service.MSBuild.v12/FSharp.Compiler.Service.MSBuild.v12.fsproj index fa208a44036..49c3436f488 100644 --- a/fcs/FSharp.Compiler.Service.MSBuild.v12/FSharp.Compiler.Service.MSBuild.v12.fsproj +++ b/fcs/FSharp.Compiler.Service.MSBuild.v12/FSharp.Compiler.Service.MSBuild.v12.fsproj @@ -3,6 +3,7 @@ $(MSBuildProjectDirectory)\..\..\src + net45 ..\..\$(Configuration.ToLower())\fcs @@ -23,7 +24,6 @@ Service/MSBuildReferenceResolver.fs - $(FSharpSourcesRoot)\..\fcs\dependencies\MSBuild.v12.0\Microsoft.Build.Framework.dll false diff --git a/fcs/FSharp.Compiler.Service.ProjectCracker/FSharp.Compiler.Service.ProjectCracker.fsproj b/fcs/FSharp.Compiler.Service.ProjectCracker/FSharp.Compiler.Service.ProjectCracker.fsproj index 506dccf4cfc..ab486b6cbcf 100644 --- a/fcs/FSharp.Compiler.Service.ProjectCracker/FSharp.Compiler.Service.ProjectCracker.fsproj +++ b/fcs/FSharp.Compiler.Service.ProjectCracker/FSharp.Compiler.Service.ProjectCracker.fsproj @@ -3,6 +3,7 @@ $(MSBuildProjectDirectory)\..\..\src + net45 ..\..\$(Configuration.ToLower())\fcs diff --git a/fcs/FSharp.Compiler.Service.ProjectCrackerTool/FSharp.Compiler.Service.ProjectCrackerTool.fsproj b/fcs/FSharp.Compiler.Service.ProjectCrackerTool/FSharp.Compiler.Service.ProjectCrackerTool.fsproj index ffd4566ee67..871579de358 100644 --- a/fcs/FSharp.Compiler.Service.ProjectCrackerTool/FSharp.Compiler.Service.ProjectCrackerTool.fsproj +++ b/fcs/FSharp.Compiler.Service.ProjectCrackerTool/FSharp.Compiler.Service.ProjectCrackerTool.fsproj @@ -3,6 +3,7 @@ $(MSBuildProjectDirectory)\..\..\src + Exe net45 diff --git a/fcs/FSharp.Compiler.Service.Tests/CSharp_Analysis/CSharp_Analysis.csproj b/fcs/FSharp.Compiler.Service.Tests/CSharp_Analysis/CSharp_Analysis.csproj index 2e44f48f9ea..49585864e4d 100644 --- a/fcs/FSharp.Compiler.Service.Tests/CSharp_Analysis/CSharp_Analysis.csproj +++ b/fcs/FSharp.Compiler.Service.Tests/CSharp_Analysis/CSharp_Analysis.csproj @@ -1,4 +1,5 @@  + net45;netstandard2.0 false diff --git a/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj b/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj index 92097280161..dd799e70ff8 100644 --- a/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj +++ b/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj @@ -3,13 +3,15 @@ $(MSBuildProjectDirectory)\..\..\src + net46;netcoreapp2.0 $(NoWarn);44; true portable true - ..\..\$(Configuration.ToLower())\fcs + false + true $(DefineConstants);FX_NO_RUNTIMEENVIRONMENT @@ -70,6 +72,7 @@ + diff --git a/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj b/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj index 4b3148b9c8c..b11fb3b1695 100644 --- a/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj +++ b/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj @@ -3,6 +3,7 @@ $(MSBuildProjectDirectory)\..\..\src + net45;netstandard2.0 $(DefineConstants);COMPILER_SERVICE_AS_DLL @@ -642,6 +643,8 @@ + + $(FSharpSourcesRoot)\..\packages\Microsoft.DiaSymReader.PortablePdb.1.2.0\lib\portable-net45+win8\Microsoft.DiaSymReader.PortablePdb.dll diff --git a/fcs/build.fsx b/fcs/build.fsx index fe17781d556..03b57797b02 100644 --- a/fcs/build.fsx +++ b/fcs/build.fsx @@ -70,8 +70,7 @@ let buildVersion = else assemblyVersion Target "Clean" (fun _ -> - () - //CleanDir releaseDir + CleanDir releaseDir ) Target "Restore" (fun _ -> @@ -90,33 +89,20 @@ Target "BuildVersion" (fun _ -> ) Target "Build" (fun _ -> - // Currently needs to use 'msbuild' on Mono, because 'dotnet' doesn't know about Mono's copy of the reference assemblies for .NET Framework - if isMono then - Shell.Exec("msbuild", "FSharp.Compiler.Service.sln /v:n /p:Configuration=Release") |> assertExitCodeZero - else - runDotnet __SOURCE_DIRECTORY__ "build FSharp.Compiler.Service.sln -v n -c Release" + runDotnet __SOURCE_DIRECTORY__ "build FSharp.Compiler.Service.sln -v n -c Release" ) Target "Test" (fun _ -> - // Test on net46. Currently needs to use 'msbuild' on Mono because 'dotnet' doesn't know about Mono's copy of the reference assemblies for .NET Framework - if isMono then - runCmdIn __SOURCE_DIRECTORY__ "../packages/NUnit.Console.3.0.0/tools/nunit3-console.exe" "../release/fcs/net46/FSharp.Compiler.Service.Tests.dll" - else - runDotnet __SOURCE_DIRECTORY__ "test FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj -v n -c Release -f net46" - // This project file is used for the netcoreapp2.0 tests to work out reference sets runDotnet __SOURCE_DIRECTORY__ "restore ../tests/projects/Sample_NETCoreSDK_FSharp_Library_netstandard2_0/Sample_NETCoreSDK_FSharp_Library_netstandard2_0.fsproj -v n" runDotnet __SOURCE_DIRECTORY__ "build ../tests/projects/Sample_NETCoreSDK_FSharp_Library_netstandard2_0/Sample_NETCoreSDK_FSharp_Library_netstandard2_0.fsproj -v n" - // Test on netcoreapp2.0 - runDotnet __SOURCE_DIRECTORY__ "test FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj -v n -c Release -f netcoreapp2.0" + // Now run the tests + runDotnet __SOURCE_DIRECTORY__ "test FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj -v n -c Release" ) Target "NuGet" (fun _ -> - if isMono then - Shell.Exec("msbuild", "FSharp.Compiler.Service.sln /v:n /p:Configuration=Release /t:Pack") |> assertExitCodeZero - else - runDotnet __SOURCE_DIRECTORY__ "pack FSharp.Compiler.Service.sln -v n -c Release" + runDotnet __SOURCE_DIRECTORY__ "pack FSharp.Compiler.Service.sln -v n -c Release" ) Target "GenerateDocsEn" (fun _ -> @@ -141,11 +127,12 @@ Target "PublishNuGet" (fun _ -> // -------------------------------------------------------------------------------------- // Run all targets by default. Invoke 'build ' to override +Target "Start" DoNothing Target "Release" DoNothing Target "GenerateDocs" DoNothing Target "TestAndNuGet" DoNothing -"Clean" +"Start" =?> ("BuildVersion", isAppVeyorBuild) ==> "Restore" ==> "Build" diff --git a/fcs/samples/EditorService/EditorService.fsproj b/fcs/samples/EditorService/EditorService.fsproj index f6e695448a4..1ece0d95e16 100644 --- a/fcs/samples/EditorService/EditorService.fsproj +++ b/fcs/samples/EditorService/EditorService.fsproj @@ -1,4 +1,6 @@  + + net46;netcoreapp2.0 Exe @@ -8,6 +10,7 @@ + diff --git a/fcs/samples/FscExe/FscExe.fsproj b/fcs/samples/FscExe/FscExe.fsproj index 781767220d8..50104299f51 100644 --- a/fcs/samples/FscExe/FscExe.fsproj +++ b/fcs/samples/FscExe/FscExe.fsproj @@ -1,4 +1,6 @@  + + net46 Exe @@ -10,6 +12,7 @@ + diff --git a/fcs/samples/FsiExe/FsiExe.fsproj b/fcs/samples/FsiExe/FsiExe.fsproj index 2825037e7bc..6455870117c 100644 --- a/fcs/samples/FsiExe/FsiExe.fsproj +++ b/fcs/samples/FsiExe/FsiExe.fsproj @@ -1,4 +1,6 @@  + + net46 Exe @@ -12,6 +14,7 @@ + diff --git a/fcs/samples/InteractiveService/InteractiveService.fsproj b/fcs/samples/InteractiveService/InteractiveService.fsproj index 43c9c8ab1c4..5c5af36461e 100644 --- a/fcs/samples/InteractiveService/InteractiveService.fsproj +++ b/fcs/samples/InteractiveService/InteractiveService.fsproj @@ -1,4 +1,6 @@  + + net46 Exe @@ -8,6 +10,7 @@ + diff --git a/fcs/samples/Tokenizer/Tokenizer.fsproj b/fcs/samples/Tokenizer/Tokenizer.fsproj index 43c9c8ab1c4..5c5af36461e 100644 --- a/fcs/samples/Tokenizer/Tokenizer.fsproj +++ b/fcs/samples/Tokenizer/Tokenizer.fsproj @@ -1,4 +1,6 @@  + + net46 Exe @@ -8,6 +10,7 @@ + diff --git a/fcs/samples/UntypedTree/UntypedTree.fsproj b/fcs/samples/UntypedTree/UntypedTree.fsproj index 43c9c8ab1c4..5c5af36461e 100644 --- a/fcs/samples/UntypedTree/UntypedTree.fsproj +++ b/fcs/samples/UntypedTree/UntypedTree.fsproj @@ -1,4 +1,6 @@  + + net46 Exe @@ -8,6 +10,7 @@ + From 4c300d1e113a72d7cf37dc353a98cc1da78645e9 Mon Sep 17 00:00:00 2001 From: Don Syme Date: Mon, 26 Feb 2018 23:25:00 +0000 Subject: [PATCH 07/11] add comment --- .../FSharp.Compiler.Service.Tests.fsproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj b/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj index dd799e70ff8..20f5ff9a80f 100644 --- a/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj +++ b/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj @@ -11,7 +11,7 @@ portable true false - true + true $(DefineConstants);FX_NO_RUNTIMEENVIRONMENT From 96b85f2f3c779669f9d4c4082ed423abda2107a4 Mon Sep 17 00:00:00 2001 From: Don Syme Date: Mon, 26 Feb 2018 23:33:46 +0000 Subject: [PATCH 08/11] set IsPackable=false explicitly in samples --- .../FSharp.Compiler.Service.MSBuild.v12.fsproj | 5 ++++- .../FSharp.Compiler.Service.Tests.fsproj | 4 ---- fcs/samples/EditorService/EditorService.fsproj | 1 + fcs/samples/FscExe/FscExe.fsproj | 1 + fcs/samples/FsiExe/FsiExe.fsproj | 1 + fcs/samples/InteractiveService/InteractiveService.fsproj | 1 + fcs/samples/Tokenizer/Tokenizer.fsproj | 1 + fcs/samples/UntypedTree/UntypedTree.fsproj | 1 + 8 files changed, 10 insertions(+), 5 deletions(-) diff --git a/fcs/FSharp.Compiler.Service.MSBuild.v12/FSharp.Compiler.Service.MSBuild.v12.fsproj b/fcs/FSharp.Compiler.Service.MSBuild.v12/FSharp.Compiler.Service.MSBuild.v12.fsproj index 49c3436f488..7e96d797f77 100644 --- a/fcs/FSharp.Compiler.Service.MSBuild.v12/FSharp.Compiler.Service.MSBuild.v12.fsproj +++ b/fcs/FSharp.Compiler.Service.MSBuild.v12/FSharp.Compiler.Service.MSBuild.v12.fsproj @@ -24,6 +24,10 @@ Service/MSBuildReferenceResolver.fs + + + + $(FSharpSourcesRoot)\..\fcs\dependencies\MSBuild.v12.0\Microsoft.Build.Framework.dll false @@ -44,6 +48,5 @@ $(FSharpSourcesRoot)\..\fcs\dependencies\MSBuild.v12.0\Microsoft.Build.Tasks.v12.0.dll false - \ No newline at end of file diff --git a/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj b/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj index 20f5ff9a80f..1f168988d1b 100644 --- a/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj +++ b/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj @@ -8,7 +8,6 @@ net46;netcoreapp2.0 $(NoWarn);44; true - portable true false true @@ -66,9 +65,6 @@ Program.fs - - Program.fs - diff --git a/fcs/samples/EditorService/EditorService.fsproj b/fcs/samples/EditorService/EditorService.fsproj index 1ece0d95e16..a82f5e8bf9a 100644 --- a/fcs/samples/EditorService/EditorService.fsproj +++ b/fcs/samples/EditorService/EditorService.fsproj @@ -4,6 +4,7 @@ net46;netcoreapp2.0 Exe + false diff --git a/fcs/samples/FscExe/FscExe.fsproj b/fcs/samples/FscExe/FscExe.fsproj index 50104299f51..ae716f00027 100644 --- a/fcs/samples/FscExe/FscExe.fsproj +++ b/fcs/samples/FscExe/FscExe.fsproj @@ -4,6 +4,7 @@ net46 Exe + false $(DefineConstants);RESIDENT_COMPILER diff --git a/fcs/samples/FsiExe/FsiExe.fsproj b/fcs/samples/FsiExe/FsiExe.fsproj index 6455870117c..6ee84579726 100644 --- a/fcs/samples/FsiExe/FsiExe.fsproj +++ b/fcs/samples/FsiExe/FsiExe.fsproj @@ -4,6 +4,7 @@ net46 Exe + false diff --git a/fcs/samples/InteractiveService/InteractiveService.fsproj b/fcs/samples/InteractiveService/InteractiveService.fsproj index 5c5af36461e..6d767f44f42 100644 --- a/fcs/samples/InteractiveService/InteractiveService.fsproj +++ b/fcs/samples/InteractiveService/InteractiveService.fsproj @@ -4,6 +4,7 @@ net46 Exe + false diff --git a/fcs/samples/Tokenizer/Tokenizer.fsproj b/fcs/samples/Tokenizer/Tokenizer.fsproj index 5c5af36461e..6d767f44f42 100644 --- a/fcs/samples/Tokenizer/Tokenizer.fsproj +++ b/fcs/samples/Tokenizer/Tokenizer.fsproj @@ -4,6 +4,7 @@ net46 Exe + false diff --git a/fcs/samples/UntypedTree/UntypedTree.fsproj b/fcs/samples/UntypedTree/UntypedTree.fsproj index 5c5af36461e..6d767f44f42 100644 --- a/fcs/samples/UntypedTree/UntypedTree.fsproj +++ b/fcs/samples/UntypedTree/UntypedTree.fsproj @@ -4,6 +4,7 @@ net46 Exe + false From ea45f1a359bc5663e3c85fe04cb0d30c8b4cc062 Mon Sep 17 00:00:00 2001 From: Don Syme Date: Mon, 26 Feb 2018 23:35:35 +0000 Subject: [PATCH 09/11] missing file --- fcs/netfx.props | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 fcs/netfx.props diff --git a/fcs/netfx.props b/fcs/netfx.props new file mode 100644 index 00000000000..0c7c3a41c6e --- /dev/null +++ b/fcs/netfx.props @@ -0,0 +1,22 @@ + + + + + + + true + /Library/Frameworks/Mono.framework/Versions/Current/lib/mono + /usr/lib/mono + /usr/local/lib/mono + $(BaseFrameworkPathOverrideForMono)/4.5-api + $(BaseFrameworkPathOverrideForMono)/4.5.1-api + $(BaseFrameworkPathOverrideForMono)/4.5.2-api + $(BaseFrameworkPathOverrideForMono)/4.6-api + $(BaseFrameworkPathOverrideForMono)/4.6.1-api + $(BaseFrameworkPathOverrideForMono)/4.6.2-api + $(BaseFrameworkPathOverrideForMono)/4.7-api + $(BaseFrameworkPathOverrideForMono)/4.7.1-api + true + $(FrameworkPathOverride)/Facades;$(AssemblySearchPaths) + + \ No newline at end of file From e539679db85155edd7268e29786e90b6f916a9d7 Mon Sep 17 00:00:00 2001 From: Don Syme Date: Mon, 26 Feb 2018 23:38:26 +0000 Subject: [PATCH 10/11] add docs --- fcs/netfx.props | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/fcs/netfx.props b/fcs/netfx.props index 0c7c3a41c6e..95862eace83 100644 --- a/fcs/netfx.props +++ b/fcs/netfx.props @@ -5,9 +5,19 @@ true - /Library/Frameworks/Mono.framework/Versions/Current/lib/mono - /usr/lib/mono - /usr/local/lib/mono + + + + /Library/Frameworks/Mono.framework/Versions/Current/lib/mono + + + /usr/lib/mono + + + /usr/local/lib/mono + + + $(BaseFrameworkPathOverrideForMono)/4.5-api $(BaseFrameworkPathOverrideForMono)/4.5.1-api $(BaseFrameworkPathOverrideForMono)/4.5.2-api @@ -17,6 +27,8 @@ $(BaseFrameworkPathOverrideForMono)/4.7-api $(BaseFrameworkPathOverrideForMono)/4.7.1-api true + + $(FrameworkPathOverride)/Facades;$(AssemblySearchPaths) \ No newline at end of file From fe4042b0e54c85a5a5cb60403499c7bc258be530 Mon Sep 17 00:00:00 2001 From: Don Syme Date: Tue, 27 Feb 2018 00:05:24 +0000 Subject: [PATCH 11/11] fix minor things --- .../FSharp.Compiler.Service.Tests.fsproj | 2 +- .../FSharp.Compiler.Service.fsproj | 22 ++++++------------- fcs/netfx.props | 12 +++------- .../EditorService/EditorService.fsproj | 1 + 4 files changed, 12 insertions(+), 25 deletions(-) diff --git a/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj b/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj index 1f168988d1b..148b5f4dad6 100644 --- a/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj +++ b/fcs/FSharp.Compiler.Service.Tests/FSharp.Compiler.Service.Tests.fsproj @@ -68,7 +68,7 @@ - + diff --git a/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj b/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj index b11fb3b1695..8d7f42d4eec 100644 --- a/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj +++ b/fcs/FSharp.Compiler.Service/FSharp.Compiler.Service.fsproj @@ -631,33 +631,25 @@ Service/fsi.fs - + + + + + + + - - - - $(FSharpSourcesRoot)\..\packages\Microsoft.DiaSymReader.PortablePdb.1.2.0\lib\portable-net45+win8\Microsoft.DiaSymReader.PortablePdb.dll - - - $(FSharpSourcesRoot)\..\packages\Microsoft.DiaSymReader.1.1.0\lib\portable-net45+win8\Microsoft.DiaSymReader.dll - - - $(FSharpSourcesRoot)\..\packages\System.Reflection.Metadata.1.4.2\lib\portable-net45+win8\System.Reflection.Metadata.dll - - - $(FSharpSourcesRoot)\..\packages\System.Collections.Immutable.1.3.1\lib\portable-net45+win8+wp8+wpa81\System.Collections.Immutable.dll - $(FSharpSourcesRoot)\..\packages\System.ValueTuple.4.3.1\lib\netstandard1.0\System.ValueTuple.dll diff --git a/fcs/netfx.props b/fcs/netfx.props index 95862eace83..064f29b1809 100644 --- a/fcs/netfx.props +++ b/fcs/netfx.props @@ -7,15 +7,9 @@ true - - /Library/Frameworks/Mono.framework/Versions/Current/lib/mono - - - /usr/lib/mono - - - /usr/local/lib/mono - + /Library/Frameworks/Mono.framework/Versions/Current/lib/mono + /usr/lib/mono + /usr/local/lib/mono $(BaseFrameworkPathOverrideForMono)/4.5-api diff --git a/fcs/samples/EditorService/EditorService.fsproj b/fcs/samples/EditorService/EditorService.fsproj index a82f5e8bf9a..470cec8c1ef 100644 --- a/fcs/samples/EditorService/EditorService.fsproj +++ b/fcs/samples/EditorService/EditorService.fsproj @@ -13,5 +13,6 @@ +