Visual Studio 2017 for Mac部署Xamarin Forms至iPhone报错求助
Hey, let's work through these issues step by step since you've already tried the basics with the docs and fastlane. Here's what you can try to fix both the account login problem in VS for Mac and the signing mismatch error:
Troubleshooting Xamarin Forms Deployment to iPhone (VS for Mac 7.3.2)
1. Fix the Apple Account Login Glitch in VS for Mac
The unresponsive login button is likely a cache or keychain issue. Let's reset that:
- Close VS for Mac completely, then open Keychain Access on your Mac. Search for and delete any keychain entries labeled with
XamarinorApple Development(be careful not to delete unrelated keys!). - Reopen VS for Mac, head to Preferences > Accounts, and manually add your Apple Developer account. Make sure to select the
Apple Developeraccount type when prompted. - If it still doesn't load, check your network settings in VS for Mac: go to Preferences > Network to confirm no misconfigured proxies are blocking access to Apple's developer services.
2. Manually Verify Signing Identity & Provisioning Profile Match
Automatic provisioning isn't working, so let's do this manually to ensure everything lines up:
- Open Xcode (VS for Mac 7.3.2 works best with Xcode 9.x, so make sure you have a compatible version installed). Go to Preferences > Accounts, select your developer account, and click Manage Certificates. Confirm you have a valid
Apple Developmentcertificate—if not, click the + icon at the bottom left to generate a new one. - Still in Xcode, click View Details under your account, then find your app's Provisioning Profile. Verify it's a Development profile, includes your iPhone's UDID, and is linked to the development certificate you just checked.
- Download the correct profile, double-click to install it on your Mac. Then in VS for Mac:
- Right-click your iOS project > Options > Build > iOS Bundle Signing
- Switch to Manual mode. In the Signing Identity dropdown, pick the matching
Apple Development: [Your Name] (XXXX)entry. - In the Provisioning Profile dropdown, select the profile you just installed.
3. Use Fastlane to Refresh Signing Assets
Since you already have fastlane set up, let it handle syncing your signing assets to avoid manual errors:
- Open Terminal in your iOS project's root folder, run
fastlane initand choose the Automatic code signing option when prompted. - Next, run
fastlane match development. Follow the prompts to enter your Apple ID and developer team ID—this will automatically generate or download the correct development certificate and provisioning profile that match each other. - Go back to VS for Mac, either switch back to Automatic provisioning mode or manually select the fastlane-generated profile, then try deploying again.
4. Final Pre-Deployment Checks
- On your iPhone, go to Settings > General > Device Management, find your developer account, and tap to trust it (this is required to run apps signed with your development certificate).
- Clean your project in VS for Mac: click Build > Clean All, restart VS, then rebuild and deploy to your iPhone.
内容的提问来源于stack exchange,提问作者MilkBottle
相关产品推荐
相关产品推荐

