From 3d4ef022af81b27f9f47c00d8952d2cc8081f211 Mon Sep 17 00:00:00 2001 From: Alex Evgrashin Date: Sat, 10 Feb 2024 12:37:42 +0100 Subject: [PATCH] Add visionOS support (#75) --- .../com.whisper.unity/Plugins/iOS/libwhisper.a.meta | 11 +++++++++++ .../com.whisper.unity/Runtime/Native/WhisperNative.cs | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/Packages/com.whisper.unity/Plugins/iOS/libwhisper.a.meta b/Packages/com.whisper.unity/Plugins/iOS/libwhisper.a.meta index dc80366..1c61841 100644 --- a/Packages/com.whisper.unity/Plugins/iOS/libwhisper.a.meta +++ b/Packages/com.whisper.unity/Plugins/iOS/libwhisper.a.meta @@ -20,6 +20,7 @@ PluginImporter: Exclude Editor: 1 Exclude Linux64: 1 Exclude OSXUniversal: 1 + Exclude VisionOS: 0 Exclude WebGL: 1 Exclude Win: 1 Exclude Win64: 1 @@ -29,6 +30,7 @@ PluginImporter: second: enabled: 0 settings: + AndroidSharedLibraryType: Executable CPU: ARMv7 - first: Any: @@ -67,6 +69,15 @@ PluginImporter: enabled: 0 settings: CPU: x86_64 + - first: + VisionOS: VisionOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + CPU: ARM64 + CompileFlags: + FrameworkDependencies: - first: iPhone: iOS second: diff --git a/Packages/com.whisper.unity/Runtime/Native/WhisperNative.cs b/Packages/com.whisper.unity/Runtime/Native/WhisperNative.cs index 84a214e..adc6e3f 100644 --- a/Packages/com.whisper.unity/Runtime/Native/WhisperNative.cs +++ b/Packages/com.whisper.unity/Runtime/Native/WhisperNative.cs @@ -11,7 +11,7 @@ namespace Whisper.Native /// public static unsafe class WhisperNative { -#if (UNITY_IOS || UNITY_ANDROID) && !UNITY_EDITOR +#if (UNITY_IOS || UNITY_VISIONOS || UNITY_ANDROID) && !UNITY_EDITOR private const string LibraryName = "__Internal"; #elif WHISPER_CUDA