Skip to content

restore coreclr.dll from a NuGet package instead of assuming its location #4005

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 27, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions tests/fsharp/packages.config
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
<package id="NUnit3TestAdapter" version="3.7.0" targetFramework="net45" />
<package id="runtime.win-x64.Microsoft.NETCore.ILDAsm" version="2.0.3" />
<package id="runtime.win-x86.Microsoft.NETCore.ILDAsm" version="2.0.3" />
<package id="runtime.win-x64.Microsoft.NETCore.Runtime.CoreCLR" version="2.0.3" />
<package id="runtime.win-x86.Microsoft.NETCore.Runtime.CoreCLR" version="2.0.3" />
<package id="System.Collections.Immutable" version="1.3.1" targetFramework="net45" />
<package id="System.Reflection.Metadata" version="1.4.2" targetFramework="net45" />
</packages>
6 changes: 3 additions & 3 deletions tests/fsharp/test-framework.fs
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,7 @@ let config configurationName envVars =
let architectureMoniker = if Is64BitOperatingSystem then "x64" else "x86"
let CSC = requireFile (CORDIR ++ "csc.exe")
let ILDASM = requireFile (packagesDir ++ ("runtime.win-" + architectureMoniker + ".Microsoft.NETCore.ILDAsm.2.0.3") ++ "runtimes" ++ ("win-" + architectureMoniker) ++ "native" ++ "ildasm.exe")
let coreclrdll = requireFile (packagesDir ++ ("runtime.win-" + architectureMoniker + ".Microsoft.NETCore.Runtime.CoreCLR.2.0.3") ++ "runtimes" ++ ("win-" + architectureMoniker) ++ "native" ++ "coreclr.dll")
let PEVERIFY = requireFile (CORSDK ++ "peverify.exe")
let FSI_FOR_SCRIPTS =
match envVars |> Map.tryFind "_fsiexe" with
Expand All @@ -191,9 +192,8 @@ let config configurationName envVars =
| _ -> failwithf "Found more than one 'FSharp.Compiler.Tools' inside '%s', please clean up." packagesDir
let toolsDir = SCRIPT_ROOT ++ ".." ++ ".." ++ "Tools"
let dotNetExe = toolsDir ++ "dotnetcli" ++ "dotnet.exe"
// ildasm requires coreclr.dll to run which has already been restored to the tools directory
let coreclrSource = toolsDir ++ "dotnet20" ++ "shared" ++ "Microsoft.NETCore.App" ++ "2.0.0" ++ "coreclr.dll"
File.Copy(coreclrSource, Path.GetDirectoryName(ILDASM) ++ "coreclr.dll", overwrite=true)
// ildasm requires coreclr.dll to run which has already been restored to the packages directory
File.Copy(coreclrdll, Path.GetDirectoryName(ILDASM) ++ "coreclr.dll", overwrite=true)

#if !FSHARP_SUITE_DRIVES_CORECLR_TESTS
let FSI = requireFile (FSCBinPath ++ "fsi.exe")
Expand Down