symbol collision being reported on stderr by opendiff (a part of Xcode)

Not really a "developer" question per se, but related to the Xcode developer tools as run on a new M1 Mac running Monterey (12.1).

When running various tools, such as "opendiff" I receive the following error reported on stderr: objc[6599]: Class AMSupportURLConnectionDelegate is implemented in both /usr/lib/libauthinstall.dylib (0x1e30deb90) and /Library/Apple/System/Library/PrivateFrameworks/MobileDevice.framework/Versions/A/MobileDevice (0x108f7c2c8). One of the two will be used. Which one is undefined. objc[6599]: Class AMSupportURLSession is implemented in both /usr/lib/libauthinstall.dylib (0x1e30debe0) and /Library/Apple/System/Library/PrivateFrameworks/MobileDevice.framework/Versions/A/MobileDevice (0x108f7c318). One of the two will be used. Which one is undefined.

I'm working on the assumption that two conflicting libraries have been installed that provide a definition for the same symbol, and (since the opendiff program loads and runs) that at least for now, both symbols are defined in a similar enough way that whichever one is actually loaded works.

I was at first very confused because there is actually no file on my system with the name /usr/lib/libauthinstall.dylib

While this makes the error message rather confusing, I found this thread https://developer.apple.com/forums/thread/692383 that makes clear that many of the files in /usr/lib in an earlier part of the release process are amalgamated, and I assume that libauthinstall.dylib is one of these files.

Given that this implies that the /usr/lib versions are likely the "more authoritative" versions, I am not actually sure why the directory /Library/Apple/System/Library/PrivateFrameworks/MobileDevice.framework even exists -- I don't do any mobile development on this machine, so I assume that it came out of the setup, or possible from a migration of the user content from a machine running BigSur (content transferred using TimeMachine).

Does anyone have any ideas regarding: (a) how this came about (as it appears that both sources are installed by Apple), and (b) how I can remove the conflict.

I'm using opendiff in a project workflow and really don't want to see the workflow polluted with spurious error messages, not to mention the fragility of not being able to control which symbol these tools are actually using.

Thanks in advance for any thoughts.

EDIT: There are a number of posts around the 'net linking this error with "homebrew". I believe that this is at least partially a red herring, because: a) I don't use homebrew (though I do use MacPorts) -- I avoid hombrew largely because of its plan to play in /usr while MacPorts keeps everything well out of the way in /opt b) both of the named sources are from Apple.

Post not yet marked as solved Up vote post of andrewhw00 Down vote post of andrewhw00
22k views
  • FYI on the arm64 (M1) Macs, Homebrew installs to /opt/homebrew/bin.

  • Installing a new macOS update, that is v12.4, resolved my issue.

Add a Comment

Replies

For iOS development sudo xcode-select -s /Library/Developer/CommandLineTools might not work. For my build flow, we make use of Cocoapods and a post-install script that leverages xcodebuild. When attempting to run, I get the following error:

error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

sudo xcode-select -r resets my state to normal, but does not silence the warnings we're discussing here.

I tried the various things suggested here and none of them fixed the problem for me. What did fix it was to disable Bitdefender's ransomware protection. Then I could do my builds and they worked just fine. So if you use Bitdefender, give that a try.

How can I remove one of them? I use Xcode 13.2.1 When I update my MacOS 12.6 it installed latest command line.

  • Basically reinstalled everthing (Xcode and Commandlines etc) worked for me.

Add a Comment