Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Xamarin iOS build error - Native linking failed (Link Framework SDKs Only)

Not able to run Xamarin iOS project after Visual studio update.

Because updated IDE requires the latest Xcode (iOS 13.4 SDK shipped with Xcode 11.4)

Environment Details

  • OS Version : macOS Mojave, OS X 10.14.6
  • IDE : Visual Studio Community 2019 for Mac Version 8.5.1 (build 42)
  • Xamarin.iOS Version: 13.16.0.11 (Visual Studio Community)
  • Xamarin.Mac Version: 6.16.0.11 (Visual Studio Community)
  • Xcode Version 13.2

What I tried.

Instead of updating the Xcode, I simply changed the Linker Behaviour to Link Framework SDKs Only.

No luck, I got the following errors.

Error MT5210: Native linking failed, undefined symbol: ___darwin_check_fd_set_overflow. 
Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. (MT5210)

Error MT5202: Native linking failed. Please review the build log. (MT5202)

Error: linker command failed with exit code 1 (use -v to see invocation)

Reference.

  • Linker Behaviour
  • mtouch arguments

Is there any other option to resolve the issue without update the Xcode and macOS?

Any help will be really appreciated.

Thank you

like image 694
Mable John Avatar asked Apr 07 '20 13:04

Mable John


Video Answer


2 Answers

The latest version of Visual-Studio use the latest version of Xamarin.iOS which may not work with the lower version of Xcode .

So use a lower Xamarin.iOS Version would solve this problem.

like image 193
nevermore Avatar answered Sep 18 '22 13:09

nevermore


Cause : Latest visual studio requires latest Xcode (iOS 13.4 SDK shipped with Xcode 11.4)

To solve the issue install the latest Xcode or use a lower Xamarin.iOS Version

 if you are on a mac, you might be able to find the previous installer here:

~/Library/Caches/VisualStudio/[Replace with Visual Studio Version]/TempDownload

or, if you know the version of the previous version of ios, you can download it from here (change the version number to suite your needs:

https://dl.xamarin.com/MonoTouch/Mac/xamarin.ios-13.14.1.39.pkg.

Xamarin/xamarin-macios Releases, which contains every version

if you are on windows, this post might give you some clues on where to find the local cache instead: https://montemagno.com/cleanup-up-space-xamarin-dev-machine/

For more details: Ans-1 | Ans-2

like image 35
Mable John Avatar answered Sep 21 '22 13:09

Mable John