Skip to content

Commit

Permalink
Fix iOS sqlite3 linking issue
Browse files Browse the repository at this point in the history
fixes #888

Co-Authored-By: Ross Savage <[email protected]>
  • Loading branch information
erdemyerebasmaz and dangeross committed Sep 23, 2024
1 parent f0c16f8 commit a0a1c2e
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions ios/Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,15 @@ post_install do |installer|
installer.pods_project.targets.each do |target|
flutter_additional_ios_build_settings(target)
target.build_configurations.each do |config|
# Remove the -lsqlite3 linker flag
# https://github.com/CocoaPods/CocoaPods/issues/830
# We already include our own sqlite3 implementation via a pod,
# so we don't want the system-provided one as well.
xcconfig_path = config.base_configuration_reference.real_path
xcconfig = File.read(xcconfig_path)
new_xcconfig = xcconfig.sub('-l"sqlite3"', '')
File.open(xcconfig_path, "w") { |file| file << new_xcconfig }

config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = deployment_target
config.build_settings['SWIFT_VERSION'] = '5.0'
config.build_settings['ENABLE_BITCODE'] = 'NO'
Expand Down

0 comments on commit a0a1c2e

Please sign in to comment.