› Forums › How to solve › Compiling for iOS 12.0, but module ‘Capacitor’ has a minimum deployment target
- This topic has 1 reply, 1 voice, and was last updated 3 months ago by
albanaavdiu.
-
AuthorPosts
-
July 30, 2025 at 7:06 am #122294
albanaavdiu
ParticipantProblem :
Compiling for iOS 12.0, but module ‘Capacitor’ has a minimum deployment target of iOS 13.0: /Users/user/Library/Developer/Xcode/DerivedData/App-gaupmbtshmqbxzekeowabwveibft/Index.noindex/Build/Products/Debug-iphonesimulator/Capacitor/Capacitor.framework/Modules/Capacitor.swiftmodule/x86_64-apple-ios-simulator.swiftmoduleSolution :
1. Set platform in your Podfile
If you don’t have a Podfile, generate one:cd ios/App
pod initThen edit the Podfile and set the platform:
platform :ios, ‘13.0’Then run:
cd ios/App
pod installgrep -rnw ‘./’ -e ‘12.0’ –include=”*.pbxproj” –include=”*.plist”
(If the value reverts back to 12.0, this happens because Pods.xcodeproj is auto-generated by CocoaPods. You should not manually edit it because CocoaPods will overwrite it):sed -i ” ‘s/IPHONEOS_DEPLOYMENT_TARGET = 12.0;/IPHONEOS_DEPLOYMENT_TARGET = 13.0;/g’ ios/App/App.xcodeproj/project.pbxproj
If still the same after npx cap sync android:
Correct Podfile structure:workspace ‘App.xcworkspace’ # ✅ Add this line first
platform :ios, ‘14.0’
use_frameworks!# workaround to avoid Xcode caching of Pods that requires
# Product -> Clean Build Folder after new Cordova plugins installed
# Requires CocoaPods 1.6 or newer
install! ‘cocoapods’, :disable_input_output_paths => true-
This topic was modified 3 months ago by
albanaavdiu.
-
This topic was modified 3 months ago by
albanaavdiu.
-
This topic was modified 3 months ago by
albanaavdiu.
July 30, 2025 at 7:13 am #122298albanaavdiu
ParticipantAfter saving :
cd ios/App
pod installForce override all deployment targets to 14.0
Open your Podfile and add this block at the end:
post_install do |installer|
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings[‘IPHONEOS_DEPLOYMENT_TARGET’] = ‘14.0’
end
end
endReinstall pods
cd ios/App
rm -rf Pods Podfile.lock
pod installRe-check the results:
grep -rnw ‘./’ -e ‘IPHONEOS_DEPLOYMENT_TARGET’ –include=”*.pbxproj” -
This topic was modified 3 months ago by
-
AuthorPosts
- You must be logged in to reply to this topic.