fix android architecture detection issues on ue 5.2
This commit is contained in:
+1
-1
@@ -16,7 +16,7 @@ This release is breaking ABI/API compatibility with the previous versions.
|
|||||||
- Add an internal SenseGloveCoreTypes module in order to share common SenseGloveCore types between various modules.
|
- Add an internal SenseGloveCoreTypes module in order to share common SenseGloveCore types between various modules.
|
||||||
- Segregated Android binaries for NDK r21e (UE 4.27 and 5.0) and r25b (UE 5.1, 5.2).
|
- Segregated Android binaries for NDK r21e (UE 4.27 and 5.0) and r25b (UE 5.1, 5.2).
|
||||||
- Fully functional and stable Linux development support.
|
- Fully functional and stable Linux development support.
|
||||||
- Fully functional and stable Unreal Engine 5.2 preview support (except Android) has been added.
|
- Fully functional and stable Unreal Engine 5.2 preview support has been added.
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
|
||||||
|
|||||||
@@ -83,11 +83,8 @@ public class SenseGloveConnectImpl : ModuleRules
|
|||||||
|
|
||||||
if (Target.Platform == UnrealTargetPlatform.Android)
|
if (Target.Platform == UnrealTargetPlatform.Android)
|
||||||
{
|
{
|
||||||
#if ! UE_5_2_OR_LATER
|
|
||||||
IAndroidToolChain ToolChain = AndroidExports.CreateToolChain(Target.ProjectFile);
|
|
||||||
List<string> Architectures = ToolChain.GetAllArchitectures();
|
|
||||||
|
|
||||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "android"));
|
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "android"));
|
||||||
|
|
||||||
#if UE_5_1_OR_LATER
|
#if UE_5_1_OR_LATER
|
||||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "r25b"));
|
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "r25b"));
|
||||||
#elif UE_4_27_OR_LATER
|
#elif UE_4_27_OR_LATER
|
||||||
@@ -96,6 +93,23 @@ public class SenseGloveConnectImpl : ModuleRules
|
|||||||
Debug.Assert(false, "Developing for Android on UE versions older than 4.27 is not supported!");
|
Debug.Assert(false, "Developing for Android on UE versions older than 4.27 is not supported!");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if UE_5_2_OR_LATER
|
||||||
|
if (Target.Architecture == UnrealArch.Arm64)
|
||||||
|
{
|
||||||
|
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "arm64"));
|
||||||
|
}
|
||||||
|
else if (Target.Architecture == UnrealArch.X64)
|
||||||
|
{
|
||||||
|
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "x64"));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Debug.Assert(false, "Unsupported Android architecture!");
|
||||||
|
}
|
||||||
|
#else
|
||||||
|
IAndroidToolChain ToolChain = AndroidExports.CreateToolChain(Target.ProjectFile);
|
||||||
|
List<string> Architectures = ToolChain.GetAllArchitectures();
|
||||||
|
|
||||||
foreach (string Arch in Architectures)
|
foreach (string Arch in Architectures)
|
||||||
{
|
{
|
||||||
if (Arch == "-arm64")
|
if (Arch == "-arm64")
|
||||||
@@ -120,15 +134,13 @@ public class SenseGloveConnectImpl : ModuleRules
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Debug.Assert(false, "Only AArch64/ARM64 variant of Android is supported!");
|
Debug.Assert(false, "Unsupported Android architecture!");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
LibraryName = string.Format("lib{0}.a", LibraryName);
|
LibraryName = string.Format("lib{0}.a", LibraryName);
|
||||||
#else
|
|
||||||
Debug.Assert(false, "Developing for Android on UE 5.2+ is not yet supported!");
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
else if (Target.Platform == UnrealTargetPlatform.Linux)
|
else if (Target.Platform == UnrealTargetPlatform.Linux)
|
||||||
{
|
{
|
||||||
@@ -202,11 +214,8 @@ public class SenseGloveConnectImpl : ModuleRules
|
|||||||
|
|
||||||
if (Target.Platform == UnrealTargetPlatform.Android)
|
if (Target.Platform == UnrealTargetPlatform.Android)
|
||||||
{
|
{
|
||||||
#if ! UE_5_2_OR_LATER
|
|
||||||
IAndroidToolChain ToolChain = AndroidExports.CreateToolChain(Target.ProjectFile);
|
|
||||||
List<string> Architectures = ToolChain.GetAllArchitectures();
|
|
||||||
|
|
||||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "android"));
|
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "android"));
|
||||||
|
|
||||||
#if UE_5_1_OR_LATER
|
#if UE_5_1_OR_LATER
|
||||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "r25b"));
|
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "r25b"));
|
||||||
#elif UE_4_27_OR_LATER
|
#elif UE_4_27_OR_LATER
|
||||||
@@ -215,6 +224,23 @@ public class SenseGloveConnectImpl : ModuleRules
|
|||||||
Debug.Assert(false, "Developing for Android on UE versions older than 4.27 is not supported!");
|
Debug.Assert(false, "Developing for Android on UE versions older than 4.27 is not supported!");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if UE_5_2_OR_LATER
|
||||||
|
if (Target.Architecture == UnrealArch.Arm64)
|
||||||
|
{
|
||||||
|
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "arm64"));
|
||||||
|
}
|
||||||
|
else if (Target.Architecture == UnrealArch.X64)
|
||||||
|
{
|
||||||
|
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "x64"));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Debug.Assert(false, "Unsupported Android architecture!");
|
||||||
|
}
|
||||||
|
#else
|
||||||
|
IAndroidToolChain ToolChain = AndroidExports.CreateToolChain(Target.ProjectFile);
|
||||||
|
List<string> Architectures = ToolChain.GetAllArchitectures();
|
||||||
|
|
||||||
foreach (string Arch in Architectures)
|
foreach (string Arch in Architectures)
|
||||||
{
|
{
|
||||||
if (Arch == "-arm64")
|
if (Arch == "-arm64")
|
||||||
@@ -239,15 +265,13 @@ public class SenseGloveConnectImpl : ModuleRules
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Debug.Assert(false, "Only AArch64/ARM64 variant of Android is supported!");
|
Debug.Assert(false, "Unsupported Android architecture!");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
LibraryName = string.Format("lib{0}.a", LibraryName);
|
LibraryName = string.Format("lib{0}.a", LibraryName);
|
||||||
#else
|
|
||||||
Debug.Assert(false, "Developing for Android on UE 5.2+ is not yet supported!");
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
else if (Target.Platform == UnrealTargetPlatform.Linux)
|
else if (Target.Platform == UnrealTargetPlatform.Linux)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -82,11 +82,8 @@ public class SenseGloveCoreImpl : ModuleRules
|
|||||||
|
|
||||||
if (Target.Platform == UnrealTargetPlatform.Android)
|
if (Target.Platform == UnrealTargetPlatform.Android)
|
||||||
{
|
{
|
||||||
#if ! UE_5_2_OR_LATER
|
|
||||||
IAndroidToolChain ToolChain = AndroidExports.CreateToolChain(Target.ProjectFile);
|
|
||||||
List<string> Architectures = ToolChain.GetAllArchitectures();
|
|
||||||
|
|
||||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "android"));
|
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "android"));
|
||||||
|
|
||||||
#if UE_5_1_OR_LATER
|
#if UE_5_1_OR_LATER
|
||||||
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "r25b"));
|
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "r25b"));
|
||||||
#elif UE_4_27_OR_LATER
|
#elif UE_4_27_OR_LATER
|
||||||
@@ -95,6 +92,23 @@ public class SenseGloveCoreImpl : ModuleRules
|
|||||||
Debug.Assert(false, "Developing for Android on UE versions older than 4.27 is not supported!");
|
Debug.Assert(false, "Developing for Android on UE versions older than 4.27 is not supported!");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if UE_5_2_OR_LATER
|
||||||
|
if (Target.Architecture == UnrealArch.Arm64)
|
||||||
|
{
|
||||||
|
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "arm64"));
|
||||||
|
}
|
||||||
|
else if (Target.Architecture == UnrealArch.X64)
|
||||||
|
{
|
||||||
|
LibraryPath = Path.GetFullPath(Path.Combine(LibraryPath, "x64"));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Debug.Assert(false, "Unsupported Android architecture!");
|
||||||
|
}
|
||||||
|
#else
|
||||||
|
IAndroidToolChain ToolChain = AndroidExports.CreateToolChain(Target.ProjectFile);
|
||||||
|
List<string> Architectures = ToolChain.GetAllArchitectures();
|
||||||
|
|
||||||
foreach (string Arch in Architectures)
|
foreach (string Arch in Architectures)
|
||||||
{
|
{
|
||||||
if (Arch == "-arm64")
|
if (Arch == "-arm64")
|
||||||
@@ -119,15 +133,13 @@ public class SenseGloveCoreImpl : ModuleRules
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Debug.Assert(false, "Only AArch64/ARM64 variant of Android is supported!");
|
Debug.Assert(false, "Unsupported Android architecture!");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
LibraryName = string.Format("lib{0}.a", LibraryName);
|
LibraryName = string.Format("lib{0}.a", LibraryName);
|
||||||
#else
|
|
||||||
Debug.Assert(false, "Developing for Android on UE 5.2+ is not yet supported!");
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
else if (Target.Platform == UnrealTargetPlatform.Linux)
|
else if (Target.Platform == UnrealTargetPlatform.Linux)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user