From 8e66cc10f1db6fa29bb9d34ecc8a6f07f0633f07 Mon Sep 17 00:00:00 2001 From: Jason Curl Date: Sat, 25 Mar 2017 17:54:37 +0100 Subject: [PATCH] Remove platform check on Linux for Mono. A platform check was introduced to ensure that for NET Standard 1.5, the user has the library nserial 1.1.0 or later installed. This is useful for Mono, but not required. Issue: DOTNET-81 --- code/Native/UnixNativeSerial.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/code/Native/UnixNativeSerial.cs b/code/Native/UnixNativeSerial.cs index 9f79871f..a7ce71c2 100644 --- a/code/Native/UnixNativeSerial.cs +++ b/code/Native/UnixNativeSerial.cs @@ -26,6 +26,7 @@ public UnixNativeSerial() throw new PlatformNotSupportedException("Can't initialise platform library"); } +#if NETSTANDARD15 // On NetStandard 1.5, we must have proper exception handling try { // These methods were first added in libnserial 1.1 @@ -33,6 +34,7 @@ public UnixNativeSerial() } catch (System.EntryPointNotFoundException) { throw new PlatformNotSupportedException("Must have libnserial 1.1.0 or later on .NET Standard 1.5"); } +#endif } private void ThrowException()