Can't debug or run Xamarin Mac app in Jetbrains Rider IDE

I have a Xamarin Mac project that was primarily developed on Visual Studio 2019.  Our team is looking to make the migration over to Jetbrains Rider.  I did the import of VS settings on initial load up of my project.  The project Cleans/Builds successfully in the Rider IDE and I am able to successfully run the application outside of the IDE (in finder). However, when I try to run it and debug in the IDE itself I get FATAL UNHANDLED EXCEPTION: System.DllNotFoundException: Could not find the runtime library libxammac.dylib at runtime.  This screams IDE/project configuration issue but I don't really know where to begin to look. There isn't much online to go off of.

0
34 comments

Hello Anna,

Did you have a chance to look at my solution that reproduces the issue?

 

Thanks,

Vanessa

0

Hello Anna Morozyuk have you had a chance to look into the solution I sent over? 
My trial is about to run out and Idon't want to purchase a subscription if I can't use the debug feature. 

 

Thanks,

Vanessa

0

Hello Vanessa ,

Sorry for the delay in the reply.

I have some trouble building your solution in different environments. To find more details, could you please build the solution by opening the terminal in Rider and running the command: 

dotnet build

and providing me with the output? 

Thank you in advance. 

0

Hello Anna Morozyuk ,

I ended up submitting a support ticket and the agent was able to figure out the problem. 

My project is an older project that was set to use the XamarinMacFullFramework. Apparently this is too old to work with Rider. 

I had to switch these lines in my csproj

<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
<UseXamMacFullFramework>true</UseXamMacFullFramework>

to use the Xamarin Modern framework and target framework 2.0 

<TargetFrameworkVersion>v2.0</TargetFrameworkVersion>
<TargetFrameworkIdentifier>Xamarin.Mac</TargetFrameworkIdentifier>

I will need to adjust other things about my application now as well but I am able to debug in Rider. 

 

Thank you for your help looking into this!

 

Vanessa

 

 

0

Please sign in to leave a comment.