Before reporting a bug:
Describe the bug
The application successfully builds but then crashes with the following error messages from the debug console:
To Reproduce
Steps to reproduce the behavior:
- Build a new .net maui project
- Install latest plugins for firebase, Plugin.Firebase and AdamE.Firebase.iOS.Core
- Follow all steps in Readme files (Install packages outside of visual studio using power shell (macbook), Linker flag addition to project, Nuget cache cleared, XamarinBuildDownload cache removal, full project clean bin/obj folders deleted, dotnet restore outside of visual studio, dotnet build outside of visual studio).
- Build failed initially citing missing firebase analytics.
- Added AdamE.Firebase.iOS.Analytics reference to csproj.
- Build failed a second time referencing missing GMTSessionFetcher.
- Added AdamE.Google.iOS.GTMSessionFetcher reference to csproj.
- Builds and installs successfully only now it crashes on app startup citing the error message above.
- Follow steps in Readme files again (Nuget cache cleared, XamarinBuildDownload cache removal, full project clean bin/obj folders deleted, dotnet restore outside of visual studio, dotnet build outside of visual studio).
- Build fails with the same error message below.
- Added AdamE.Firebase.iOS.Firestore reference and package to project.
- Follow steps in Readme files again (Nuget cache cleared, XamarinBuildDownload cache removal, full project clean bin/obj folders deleted, dotnet restore outside of visual studio, dotnet build outside of visual studio).
- Deployment error is exactly the same except the package reference changed to FirebaseRemoteConfig.
- Added all AdamE.Firebase.iOS* packages.
- Follow steps in Readme files again (Nuget cache cleared, XamarinBuildDownload cache removal, full project clean bin/obj folders deleted, dotnet restore outside of visual studio, dotnet build outside of visual studio).
- Deployment error is exactly the same with a reference to FirebaseRemoteConfig.
- See error
Expected behavior
Build and deploy successfully.
Error messages
error HE1045: Failed to execute 'devicectl': 'devicectl -j /var/folders/b3/0lxs40sd41v70zqtdndnqmpm0000gn/T/tmpPcf12Z.tmp device process launch --terminate-existing --device 00008110-001145E13AE8401E --console com.company.MyMauiApp' returned the exit code 1.
error HE1046: Additional output: xcrun devicectl -j /var/folders/b3/0lxs40sd41v70zqtdndnqmpm0000gn/T/tmpPcf12Z.tmp device process launch --terminate-existing --device 00008110-001145E13AE8401E --console com.company.MyMauiApp
error HE1046: Additional output: dyld[13554]: Symbol not found: __ZN5swift39swift51override_conformsToSwiftProtocolEPKNS_14TargetMetadataINS_9InProcessEEEPKNS_24TargetProtocolDescriptorIS1_EEN7__swift9__runtime4llvm9StringRefEPFPKNS_35TargetProtocolConformanceDescriptorIS1_EES4_S8_SC_E
error HE1046: Additional output: Referenced from: <9B687E21-801B-34A8-BC2F-D2811C85D21C> /private/var/containers/Bundle/Application/8CB99D8C-27B6-47DF-97E3-DA36BF385C7C/MyMauiApp.app/Frameworks/FirebaseFirestore.framework/FirebaseFirestore
error HE1046: Additional output: Expected in: <34DD8225-075B-3F6E-9467-C22809180549> /private/var/containers/Bundle/Application/8CB99D8C-27B6-47DF-97E3-DA36BF385C7C/MyMauiApp.app/Frameworks/FirebaseSharedSwift.framework/FirebaseSharedSwift
And the following error message from the symbolicated crashlogs:
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Termination Reason: DYLD 4 Symbol missing
Symbol not found: __ZN5swift39swift51override_conformsToSwiftProtocolEPKNS_14TargetMetadataINS_9InProcessEEEPKNS_24TargetProtocolDescriptorIS1_EEN7__swift9__runtime4llvm9StringRefEPFPKNS_35TargetProtocolConformanceDescriptorIS1_EES4_S8_SC_E
Referenced from: <9B687E21-801B-34A8-BC2F-D2811C85D21C> /Volumes/VOLUME//MyMauiApp.app/Frameworks/FirebaseFirestore.framework/FirebaseFirestore
Expected in: <34DD8225-075B-3F6E-9467-C22809180549> /Volumes/VOLUME//MyMauiApp.app/Frameworks/FirebaseSharedSwift.framework/FirebaseSharedSwift
(terminated at launch; ignore backtrace)
Screenshots
N/A
Environment (please complete the following information):
- Using Macbook Pro M1 Max Sequoia 15.3.2
- OS: iOS, arm64
- IDE (if applicable): Visual Studio and dotnet PowerShell
- .NET version: 9.0.3
- .NET SDK version: 9.0.202
- XCode version: 16.2
- Plugin.Firebase Version: 3.1.4
- AdamE.Firebase.iOS.Core: 11.10.0
.csproj
Current Status:
<!-- iOS - Debug -->
<PropertyGroup Condition="$(TargetFramework.Contains('-ios')) and '$(Configuration)' == 'Debug'">
<_ExportSymbolsExplicitly>false</_ExportSymbolsExplicitly>
<MtouchLink>SdkOnly</MtouchLink>
<CodesignKey>mykey</CodesignKey>
<CodesignProvision>myprovision</CodesignProvision>
<CodesignEntitlements>Platforms\iOS\Entitlements.iOS.Debug.plist</CodesignEntitlements>
<UseHardenedRuntime>true</UseHardenedRuntime>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="CommunityToolkit.Maui" Version="11.2.0" />
<PackageReference Include="Microsoft.Maui.Controls" Version="9.0.50" />
<PackageReference Include="Microsoft.Maui.Controls.Compatibility" Version="9.0.50" />
<PackageReference Include="Microsoft.Maui.Essentials" Version="9.0.50" />
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="9.0.4" />
<PackageReference Include="Plugin.Firebase" Version="3.1.4" />
<PackageReference Include="Plugin.InAppBilling" Version="8.0.5" />
<PackageReference Include="Plugin.Maui.Audio" Version="3.1.1" />
<PackageReference Include="Plugin.MauiMTAdmob" Version="2.0.0.5" />
<PackageReference Include="ReactiveUI" Version="20.1.63" />
<PackageReference Include="ReactiveUI.Fody" Version="19.5.41" />
<PackageReference Include="ReactiveUI.Maui" Version="20.1.63" />
<PackageReference Include="sqlite-net-pcl" Version="1.9.172" />
<PackageReference Include="SQLitePCLRaw.bundle_green" Version="2.1.11" />
<PackageReference Include="System.Text.Json" Version="9.0.4" />
<PackageReference Include="Xamarin.Build.Download" Version="0.11.4" />
</ItemGroup>
<ItemGroup Condition="'$(TargetFramework)' == 'net9.0-ios'">
<PackageReference Include="AdamE.Firebase.iOS.Core" Version="11.10.0" />
<PackageReference Include="AdamE.Firebase.iOS.Analytics" Version="11.10.0" />
<PackageReference Include="AdamE.Google.iOS.GTMSessionFetcher" Version="4.3.0" />
</ItemGroup>
<!--Needed for Crashlytics on iOS-->
<!-- Target needed until LinkWithSwiftSystemLibraries makes it into the SDK: https://github.com/xamarin/xamarin-macios/pull/20463 -->
<Target Name="LinkWithSwift" DependsOnTargets="_ParseBundlerArguments;_DetectSdkLocations" BeforeTargets="_LinkNativeExecutable">
<PropertyGroup>
<_SwiftPlatform Condition="$(RuntimeIdentifier.StartsWith('iossimulator-'))">iphonesimulator</_SwiftPlatform>
<_SwiftPlatform Condition="$(RuntimeIdentifier.StartsWith('ios-'))">iphoneos</_SwiftPlatform>
</PropertyGroup>
<ItemGroup>
<_CustomLinkFlags Include="-L" />
<_CustomLinkFlags Include="/usr/lib/swift" />
<_CustomLinkFlags Include="-L" />
<_CustomLinkFlags Include="$(_SdkDevPath)/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/$(_SwiftPlatform)" />
<_CustomLinkFlags Include="-Wl,-rpath" />
<_CustomLinkFlags Include="-Wl,/usr/lib/swift" />
</ItemGroup>
</Target>
What I have Tried
Additional context
- Builds, deploys, and publishes on Android with an additional reference to the latest Xamarin.Firebase.Analytics.
- Each additional AdamE.Firebase.iOS* package reference would sometimes change the error message received to state a different package than the Firestore package. For example, adding the Firestore reference or package to the project then causes the error to reference a different package so on and so forth. Adding all of the packages did not get rid of the error however.
-Three additional warnings appear on successful builds
warning MT7091: The framework /Users/user/Library/Caches/XamarinBuildDownload/FAnlytcs-11.10.0/FirebaseAnalytics-11.10.0/Frameworks/FirebaseAnalytics.xcframework/ios-arm64/FirebaseAnalytics.framework is a framework of static libraries, and will not be copied to the app.
warning MT7091: The framework /Users/user/Library/Caches/XamarinBuildDownload/GAppM-11.10.0/GoogleAppMeasurement-11.10.0/Frameworks/GoogleAppMeasurement.xcframework/ios-arm64/GoogleAppMeasurement.framework is a framework of static libraries, and will not be copied to the app.
warning MT7091: The framework /Users/user/Library/Caches/XamarinBuildDownload/GAppM-11.10.0/GoogleAppMeasurement-11.10.0/Frameworks/GoogleAppMeasurementIdentitySupport.xcframework/ios-arm64/GoogleAppMeasurementIdentitySupport.framework is a framework of static libraries, and will not be copied to the app
Before reporting a bug:
Describe the bug
The application successfully builds but then crashes with the following error messages from the debug console:
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Build and deploy successfully.
Error messages
error HE1045: Failed to execute 'devicectl': 'devicectl -j /var/folders/b3/0lxs40sd41v70zqtdndnqmpm0000gn/T/tmpPcf12Z.tmp device process launch --terminate-existing --device 00008110-001145E13AE8401E --console com.company.MyMauiApp' returned the exit code 1.
error HE1046: Additional output: xcrun devicectl -j /var/folders/b3/0lxs40sd41v70zqtdndnqmpm0000gn/T/tmpPcf12Z.tmp device process launch --terminate-existing --device 00008110-001145E13AE8401E --console com.company.MyMauiApp
error HE1046: Additional output: dyld[13554]: Symbol not found: __ZN5swift39swift51override_conformsToSwiftProtocolEPKNS_14TargetMetadataINS_9InProcessEEEPKNS_24TargetProtocolDescriptorIS1_EEN7__swift9__runtime4llvm9StringRefEPFPKNS_35TargetProtocolConformanceDescriptorIS1_EES4_S8_SC_E
error HE1046: Additional output: Referenced from: <9B687E21-801B-34A8-BC2F-D2811C85D21C> /private/var/containers/Bundle/Application/8CB99D8C-27B6-47DF-97E3-DA36BF385C7C/MyMauiApp.app/Frameworks/FirebaseFirestore.framework/FirebaseFirestore
error HE1046: Additional output: Expected in: <34DD8225-075B-3F6E-9467-C22809180549> /private/var/containers/Bundle/Application/8CB99D8C-27B6-47DF-97E3-DA36BF385C7C/MyMauiApp.app/Frameworks/FirebaseSharedSwift.framework/FirebaseSharedSwift
And the following error message from the symbolicated crashlogs:
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Termination Reason: DYLD 4 Symbol missing
Symbol not found: __ZN5swift39swift51override_conformsToSwiftProtocolEPKNS_14TargetMetadataINS_9InProcessEEEPKNS_24TargetProtocolDescriptorIS1_EEN7__swift9__runtime4llvm9StringRefEPFPKNS_35TargetProtocolConformanceDescriptorIS1_EES4_S8_SC_E
Referenced from: <9B687E21-801B-34A8-BC2F-D2811C85D21C> /Volumes/VOLUME//MyMauiApp.app/Frameworks/FirebaseFirestore.framework/FirebaseFirestore
Expected in: <34DD8225-075B-3F6E-9467-C22809180549> /Volumes/VOLUME//MyMauiApp.app/Frameworks/FirebaseSharedSwift.framework/FirebaseSharedSwift
(terminated at launch; ignore backtrace)
Screenshots
N/A
Environment (please complete the following information):
.csproj
What I have Tried
-Adding AdamE.Google.iOS.GTMSessionFetcher which resolved TobiaBuchholz/Plugin.Firebase issue Fix "supermarket" missing from PlaceTypes xamarin/GoogleApisForiOSComponents#402 (Crash in .net Maui iOS app on startup with 'missing library' GTMSessionFetcher TobiasBuchholz/Plugin.Firebase#402).
-Adding more AdamE plugin references to Installations, Cloudfirestore, Crashlytics, CloudFunctions, and GoogleAppMeasurement. (Currently not in csproj because the same error appears with or without them).
Additional context
-Three additional warnings appear on successful builds
warning MT7091: The framework /Users/user/Library/Caches/XamarinBuildDownload/FAnlytcs-11.10.0/FirebaseAnalytics-11.10.0/Frameworks/FirebaseAnalytics.xcframework/ios-arm64/FirebaseAnalytics.framework is a framework of static libraries, and will not be copied to the app.
warning MT7091: The framework /Users/user/Library/Caches/XamarinBuildDownload/GAppM-11.10.0/GoogleAppMeasurement-11.10.0/Frameworks/GoogleAppMeasurement.xcframework/ios-arm64/GoogleAppMeasurement.framework is a framework of static libraries, and will not be copied to the app.
warning MT7091: The framework /Users/user/Library/Caches/XamarinBuildDownload/GAppM-11.10.0/GoogleAppMeasurement-11.10.0/Frameworks/GoogleAppMeasurementIdentitySupport.xcframework/ios-arm64/GoogleAppMeasurementIdentitySupport.framework is a framework of static libraries, and will not be copied to the app