CapApp-SPM Package.swift always generates iOS 14 instead of iOS 15 after Capacitor 8 SPM migration

Hello,

I’m migrating a Capacitor iOS project (Capacitor 8) from CocoaPods to Swift Package Manager using:

npx cap spm-migration-assistant
npx cap sync ios

Everything works correctly, but I have an issue with the generated SPM wrapper:

ios/App/CapApp-SPM/Package.swift is always generated with:

platforms: [.iOS(.v14)]

However, my project and dependencies require iOS 15 (Firebase SPM, RevenueCat, Sentry, etc.), and my Xcode deployment target is also set to iOS 15.

This causes SwiftPM resolution errors when building the project.


What I want

I would like CapApp-SPM to automatically generate:

platforms: [.iOS(.v15)]

instead of .v14 when running:

npx cap sync ios

or npx cap spm-migration-assistant.


Expected behavior

Capacitor should respect the project minimum iOS version (e.g. from capacitor.config.ts or Xcode deployment target) and generate the correct platform version in CapApp-SPM/Package.swift.


Environment

  • Capacitor: 8.x
  • Xcode: 15+
  • iOS deployment target: 15.0
  • Using SPM migration (CapApp-SPM)

Impact

This mismatch breaks Swift Package Manager resolution when dependencies require iOS 15, even though the app itself is configured correctly.

Camille