Skip to content

[Bug]: CapApp-SPM always generates .iOS(.v14) even when project requires iOS 15 (Capacitor 8 SPM migration)#8523

Description

@CamilleFrive

Capacitor Version

npx cap doctor:
BUILDING for env: undefined
馃拪 Capacitor Doctor 馃拪

Latest Dependencies:

@capacitor/cli: 8.4.1
@capacitor/core: 8.4.1
@capacitor/android: 8.4.1
@capacitor/ios: 8.4.1

Installed Dependencies:

@capacitor/cli: 8.4.1
@capacitor/core: 8.4.1
@capacitor/android: 8.4.1
@capacitor/ios: 8.4.1

[success] iOS looking great! 馃憣
[success] Android looking great! 馃憣

Other API Details

npm --version 10.2.3
node --version v22.22.2

Platforms Affected

  • iOS
  • Android
  • Web

Current Behavior

After migrated with
npx cap spm-migration-assistant

and running:
npx cap sync ios

the generated file:

ios/App/CapApp-SPM/Package.swift

always contains:

platforms: [.iOS(.v14)]

This happens even when:

Xcode deployment target is set to iOS 15
Capacitor config includes ios.minVersion = "15.0"
The project is fully migrated to SPM

Expected Behavior

The generated CapApp-SPM/Package.swift should respect the project minimum iOS version and generate:

platforms: [.iOS(.v15)]

Specifically, it should:

Respect capacitor.config.ts iOS minimum version
Or align with Xcode deployment target
Or infer from installed plugin requirements (Firebase, Sentry, RevenueCat, etc.)

Project Reproduction

i cant share the project, sorry

Additional Information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    needs reproductionneeds reproducible example to illustrate the issue

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions