From b16e7faacc5a2046cfce0bded1f0ae675e5ab08c Mon Sep 17 00:00:00 2001
From: Dan Balasescu <1329837+smoogipoo@users.noreply.github.com>
Date: Tue, 23 Jan 2018 18:13:27 +0900
Subject: [PATCH] Fix Xamarin project compiles (#725)
* Fix Generator.Rewrite failing on iOS builds
* Fix incorrect path
* Directly link to Xamarin.iOS facades
* Fix Xamarin.Mac framework directory
* Add TVOS/WatchOS framework directories
* Add Android framework directory
* Remove unused framework dirs for now
Maybe we can add these back in later, when we have compiling support for these platforms.
* Remove ProjectExtensions
---
src/Generator.Rewrite/OpenTKAssemblyResolver.cs | 9 ++++++++-
src/OpenTK/OpenTK.iOS.csproj | 8 ++++----
2 files changed, 12 insertions(+), 5 deletions(-)
diff --git a/src/Generator.Rewrite/OpenTKAssemblyResolver.cs b/src/Generator.Rewrite/OpenTKAssemblyResolver.cs
index 092cf84c..61f32a2e 100644
--- a/src/Generator.Rewrite/OpenTKAssemblyResolver.cs
+++ b/src/Generator.Rewrite/OpenTKAssemblyResolver.cs
@@ -53,7 +53,14 @@ namespace OpenTK.Rewrite
var framework_dir = Path.GetDirectoryName(typeof(object).Module.FullyQualifiedName);
var framework_dirs = on_mono
- ? new[] { framework_dir, Path.Combine(framework_dir, "Facades") }
+ ? new[]
+ {
+ framework_dir,
+ Path.Combine(framework_dir, "Facades"),
+ "/Library/Frameworks/Xamarin.iOS.framework/Versions/Current/lib/mono/Xamarin.iOS",
+ "/Library/Frameworks/Xamarin.iOS.framework/Versions/Current/lib/mono/Xamarin.iOS/Facades",
+ "/Library/Frameworks/Xamarin.Android.framework/Versions/Current/lib/mono/2.1"
+ }
: new[] { framework_dir };
if (IsZero(name.Version))
diff --git a/src/OpenTK/OpenTK.iOS.csproj b/src/OpenTK/OpenTK.iOS.csproj
index efc9795e..621534eb 100644
--- a/src/OpenTK/OpenTK.iOS.csproj
+++ b/src/OpenTK/OpenTK.iOS.csproj
@@ -247,10 +247,10 @@
-->
-
-
-
-
+
+
+
+