diff --git a/src/double/Edge.js/dotnetcore/coreclrembedding.cs b/src/double/Edge.js/dotnetcore/coreclrembedding.cs index b5714a25..b7cc41fb 100644 --- a/src/double/Edge.js/dotnetcore/coreclrembedding.cs +++ b/src/double/Edge.js/dotnetcore/coreclrembedding.cs @@ -155,7 +155,7 @@ protected override Assembly Load(AssemblyName assemblyName) try { DebugMessage("EdgeAssemblyLoadContext::Load (CLR) - Trying to load from {0}", assemblyPath); - Assembly assembly = LoadFromAssemblyPath(assemblyPath); + Assembly assembly = Default.LoadFromAssemblyPath(assemblyPath); if (assembly != null) { @@ -291,7 +291,6 @@ private void AddDependencies(DependencyContext dependencyContext, bool standalon assemblyPath = Path.Combine(_packagesPath, runtimeLibrary.Name.ToLower(), runtimeLibrary.Version, assetPath.Replace('/', Path.DirectorySeparatorChar)); } - DebugMessage("EdgeAssemblyResolver::AddDependencies (CLR) - Assembly path {0}", assemblyPath); string libraryNameFromPath = Path.GetFileNameWithoutExtension(assemblyPath); if (!File.Exists(assemblyPath) && !string.IsNullOrEmpty(runtimePath)) @@ -388,7 +387,7 @@ private void AddDependencyFromRuntime(RuntimeLibrary runtimeLibrary) } var asset = runtimeLibrary.Name; - if (!asset.EndsWith(".dll")) + if (!asset.EndsWith(".dll") && !asset.EndsWith(".sni")) { asset += ".dll"; } @@ -398,6 +397,11 @@ private void AddDependencyFromRuntime(RuntimeLibrary runtimeLibrary) asset = "System.dll"; } + if (asset == "NETStandard.Library.dll") + { + asset = "netstandard.dll"; + } + var assemblyPath = Path.Combine(runtimePath, Path.GetFileName(asset)); if (File.Exists(assemblyPath)) { @@ -428,7 +432,7 @@ private void AddDependencyFromAppDirectory(RuntimeLibrary runtimeLibrary) DebugMessage("EdgeAssemblyResolver::AddDependencies (CLR) - Processing dependency {1} {0} using .nuget packages and ApplicationDirectory path.", runtimeLibrary.Name, runtimeLibrary.Type); var asset = runtimeLibrary.Name; - if (!asset.EndsWith(".dll")) + if (!asset.EndsWith(".dll") && !asset.EndsWith(".sni")) { asset += ".dll"; }