I just updated my iPhone to iOS 16.4 and Android Studio/VSCode release build to physical phone fails with the error:
Failed to build iOS app
Could not build the precompiled application for the device.
How do I fix this?
An iPhone running iOS 16.4 requires Xcode 14.3+ to sign & build apps to install on phones running the latest iOS.
The quick fix is to copy DeviceSupport files from the latest XCode (via a Github mirror) into your XCode installed on your development machine. (The long fix is to install the latest Xcode version via Apple App Store, which will support your updated iPhone iOS.)
The DeviceSupport files can be found here: https://github.com/iGhibli/iOS-DeviceSupport/tree/master/DeviceSupport
Download the zip file matching your iOS version.
For example:
16.4(FromXcode_14.3(14E222b)).zip
for iOS 16.4 which is supported on Xcode 14.3.
Unzip that file.
Copy that 16.4 folder to your Xcode installation under the directory
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport
Close Xcode (if open) and reopen.
You should now be able to perform a release build onto your physical iPhone from either Android Studio, VSCode or Xcode.
For more details / step-by-step instructions see this.