AU on XCode 10: ResMerger Error

I’m getting the same error. XCode 11.3, but I used CMake on CLion 2019.3.
Changing
#include <AudioUnit/AudioUnit.r>
to
#include <AudioUnit.r>
fixed it for me as well.

Error before:

/Applications/CLion.app/Contents/bin/cmake/mac/bin/cmake -DCMAKE_BUILD_TYPE=Debug -G "CodeBlocks - Unix Makefiles" /..../Project/Builds/CLion
failed to find AUComponent/AUComponent.r
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/AudioUnit.framework/Headers/AudioUnit.r:18: ### Rez - noErr (0) during open of "AUComponent.r".
Fatal Error!
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/AudioUnit.framework/Headers/AudioUnit.r:18: ### Rez - Fatal Error, can't recover.
AUComponent.r: ### Rez - Since errors occurred, /..../Project/Builds/CLion/cmake-build-debug/SquipJuceProject.rsrc's resource fork was not completely updated.
-- Configuring done
-- Generating done
-- Build files have been written to: /..../Project/Builds/CLion/cmake-build-debug

[Finished]

This was a fresh project.
Note: This happens on master as well as on develop

1 Like

Thanks for you help @t0m!

Here are my steps to recreate on another machine (MacOS 10.14.6, XCode 11.3):

  1. Get JUCE from develop branch.
  2. Build Projucer.
  3. Create a blank project using the audio plugin template.
  4. Add CLion exporter
  5. Open the generated CLion project.

Here’s the error message:

failed to find AUComponent/AUComponent.r
    /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/AudioUnit.framework/Headers/AudioUnit.r:18: ### Rez - noErr (0) during open of "AUComponent.r".
    Fatal Error!
    /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/AudioUnit.framework/Headers/AudioUnit.r:18: ### Rez - Fatal Error, can't recover.
    AUComponent.r: ### Rez - Since errors occurred, /Users/eyalamir/Code/NewProject/Builds/CLion/cmake-build-debug/NewProject.rsrc's resource fork was not completely updated.

That should fix CLion. The original ResMerger errFSBadFSRef error is unlikely to be affected though.

1 Like

I got this error now too, out of the blue it started to happen on the build server. This is the error message:

/usr/bin/ResMerger -dstIs DF /Volumes/Buildserver/Jenkins/Home/workspace/PlayX-Mac/Builds/MacOSX/build/PlayX.build/Release/PlayX\ -\ AU.build/ResourceManagerResources/Objects/include_juce_audio_plugin_client_AU.rsrc -o /Volumes/Buildserver/Jenkins/Home/workspace/PlayX-Mac/Builds/MacOSX/build/PlayX.build/Release/PlayX\ -\ AU.build/ResourceManagerResources/lsPlayX.rsrc

file /Volumes/Buildserver/Jenkins/Home/workspace/PlayX-Mac/Builds/MacOSX/build/PlayX.build/Release/PlayX - AU.build/ResourceManagerResources/lsPlayX.rsrc: ### /Applications/Xcode 11.app/Contents/Developer/usr/bin/ResMerger - ERROR: errFSBadFSRef

Here is what some docs say:

|errFSBadFSRef|-1401|An FSRef parameter was invalid. There are several possible causes:

The parameter was not optional, but the pointer was NULL.

The volume reference number contained within the FSRef does not match a currently mounted volume. This can happen if the volume was unmounted after the FSRef was created.

Some other private field inside the FSRef contains a value that could never be valid. If the field value could be valid, but doesn’t happen to match the existing volume or in-memory structures, a “not found” error would be returned instead.

This did not help me unfortunately. Does anyone found a workaround or a fix ?

Had this same error a for a couple of days, but I tried the project again today and AU magically worked. I don’t know what happened.

2 Likes

this fixed it for me aswell.

I’m on 5.4.3. Updated Catalina & Xcode, this just devoured a good chunk of time but changing the <AU.r> path worked for me as well

I have the same problem. The solution of renaming #include <AudioUnit/AudioUnit.r> to #include <AudioUnit.r> doesn’t apply for me as it is already #include <AudioUnit.r> . I tried to create a new project in the home folder but still doesn’t build.

  • ERROR: errFSBadFSRef
    Command ResMergerCollector failed with a nonzero exit code

Anyone has idea of how to get rid of this error?