From e128e09954f891d299f137ecafd663464422f4ff Mon Sep 17 00:00:00 2001 From: Kazuki Sakamoto Date: Wed, 7 Dec 2016 20:04:00 -0800 Subject: [PATCH] Support Xamarin.iOS - `__Internal` https://developer.xamarin.com/guides/ios/advanced_topics/native_interop/#Static_Libraries > Since you can only use static libraries on iOS, there is no external shared library to link with, so the path parameter in the DllImport attribute needs to use the special name __Internal (note the double underscore characters at the start of the name) as opposed to the path name. - `__IOS__` https://developer.xamarin.com/guides/cross-platform/application_fundamentals/building_cross_platform_applications/part_4_-_platform_divergence_abstraction_divergent_implementation/#iOS > Xamarin.iOS defines __IOS__ which you can use to detect iOS devices. --- csharp/Facebook.Yoga/Native.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/csharp/Facebook.Yoga/Native.cs b/csharp/Facebook.Yoga/Native.cs index 7786b8cf..9b1eb03d 100644 --- a/csharp/Facebook.Yoga/Native.cs +++ b/csharp/Facebook.Yoga/Native.cs @@ -14,7 +14,7 @@ namespace Facebook.Yoga { internal static class Native { -#if UNITY_IOS && !UNITY_EDITOR +#if (UNITY_IOS && !UNITY_EDITOR) || __IOS__ private const string DllName = "__Internal"; #else private const string DllName = "yoga";