From 9e29be5c7999eed09eae0edd47ca7334f7c1fdc3 Mon Sep 17 00:00:00 2001 From: Fabian Mastenbroek Date: Tue, 24 May 2022 12:58:21 +0200 Subject: [PATCH] mac-virtualcam: Build DAL plugin for ARM64e target as well This change fixes an issue where the DAL plugin would not load due to not supporting the architecture arm64e. We update the build configuration to build a universal binary that includes arm64e as well. See https://github.com/obsproject/obs-studio/issues/6285 for more information regarding this issue. --- plugins/mac-virtualcam/src/dal-plugin/CMakeLists.txt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/plugins/mac-virtualcam/src/dal-plugin/CMakeLists.txt b/plugins/mac-virtualcam/src/dal-plugin/CMakeLists.txt index 8af3cec40..f7747b680 100644 --- a/plugins/mac-virtualcam/src/dal-plugin/CMakeLists.txt +++ b/plugins/mac-virtualcam/src/dal-plugin/CMakeLists.txt @@ -1,7 +1,3 @@ -# Build DAL plugin universal to ensure compatibility with Rosetta-translated -# apps on arm64 hosts -set(CMAKE_OSX_ARCHITECTURES "x86_64;arm64") - project(mac-dal-plugin) find_library(COCOA Cocoa) @@ -58,6 +54,10 @@ set_target_properties( FOLDER "plugins" VERSION "0" SOVERSION "0" + # Force the DAL plugin to be built for arm64e as well. Note that + # we cannot build OBS for arm64e, since its libraries are not + # built for this architecture at the moment. + OSX_ARCHITECTURES "x86_64;arm64;arm64e" LIBRARY_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/../../" MACOSX_BUNDLE_INFO_PLIST "${CMAKE_SOURCE_DIR}/cmake/bundle/macOS/Virtualcam-Info.plist.in")