|
|
|
@ -83,13 +83,13 @@ namespace Grpc.Core.Internal |
|
|
|
|
// See https://github.com/grpc/grpc/pull/7303 for one option. |
|
|
|
|
var assemblyDirectory = Path.GetDirectoryName(GetAssemblyPath()); |
|
|
|
|
|
|
|
|
|
// With old-style VS projects, the native libraries get copied using a .targets rule to the build output folder |
|
|
|
|
// With "classic" VS projects, the native libraries get copied using a .targets rule to the build output folder |
|
|
|
|
// alongside the compiled assembly. |
|
|
|
|
// With dotnet cli projects targeting net45 framework, the native libraries (just the required ones) |
|
|
|
|
// are similarly copied to the built output folder, through the magic of Microsoft.NETCore.Platforms. |
|
|
|
|
var classicPath = Path.Combine(assemblyDirectory, GetNativeLibraryFilename()); |
|
|
|
|
|
|
|
|
|
// With dotnet cli project targeting netcoreapp1.0, projects will use Grpc.Core assembly directly in the location where it got restored |
|
|
|
|
// With dotnet cli project targeting netcoreappX.Y, projects will use Grpc.Core assembly directly in the location where it got restored |
|
|
|
|
// by nuget. We locate the native libraries based on known structure of Grpc.Core nuget package. |
|
|
|
|
// When "dotnet publish" is used, the runtimes directory is copied next to the published assemblies. |
|
|
|
|
string runtimesDirectory = string.Format("runtimes/{0}/native", GetPlatformString()); |
|
|
|
|