Hey everyone,
I have finally made the switch from the Resources folder to Addressables, but I’m having problems building for Mac OS. I’m on the latest 2022.3.10f1 LTS version.
Both the Windows and Linux Build work without issues, but when building for Mac I get two error messages:
Cannot read BuildLayout header, BuildLayout has not open for a file
UnityEditor.AddressableAssets.Settings.AddressableAssetSettings:BuildPlayerContent (UnityEditor.AddressableAssets.Build.AddressablesPlayerBuildResult&)
AddressablesPlayerBuildProcessor:PrepareForPlayerbuild (UnityEditor.AddressableAssets.Settings.AddressableAssetSettings,UnityEditor.Build.BuildPlayerContext,bool) (at ./Library/PackageCache/[email protected]/Editor/Build/AddressablesPlayerBuildProcessor.cs:101)
AddressablesPlayerBuildProcessor:PrepareForBuild (UnityEditor.Build.BuildPlayerContext) (at ./Library/PackageCache/[email protected]/Editor/Build/AddressablesPlayerBuildProcessor.cs:80)
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)
, which is also a weird wording (?). This message also pops up when I try to build the addressables on their own. It seems to happen after the Archive And Compress Bundles step.
Then during the actual player build (if the addressable build was part of the player build process) because the addressables build failed (I assume) I get:
Building C:\Users\[...]\mac.app\Contents\PlugIns\npcs_assets_all_63fb603432b5398f06234c8c5a4f4ec9.bundle failed with output:
System.Exception: Cannot sign 'C:/Users/[...]/mac.app/Contents/PlugIns/npcs_assets_all_63fb603432b5398f06234c8c5a4f4ec9.bundle' because it is not a valid Mach-O binary.
at MacOSCodeSignDylibCopy.Run(CSharpActionContext ctx, SignFlags signFlags)
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)
This refers to a specific addressables group, and during the addressables build process it seems that all the other ones seem to build fine?
Interestingly I switched this problematic bundle to pack seperately so the “npcs_assets_all_” bundle should not even exist anymore and it doesn’t look like it does in the Addressables report, but the build still throws the same error where the “npcs_assets_all_” bundle is still marked as the problem.
I also tried not including this bundle in the build at all with the same result.
I also tried deleting the Library folder and completely reimporting all assets, which I read somewhere should force the Addressables system to redo everything?
I also used “Clear Build Cache” in the Addressables Build dropdown between every step.
So I’m out of ideas for this. Especially since the Windows and Linux builds have no problems whatsoever. Does anybody have an idea what could go wrong here?
Just a side note: This is not in Xcode as it usually is with Mach-O errors. I’m building Mac executables in Unity directly without XCode. I don’t have a Mac for that. All error messages are from the Unity console.
Here are the full stacktrace from the Editor log file:
Build completed with a result of 'Failed' in 49 seconds (48517 ms)
Building C:\Users\retra\Documents\Programmieren\bmo builds\mac.app\Contents\PlugIns\npcs_assets_all_63fb603432b5398f06234c8c5a4f4ec9.bundle failed with output:
System.Exception: Cannot sign 'C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/PlugIns/npcs_assets_all_63fb603432b5398f06234c8c5a4f4ec9.bundle' because it is not a valid Mach-O binary.
at MacOSCodeSignDylibCopy.Run(CSharpActionContext ctx, SignFlags signFlags)
UnityEngine.StackTraceUtility:ExtractStackTrace ()
UnityEngine.DebugLogHandler:LogFormat (UnityEngine.LogType,UnityEngine.Object,string,object[])
UnityEngine.Logger:Log (UnityEngine.LogType,object)
UnityEngine.Debug:LogError (object)
UnityEditor.BuildPlayerWindow/DefaultBuildMethods:BuildPlayer (UnityEditor.BuildPlayerOptions)
UnityEditor.BuildPlayerWindow:CallBuildMethods (bool,UnityEditor.BuildOptions)
UnityEditor.BuildPlayerWindow:GUIBuildButtons (UnityEditor.Modules.IBuildWindowExtension,bool,bool,bool,UnityEditor.Build.BuildPlatform,UnityEditor.Modules.IBuildPostprocessor)
UnityEditor.BuildPlayerWindow:ShowBuildTargetSettings ()
UnityEditor.BuildPlayerWindow:OnGUI ()
UnityEditor.HostView:InvokeOnGUI (UnityEngine.Rect)
UnityEditor.DockArea:DrawView (UnityEngine.Rect)
UnityEditor.DockArea:OldOnGUI ()
UnityEngine.UIElements.IMGUIContainer:DoOnGUI (UnityEngine.Event,UnityEngine.Matrix4x4,UnityEngine.Rect,bool,UnityEngine.Rect,System.Action,bool)
UnityEngine.UIElements.IMGUIContainer:HandleIMGUIEvent (UnityEngine.Event,UnityEngine.Matrix4x4,UnityEngine.Rect,System.Action,bool)
UnityEngine.UIElements.IMGUIContainer:HandleIMGUIEvent (UnityEngine.Event,System.Action,bool)
UnityEngine.UIElements.IMGUIContainer:HandleIMGUIEvent (UnityEngine.Event,bool)
UnityEngine.UIElements.IMGUIContainer:SendEventToIMGUIRaw (UnityEngine.UIElements.EventBase,bool,bool)
UnityEngine.UIElements.IMGUIContainer:SendEventToIMGUI (UnityEngine.UIElements.EventBase,bool,bool)
UnityEngine.UIElements.IMGUIContainer:ProcessEvent (UnityEngine.UIElements.EventBase)
UnityEngine.UIElements.CallbackEventHandler:HandleEvent (UnityEngine.UIElements.EventBase)
UnityEngine.UIElements.CallbackEventHandler:HandleEventAtCurrentTargetAndPhase (UnityEngine.UIElements.EventBase)
UnityEngine.UIElements.CallbackEventHandler:HandleEventAtTargetPhase (UnityEngine.UIElements.EventBase)
UnityEngine.UIElements.MouseCaptureDispatchingStrategy:DispatchEvent (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.IPanel)
UnityEngine.UIElements.EventDispatcher:ApplyDispatchingStrategies (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.IPanel,bool)
UnityEngine.UIElements.EventDispatcher:ProcessEvent (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.IPanel)
UnityEngine.UIElements.EventDispatcher:ProcessEventQueue ()
UnityEngine.UIElements.EventDispatcher:OpenGate ()
UnityEngine.UIElements.EventDispatcherGate:Dispose ()
UnityEngine.UIElements.EventDispatcher:ProcessEvent (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.IPanel)
UnityEngine.UIElements.EventDispatcher:Dispatch (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.IPanel,UnityEngine.UIElements.DispatchMode)
UnityEngine.UIElements.BaseVisualElementPanel:SendEvent (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.DispatchMode)
UnityEngine.UIElements.UIElementsUtility:DoDispatch (UnityEngine.UIElements.BaseVisualElementPanel)
UnityEngine.UIElements.UIElementsUtility:UnityEngine.UIElements.IUIElementsUtility.ProcessEvent (int,intptr,bool&)
UnityEngine.UIElements.UIEventRegistration:ProcessEvent (int,intptr)
UnityEngine.UIElements.UIEventRegistration/<>c:<.cctor>b__1_2 (int,intptr)
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)
Starting: C:\Program Files\Unity\Hub\Editor\2022.3.10f1\Editor\Data\Tools\netcorerun\netcorerun.exe "C:\Program Files\Unity\Hub\Editor\2022.3.10f1\Editor\Data\PlaybackEngines\MacStandaloneSupport\MacStandalonePlayerBuildProgram.exe" "C:/Program Files/Unity/Hub/Editor/2022.3.10f1/Editor/Data/PlaybackEngines/MacStandaloneSupport/Bee;C:/Program Files/Unity/Hub/Editor/2022.3.10f1/Editor/Data/Tools/BuildPipeline" "Library/Bee/Playerc256e86c.dag.json" "Library/Bee/Playerc256e86c-inputdata.json" "Library\Bee\buildprogram0.traceevents"
WorkingDir: C:/Users/retra/Documents/Programmieren/bmotv-fresh
ExitCode: 0 Duration: 1s296ms
Starting: C:\Program Files\Unity\Hub\Editor\2022.3.10f1\Editor\Data\bee_backend.exe --dont-print-to-structured-log --ipc --dagfile="Library/Bee/Playerc256e86c.dag" --dagfilejson="Library\Bee\Playerc256e86c.dag.json" --profile="Library/Bee/backend2.traceevents" Player
WorkingDir: C:/Users/retra/Documents/Programmieren/bmotv-fresh
Finished compiling graph: 295 nodes, 868 flattened edges (868 ToBuild, 0 ToUse), maximum node priority 162
[ 0s] Delete 27 artifact files that are no longer in use. (like C:\Users\retra\Documents\Programmieren\bmo builds\mac.app\Contents\Resources\Data\StreamingAssets\aa\StandaloneOSX\defaultlocalgroup_scenes_all_b5a34e549e8ebad6651791f382ec89b8.bundle)
[ 37/294 0s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/StandaloneOSX/localization-locales_assets_all.bundle
[ 38/294 0s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/StandaloneOSX/localization-assets-shared_assets_all.bundle
[ 39/294 0s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/StandaloneOSX/localization-string-tables-russian(ru)_assets_all.bundle
[ 40/294 0s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/StandaloneOSX/defaultlocalgroup_assets_all_232cd64e0fc677f9d099fc82ca11875b.bundle
[ 41/294 0s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/StandaloneOSX/localization-string-tables-french(fr)_assets_all.bundle
[ 42/294 0s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/StandaloneOSX/localization-string-tables-english(en)_assets_all.bundle
[ 43/294 0s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/StandaloneOSX/localization-string-tables-spanish(es)_assets_all.bundle
[ 44/294 0s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/StandaloneOSX/localization-string-tables-german(de)_assets_all.bundle
[ 45/294 0s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/PlayerIcon.icns
[ 55/294 0s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/AddressablesLink/link.xml
[ 61/294 0s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/StandaloneOSX/1f55e67d56fb142ae83da33a81aea2cd_unitybuiltinshaders_f37d6e19c07945aa7b3ad5df8bfb5f5e.bundle
[124/294 0s] WriteText Library/Bee/artifacts/csharpactions/BMO-TV_dh29.info
[131/294 0s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/catalog.json
[132/294 0s] AddBootConfigGUID Library/Bee/artifacts/MacStandalonePlayerBuildProgram/boot.config
[133/294 0s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/boot.config
[134/294 4s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/StandaloneOSX/audio_assets_all_ddf3c3ffe14c0f92456812aac74a6406.bundle
[135/294 6s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/StandaloneOSX/defaultlocalgroup_scenes_all_7cde3a6a8384deae9bb7694231950a0d.bundle
[136/294 6s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/StandaloneOSX/rooms_assets_all_17168c1b27ce1f6fdeef61efd8a43fa0.bundle
[137/294 9s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/StandaloneOSX/maincharacter_assets_main_c305f78cae0a4bfacb82267810e4fdb8.bundle
[138/294 9s] CopyFiles C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/Resources/Data/StreamingAssets/aa/StandaloneOSX/videos_assets_all_4b6d9849f8d2d3f72f82a65bd44a2011.bundle
[BUSY 14s] UnityLinker C:/Users/retra/Documents/Programmieren/bmotv-fresh/Library/Bee/artifacts/unitylinker_hph0.traceevents
[139/294 15s] UnityLinker C:/Users/retra/Documents/Programmieren/bmotv-fresh/Library/Bee/artifacts/unitylinker_hph0.traceevents
C:\Program Files\Unity\Hub\Editor\2022.3.10f1\Editor\Data\il2cpp\build\deploy\UnityLinker.exe @Library\Bee\artifacts\rsp\17315264102192084404.rsp
[140/294 5s] MacOSCodeSignDylibCopy C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/PlugIns/npcs_assets_all_63fb603432b5398f06234c8c5a4f4ec9.bundle
##### CommandLine
"C:\Program Files\Unity\Hub\Editor\2022.3.10f1\Editor\Data\Tools\netcorerun\netcorerun.exe" "C:\Program Files\Unity\Hub\Editor\2022.3.10f1\Editor\Data\PlaybackEngines\MacStandaloneSupport\MacStandalonePlayerBuildProgram.exe" "C:/Program Files/Unity/Hub/Editor/2022.3.10f1/Editor/Data/PlaybackEngines/MacStandaloneSupport/Bee;C:/Program Files/Unity/Hub/Editor/2022.3.10f1/Editor/Data/Tools/BuildPipeline" invoke_static_method "Library\Bee\artifacts\csharpactions\npcs_assets_all_63fb603432b5398f06234c8c5a4f4ec9.bundle_ivee.info"
##### ExitCode
1
##### Output
System.Exception: Cannot sign 'C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/PlugIns/npcs_assets_all_63fb603432b5398f06234c8c5a4f4ec9.bundle' because it is not a valid Mach-O binary.
at MacOSCodeSignDylibCopy.Run(CSharpActionContext ctx, SignFlags signFlags)
*** Tundra build failed (16.47 seconds), 22 items updated, 135 evaluated
ExitCode: 3 Duration: 16s
Building C:\Users\retra\Documents\Programmieren\bmo builds\mac.app\Contents\PlugIns\npcs_assets_all_63fb603432b5398f06234c8c5a4f4ec9.bundle failed with output:
System.Exception: Cannot sign 'C:/Users/retra/Documents/Programmieren/bmo builds/mac.app/Contents/PlugIns/npcs_assets_all_63fb603432b5398f06234c8c5a4f4ec9.bundle' because it is not a valid Mach-O binary.
at MacOSCodeSignDylibCopy.Run(CSharpActionContext ctx, SignFlags signFlags)
UnityEngine.StackTraceUtility:ExtractStackTrace ()
UnityEngine.DebugLogHandler:LogFormat (UnityEngine.LogType,UnityEngine.Object,string,object[])
UnityEngine.Logger:Log (UnityEngine.LogType,object)
UnityEngine.Debug:LogError (object)
UnityEditor.Modules.BeeBuildPostprocessor:DefaultResultProcessor (Bee.BinLog.NodeFinishedMessage,bool,bool)
UnityEditor.Modules.BeeBuildPostprocessor:ReportBuildResults ()
UnityEditor.Modules.BeeBuildPostprocessor:PostProcess (UnityEditor.Modules.BuildPostProcessArgs)
UnityEditor.OSXStandalone.OSXDesktopStandalonePostProcessor:PostProcess (UnityEditor.Modules.BuildPostProcessArgs)
UnityEditor.Modules.DefaultBuildPostprocessor:PostProcess (UnityEditor.Modules.BuildPostProcessArgs,UnityEditor.BuildProperties&)
UnityEditor.PostprocessBuildPlayer:Postprocess (UnityEditor.BuildTargetGroup,UnityEditor.BuildTarget,int,string,string,string,int,int,UnityEditor.BuildOptions,UnityEditor.RuntimeClassRegistry,UnityEditor.Build.Reporting.BuildReport)
UnityEditor.BuildPlayerWindow/DefaultBuildMethods:BuildPlayer (UnityEditor.BuildPlayerOptions)
UnityEditor.BuildPlayerWindow:CallBuildMethods (bool,UnityEditor.BuildOptions)
UnityEditor.BuildPlayerWindow:GUIBuildButtons (UnityEditor.Modules.IBuildWindowExtension,bool,bool,bool,UnityEditor.Build.BuildPlatform,UnityEditor.Modules.IBuildPostprocessor)
UnityEditor.BuildPlayerWindow:ShowBuildTargetSettings ()
UnityEditor.BuildPlayerWindow:OnGUI ()
UnityEditor.HostView:InvokeOnGUI (UnityEngine.Rect)
UnityEditor.DockArea:DrawView (UnityEngine.Rect)
UnityEditor.DockArea:OldOnGUI ()
UnityEngine.UIElements.IMGUIContainer:DoOnGUI (UnityEngine.Event,UnityEngine.Matrix4x4,UnityEngine.Rect,bool,UnityEngine.Rect,System.Action,bool)
UnityEngine.UIElements.IMGUIContainer:HandleIMGUIEvent (UnityEngine.Event,UnityEngine.Matrix4x4,UnityEngine.Rect,System.Action,bool)
UnityEngine.UIElements.IMGUIContainer:HandleIMGUIEvent (UnityEngine.Event,System.Action,bool)
UnityEngine.UIElements.IMGUIContainer:HandleIMGUIEvent (UnityEngine.Event,bool)
UnityEngine.UIElements.IMGUIContainer:SendEventToIMGUIRaw (UnityEngine.UIElements.EventBase,bool,bool)
UnityEngine.UIElements.IMGUIContainer:SendEventToIMGUI (UnityEngine.UIElements.EventBase,bool,bool)
UnityEngine.UIElements.IMGUIContainer:ProcessEvent (UnityEngine.UIElements.EventBase)
UnityEngine.UIElements.CallbackEventHandler:HandleEvent (UnityEngine.UIElements.EventBase)
UnityEngine.UIElements.CallbackEventHandler:HandleEventAtCurrentTargetAndPhase (UnityEngine.UIElements.EventBase)
UnityEngine.UIElements.CallbackEventHandler:HandleEventAtTargetPhase (UnityEngine.UIElements.EventBase)
UnityEngine.UIElements.MouseCaptureDispatchingStrategy:DispatchEvent (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.IPanel)
UnityEngine.UIElements.EventDispatcher:ApplyDispatchingStrategies (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.IPanel,bool)
UnityEngine.UIElements.EventDispatcher:ProcessEvent (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.IPanel)
UnityEngine.UIElements.EventDispatcher:ProcessEventQueue ()
UnityEngine.UIElements.EventDispatcher:OpenGate ()
UnityEngine.UIElements.EventDispatcherGate:Dispose ()
UnityEngine.UIElements.EventDispatcher:ProcessEvent (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.IPanel)
UnityEngine.UIElements.EventDispatcher:Dispatch (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.IPanel,UnityEngine.UIElements.DispatchMode)
UnityEngine.UIElements.BaseVisualElementPanel:SendEvent (UnityEngine.UIElements.EventBase,UnityEngine.UIElements.DispatchMode)
UnityEngine.UIElements.UIElementsUtility:DoDispatch (UnityEngine.UIElements.BaseVisualElementPanel)
UnityEngine.UIElements.UIElementsUtility:UnityEngine.UIElements.IUIElementsUtility.ProcessEvent (int,intptr,bool&)
UnityEngine.UIElements.UIEventRegistration:ProcessEvent (int,intptr)
UnityEngine.UIElements.UIEventRegistration/<>c:<.cctor>b__1_2 (int,intptr)
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)
Total cache size 164754660
Total cache size after purge 164754660
Unloading 18 Unused Serialized files (Serialized files now loaded: 0)
Unloading 34338 unused Assets / (0.90 GB). Loaded Objects now: 107216.
Memory consumption went from 27.49 GB to 26.59 GB.
Total: 3615.296300 ms (FindLiveObjects: 20.627300 ms CreateObjectMapping: 7.742600 ms MarkObjects: 1323.648800 ms DeleteObjects: 2263.275700 ms)
Build Finished, Result: Failure.
(Also yes, this build uses 28GB RAM, but I have 32 and the Windows and Linux builds use the same amount so I don’t think it’s because of that.)