13

I am unable to debug a Xamarin.iOS application out of JetBrains Rider 2022.2.2. This is the error that gets thrown when trying to deploy to the simulator:

error HE0004: Could not load the framework 'DVTITunesSoftwareServiceFoundation' (path: /Applications/Xcode.app/Contents/SharedFrameworks/DVTITunesSoftwareServiceFoundation.framework/DVTITunesSoftwareServiceFoundation): 
dlopen(/Applications/Xcode.app/Contents/SharedFrameworks/DVTITunesSoftwareServiceFoundation.framework/DVTITunesSoftwareServiceFoundation, 0x0001): Library not loaded: '@rpath/ContentDelivery.framework/Versions/A/ContentDelivery'
  Referenced from: '/Applications/Xcode.app/Contents/SharedFrameworks/DVTITunesSoftwareServiceFoundation.framework/Versions/A/DVTITunesSoftwareServiceFoundation'
  Reason: tried: '/usr/lib/swift/ContentDelivery.framework/Versions/A/ContentDelivery' (no such file), '/Library/Frameworks/Xamarin.iOS.framework/Versions/15.12.0.2/lib/mlaunch/mlaunch.app/Contents/MacOS/../Frameworks/ContentDelivery.framework/Versions/A/ContentDelivery' (no such file), '/Applications/Xcode.app/Contents/SharedFrameworks/DVTITunesSoftwareServiceFoundation.framework/Versions/A/Frameworks/ContentDelivery.framework/Versions/A/ContentDelivery' (no such file), '/usr/lib/swift/ContentDelivery.framework/Versions/A/ContentDelivery' (no such file), '/Library/Frameworks/Xamarin.iOS.framework/Versions/15.12.0.2/lib/mlaunch/mlaunch.app/Contents/MacOS/../Frameworks/ContentDelivery.framework/Versions/A/ContentDelivery' (no such file), '/Applications/Xcode.app/Contents/SharedFrameworks/DVTITunesSoftwareServiceFoundation.framework/Versions/A/Frameworks/ContentDelivery.framework/Versions/A/ContentDelivery' (no such file), '/System/Library/Frameworks/ContentDelivery.framework/Versions/A/ContentDelivery' (no such file)
Ron Saylor
  • 381
  • 6
  • 19
  • See related link [here](https://stackoverflow.com/questions/73704829/xamarin-deploy-on-iphone-not-working-with-xcode-14). You may need to downgrade XCode for now. – Tony Sep 13 '22 at 20:36
  • @Tony That moved me forward. I am getting this now, but I imagine there is a fix for that as well out in the void. ```error MT1216: Could not find the simulator UDID``` – Ron Saylor Sep 13 '22 at 22:33

5 Answers5

10

I had the same problem. Let me guess... You just upgraded to XCode14 and the corresponding Command Line Tools?

Downgrading XCode and Command Line Tools to 13.4.1 helped me.

What worked for me

Go To https://developer.apple.com/download/all/?q=command%20line%20tools

Download XCode and Command Line Tools for Xcode 13.4. Unpack Xcode (13.4.1) and rename it (for example Xcode 13) and place it parallel to Xcode (14) in the programfolder.

Xcode 14 and 13 parallel installed.

Then install the Command Line Tool.

Now in Xcode (still 14) > Preferences > Location > Command Line Tools, select version 13.4.1 instead of 14. You can see the Path for it is "Application/Xcode 13".

enter image description here

For safety restart tools, and it worked again...

Update: With the last update of Visual Studio, the downgrade was no longer necessary for me. Since then I can build the apps with XCode 14 and the corresponding command line tools without any problems. So I suggest upgrading Visual Studio to the latest version first.

M31k
  • 116
  • 1
  • 5
3

Here is how I made it work:

  1. Download the former version here (note: you need a developer account)
  2. Double-click on the downloaded .xip file to install XCode 13.4.1
  3. Rename the newly installed XCode application into Xcode.13.4.1.app and move it into your Applications folder
  4. Open the usual XCode application and go to the preferences
  5. In the locations tab you will be able to select XCode 13.4.1 for Command Line Tools

enter image description here

Kapusch
  • 287
  • 1
  • 13
  • This worked for VS 17.5.3 and Xcode 14.3. Downgrading to 14.2 in this fashion worked perfectly. I didn't have to download/install the Command Line Tools. Just Xcode itself. – ahwm Apr 06 '23 at 19:55
0

Redownload Visual Studio?

It turns out Microsoft released a brand new Visual Studio at some point.

We haven't been in our Xamarin project for a while and even though it said there were no updates, no Simulators were showing up.

Our Visual Studio said the version was 8.10.25 yet when I was reading the release notes, they referred to version 17.3.7.

Our team had to download Visual Studio again and then we saw the version updated to 17.3.7.

So check your version of Visual Studio and redownload the newest one. That's what fixed this issue for us.

Mark Moeykens
  • 15,915
  • 6
  • 63
  • 62
0

Latest update fixed the issue for me.

I had the same issue, while searching for answer I found this thread, writing this to confirm that I took the latest update on 9th nov(NET 7 SDK). Issue seems resolved with latest update.

Saket Kumar
  • 1,157
  • 2
  • 14
  • 30
0

There is a more elegant solution to this problem. You need to upgrade Xamarin.iOS manually. The releases are on GitHub 16.0.0.72 did the trick for me.

mwojtera
  • 471
  • 4
  • 6