Looking for someone willing verify a minimal Xcode project on Apple Silicon

I’m trying to verify a minimal combination of settings that will allow an Xcode project to produce a universal binary on macOS. I don’t have access to an Apple Silicon machine, so I can only verify that it works on Intel. Would anyone with access to an Apple Silicon machine be willing to test out the attached project? It is very minimal and has brief instructions in the README file contained therein.
Make sure when you run CMake that there isn’t already a previous run in that build directory.

MinimalApp.tar.gz (9.3 KB)

Edit: You will need to use CMake 3.19 for this test, potentially the latest 3.19.2 release.

For convenience so you don’t have to download the tarball to read it, the CMakeLists.txt file looks like this:

cmake_minimum_required(VERSION 3.19)

# The effect of these two lines is what I'm most interested in
set(CMAKE_OSX_DEPLOYMENT_TARGET 10.15 CACHE STRING "")
set(CMAKE_OSX_ARCHITECTURES "$(ARCHS_STANDARD)" CACHE STRING "")

project(MinApp LANGUAGES OBJC)

set(compiledResources
    Base.lproj/Main.storyboard
    Assets.xcassets
)

add_executable(MinimalApp MACOSX_BUNDLE
    AppDelegate.h
    AppDelegate.m
    main.m
    ViewController.h
    ViewController.m
    ${compiledResources}
)
target_link_libraries(MinimalApp PRIVATE "-framework AppKit")

set_target_properties(MinimalApp PROPERTIES
    MACOSX_BUNDLE_INFO_PLIST "${CMAKE_CURRENT_SOURCE_DIR}/Info.plist"
)
set_source_files_properties(${compiledResources} PROPERTIES
    MACOSX_PACKAGE_LOCATION Resources
)

Hi Craig,

I just tried with CMake 3.19.2 on a up-to-date M1 MBP and faced errors during the “cmake --build” step. Full terminal trace:

user@hostname trash % cd MinimalApp 
user@hostname MinimalApp % mkdir build 
user@hostname MinimalApp % cd build 
user@hostname build % cmake -G Xcode ..
-- The OBJC compiler identification is AppleClang 12.0.0.12000032
-- Detecting OBJC compiler ABI info
-- Detecting OBJC compiler ABI info - done
-- Check for working OBJC compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang - skipped
-- Configuring done
-- Generating done
-- Build files have been written to: /Users/user/lab/trash/MinimalApp/build
user@hostname build % cmake --build .
objc[11841]: Class AMSupportURLConnectionDelegate is implemented in both ?? (0x1f59678f0) and ?? (0x1185342b8). One of the two will be used. Which one is undefined.
objc[11841]: Class AMSupportURLSession is implemented in both ?? (0x1f5967940) and ?? (0x118534308). One of the two will be used. Which one is undefined.
Command line invocation:
    /Applications/Xcode.app/Contents/Developer/usr/bin/xcodebuild -project MinApp.xcodeproj build -target ALL_BUILD -parallelizeTargets -configuration Debug -hideShellScriptEnvironment

User defaults from command line:
    HideShellScriptEnvironment = YES

note: Using new build system
note: Building targets in parallel
note: Planning build
note: Constructing build description
CreateBuildDirectory /Users/user/lab/trash/MinimalApp/build (in target 'MinimalApp' from project 'MinApp')
    cd /Users/user/lab/trash/MinimalApp
    builtin-create-build-directory /Users/user/lab/trash/MinimalApp/build

WriteAuxiliaryFile /Users/user/lab/trash/MinimalApp/build/MinApp.build/Debug/ZERO_CHECK.build/Script-8535AA84668144FFB25382B5.sh (in target 'ZERO_CHECK' from project 'MinApp')
    cd /Users/user/lab/trash/MinimalApp
    write-file /Users/user/lab/trash/MinimalApp/build/MinApp.build/Debug/ZERO_CHECK.build/Script-8535AA84668144FFB25382B5.sh

MkDir /Users/user/lab/trash/MinimalApp/build/Debug/MinimalApp.app (in target 'MinimalApp' from project 'MinApp')
    cd /Users/user/lab/trash/MinimalApp
    /bin/mkdir -p /Users/user/lab/trash/MinimalApp/build/Debug/MinimalApp.app

MkDir /Users/user/lab/trash/MinimalApp/build/Debug/MinimalApp.app/Contents (in target 'MinimalApp' from project 'MinApp')
    cd /Users/user/lab/trash/MinimalApp
    /bin/mkdir -p /Users/user/lab/trash/MinimalApp/build/Debug/MinimalApp.app/Contents

MkDir /Users/user/lab/trash/MinimalApp/build/Debug/MinimalApp.app/Contents/MacOS (in target 'MinimalApp' from project 'MinApp')
    cd /Users/user/lab/trash/MinimalApp
    /bin/mkdir -p /Users/user/lab/trash/MinimalApp/build/Debug/MinimalApp.app/Contents/MacOS

MkDir /Users/user/lab/trash/MinimalApp/build/Debug/MinimalApp.app/Contents/Resources (in target 'MinimalApp' from project 'MinApp')
    cd /Users/user/lab/trash/MinimalApp
    /bin/mkdir -p /Users/user/lab/trash/MinimalApp/build/Debug/MinimalApp.app/Contents/Resources

PhaseScriptExecution Generate\ CMakeFiles/ZERO_CHECK /Users/user/lab/trash/MinimalApp/build/MinApp.build/Debug/ZERO_CHECK.build/Script-8535AA84668144FFB25382B5.sh (in target 'ZERO_CHECK' from project 'MinApp')
    cd /Users/user/lab/trash/MinimalApp
    /bin/sh -c /Users/user/lab/trash/MinimalApp/build/MinApp.build/Debug/ZERO_CHECK.build/Script-8535AA84668144FFB25382B5.sh
make: `/Users/user/lab/trash/MinimalApp/build/CMakeFiles/cmake.check_cache' is up to date.

WriteAuxiliaryFile /Users/user/lab/trash/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/DerivedSources/Entitlements.plist (in target 'MinimalApp' from project 'MinApp')
    cd /Users/user/lab/trash/MinimalApp
    write-file /Users/user/lab/trash/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/DerivedSources/Entitlements.plist

ProcessProductPackaging "" /Users/user/lab/trash/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/MinimalApp.app.xcent (in target 'MinimalApp' from project 'MinApp')
    cd /Users/user/lab/trash/MinimalApp
    

Entitlements:

{
    "com.apple.security.get-task-allow" = 1;
}


    builtin-productPackagingUtility -entitlements -format xml -o /Users/user/lab/trash/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/MinimalApp.app.xcent

CompileAssetCatalog /Users/user/lab/trash/MinimalApp/build/Debug/MinimalApp.app/Contents/Resources /Users/user/lab/trash/MinimalApp/Assets.xcassets (in target 'MinimalApp' from project 'MinApp')
    cd /Users/user/lab/trash/MinimalApp
    /Applications/Xcode.app/Contents/Developer/usr/bin/actool --output-format human-readable-text --notices --warnings --export-dependency-info /Users/user/lab/trash/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/assetcatalog_dependencies --output-partial-info-plist /Users/user/lab/trash/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/assetcatalog_generated_info.plist --enable-on-demand-resources NO --development-region en --target-device mac --minimum-deployment-target 10.15 --platform macosx --compile /Users/user/lab/trash/MinimalApp/build/Debug/MinimalApp.app/Contents/Resources /Users/user/lab/trash/MinimalApp/Assets.xcassets
2020-12-23 14:38:45.782 ibtoold[11856:43696] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBCocoaTouchBuildSupport.PlatformDefinition.MacCatalyst of plug-in com.apple.dt.IDE.IBCocoaBuildSupport
2020-12-23 14:38:45.782 ibtoold[11856:43696] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBCocoaBuildSupport.PlatformDefinition.Cocoa of plug-in com.apple.dt.IDE.IBCocoaBuildSupport
2020-12-23 14:38:45.782 ibtoold[11856:43696] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBCocoaTouchBuildSupport.PlatformDefinition.CocoaTouch of plug-in com.apple.dt.IDE.IBCocoaTouchBuildSupport
2020-12-23 14:38:45.782 ibtoold[11856:43696] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBAppleTVBuildSupport.PlatformDefinition.AppleTV of plug-in com.apple.dt.IDE.IBAppleTVBuildSupport
2020-12-23 14:38:45.783 ibtoold[11856:43696] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IDEInterfaceBuilder.PlatformDefinition.WatchOS of plug-in com.apple.dt.IDE.IDEInterfaceBuilderWatchKitBuildSupport
2020-12-23 14:38:45.797 ibtoold[11856:43696] [MT] DVTPlugInLoading: Failed to load code for plug-in com.apple.dt.IDE.IDEInterfaceBuilderCocoaTouchIntegration (/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework), error = Error Domain=NSCocoaErrorDomain Code=3587 "dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found" UserInfo={NSLocalizedFailureReason=The bundle is damaged or missing necessary resources., NSLocalizedRecoverySuggestion=Try reinstalling the bundle., NSFilePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, NSDebugDescription=dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found, NSBundlePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework, NSLocalizedDescription=The bundle “IDEInterfaceBuilderCocoaTouchIntegration” couldn’t be loaded because it is damaged or missing necessary resources.}, dyldError = dlopen(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, 0): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found
2020-12-23 14:38:45.797 ibtoold[11856:43696] [MT] DVTPlugInExtensionFaulting: Failed to fire fault for extension Xcode.InterfaceBuilderKit.AppleTVIntegration.Singletons: Error Domain=DVTPlugInErrorDomain Code=2 "Loading a plug-in failed." UserInfo={DVTPlugInIdentifierErrorKey=com.apple.dt.IDE.IDEInterfaceBuilderCocoaTouchIntegration, DVTPlugInExecutablePathErrorKey=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, NSLocalizedRecoverySuggestion=The plug-in or one of its prerequisite plug-ins may be missing or damaged and may need to be reinstalled., DVTPlugInDYLDErrorMessageErrorKey=dlopen(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, 0): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found, NSLocalizedDescription=Loading a plug-in failed., NSFilePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework, NSLocalizedFailureReason=The plug-in “com.apple.dt.IDE.IDEInterfaceBuilderCocoaTouchIntegration” at path “/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework” could not be loaded.  The plug-in or one of its prerequisite plug-ins may be missing or damaged., NSUnderlyingError=0x12b7051b0 {Error Domain=NSCocoaErrorDomain Code=3587 "dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found" UserInfo={NSLocalizedFailureReason=The bundle is damaged or missing necessary resources., NSLocalizedRecoverySuggestion=Try reinstalling the bundle., NSFilePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, NSDebugDescription=dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found, NSBundlePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework, NSLocalizedDescription=The bundle “IDEInterfaceBuilderCocoaTouchIntegration” couldn’t be loaded because it is damaged or missing necessary resources.}}}
2020-12-23 14:38:45.798 ibtoold[11856:43696] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Error getting value for parameter key 'name' of extension 'Xcode.InterfaceBuilderKit.AppleTVIntegration.Singletons' in plug-in 'com.apple.dt.IDE.IDEInterfaceBuilderAppleTVIntegration''
*** First throw call stack:
(
	0   CoreFoundation                      0x000000018b1bd320 __exceptionPreprocess + 240
	1   libobjc.A.dylib                     0x000000018aeebc04 objc_exception_throw + 60
	2   DVTFoundation                       0x000000010326974c -[DVTExtensionParameter valueForKey:error:] + 0
	3   IDEInterfaceBuilderKit              0x0000000102985054 -[IBScopedSingletonRegistry init] + 564
	4   IDEInterfaceBuilderKit              0x0000000102984e08 __43+[IBScopedSingletonRegistry sharedInstance]_block_invoke + 20
	5   libdispatch.dylib                   0x000000018ae98420 _dispatch_client_callout + 20
	6   libdispatch.dylib                   0x000000018ae99c38 _dispatch_once_callout + 32
	7   IDEInterfaceBuilderKit              0x0000000102984df0 +[IBScopedSingletonRegistry sharedInstance] + 60
	8   IDEInterfaceBuilderKit              0x00000001027b3d44 -[IBInterfaceBuilderPlugin init] + 120
	9   IDEInterfaceBuilderKit              0x00000001027b3cb0 +[IBInterfaceBuilderPlugin ide_initializeWithOptions:error:] + 16
	10  IDEFoundation                       0x0000000103be3c44 _IDEInitializeOnePlugInAndPrerequisites + 1776
	11  IDEFoundation                       0x0000000103be3720 _IDEInitializeOnePlugInAndPrerequisites + 460
	12  IDEFoundation                       0x0000000103be3720 _IDEInitializeOnePlugInAndPrerequisites + 460
	13  IDEFoundation                       0x0000000103be2568 _IDEInitializePlugIns + 1164
	14  IDEFoundation                       0x0000000103be156c IDEInitialize + 8460
	15  ibtoold                             0x00000001022985ec IBIDEInitialize + 56
	16  ibtoold                             0x00000001022978c8 main + 1484
	17  libdyld.dylib                       0x000000018b060f34 start + 4
)
libc++abi.dylib: terminating with uncaught exception of type NSException
Command CompileAssetCatalog failed with a nonzero exit code

CompileStoryboard /Users/user/lab/trash/MinimalApp/Base.lproj/Main.storyboard (in target 'MinimalApp' from project 'MinApp')
    cd /Users/user/lab/trash/MinimalApp
    /Applications/Xcode.app/Contents/Developer/usr/bin/ibtool --errors --warnings --notices --module MinimalApp --output-partial-info-plist /Users/user/lab/trash/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/Base.lproj/Main-SBPartialInfo.plist --auto-activate-custom-fonts --target-device mac --minimum-deployment-target 10.15 --output-format human-readable-text --compilation-directory /Users/user/lab/trash/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/Base.lproj /Users/user/lab/trash/MinimalApp/Base.lproj/Main.storyboard
2020-12-23 14:38:45.781 ibtoold[11855:43689] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBCocoaTouchBuildSupport.PlatformDefinition.MacCatalyst of plug-in com.apple.dt.IDE.IBCocoaBuildSupport
2020-12-23 14:38:45.781 ibtoold[11855:43689] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBCocoaBuildSupport.PlatformDefinition.Cocoa of plug-in com.apple.dt.IDE.IBCocoaBuildSupport
2020-12-23 14:38:45.781 ibtoold[11855:43689] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBCocoaTouchBuildSupport.PlatformDefinition.CocoaTouch of plug-in com.apple.dt.IDE.IBCocoaTouchBuildSupport
2020-12-23 14:38:45.781 ibtoold[11855:43689] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBAppleTVBuildSupport.PlatformDefinition.AppleTV of plug-in com.apple.dt.IDE.IBAppleTVBuildSupport
2020-12-23 14:38:45.781 ibtoold[11855:43689] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IDEInterfaceBuilder.PlatformDefinition.WatchOS of plug-in com.apple.dt.IDE.IDEInterfaceBuilderWatchKitBuildSupport
2020-12-23 14:38:45.797 ibtoold[11855:43689] [MT] DVTPlugInLoading: Failed to load code for plug-in com.apple.dt.IDE.IDEInterfaceBuilderCocoaTouchIntegration (/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework), error = Error Domain=NSCocoaErrorDomain Code=3587 "dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found" UserInfo={NSLocalizedFailureReason=The bundle is damaged or missing necessary resources., NSLocalizedRecoverySuggestion=Try reinstalling the bundle., NSFilePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, NSDebugDescription=dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found, NSBundlePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework, NSLocalizedDescription=The bundle “IDEInterfaceBuilderCocoaTouchIntegration” couldn’t be loaded because it is damaged or missing necessary resources.}, dyldError = dlopen(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, 0): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found
2020-12-23 14:38:45.797 ibtoold[11855:43689] [MT] DVTPlugInExtensionFaulting: Failed to fire fault for extension Xcode.InterfaceBuilderKit.AppleTVIntegration.Singletons: Error Domain=DVTPlugInErrorDomain Code=2 "Loading a plug-in failed." UserInfo={DVTPlugInIdentifierErrorKey=com.apple.dt.IDE.IDEInterfaceBuilderCocoaTouchIntegration, DVTPlugInExecutablePathErrorKey=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, NSLocalizedRecoverySuggestion=The plug-in or one of its prerequisite plug-ins may be missing or damaged and may need to be reinstalled., DVTPlugInDYLDErrorMessageErrorKey=dlopen(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, 0): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found, NSLocalizedDescription=Loading a plug-in failed., NSFilePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework, NSLocalizedFailureReason=The plug-in “com.apple.dt.IDE.IDEInterfaceBuilderCocoaTouchIntegration” at path “/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework” could not be loaded.  The plug-in or one of its prerequisite plug-ins may be missing or damaged., NSUnderlyingError=0x13762ad20 {Error Domain=NSCocoaErrorDomain Code=3587 "dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found" UserInfo={NSLocalizedFailureReason=The bundle is damaged or missing necessary resources., NSLocalizedRecoverySuggestion=Try reinstalling the bundle., NSFilePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, NSDebugDescription=dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found, NSBundlePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework, NSLocalizedDescription=The bundle “IDEInterfaceBuilderCocoaTouchIntegration” couldn’t be loaded because it is damaged or missing necessary resources.}}}
2020-12-23 14:38:45.798 ibtoold[11855:43689] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Error getting value for parameter key 'name' of extension 'Xcode.InterfaceBuilderKit.AppleTVIntegration.Singletons' in plug-in 'com.apple.dt.IDE.IDEInterfaceBuilderAppleTVIntegration''
*** First throw call stack:
(
	0   CoreFoundation                      0x000000018b1bd320 __exceptionPreprocess + 240
	1   libobjc.A.dylib                     0x000000018aeebc04 objc_exception_throw + 60
	2   DVTFoundation                       0x0000000105fad74c -[DVTExtensionParameter valueForKey:error:] + 0
	3   IDEInterfaceBuilderKit              0x00000001056c9054 -[IBScopedSingletonRegistry init] + 564
	4   IDEInterfaceBuilderKit              0x00000001056c8e08 __43+[IBScopedSingletonRegistry sharedInstance]_block_invoke + 20
	5   libdispatch.dylib                   0x000000018ae98420 _dispatch_client_callout + 20
	6   libdispatch.dylib                   0x000000018ae99c38 _dispatch_once_callout + 32
	7   IDEInterfaceBuilderKit              0x00000001056c8df0 +[IBScopedSingletonRegistry sharedInstance] + 60
	8   IDEInterfaceBuilderKit              0x00000001054f7d44 -[IBInterfaceBuilderPlugin init] + 120
	9   IDEInterfaceBuilderKit              0x00000001054f7cb0 +[IBInterfaceBuilderPlugin ide_initializeWithOptions:error:] + 16
	10  IDEFoundation                       0x0000000106927c44 _IDEInitializeOnePlugInAndPrerequisites + 1776
	11  IDEFoundation                       0x0000000106927720 _IDEInitializeOnePlugInAndPrerequisites + 460
	12  IDEFoundation                       0x0000000106927720 _IDEInitializeOnePlugInAndPrerequisites + 460
	13  IDEFoundation                       0x0000000106926568 _IDEInitializePlugIns + 1164
	14  IDEFoundation                       0x000000010692556c IDEInitialize + 8460
	15  ibtoold                             0x0000000104dd85ec IBIDEInitialize + 56
	16  ibtoold                             0x0000000104dd78c8 main + 1484
	17  libdyld.dylib                       0x000000018b060f34 start + 4
)
libc++abi.dylib: terminating with uncaught exception of type NSException
Command CompileStoryboard failed with a nonzero exit code

** BUILD FAILED **


The following build commands failed:
	CompileAssetCatalog /Users/user/lab/trash/MinimalApp/build/Debug/MinimalApp.app/Contents/Resources /Users/user/lab/trash/MinimalApp/Assets.xcassets
	CompileStoryboard /Users/user/lab/trash/MinimalApp/Base.lproj/Main.storyboard
(2 failures)

This is what happens. I do not know if the build fails because of my machine not having the right resources. I got the new machine very recently and simply installed the latest version of XCode (from the App Store).

(ypujante@mair20:.../Downloads/MinimalApp/build/ )cmake -G Xcode ..
-- The OBJC compiler identification is AppleClang 12.0.0.12000032
-- Detecting OBJC compiler ABI info
-- Detecting OBJC compiler ABI info - done
-- Check for working OBJC compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang - skipped
-- Configuring done
-- Generating done
-- Build files have been written to: /Users/ypujante/Downloads/MinimalApp/build
(ypujante@mair20:.../Downloads/MinimalApp/build/ )cmake --build .
objc[23300]: Class AMSupportURLConnectionDelegate is implemented in both ?? (0x1f4472518) and ?? (0x1144482b8). One of the two will be used. Which one is undefined.
objc[23300]: Class AMSupportURLSession is implemented in both ?? (0x1f4472568) and ?? (0x114448308). One of the two will be used. Which one is undefined.
Command line invocation:
    /Applications/Xcode.app/Contents/Developer/usr/bin/xcodebuild -project MinApp.xcodeproj build -target ALL_BUILD -parallelizeTargets -configuration Debug -hideShellScriptEnvironment

User defaults from command line:
    HideShellScriptEnvironment = YES

note: Using new build system
note: Building targets in parallel
note: Planning build
note: Constructing build description
CreateBuildDirectory /Users/ypujante/Downloads/MinimalApp/build (in target 'MinimalApp' from project 'MinApp')
    cd /Users/ypujante/Downloads/MinimalApp
    builtin-create-build-directory /Users/ypujante/Downloads/MinimalApp/build

MkDir /Users/ypujante/Downloads/MinimalApp/build/Debug/MinimalApp.app (in target 'MinimalApp' from project 'MinApp')
    cd /Users/ypujante/Downloads/MinimalApp
    /bin/mkdir -p /Users/ypujante/Downloads/MinimalApp/build/Debug/MinimalApp.app

MkDir /Users/ypujante/Downloads/MinimalApp/build/Debug/MinimalApp.app/Contents (in target 'MinimalApp' from project 'MinApp')
    cd /Users/ypujante/Downloads/MinimalApp
    /bin/mkdir -p /Users/ypujante/Downloads/MinimalApp/build/Debug/MinimalApp.app/Contents

MkDir /Users/ypujante/Downloads/MinimalApp/build/Debug/MinimalApp.app/Contents/Resources (in target 'MinimalApp' from project 'MinApp')
    cd /Users/ypujante/Downloads/MinimalApp
    /bin/mkdir -p /Users/ypujante/Downloads/MinimalApp/build/Debug/MinimalApp.app/Contents/Resources

MkDir /Users/ypujante/Downloads/MinimalApp/build/Debug/MinimalApp.app/Contents/MacOS (in target 'MinimalApp' from project 'MinApp')
    cd /Users/ypujante/Downloads/MinimalApp
    /bin/mkdir -p /Users/ypujante/Downloads/MinimalApp/build/Debug/MinimalApp.app/Contents/MacOS

WriteAuxiliaryFile /Users/ypujante/Downloads/MinimalApp/build/MinApp.build/Debug/ZERO_CHECK.build/Script-2139036416CF47E59FDB7A36.sh (in target 'ZERO_CHECK' from project 'MinApp')
    cd /Users/ypujante/Downloads/MinimalApp
    write-file /Users/ypujante/Downloads/MinimalApp/build/MinApp.build/Debug/ZERO_CHECK.build/Script-2139036416CF47E59FDB7A36.sh

PhaseScriptExecution Generate\ CMakeFiles/ZERO_CHECK /Users/ypujante/Downloads/MinimalApp/build/MinApp.build/Debug/ZERO_CHECK.build/Script-2139036416CF47E59FDB7A36.sh (in target 'ZERO_CHECK' from project 'MinApp')
    cd /Users/ypujante/Downloads/MinimalApp
    /bin/sh -c /Users/ypujante/Downloads/MinimalApp/build/MinApp.build/Debug/ZERO_CHECK.build/Script-2139036416CF47E59FDB7A36.sh
make: `/Users/ypujante/Downloads/MinimalApp/build/CMakeFiles/cmake.check_cache' is up to date.

WriteAuxiliaryFile /Users/ypujante/Downloads/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/DerivedSources/Entitlements.plist (in target 'MinimalApp' from project 'MinApp')
    cd /Users/ypujante/Downloads/MinimalApp
    write-file /Users/ypujante/Downloads/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/DerivedSources/Entitlements.plist

ProcessProductPackaging "" /Users/ypujante/Downloads/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/MinimalApp.app.xcent (in target 'MinimalApp' from project 'MinApp')
    cd /Users/ypujante/Downloads/MinimalApp


Entitlements:

{
    "com.apple.security.get-task-allow" = 1;
}


    builtin-productPackagingUtility -entitlements -format xml -o /Users/ypujante/Downloads/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/MinimalApp.app.xcent

CompileAssetCatalog /Users/ypujante/Downloads/MinimalApp/build/Debug/MinimalApp.app/Contents/Resources /Users/ypujante/Downloads/MinimalApp/Assets.xcassets (in target 'MinimalApp' from project 'MinApp')
    cd /Users/ypujante/Downloads/MinimalApp
    /Applications/Xcode.app/Contents/Developer/usr/bin/actool --output-format human-readable-text --notices --warnings --export-dependency-info /Users/ypujante/Downloads/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/assetcatalog_dependencies --output-partial-info-plist /Users/ypujante/Downloads/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/assetcatalog_generated_info.plist --enable-on-demand-resources NO --development-region en --target-device mac --minimum-deployment-target 10.15 --platform macosx --compile /Users/ypujante/Downloads/MinimalApp/build/Debug/MinimalApp.app/Contents/Resources /Users/ypujante/Downloads/MinimalApp/Assets.xcassets
2020-12-23 05:59:20.616 ibtoold[23314:380161] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBCocoaTouchBuildSupport.PlatformDefinition.MacCatalyst of plug-in com.apple.dt.IDE.IBCocoaBuildSupport
2020-12-23 05:59:20.616 ibtoold[23314:380161] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBCocoaBuildSupport.PlatformDefinition.Cocoa of plug-in com.apple.dt.IDE.IBCocoaBuildSupport
2020-12-23 05:59:20.616 ibtoold[23314:380161] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBCocoaTouchBuildSupport.PlatformDefinition.CocoaTouch of plug-in com.apple.dt.IDE.IBCocoaTouchBuildSupport
2020-12-23 05:59:20.617 ibtoold[23314:380161] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBAppleTVBuildSupport.PlatformDefinition.AppleTV of plug-in com.apple.dt.IDE.IBAppleTVBuildSupport
2020-12-23 05:59:20.617 ibtoold[23314:380161] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IDEInterfaceBuilder.PlatformDefinition.WatchOS of plug-in com.apple.dt.IDE.IDEInterfaceBuilderWatchKitBuildSupport
2020-12-23 05:59:20.633 ibtoold[23314:380161] [MT] DVTPlugInLoading: Failed to load code for plug-in com.apple.dt.IDE.IDEInterfaceBuilderCocoaTouchIntegration (/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework), error = Error Domain=NSCocoaErrorDomain Code=3587 "dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found" UserInfo={NSLocalizedFailureReason=The bundle is damaged or missing necessary resources., NSLocalizedRecoverySuggestion=Try reinstalling the bundle., NSFilePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, NSDebugDescription=dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found, NSBundlePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework, NSLocalizedDescription=The bundle “IDEInterfaceBuilderCocoaTouchIntegration” couldn’t be loaded because it is damaged or missing necessary resources.}, dyldError = dlopen(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, 0): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found
2020-12-23 05:59:20.633 ibtoold[23314:380161] [MT] DVTPlugInExtensionFaulting: Failed to fire fault for extension Xcode.InterfaceBuilderKit.iOSMacIntegration.Singletons: Error Domain=DVTPlugInErrorDomain Code=2 "Loading a plug-in failed." UserInfo={DVTPlugInIdentifierErrorKey=com.apple.dt.IDE.IDEInterfaceBuilderCocoaTouchIntegration, DVTPlugInExecutablePathErrorKey=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, NSLocalizedRecoverySuggestion=The plug-in or one of its prerequisite plug-ins may be missing or damaged and may need to be reinstalled., DVTPlugInDYLDErrorMessageErrorKey=dlopen(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, 0): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found, NSLocalizedDescription=Loading a plug-in failed., NSFilePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework, NSLocalizedFailureReason=The plug-in “com.apple.dt.IDE.IDEInterfaceBuilderCocoaTouchIntegration” at path “/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework” could not be loaded.  The plug-in or one of its prerequisite plug-ins may be missing or damaged., NSUnderlyingError=0x114c8a650 {Error Domain=NSCocoaErrorDomain Code=3587 "dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found" UserInfo={NSLocalizedFailureReason=The bundle is damaged or missing necessary resources., NSLocalizedRecoverySuggestion=Try reinstalling the bundle., NSFilePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, NSDebugDescription=dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found, NSBundlePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework, NSLocalizedDescription=The bundle “IDEInterfaceBuilderCocoaTouchIntegration” couldn’t be loaded because it is damaged or missing necessary resources.}}}
2020-12-23 05:59:20.634 ibtoold[23314:380161] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Error getting value for parameter key 'name' of extension 'Xcode.InterfaceBuilderKit.iOSMacIntegration.Singletons' in plug-in 'com.apple.dt.IDE.IDEInterfaceBuilderiOSMacIntegration''
*** First throw call stack:
(
	0   CoreFoundation                      0x000000018c119320 __exceptionPreprocess + 240
	1   libobjc.A.dylib                     0x000000018be47c04 objc_exception_throw + 60
	2   DVTFoundation                       0x0000000105e0174c -[DVTExtensionParameter valueForKey:error:] + 0
	3   IDEInterfaceBuilderKit              0x000000010551d054 -[IBScopedSingletonRegistry init] + 564
	4   IDEInterfaceBuilderKit              0x000000010551ce08 __43+[IBScopedSingletonRegistry sharedInstance]_block_invoke + 20
	5   libdispatch.dylib                   0x000000018bdf4420 _dispatch_client_callout + 20
	6   libdispatch.dylib                   0x000000018bdf5c38 _dispatch_once_callout + 32
	7   IDEInterfaceBuilderKit              0x000000010551cdf0 +[IBScopedSingletonRegistry sharedInstance] + 60
	8   IDEInterfaceBuilderKit              0x000000010534bd44 -[IBInterfaceBuilderPlugin init] + 120
	9   IDEInterfaceBuilderKit              0x000000010534bcb0 +[IBInterfaceBuilderPlugin ide_initializeWithOptions:error:] + 16
	10  IDEFoundation                       0x000000010677bc44 _IDEInitializeOnePlugInAndPrerequisites + 1776
	11  IDEFoundation                       0x000000010677b720 _IDEInitializeOnePlugInAndPrerequisites + 460
	12  IDEFoundation                       0x000000010677b720 _IDEInitializeOnePlugInAndPrerequisites + 460
	13  IDEFoundation                       0x000000010677a568 _IDEInitializePlugIns + 1164
	14  IDEFoundation                       0x000000010677956c IDEInitialize + 8460
	15  ibtoold                             0x0000000104d6c5ec IBIDEInitialize + 56
	16  ibtoold                             0x0000000104d6b8c8 main + 1484
	17  libdyld.dylib                       0x000000018bfbcf64 start + 4
)
libc++abi.dylib: terminating with uncaught exception of type NSException
Command CompileAssetCatalog failed with a nonzero exit code

CompileStoryboard /Users/ypujante/Downloads/MinimalApp/Base.lproj/Main.storyboard (in target 'MinimalApp' from project 'MinApp')
    cd /Users/ypujante/Downloads/MinimalApp
    /Applications/Xcode.app/Contents/Developer/usr/bin/ibtool --errors --warnings --notices --module MinimalApp --output-partial-info-plist /Users/ypujante/Downloads/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/Base.lproj/Main-SBPartialInfo.plist --auto-activate-custom-fonts --target-device mac --minimum-deployment-target 10.15 --output-format human-readable-text --compilation-directory /Users/ypujante/Downloads/MinimalApp/build/MinApp.build/Debug/MinimalApp.build/Base.lproj /Users/ypujante/Downloads/MinimalApp/Base.lproj/Main.storyboard
2020-12-23 05:59:20.617 ibtoold[23315:380169] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBCocoaTouchBuildSupport.PlatformDefinition.MacCatalyst of plug-in com.apple.dt.IDE.IBCocoaBuildSupport
2020-12-23 05:59:20.617 ibtoold[23315:380169] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBCocoaBuildSupport.PlatformDefinition.Cocoa of plug-in com.apple.dt.IDE.IBCocoaBuildSupport
2020-12-23 05:59:20.617 ibtoold[23315:380169] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBCocoaTouchBuildSupport.PlatformDefinition.CocoaTouch of plug-in com.apple.dt.IDE.IBCocoaTouchBuildSupport
2020-12-23 05:59:20.617 ibtoold[23315:380169] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IBAppleTVBuildSupport.PlatformDefinition.AppleTV of plug-in com.apple.dt.IDE.IBAppleTVBuildSupport
2020-12-23 05:59:20.618 ibtoold[23315:380169] Requested but did not find extension point with identifier Xcode.InterfaceBuilderBuildSupport.PlatformDefinition for extension Xcode.IDEInterfaceBuilder.PlatformDefinition.WatchOS of plug-in com.apple.dt.IDE.IDEInterfaceBuilderWatchKitBuildSupport
2020-12-23 05:59:20.633 ibtoold[23315:380169] [MT] DVTPlugInLoading: Failed to load code for plug-in com.apple.dt.IDE.IDEInterfaceBuilderCocoaTouchIntegration (/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework), error = Error Domain=NSCocoaErrorDomain Code=3587 "dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found" UserInfo={NSLocalizedFailureReason=The bundle is damaged or missing necessary resources., NSLocalizedRecoverySuggestion=Try reinstalling the bundle., NSFilePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, NSDebugDescription=dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found, NSBundlePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework, NSLocalizedDescription=The bundle “IDEInterfaceBuilderCocoaTouchIntegration” couldn’t be loaded because it is damaged or missing necessary resources.}, dyldError = dlopen(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, 0): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found
2020-12-23 05:59:20.633 ibtoold[23315:380169] [MT] DVTPlugInExtensionFaulting: Failed to fire fault for extension Xcode.InterfaceBuilderKit.CocoaTouchIntegration.Singletons: Error Domain=DVTPlugInErrorDomain Code=2 "Loading a plug-in failed." UserInfo={DVTPlugInIdentifierErrorKey=com.apple.dt.IDE.IDEInterfaceBuilderCocoaTouchIntegration, DVTPlugInExecutablePathErrorKey=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, NSLocalizedRecoverySuggestion=The plug-in or one of its prerequisite plug-ins may be missing or damaged and may need to be reinstalled., DVTPlugInDYLDErrorMessageErrorKey=dlopen(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, 0): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found, NSLocalizedDescription=Loading a plug-in failed., NSFilePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework, NSLocalizedFailureReason=The plug-in “com.apple.dt.IDE.IDEInterfaceBuilderCocoaTouchIntegration” at path “/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework” could not be loaded.  The plug-in or one of its prerequisite plug-ins may be missing or damaged., NSUnderlyingError=0x116837d30 {Error Domain=NSCocoaErrorDomain Code=3587 "dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found" UserInfo={NSLocalizedFailureReason=The bundle is damaged or missing necessary resources., NSLocalizedRecoverySuggestion=Try reinstalling the bundle., NSFilePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration, NSDebugDescription=dlopen_preflight(/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/IDEInterfaceBuilderCocoaTouchIntegration): Library not loaded: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
  Referenced from: /Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework/Versions/A/IDEInterfaceBuilderCocoaTouchIntegration
  Reason: image not found, NSBundlePath=/Applications/Xcode.app/Contents/PlugIns/IDEInterfaceBuilderCocoaTouchIntegration.framework, NSLocalizedDescription=The bundle “IDEInterfaceBuilderCocoaTouchIntegration” couldn’t be loaded because it is damaged or missing necessary resources.}}}
2020-12-23 05:59:20.634 ibtoold[23315:380169] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Error getting value for parameter key 'name' of extension 'Xcode.InterfaceBuilderKit.CocoaTouchIntegration.Singletons' in plug-in 'com.apple.dt.IDE.IDEInterfaceBuilderCocoaTouchIntegration''
*** First throw call stack:
(
	0   CoreFoundation                      0x000000018c119320 __exceptionPreprocess + 240
	1   libobjc.A.dylib                     0x000000018be47c04 objc_exception_throw + 60
	2   DVTFoundation                       0x000000010134d74c -[DVTExtensionParameter valueForKey:error:] + 0
	3   IDEInterfaceBuilderKit              0x0000000100a69054 -[IBScopedSingletonRegistry init] + 564
	4   IDEInterfaceBuilderKit              0x0000000100a68e08 __43+[IBScopedSingletonRegistry sharedInstance]_block_invoke + 20
	5   libdispatch.dylib                   0x000000018bdf4420 _dispatch_client_callout + 20
	6   libdispatch.dylib                   0x000000018bdf5c38 _dispatch_once_callout + 32
	7   IDEInterfaceBuilderKit              0x0000000100a68df0 +[IBScopedSingletonRegistry sharedInstance] + 60
	8   IDEInterfaceBuilderKit              0x0000000100897d44 -[IBInterfaceBuilderPlugin init] + 120
	9   IDEInterfaceBuilderKit              0x0000000100897cb0 +[IBInterfaceBuilderPlugin ide_initializeWithOptions:error:] + 16
	10  IDEFoundation                       0x0000000101cc7c44 _IDEInitializeOnePlugInAndPrerequisites + 1776
	11  IDEFoundation                       0x0000000101cc7720 _IDEInitializeOnePlugInAndPrerequisites + 460
	12  IDEFoundation                       0x0000000101cc7720 _IDEInitializeOnePlugInAndPrerequisites + 460
	13  IDEFoundation                       0x0000000101cc6568 _IDEInitializePlugIns + 1164
	14  IDEFoundation                       0x0000000101cc556c IDEInitialize + 8460
	15  ibtoold                             0x00000001002505ec IBIDEInitialize + 56
	16  ibtoold                             0x000000010024f8c8 main + 1484
	17  libdyld.dylib                       0x000000018bfbcf64 start + 4
)
libc++abi.dylib: terminating with uncaught exception of type NSException
Command CompileStoryboard failed with a nonzero exit code

** BUILD FAILED **

This is my output of

file Debug/MinimalApp.app/Contents/MacOS/MinimalApp

Debug/MinimalApp.app/Contents/MacOS/MinimalApp: Mach-O universal binary with 2 architectures: [x86_64:Mach-O 64-bit executable x86_64] [arm64:Mach-O 64-bit executable arm64]
Debug/MinimalApp.app/Contents/MacOS/MinimalApp (for architecture x86_64): Mach-O 64-bit executable x86_64
Debug/MinimalApp.app/Contents/MacOS/MinimalApp (for architecture arm64): Mach-O 64-bit executable arm64

I got the same error on my M1 Mac Mini (macOS 11.1, Xcode 12.3). I had installed Xcode.app from the Mac App Store but hadn’t yet launched it. The first time I launched it, it asked to install additional components which I did. After that, the CMake test project built successfully.

The build log includes a CreateUniversalBinary line, and the output binary contains both x86_64 and arm64 architectures. :100:

Thanks all, looks like that’s a viable way to set things up then. Cheers.

@craig.scott Can you explain what $(ARCHS_STANDARD) is exactly? Is it different from ${ARCHS_STANDARD} (parenthesis vs curly braces?) ?

I have another chicken and egg problem with your suggested solution:

If I do this:

if(APPLE)
  set(CMAKE_OSX_ARCHITECTURES "$(ARCHS_STANDARD)" CACHE STRING "")
endif()
project(xxx)

then it works for the XCode generator but it fails with Unix Makefiles (default if no generator provided):

> cmake ..
-- The C compiler identification is AppleClang 12.0.0.12000032
-- The CXX compiler identification is AppleClang 12.0.0.12000032
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - failed
-- Check for working C compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc
-- Check for working C compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc - broken
CMake Error at /Applications/CMake.app/Contents/share/cmake-3.19/Modules/CMakeTestCCompiler.cmake:66 (message):
  The C compiler

    "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc"

  is not able to compile a simple test program.

  It fails with the following output:

    Change Dir: /Users/ypujante/src/local/test/build/CMakeFiles/CMakeTmp

    Run Build Command(s):/usr/bin/make cmTC_1fadc/fast && /Applications/Xcode.app/Contents/Developer/usr/bin/make  -f CMakeFiles/cmTC_1fadc.dir/build.make CMakeFiles/cmTC_1fadc.dir/build
    Building C object CMakeFiles/cmTC_1fadc.dir/testCCompiler.c.o
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc   -arch  -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.1.sdk -mmacosx-version-min=11.0 -o CMakeFiles/cmTC_1fadc.dir/testCCompiler.c.o -c /Users/ypujante/src/local/test/build/CMakeFiles/CMakeTmp/testCCompiler.c
    clang: error: invalid arch name '-arch -isysroot'
    clang: warning: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.1.sdk: 'linker' input unused [-Wunused-command-line-argument]
    make[1]: *** [CMakeFiles/cmTC_1fadc.dir/testCCompiler.c.o] Error 1
    make: *** [cmTC_1fadc/fast] Error 2

But if I try to do this:

if(APPLE AND XCODE)
  set(CMAKE_OSX_ARCHITECTURES "$(ARCHS_STANDARD)" CACHE STRING "")
endif()
project(xxx)

then it doesn’t work with Xcode because XCODE is defined only after project

I want my CMake configuration to be generic and work for macOS or not (APPLE) but should also work if XCode is used or not. If not used then simply build a single binary, but if used, then build a universal binary. And of course if mac Intel, build only single binary…

The "$()" syntax is ignored by CMake and interpreted by Xcode (so it won’t work with the Unix Makefiles generator).

Thank you.

I think I find a way to make it work:

if(APPLE)
  if(CMAKE_GENERATOR STREQUAL "Xcode")
    set(CMAKE_OSX_ARCHITECTURES "$(ARCHS_STANDARD)" CACHE STRING "")
  endif()
endif()

I don’t know if it is the proper way of doing it but it seems to work in my scenario.