TobiasBuchholz / Plugin.Firebase

Wrapper around the native Android and iOS Firebase Xamarin SDKs
MIT License
211 stars 49 forks source link

Unable to build iOS target #227

Closed GODston closed 10 months ago

GODston commented 10 months ago

Whenever i try to build my project with iOS target enabled i get the following errors:

1>C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(4879,5): error MSB3030: Could not copy the file "C:\.ng\xamarin.firebase.ios.cloudfirestore\8.10.0.3\lib\net6.0-ios15.4\Firebase.CloudFirestore.resources\grpc.xcframework\ios-arm64\grpc.framework\PrivateHeaders\src\core\ext\upb-generated\envoy\config\filter\network\http_connection_manager\v2\http_connection_manager.upb.h" because it was not found.
1>C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(4879,5): error MSB3030: Could not copy the file "C:\.ng\xamarin.firebase.ios.cloudfirestore\8.10.0.3\lib\net6.0-ios15.4\Firebase.CloudFirestore.resources\grpc.xcframework\ios-arm64_x86_64-simulator\grpc.framework\PrivateHeaders\src\core\ext\filters\client_channel\lb_policy\grpclb\client_load_reporting_filter.h" because it was not found.
1>C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(4879,5): error MSB3030: Could not copy the file "C:\.ng\xamarin.firebase.ios.cloudfirestore\8.10.0.3\lib\net6.0-ios15.4\Firebase.CloudFirestore.resources\grpc.xcframework\ios-arm64_x86_64-simulator\grpc.framework\PrivateHeaders\src\core\tsi\alts\zero_copy_frame_protector\alts_grpc_privacy_integrity_record_protocol.h" because it was not found.
1>C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(4879,5): error MSB3030: Could not copy the file "C:\.ng\xamarin.firebase.ios.cloudfirestore\8.10.0.3\lib\net6.0-ios15.4\Firebase.CloudFirestore.resources\grpc.xcframework\ios-arm64_x86_64-simulator\grpc.framework\PrivateHeaders\src\core\tsi\alts\zero_copy_frame_protector\alts_grpc_integrity_only_record_protocol.h" because it was not found.
1>C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(4879,5): error MSB3030: Could not copy the file "C:\.ng\xamarin.firebase.ios.cloudfirestore\8.10.0.3\lib\net6.0-ios15.4\Firebase.CloudFirestore.resources\grpcpp.xcframework\ios-arm64\grpcpp.framework\PrivateHeaders\src\core\ext\upb-generated\envoy\config\filter\network\http_connection_manager\v2\http_connection_manager.upb.h" because it was not found.
1>C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(4879,5): error MSB3030: Could not copy the file "C:\.ng\xamarin.firebase.ios.cloudfirestore\8.10.0.3\lib\net6.0-ios15.4\Firebase.CloudFirestore.resources\grpcpp.xcframework\ios-arm64_x86_64-simulator\grpcpp.framework\PrivateHeaders\src\core\ext\filters\client_channel\lb_policy\grpclb\client_load_reporting_filter.h" because it was not found.
1>C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(4879,5): error MSB3030: Could not copy the file "C:\.ng\xamarin.firebase.ios.cloudfirestore\8.10.0.3\lib\net6.0-ios15.4\Firebase.CloudFirestore.resources\grpcpp.xcframework\ios-arm64_x86_64-simulator\grpcpp.framework\PrivateHeaders\src\core\ext\filters\client_channel\resolver\dns\c_ares\grpc_ares_ev_driver.h" because it was not found.
1>C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(4879,5): error MSB3030: Could not copy the file "C:\.ng\xamarin.firebase.ios.cloudfirestore\8.10.0.3\lib\net6.0-ios15.4\Firebase.CloudFirestore.resources\grpcpp.xcframework\ios-arm64_x86_64-simulator\grpcpp.framework\PrivateHeaders\src\core\ext\upb-generated\src\proto\grpc\gcp\transport_security_common.upb.h" because it was not found.
1>C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(4879,5): error MSB3030: Could not copy the file "C:\.ng\xamarin.firebase.ios.cloudfirestore\8.10.0.3\lib\net6.0-ios15.4\Firebase.CloudFirestore.resources\grpcpp.xcframework\ios-arm64_x86_64-simulator\grpcpp.framework\PrivateHeaders\src\core\lib\security\credentials\google_default\google_default_credentials.h" because it was not found.
1>C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(4879,5): error MSB3030: Could not copy the file "C:\.ng\xamarin.firebase.ios.cloudfirestore\8.10.0.3\lib\net6.0-ios15.4\Firebase.CloudFirestore.resources\grpcpp.xcframework\ios-arm64_x86_64-simulator\grpcpp.framework\PrivateHeaders\src\core\tsi\alts\zero_copy_frame_protector\alts_grpc_integrity_only_record_protocol.h" because it was not found.
1>C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(4879,5): error MSB3030: Could not copy the file "C:\.ng\xamarin.firebase.ios.cloudfirestore\8.10.0.3\lib\net6.0-ios15.4\Firebase.CloudFirestore.resources\grpcpp.xcframework\ios-arm64_x86_64-simulator\grpcpp.framework\PrivateHeaders\src\core\tsi\alts\zero_copy_frame_protector\alts_grpc_privacy_integrity_record_protocol.h" because it was not found.
1>C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\Microsoft.Common.CurrentVersion.targets(4879,5): error MSB3030: Could not copy the file "C:\.ng\xamarin.firebase.ios.cloudfirestore\8.10.0.3\lib\net6.0-ios15.4\Firebase.CloudFirestore.resources\grpcpp.xcframework\ios-arm64_x86_64-simulator\grpcpp.framework\PrivateHeaders\src\core\tsi\alts\zero_copy_frame_protector\alts_grpc_record_protocol_common.h" because it was not found.

I actually had many more, but i changed my project directory to a smaller one (from C:\Repos\MAUIProjects\ProjectName\Version to just C:\Repos\ProjectName) and moving the .nuget forlder location as indicated in the paths above, since it seemed to be a MAX_PATH error.

The issue is i can shorten the .ng path any more, and some of the paths in the errors above are even > 270 without even the C:\ directory.

Any advice on this?

GODston commented 10 months ago

As an extra, im running on Windows 11, and this errors only happened since i changed my laptop, and disabling the iOS target allows me to build with no problems.

TobiasBuchholz commented 10 months ago

Please take a look at https://github.com/TobiasBuchholz/Plugin.Firebase/issues/199#issuecomment-1795405599 which explains the issue with Windows 11 quite good.

GODston commented 10 months ago

Thank you for your replay, just a question: Should switch to Win10 as OS solve this issue? or should i just give up compatibility with iOS? Either way, thanks again!

TobiasBuchholz commented 10 months ago

Yeah, I guess using Windows 10 or MacOS as operating system is the only solution for now...additionally you can create an issue at https://github.com/xamarin/GoogleApisForiOSComponents and hope Microsoft will fix this problem as soon as possible.

GODston commented 10 months ago

Thank you very much! i will be creating a ticket, but i honestly wont expect a response too soon xd, ill just work with what i have for now. I will try to get my hands on a MacOS system, or try to get a VM running with it, as i need it anyway to run my app tests on iPhone devices. If that fails i can just turn off the iOS build for the time being (which is what i've been doing up until now).

And again, thank you!