Allow xcframework dependencies for Xcode.

This commit is contained in:
Justin Espedal
2020-05-26 18:01:34 +09:00
committed by Joshua Granick
parent fbe94170c9
commit 0d325bfb07
2 changed files with 16 additions and 2 deletions

View File

@@ -141,7 +141,8 @@ class IOSPlatform extends PlatformTarget
{ {
if (!StringTools.endsWith(dependency.name, ".framework") if (!StringTools.endsWith(dependency.name, ".framework")
&& !StringTools.endsWith(dependency.name, ".tbd") && !StringTools.endsWith(dependency.name, ".tbd")
&& !StringTools.endsWith(dependency.path, ".framework")) && !StringTools.endsWith(dependency.path, ".framework")
&& !StringTools.endsWith(dependency.path, ".xcframework"))
{ {
if (dependency.path != "") if (dependency.path != "")
{ {
@@ -318,6 +319,12 @@ class IOSPlatform extends PlatformTarget
path = Path.tryFullPath(dependency.path); path = Path.tryFullPath(dependency.path);
fileType = "wrapper.framework"; fileType = "wrapper.framework";
} }
else if (Path.extension(dependency.path) == "xcframework")
{
name = Path.withoutDirectory(dependency.path);
path = Path.tryFullPath(dependency.path);
fileType = "wrapper.xcframework";
}
if (name != null) if (name != null)
{ {

View File

@@ -118,7 +118,8 @@ class TVOSPlatform extends PlatformTarget
{ {
if (!StringTools.endsWith(dependency.name, ".framework") if (!StringTools.endsWith(dependency.name, ".framework")
&& !StringTools.endsWith(dependency.name, ".tbd") && !StringTools.endsWith(dependency.name, ".tbd")
&& !StringTools.endsWith(dependency.path, ".framework")) && !StringTools.endsWith(dependency.path, ".framework")
&& !StringTools.endsWith(dependency.path, ".xcframework"))
{ {
if (dependency.path != "") if (dependency.path != "")
{ {
@@ -263,6 +264,12 @@ class TVOSPlatform extends PlatformTarget
path = Path.tryFullPath(dependency.path); path = Path.tryFullPath(dependency.path);
fileType = "wrapper.framework"; fileType = "wrapper.framework";
} }
else if (Path.extension(dependency.path) == "xcframework")
{
name = Path.withoutDirectory(dependency.path);
path = Path.tryFullPath(dependency.path);
fileType = "wrapper.xcframework";
}
if (name != null) if (name != null)
{ {