Open SimpsOff opened 4 years ago
Hi guys. Any update on this? It's a blocker issue for us.
MTOUCH : warning MT5215: References to 'System' might require additional -framework=XXX or -lXXX instructions to the native linker MTOUCH : warning MT5215: References to 'System' might require additional -framework=XXX or -lXXX instructions to the native linker MTOUCH : warning MT5215: References to 'System.Net.Security' might require additional -framework=XXX or -lXXX instructions to the native linker MTOUCH : warning MT5215: References to 'System' might require additional -framework=XXX or -lXXX instructions to the native linker MTOUCH : warning MT5215: References to 'System' might require additional -framework=XXX or -lXXX instructions to the native linker MTOUCH : error MT5210: Native linking failed, undefined symbol: _FIRInstallationIDDidChangeNotification. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _GULIsLoggableLevel. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _GULLogBasic. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _GULLogError. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _GULLogInfo. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _GULLogWarning. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _GULSetLoggerLevel. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: FIRApp. The symbol '_OBJCCLASS$_FIRApp' could not be found in any of the libraries or frameworks linked with your application. MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: FIRComponent. The symbol '_OBJCCLASS$_FIRComponent' could not be found in any of the libraries or frameworks linked with your application. MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: FIRInstallations. The symbol '_OBJCCLASS$_FIRInstallations' could not be found in any of the libraries or frameworks linked with your application. MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: FIROptions. The symbol '_OBJCCLASS$_FIROptions' could not be found in any of the libraries or frameworks linked with your application. MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: GULAppDelegateSwizzler. The symbol '_OBJCCLASS$_GULAppDelegateSwizzler' could not be found in any of the libraries or frameworks linked with your application. MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: GULAppEnvironmentUtil. The symbol '_OBJCCLASS$_GULAppEnvironmentUtil' could not be found in any of the libraries or frameworks linked with your application. MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: GULMutableDictionary. The symbol '_OBJCCLASS$_GULMutableDictionary' could not be found in any of the libraries or frameworks linked with your application. MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: GULNetwork. The symbol '_OBJCCLASS$_GULNetwork' could not be found in any of the libraries or frameworks linked with your application. MTOUCH : error MT5211: Native linking failed, undefined Objective-C class: GULSwizzler. The symbol '_OBJCCLASS$_GULSwizzler' could not be found in any of the libraries or frameworks linked with your application. MTOUCH : error MT5210: Native linking failed, undefined symbol: _kFIRLoggerAnalytics. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _kGULNetworkHTTPStatusCodeCannotAcceptTraffic. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _kGULNetworkHTTPStatusCodeNotFound. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _kGULNetworkHTTPStatusCodeNotModified. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _kGULNetworkHTTPStatusCodeUnavailable. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _kGULNetworkHTTPStatusNoContent. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _kGULNetworkHTTPStatusOK. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _pb_decode. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _pb_decode_varint. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _pb_encode. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _pb_encode_string. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _pb_encode_submessage. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _pb_encode_tag_for_field. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _pb_encode_varint. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _pb_istream_from_buffer. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _pb_ostream_from_buffer. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: _pb_read. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5201: Native linking failed. Please review the build log and the user flags provided to gcc: -ObjC -lc++ -lsqlite3 -lz -ObjC -lc++ -lsqlite3 -lz -[APMMeasurement networkUploadCompletionHandlerWithResponse : error : ] in GoogleAppMeasurement(APMMeasurement_87bdad44f2b9aa68c2d607a36be1b8c5.o) -[APMMeasurement networkUploadCompletionHandlerWithResponse : error : ] in GoogleAppMeasurement(APMMeasurement_87bdad44f2b9aa68c2d607a36be1b8c5.o) -[APMMeasurement networkUploadCompletionHandlerWithResponse : error : ] in GoogleAppMeasurement(APMMeasurement_87bdad44f2b9aa68c2d607a36be1b8c5.o) -[APMMeasurement networkUploadCompletionHandlerWithResponse : error : ] in GoogleAppMeasurement(APMMeasurement_87bdad44f2b9aa68c2d607a36be1b8c5.o)
Happens on latest firebase.ios packages. This can easily be reproduced in an empty app
Using the example repo from @SimpsOff, I got the below build error,
I was able to fix the error by replacing FinishedLaunching
method in the AppDelegate
with the below,
public override bool FinishedLaunching(UIApplication application, NSDictionary launchOptions)
{
// Override point for customization after application launch.
// If not required for your application you can safely delete this method
var type = typeof(Analytics);
App.Configure();
return true;
}
I can confirm the solution posted by @dmariogatto works. I tried adding --linkskip=Firebase.Analytics to the mtouch arguments, but that didn't work. I think this is because it's not the Xamarin Linker removing this, but the Native linker, but I'm not 100% sure this is the case.
I already have Firebase.Core.App.Configure();
and the error still persist.
@jbtamaresgit var type = typeof(Analytics)
is the line that makes it work for me.
Failed to resolve "ObjCRuntime.TrampolineBlockBase" reference from "Xamarin.iOS, Version=0.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065"
Im still getting the same error in server machine. But its working fine in local machine. Any help or resolution to this would be appreciated.
@jbtamaresgit @jeroen-corteville Anyone please confirm the version of Xamarin.ios and Xamarin.forms. It would be great help!!!
@SimpsOff Did you find any solution?
@padmasrisekar Xamarin.Forms 4.5.0.725 Xamarin.iOS 14.2.0.12
There's a new version of iOS.Crashlytics 4.6.2 The error still persists with these packages: Any solution for this?
@jbtamaresgit
var type = typeof(Analytics)
is the line that makes it work for me.
Hmm, this is considered as a temporary work around and shouldn't be done as the variable wouldn't be used. They just released a new version and the issue still persists with their latest packages.
@jbtamaresgit Delete the XamarinBuildDownload in caches and delete bin and obj folder from your project, then try to build. It will work. App works well. But I cant see the crashes report in crashlytics console. Do you have any idea regarding that. i have uploaded the dsyms as well. but i still shows missing dsyms.
@padmasrisekar I have forgotten regarding my analytics package that it isn't updated yet. Just did a quick update for analytics and the error was gone regarding the XamarinBuildDownload however, the native linking problem still occurs after I have upgraded
@jbtamaresgit are you using any other packages that depends on xamarin.build.download? Please check that and update and try. In my project, after updation of xamarin.google.ios.analytics package, that error has gone.
I tried @dmariogatto 's suggestion of from here https://github.com/xamarin/GoogleApisForiOSComponents/issues/443#issuecomment-719379516
But I'm still getting the same error:
Failed to resolve "ObjCRuntime.TrampolineBlockBase" reference from "Xamarin.iOS, Version=0.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065"
😞
@padmasrisekar I'm still having the problem, and using the old firebase packages. Did you resolve the issue with clearing your caches?
Try to install xamarin.ios 13.8 or above version depends upon your xcode version
On Sun, Nov 15, 2020, 20:39 Andrew Simpson notifications@github.com wrote:
I tried @dmariogatto https://github.com/dmariogatto 's suggestion of from here #443 (comment) https://github.com/xamarin/GoogleApisForiOSComponents/issues/443#issuecomment-719379516
But I'm still getting the same error: Failed to resolve "ObjCRuntime.TrampolineBlockBase" reference from "Xamarin.iOS, Version=0.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065" 😞
@padmasrisekar https://github.com/padmasrisekar I'm still having the problem, and using the old firebase packages. Did you resolve the issue with clearing your caches?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/xamarin/GoogleApisForiOSComponents/issues/443#issuecomment-727584563, or unsubscribe https://github.com/notifications/unsubscribe-auth/AKCVWMGSC45EOO3FAZT2HWDSP7VJBANCNFSM4STZ7HFA .
@padmasrisekar Thanks, I've updated the packages dependent to the xamarin.build.download to the latest version
Any update on this? RemovingCrashlytics.SharedInstance.SetCrashlyticsCollectionEnabled(true);
in the AppDelegate.cs
results into linking errors.
MTOUCH: Error MT5210: Native linking failed, undefined symbol: _FIRInstallationIDDidChangeNotification. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. (MT5210)
Error: linker command failed with exit code 1 (use -v to see invocation)
MTOUCH: Error MT5211: Native linking failed, undefined Objective-C class: FIRInstallations. The symbol '_OBJC_CLASS_$_FIRInstallations' could not be found in any of the libraries or frameworks linked with your application. (MT5211)
MTOUCH: Error MT5201: Native linking failed. Please review the build log and the user flags provided to gcc: -ObjC -ObjC -ObjC -lc++ -lz -ObjC -lc++ -lsqlite3 -lz -ObjC -lc++ -lsqlite3 -lz (MT5201)
Hi! My project has an OpenCV Binding made with this tutorial https://chamoda.com/how-to-use-opencv-with-xamarin-ios/ It works fine before adding Firebase. When I add any Firebase library to my project, the project stops compiling. I get 98 errors like these:
MTOUCH : error MT5210: Native linking failed, undefined symbol: (extension in Foundation):Foundation.DataProtocol.copyBytes(to: Swift.UnsafeMutableRawBufferPointer) -> Swift.Int. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: Foundation.__DataStorage.init(bytes: Swift.UnsafeRawPointer?, length: Swift.Int) -> Foundation.__DataStorage. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: type metadata accessor for Foundation.__DataStorage. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: type metadata accessor for Foundation.Data.RangeReference. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: Foundation.Data._bridgeToObjectiveC() -> __C.NSData. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: static Foundation.Data._unconditionallyBridgeFromObjectiveC(__C.NSData?) -> Foundation.Data. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: protocol conformance descriptor for Foundation.Data : Foundation.DataProtocol in Foundation. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: (extension in Swift):Swift.BinaryInteger.description.getter : Swift.String. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5210: Native linking failed, undefined symbol: Swift._StringGuts.grow(Swift.Int) -> (). Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. ............................ Many more similar ............................ MTOUCH : error MT5201: Native linking failed. Please review the build log and the user flags provided to gcc: -ObjC -lc++ -lsqlite3 -lz -ObjC -lz -lsqlite3 clang : error : linker command failed with exit code 1 (use -v to see invocation)
By doing a lot of testing, I have verified that linking errors appear when I construct the private OpenCV4 OpenCV = new OpenCV4 () class; By removing that instance the application compiles with Firebase installed. If I remove Firebase and add the instance to OpenCv the application works correctly. I think there is a conflict and I don't know where to solve it. Can you help me? Thanks a lot
None of the solutions works in my case.
I'm including the latest versions of Analytics and Crashlytics, the debug build works fine but not the release.
Process exited with code 1, command:
MTOUCH : error MT5210: Native linking failed, undefined symbol: _FIRInstallationIDDidChangeNotification. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in.
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -F /Users/user/Library/Caches/XamarinBuildDownload/GAppM-6.9.0/Frameworks -framework GoogleAppMeasurement [...]
Undefined symbols for architecture arm64:
"_FIRInstallationIDDidChangeNotification", referenced from:
+[FIRAnalytics observeFirebaseInstallationIDChanges] in FirebaseAnalytics(FIRAnalytics_bcf240aa84bc544bc770b8f84276795f.o)
"_OBJC_CLASS_$_FIRInstallations", referenced from:
objc-class-ref in FirebaseAnalytics(FIRAnalytics_bcf240aa84bc544bc770b8f84276795f.o)
ld: symbol(s) not found for architecture arm64
clang : error : linker command failed with exit code 1 (use -v to see invocation)
For the ones having problems with FIRInstallations framework missing, downgrade to the following versions: Firebase Installations was included in Firebase Instance ID at the time of these releases, so you won't have linking problems.
Managed to fix it: Update Visual Studio for Mac to the latest version, then use the following packages versions:
Then, in your code, reference at least one time the class Firebase.Analytics.Analytics
, for example:
Analytics.SetAnalyticsCollectionEnabled(true);
Update Visual Studio for Mac to the latest version, then use the following packages versions:
Then, in your code, reference at least one time the class
Firebase.Analytics.Analytics
, for example:Analytics.SetAnalyticsCollectionEnabled(true);
I followed these instructions and version from the screenshot but still see this issue happening.
For the ones having problems with FIRInstallations framework missing, downgrade to the following versions: Firebase Installations was included in Firebase Instance ID at the time of these releases, so you won't have linking problems.
Downgrading to these package versions didn't help either...
Downgrading packages did not work for me either. Although, I left them downgraded
Adding this line of code in my app delegate magically fixed the build issue for me. Not sure why.
// Configure firebase for push notifications
Firebase.Core.App.Configure();
**var instance = Firebase.Installations.Installations.DefaultInstance;**
For me was a combination of adding both:
Firebase.Core.App.Configure();
Analytics.SetAnalyticsCollectionEnabled(true);
with the additional MTOUCH args in the iOS Build Options: --registrar:static
Thank y'all!
Having same issues, MTOUCH args, combination
Firebase.Core.App.Configure(); Analytics.SetAnalyticsCollectionEnabled(true);
and downgrading none works( Please, help.
I had run into a similar issue with a different library (EFCore).
I've worked around this by adding an Assembly tag to AppDelegate.cs
[assembly: Preserve(typeof(Firebase.Analytics.Analytics), AllMembers = true)]
namespace MyProject.iOS
{
[Register("AppDelegate")]
public partial class AppDelegate : global::Xamarin.Forms.Platform.iOS.FormsApplicationDelegate
I find this more palatable than var type = typeof(Analytics);
, but your mileage may vary.
Using the example repo from @SimpsOff, I got the below build error,
I was able to fix the error by replacing
FinishedLaunching
method in theAppDelegate
with the below,public override bool FinishedLaunching(UIApplication application, NSDictionary launchOptions) { // Override point for customization after application launch. // If not required for your application you can safely delete this method var type = typeof(Analytics); App.Configure(); return true; }
Worked for me.
Hi! My project has an OpenCV Binding made with this tutorial https://chamoda.com/how-to-use-opencv-with-xamarin-ios/ It works fine before adding Firebase. When I add any Firebase library to my project, the project stops compiling. I get 98 errors like these:
MTOUCH : error MT5210: Native linking failed, undefined symbol: (extension in ........................... Many more similar ............................ MTOUCH : error MT5201: Native linking failed. Please review the build log and the user flags provided to gcc: -ObjC -lc++ -lsqlite3 -lz -ObjC -lz -lsqlite3 clang : error : linker command failed with exit code 1 (use -v to see invocation)
By doing a lot of testing, I have verified that linking errors appear when I construct the private OpenCV4 OpenCV = new OpenCV4 () class; By removing that instance the application compiles with Firebase installed. If I remove Firebase and add the instance to OpenCv the application works correctly. I think there is a conflict and I don't know where to solve it. Can you help me? Thanks a lot
Hi @pablogupi , we have the same issue:
The app is compiled only with one of the two, never with both together.
Have you found a solution in the meantime?
I have the same error when have upgraded FIrebase.iOS.Core from 6.10.4 to 8.10.03 and Google.iOS.SignIn from 5.0.2.1 to 5.0.2.4. I see this in the build log:
Undefined symbols for architecture arm64:
"_kFirebaseErrorDomain", referenced from:
-[GGLContext configureWithError:] in GGLCore(GGLContext_8606885088d11458ba27dd487a24d742.o)
ld: symbol(s) not found for architecture arm64
clang : error : linker command failed with exit code 1 (use -v to see invocation)
Besides seeing this:
MTOUCH : error MT5210: Native linking failed, undefined symbol: _kFirebaseErrorDomain. Please verify that all the necessary frameworks have been referenced and native libraries are properly linked in. MTOUCH : error MT5201: Native linking failed. Please review the build log and the user flags provided to gcc: -ObjC -lz -lstdc++ -lsqlite3 -ObjC -lsqlite3 -ObjC -lc++ -lsqlite3 -lz -ObjC -lc++ -lsqlite3 -lz -lsqlite3 -lsqlite3 -lc++ -lz -lsqlite3 -lc++ -lz -lsqlite3 -lc++ -lz clang : error : linker command failed with exit code 1 (use -v to see invocation)
UPDATE I have resolved, removing the package Google.iOS.Core (deprecated)
Here is an empty app example with just the firebase packages added: https://github.com/SimpsOff/FirebaseExample
This seems to be a continuation of this issue: https://github.com/xamarin/GoogleApisForiOSComponents/issues/158 but it was asked in that thread that a new issue be opened. I've tried all steps listed in the thread without success.
When adding these packages, and upgrading to the latest version (which are used in another app we have): Firebase.iOS Core - 6.6.6 Firebase.iOS.Analytics - 6.4.1 Firebase.iOS.Auth - 6.5.1 Firebase.iOS.Installations - 1.1.1.1 Firebase.iOS.InstanceID - 4.3.3
Upon build attempt, the following errors are observed in the build log:
Later, including this code recommended to fix the linker errors (
var sharedInstance = Firebase.Core.Configuration.SharedInstance;
) produces a new error:Any help or resolution to this would be greatly appreciated.