Native linking failed with error code 1. unknown type name 'QTMovieView'

KeithBoyntonKeithBoynton GBMember ✭✭

I'm getting the following errors relating to unknown QT definitions. I've seen this post that mentions Apple removing the QTKit headers but not the symbols:
https://forums.xamarin.com/discussion/85914/difficulty-using-the-static-registrar

I've switched to unified and am running on all the latest updates from Stable but am still getting the errors below.

Process exited with code 1, command:
        xcrun -sdk macosx clang -mmacosx-version-min=10.6 -arch x86_64 -fobjc-runtime=macosx -ObjC

/obj/x86/Distribution/mmp-cache/registrar.m:20984:8: error: unknown type name 'QTMovieView'
        /obj/x86/Distribution/mmp-cache/registrar.m:20988:2: error: unknown type name 'QTMovieView'
        /obj/x86/Distribution/mmp-cache/registrar.m:21030:99: error: unknown type name 'QTMovieView'
        /obj/x86/Distribution/mmp-cache/registrar.m:21859:11: warning: duplicate protocol definition of 'WebDownloadDelegate' is ignored
        /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/System/Library/Frameworks/WebKit.framework/Headers/WebDownload.h:60:11: note: previous definition is here
        /obj/x86/Distribution/mmp-cache/registrar.m:21862:11: warning: duplicate protocol definition of 'WebFrameLoadDelegate' is ignored
        /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/System/Library/Frameworks/WebKit.framework/Headers/WebFrameLoadDelegate.h:51:11: note: previous definition is here
        /obj/x86/Distribution/mmp-cache/registrar.m:21865:11: warning: duplicate protocol definition of 'WebPolicyDelegate' is ignored
        /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/System/Library/Frameworks/WebKit.framework/Headers/WebPolicyDelegate.h:138:11: note: previous definition is here
        /obj/x86/Distribution/mmp-cache/registrar.m:21868:11: warning: duplicate protocol definition of 'WebResourceLoadDelegate' is ignored
        /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/System/Library/Frameworks/WebKit.framework/Headers/WebResourceLoadDelegate.h:46:11: note: previous definition is here
        /obj/x86/Distribution/mmp-cache/registrar.m:21871:11: warning: duplicate protocol definition of 'WebUIDelegate' is ignored
        /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/System/Library/Frameworks/WebKit.framework/Headers/WebUIDelegate.h:153:11: note: previous definition is here
        /obj/x86/Distribution/mmp-cache/registrar.m:31585:11: warning: duplicate protocol definition of 'CALayerDelegate' is ignored
        /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/System/Library/Frameworks/QuartzCore.framework/Headers/CALayer.h:798:11: note: previous definition is here
        /obj/x86/Distribution/mmp-cache/registrar.m:39019:17: warning: method 'deviceBrowserView:selectionDidChange:' in protocol 'IKDeviceBrowserViewDelegate' not implemented [-Wprotocol]
        /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/System/Library/Frameworks/Quartz.framework/Frameworks/ImageKit.framework/Headers/IKDeviceBrowserView.h:29:1: note: method 'deviceBrowserView:selectionDidChange:' declared here
        /obj/x86/Distribution/mmp-cache/registrar.m:44139:32: error: unknown type name 'QTMovieView'
        /obj/x86/Distribution/mmp-cache/registrar.m:44206:4: error: expected a type
        /obj/x86/Distribution/mmp-cache/registrar.m:44207:28: error: expected a type
        /obj/x86/Distribution/mmp-cache/registrar.m:44139:46: error: type of property 'QTMediaPlayer' ('int *') does not match type of accessor 'QTMediaPlayer' ('id')
        /obj/x86/Distribution/mmp-cache/registrar.m:44206:2: note: declared here
        /obj/x86/Distribution/mmp-cache/registrar.m:44139:46: warning: type of property 'QTMediaPlayer' does not match type of accessor 'setQTMediaPlayer:'
        /obj/x86/Distribution/mmp-cache/registrar.m:44207:2: note: declared here
        /obj/x86/Distribution/mmp-cache/registrar.m:44598:4: error: expected a type
        /obj/x86/Distribution/mmp-cache/registrar.m:44604:28: error: expected a type
        /obj/x86/Distribution/mmp-cache/registrar.m:44601:10: error: cannot initialize return object of type 'id' with an rvalue of type 'int *'
        /obj/x86/Distribution/mmp-cache/registrar.m:44607:3: error: no matching function for call to 'native_to_managed_trampoline_379'
        /obj/x86/Distribution/mmp-cache/registrar.m:21030:13: note: candidate function not viable: no known conversion from 'id' to 'int *' for 4th argument

MMP: error MM5109: Native linking failed with error code 1.  Check build log for details.
    Task "Mmp" execution -- FAILED
    Done building target "_CompileToNative" in project "/Trackhunter.csproj".-- FAILED

Any help would be really appreciated!

Posts

  • ChrisHamonsChrisHamons USForum Administrator, Xamarin Team Xamurai

    You are very likely running into trouble with this change:

    https://developer.xamarin.com/releases/mac/xamarin.mac_3/xamarin.mac_3.2/#Release_Mode_MMP_Default_Changes

    which defaulted the registrar to static in release builds.

    I wrote about it in detail here:

    https://medium.com/@donblas/how-a-default-behavior-change-broke-mac-app-store-submissions-bb92314065a0

    but the short version is:

    --registrar:dynamic in your mmp arguments should make it go away.

    In a future Xamarin.Mac, we will be enabling Platform Linking to allow static registrar + XM Full profile.

  • KeithBoyntonKeithBoynton GBMember ✭✭

    Thank you! I can confirm forcing dynamic does resolve it!

  • limtingfeilimtingfei Member ✭✭

    Hi can I ask whether this argument that we insert into MMP cause any changes in any Reference directory?
    Because after inserting this argument the error above went away, but another error came accross (MM0008 : You should provide one root assembly only, found 2 assemblies).
    I have searched for the entire solution and there are no spaces in any directory, and tried cleaning and rebuilt. Nothing seems to work. Wondering if this argument is the cause of it?

  • ChrisHamonsChrisHamons USForum Administrator, Xamarin Team Xamurai

    Very often MM0008 is from mistyping or misforming command line arguments. Please make sure you have everything typed correctly.

    Also, this thread is from 2017 and by messaging it, it notified everyone apart of the original conversation. Consider opening a new thread.

  • limtingfeilimtingfei Member ✭✭

    Thank you. And sorry for inconvenience.

Sign In or Register to comment.