tekartik / sqflite

SQLite flutter plugin
BSD 2-Clause "Simplified" License
2.87k stars 523 forks source link

Unable to build iOS app after adding sqflite(1.1.7+3) dependency flutter #362

Open Mohammed3194 opened 4 years ago

Mohammed3194 commented 4 years ago

Hi i am newbie, into flutter, trying to generate an ipa file to share for testing. I have added sqflite dependency, when i try to build i am getting below error. Please help me out in resolving this issue Any help would be appreciated,

Sqflite: ^1.1.7+3

Running pod install... CocoaPods' output: ↳ Preparing

Analyzing dependencies

Inspecting targets to integrate
  Using `ARCHS` setting to build architectures of target `Pods-Runner`: (``)

Fetching external sources
-> Fetching podspec for `Flutter` from `.symlinks/flutter/ios`
-> Fetching podspec for `sqflite` from `.symlinks/plugins/sqflite/ios`

Resolving dependencies of `Podfile`
  CDN: trunk Relative path: CocoaPods-version.yml exists! Returning local because checking is only perfomed in repo update
  CDN: trunk Relative path: all_pods_versions_f_4_e.txt exists! Returning local because checking is only perfomed in repo update
  CDN: trunk Relative path: Specs/f/4/e/FMDB/2.7.5/FMDB.podspec.json exists! Returning local because checking is only perfomed in repo update
  CDN: trunk Relative path: Specs/f/4/e/FMDB/2.7.5/FMDB.podspec.json exists! Returning local because checking is only perfomed in repo update
  CDN: trunk Relative path: Specs/f/4/e/FMDB/2.7.2/FMDB.podspec.json exists! Returning local because checking is only perfomed in repo update
  CDN: trunk Relative path: Specs/f/4/e/FMDB/2.7.5/FMDB.podspec.json exists! Returning local because checking is only perfomed in repo update

Comparing resolved specification to the sandbox manifest
  A FMDB
  A Flutter
  A sqflite

Downloading dependencies

-> Installing FMDB (2.7.5)
 > Git download
 > Git download
     $ /usr/local/bin/git clone https://github.com/ccgus/fmdb.git /var/folders/mw/k3cjxrd92hs2jl3rr_mdh49h0000gn/T/d20200130-10239-gboxgo --template= --single-branch --depth 1 --branch 2.7.5

[!] Error installing FMDB
[!] /usr/local/bin/git clone https://github.com/ccgus/fmdb.git /var/folders/mw/k3cjxrd92hs2jl3rr_mdh49h0000gn/T/d20200130-10239-gboxgo --template= --single-branch --depth 1 --branch 2.7.5

Cloning into '/var/folders/mw/k3cjxrd92hs2jl3rr_mdh49h0000gn/T/d20200130-10239-gboxgo'...
fatal: unable to access 'https://github.com/ccgus/fmdb.git/': could not load PEM client certificate, LibreSSL error error:02FFF002:system library:func(4095):No such file or directory, (no key found, wrong pass phrase, or wrong file format?)

/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:142:in `rescue in execute_command'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:139:in `execute_command'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-downloader-1.2.2/lib/cocoapods-downloader/base.rb:154:in `block in executable'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-downloader-1.2.2/lib/cocoapods-downloader/git.rb:79:in `block in clone'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:173:in `block in ui_sub_action'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/user_interface.rb:64:in `section'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:172:in `ui_sub_action'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-downloader-1.2.2/lib/cocoapods-downloader/git.rb:77:in `clone'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-downloader-1.2.2/lib/cocoapods-downloader/git.rb:45:in `download!'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-downloader-1.2.2/lib/cocoapods-downloader/base.rb:82:in `block in download'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:157:in `block in ui_action'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/user_interface.rb:64:in `section'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:156:in `ui_action'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-downloader-1.2.2/lib/cocoapods-downloader/base.rb:80:in `download'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:108:in `download_source'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:75:in `download_request'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader/cache.rb:171:in `download'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader/cache.rb:154:in `block in uncached_pod'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader/cache.rb:181:in `in_tmpdir'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader/cache.rb:153:in `uncached_pod'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader/cache.rb:33:in `download_pod'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:42:in `download'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer/pod_source_installer.rb:117:in `download_source'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer/pod_source_installer.rb:69:in `install!'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:557:in `install_source_of_pod'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:508:in `block (2 levels) in install_pod_sources'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/user_interface.rb:86:in `titled_section'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:507:in `block in install_pod_sources'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:490:in `each'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:490:in `install_pod_sources'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:248:in `block in download_dependencies'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/user_interface.rb:64:in `section'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:247:in `download_dependencies'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:157:in `install!'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/command/install.rb:52:in `run'
/Library/Ruby/Gems/2.3.0/gems/claide-1.0.2/lib/claide/command.rb:334:in `run'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/command.rb:52:in `run'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/bin/pod:55:in `<top (required)>'
/usr/local/bin/pod:22:in `load'
/usr/local/bin/pod:22:in `<main>'

Error output from CocoaPods: ↳ Cloning into '/var/folders/mw/k3cjxrd92hs2jl3rr_mdh49h0000gn/T/d20200130-10239-gboxgo'... fatal: unable to access 'https://github.com/ccgus/fmdb.git/': could not load PEM client certificate, LibreSSL error error:02FFF002:system library:func(4095):No such file or directory, (no key found, wrong pass phrase, or wrong file format?)

[!] `<PBXGroup UUID=`97C146E51CF9000F007C117D`>` attempted to initialize an object with an unknown UUID. `CF3B75C9A7D2FA2A4C99F110` for attribute: `children`. This can be the result of a merge and the unknown UUID is being discarded.

[!] Automatically assigning platform `iOS` with version `8.0` on target `Runner` because no platform was specified. Please specify a platform for this target in your Podfile. See `https://guides.cocoapods.org/syntax/podfile.html#platform`.

Finished with error: Error running pod install

kavya-shri-as commented 4 years ago

Hi, Getting below error when trying to install pod files

Mac-mini:ios skm-04$ pod install Analyzing dependencies Downloading dependencies Installing !ProtoCompiler (3.11.2) Installing FMDB (2.7.5)

[!] Error installing FMDB [!] /usr/local/bin/git clone https://github.com/ccgus/fmdb.git /var/folders/mw/k3cjxrd92hs2jl3rr_mdh49h0000gn/T/d20200131-49343-r9cn7u --template= --single-branch --depth 1 --branch 2.7.5

Cloning into '/var/folders/mw/k3cjxrd92hs2jl3rr_mdh49h0000gn/T/d20200131-49343-r9cn7u'... fatal: unable to access 'https://github.com/ccgus/fmdb.git/': could not load PEM client certificate, LibreSSL error error:02FFF002:system library:func(4095):No such file or directory, (no key found, wrong pass phrase, or wrong file format?)

alextekartik commented 4 years ago

v1.2.1 fixes an iOS build issue that you might want to try

Moosphan commented 4 years ago

I had the same issue.

Saurav1143 commented 4 years ago

still i am getting this error.

alextekartik commented 4 years ago

I'm sorry I cannot reproduce. It seems to be an network/SSL/git issue on your side. Does it happen in the following simple scenario:

@Moosphan @kavya-shri-as does it still happen to you? If no, how did you solve this issue? Thanks!

saviourdog commented 4 years ago

in new flutter project add sqflite dependency will go wrong in pod install...

Moosphan commented 4 years ago

Sorry so late to be here, it's fine now on my ios devices, but i have forgot how i fixed this. I just update my xcode to official version (previous was beta), and modified my podfile:

# Uncomment this line to define a global platform for your project
platform :ios, '9.0'

# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
ENV['COCOAPODS_DISABLE_STATS'] = 'true'

project 'Runner', {
  'Debug' => :debug,
  'Profile' => :release,
  'Release' => :release,
}

def parse_KV_file(file, separator='=')
  file_abs_path = File.expand_path(file)
  if !File.exists? file_abs_path
    return [];
  end
  generated_key_values = {}
  skip_line_start_symbols = ["#", "/"]
  File.foreach(file_abs_path) do |line|
    next if skip_line_start_symbols.any? { |symbol| line =~ /^\s*#{symbol}/ }
    plugin = line.split(pattern=separator)
    if plugin.length == 2
      podname = plugin[0].strip()
      path = plugin[1].strip()
      podpath = File.expand_path("#{path}", file_abs_path)
      generated_key_values[podname] = podpath
    else
      puts "Invalid plugin specification: #{line}"
    end
  end
  generated_key_values
end

target 'Runner' do
  use_frameworks!
  use_modular_headers!

  # Flutter Pod

  copied_flutter_dir = File.join(__dir__, 'Flutter')
  copied_framework_path = File.join(copied_flutter_dir, 'Flutter.framework')
  copied_podspec_path = File.join(copied_flutter_dir, 'Flutter.podspec')
  unless File.exist?(copied_framework_path) && File.exist?(copied_podspec_path)
    # Copy Flutter.framework and Flutter.podspec to Flutter/ to have something to link against if the xcode backend script has not run yet.
    # That script will copy the correct debug/profile/release version of the framework based on the currently selected Xcode configuration.
    # CocoaPods will not embed the framework on pod install (before any build phases can generate) if the dylib does not exist.

    generated_xcode_build_settings_path = File.join(copied_flutter_dir, 'Generated.xcconfig')
    unless File.exist?(generated_xcode_build_settings_path)
      raise "Generated.xcconfig must exist. If you're running pod install manually, make sure flutter pub get is executed first"
    end
    generated_xcode_build_settings = parse_KV_file(generated_xcode_build_settings_path)
    cached_framework_dir = generated_xcode_build_settings['FLUTTER_FRAMEWORK_DIR'];

    unless File.exist?(copied_framework_path)
      FileUtils.cp_r(File.join(cached_framework_dir, 'Flutter.framework'), copied_flutter_dir)
    end
    unless File.exist?(copied_podspec_path)
      FileUtils.cp(File.join(cached_framework_dir, 'Flutter.podspec'), copied_flutter_dir)
    end
  end

  # Keep pod path relative so it can be checked into Podfile.lock.
  pod 'Flutter', :path => 'Flutter'

  # Plugin Pods

  # Prepare symlinks folder. We use symlinks to avoid having Podfile.lock
  # referring to absolute paths on developers' machines.
  system('rm -rf .symlinks')
  system('mkdir -p .symlinks/plugins')
  plugin_pods = parse_KV_file('../.flutter-plugins')
  plugin_pods.each do |name, path|
    symlink = File.join('.symlinks', 'plugins', name)
    File.symlink(path, symlink)
    pod name, :path => File.join(symlink, 'ios')
  end
end

pre_install do |installer|
  # workaround for https://github.com/CocoaPods/CocoaPods/issues/3289
  Pod::Installer::Xcode::TargetValidator.send(:define_method, :verify_no_static_framework_transitive_dependencies) {}
end

# Prevent Cocoapods from embedding a second Flutter framework and causing an error with the new Xcode build system.
install! 'cocoapods', :disable_input_output_paths => true

post_install do |installer|
  installer.pods_project.targets.each do |target|
    target.build_configurations.each do |config|
      config.build_settings['ENABLE_BITCODE'] = 'NO'
      config.build_settings['SWIFT_VERSION'] = '5.0' # added this
    end
  end
end
ahmetselman commented 4 years ago

I had the same issue and can not solve it yet... Is there any solution? i'm using v1.3.1

Mohammed3194 commented 4 years ago

Hi,

Even i was facing the same problem, The problem is with Cocoapods installation.

What i did is, Formatted my Mac and fresh installed Xcode version greater than 10.1 - (My current version is 10.3) and necessary IDE (Android Studio)

Next installed Cocoapods in mac and then tried installing pods for Sqflite for project with below steps

Go to your project -> iOS -> and run pod install And try building your app it should work.

Thanks

On Tue, 11 Aug, 2020, 8:59 am AhmetSelman, notifications@github.com wrote:

I had the same issue and can not solve it yet... Is there any solution?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/tekartik/sqflite/issues/362#issuecomment-671703415, or unsubscribe https://github.com/notifications/unsubscribe-auth/AFJUUWLIJQQPEFWHWGLA6WTSAC3K7ANCNFSM4KNUILKA .

mshenawy22 commented 3 years ago

same issue here with pod install

MiLLOR-GG commented 2 years ago

Hi i am newbie, into flutter, trying to generate an ipa file to share for testing. I have added sqflite dependency, when i try to build i am getting below error. Please help me out in resolving this issue Any help would be appreciated,

Sqflite: ^1.1.7+3

Running pod install... CocoaPods' output: ↳ Preparing

Analyzing dependencies

Inspecting targets to integrate
  Using `ARCHS` setting to build architectures of target `Pods-Runner`: (``)

Fetching external sources
-> Fetching podspec for `Flutter` from `.symlinks/flutter/ios`
-> Fetching podspec for `sqflite` from `.symlinks/plugins/sqflite/ios`

Resolving dependencies of `Podfile`
  CDN: trunk Relative path: CocoaPods-version.yml exists! Returning local because checking is only perfomed in repo update
  CDN: trunk Relative path: all_pods_versions_f_4_e.txt exists! Returning local because checking is only perfomed in repo update
  CDN: trunk Relative path: Specs/f/4/e/FMDB/2.7.5/FMDB.podspec.json exists! Returning local because checking is only perfomed in repo update
  CDN: trunk Relative path: Specs/f/4/e/FMDB/2.7.5/FMDB.podspec.json exists! Returning local because checking is only perfomed in repo update
  CDN: trunk Relative path: Specs/f/4/e/FMDB/2.7.2/FMDB.podspec.json exists! Returning local because checking is only perfomed in repo update
  CDN: trunk Relative path: Specs/f/4/e/FMDB/2.7.5/FMDB.podspec.json exists! Returning local because checking is only perfomed in repo update

Comparing resolved specification to the sandbox manifest
  A FMDB
  A Flutter
  A sqflite

Downloading dependencies

-> Installing FMDB (2.7.5)
 > Git download
 > Git download
     $ /usr/local/bin/git clone https://github.com/ccgus/fmdb.git /var/folders/mw/k3cjxrd92hs2jl3rr_mdh49h0000gn/T/d20200130-10239-gboxgo --template= --single-branch --depth 1 --branch 2.7.5

[!] Error installing FMDB
[!] /usr/local/bin/git clone https://github.com/ccgus/fmdb.git /var/folders/mw/k3cjxrd92hs2jl3rr_mdh49h0000gn/T/d20200130-10239-gboxgo --template= --single-branch --depth 1 --branch 2.7.5

Cloning into '/var/folders/mw/k3cjxrd92hs2jl3rr_mdh49h0000gn/T/d20200130-10239-gboxgo'...
fatal: unable to access 'https://github.com/ccgus/fmdb.git/': could not load PEM client certificate, LibreSSL error error:02FFF002:system library:func(4095):No such file or directory, (no key found, wrong pass phrase, or wrong file format?)

/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:142:in `rescue in execute_command'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:139:in `execute_command'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-downloader-1.2.2/lib/cocoapods-downloader/base.rb:154:in `block in executable'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-downloader-1.2.2/lib/cocoapods-downloader/git.rb:79:in `block in clone'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:173:in `block in ui_sub_action'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/user_interface.rb:64:in `section'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:172:in `ui_sub_action'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-downloader-1.2.2/lib/cocoapods-downloader/git.rb:77:in `clone'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-downloader-1.2.2/lib/cocoapods-downloader/git.rb:45:in `download!'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-downloader-1.2.2/lib/cocoapods-downloader/base.rb:82:in `block in download'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:157:in `block in ui_action'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/user_interface.rb:64:in `section'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:156:in `ui_action'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-downloader-1.2.2/lib/cocoapods-downloader/base.rb:80:in `download'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:108:in `download_source'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:75:in `download_request'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader/cache.rb:171:in `download'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader/cache.rb:154:in `block in uncached_pod'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader/cache.rb:181:in `in_tmpdir'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader/cache.rb:153:in `uncached_pod'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader/cache.rb:33:in `download_pod'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/downloader.rb:42:in `download'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer/pod_source_installer.rb:117:in `download_source'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer/pod_source_installer.rb:69:in `install!'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:557:in `install_source_of_pod'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:508:in `block (2 levels) in install_pod_sources'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/user_interface.rb:86:in `titled_section'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:507:in `block in install_pod_sources'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:490:in `each'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:490:in `install_pod_sources'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:248:in `block in download_dependencies'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/user_interface.rb:64:in `section'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:247:in `download_dependencies'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/installer.rb:157:in `install!'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/command/install.rb:52:in `run'
/Library/Ruby/Gems/2.3.0/gems/claide-1.0.2/lib/claide/command.rb:334:in `run'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/lib/cocoapods/command.rb:52:in `run'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.4/bin/pod:55:in `<top (required)>'
/usr/local/bin/pod:22:in `load'
/usr/local/bin/pod:22:in `<main>'

Error output from CocoaPods: ↳ Cloning into '/var/folders/mw/k3cjxrd92hs2jl3rr_mdh49h0000gn/T/d20200130-10239-gboxgo'... fatal: unable to access 'https://github.com/ccgus/fmdb.git/': could not load PEM client certificate, LibreSSL error error:02FFF002:system library:func(4095):No such file or directory, (no key found, wrong pass phrase, or wrong file format?)

[!] `<PBXGroup UUID=`97C146E51CF9000F007C117D`>` attempted to initialize an object with an unknown UUID. `CF3B75C9A7D2FA2A4C99F110` for attribute: `children`. This can be the result of a merge and the unknown UUID is being discarded.

[!] Automatically assigning platform `iOS` with version `8.0` on target `Runner` because no platform was specified. Please specify a platform for this target in your Podfile. See `https://guides.cocoapods.org/syntax/podfile.html#platform`.

Finished with error: Error running pod install

اhi i get the same problem any solution 🙏

MiLLOR-GG commented 2 years ago

hi i get the same problem any solution

lahirunc commented 2 years ago

Try this. It worked for me. Paste it into Podfile

pod 'FMDB', :git => 'https://github.com/ccgus/fmdb.git', :commit => '61e51fd'

threells1939 commented 2 years ago

Me too. When I remove sqflite everything is fine.

Running "flutter pub get" in flutter_test_demo...
Launching lib/main.dart on iPhone 13 Pro Max in debug mode...
Running pod install...
CocoaPods' output:
↳
      Preparing

    Analyzing dependencies

    Inspecting targets to integrate
      Using `ARCHS` setting to build architectures of target `Pods-Runner`: (``)

    Fetching external sources
    -> Fetching podspec for `Flutter` from `Flutter`
    -> Fetching podspec for `sqflite` from `.symlinks/plugins/sqflite/ios`

    Resolving dependencies of `Podfile`
      CDN: trunk Relative path: CocoaPods-version.yml exists! Returning local because checking is only performed in repo update
      CDN: trunk Relative path: CocoaPods-version.yml exists! Returning local because checking is only performed in repo update

    ――― MARKDOWN TEMPLATE ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――――

    ### Command
/usr/local/bin/pod install --verbose
```

### Report

* What did you do?

* What did you expect to happen?

* What happened instead?

### Stack

```
   CocoaPods : 1.11.3
        Ruby : ruby 2.6.8p205 (2021-07-07 revision 67951) [universal.arm64e-darwin21]
    RubyGems : 3.0.3.1
        Host : macOS 12.4 (21F79)
       Xcode : 13.4 (13F17a)
         Git : git version 2.36.1
Ruby lib dir : /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib
Repositories : master - git - https://mirrors.tuna.tsinghua.edu.cn/git/CocoaPods/Specs.git @ 1370bb4e4a423b36055c7fcd77702990360644c4

               trunk - CDN - https://cdn.cocoapods.org/
```

### Plugins

```
cocoapods-deintegrate : 1.0.5
cocoapods-plugins     : 1.0.0
cocoapods-search      : 1.0.1
cocoapods-trunk       : 1.6.0
cocoapods-try         : 1.2.0
```

### Podfile

```ruby
# Uncomment this line to define a global platform for your project
# platform :ios, '9.0'

# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
ENV['COCOAPODS_DISABLE_STATS'] = 'true'

project 'Runner', {
  'Debug' => :debug,
  'Profile' => :release,
  'Release' => :release,
}

def flutter_root
  generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__)
  unless File.exist?(generated_xcode_build_settings_path)
    raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first"
  end

  File.foreach(generated_xcode_build_settings_path) do |line|
    matches = line.match(/FLUTTER_ROOT\=(.*)/)
    return matches[1].strip if matches
  end
  raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get"
end

require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root)

flutter_ios_podfile_setup

target 'Runner' do
  use_frameworks!
  use_modular_headers!

  flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__))
end

post_install do |installer|
  installer.pods_project.targets.each do |target|
    flutter_additional_ios_build_settings(target)
  end
end
```

### Error

```
LoadError - dlopen(/Library/Ruby/Gems/2.6.0/gems/ffi-1.15.5/lib/ffi_c.bundle, 0x0009): tried: '/Library/Ruby/Gems/2.6.0/gems/ffi-1.15.5/lib/ffi_c.bundle' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64e')) - /Library/Ruby/Gems/2.6.0/gems/ffi-1.15.5/lib/ffi_c.bundle
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/Library/Ruby/Gems/2.6.0/gems/ffi-1.15.5/lib/ffi.rb:5:in `rescue in <top (required)>'
/Library/Ruby/Gems/2.6.0/gems/ffi-1.15.5/lib/ffi.rb:2:in `<top (required)>'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/Library/Ruby/Gems/2.6.0/gems/ethon-0.15.0/lib/ethon.rb:3:in `<top (required)>'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/Library/Ruby/Gems/2.6.0/gems/typhoeus-1.4.0/lib/typhoeus.rb:2:in `<top (required)>'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.11.3/lib/cocoapods-core/cdn_source.rb:440:in `download_typhoeus_impl_async'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.11.3/lib/cocoapods-core/cdn_source.rb:372:in `download_and_save_with_retries_async'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.11.3/lib/cocoapods-core/cdn_source.rb:365:in `download_file_async'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.11.3/lib/cocoapods-core/cdn_source.rb:338:in `download_file'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.11.3/lib/cocoapods-core/cdn_source.rb:284:in `ensure_versions_file_loaded'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.11.3/lib/cocoapods-core/cdn_source.rb:208:in `search'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.11.3/lib/cocoapods-core/source/aggregate.rb:83:in `block in search'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.11.3/lib/cocoapods-core/source/aggregate.rb:83:in `select'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.11.3/lib/cocoapods-core/source/aggregate.rb:83:in `search'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/resolver.rb:416:in `create_set_from_sources'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/resolver.rb:385:in `find_cached_set'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/resolver.rb:360:in `specifications_for_dependency'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/resolver.rb:165:in `search_for'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/resolver.rb:274:in `block in sort_dependencies'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/resolver.rb:267:in `each'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/resolver.rb:267:in `sort_by'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/resolver.rb:267:in `sort_by!'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/resolver.rb:267:in `sort_dependencies'
/Library/Ruby/Gems/2.6.0/gems/molinillo-0.8.0/lib/molinillo/delegates/specification_provider.rb:60:in `block in sort_dependencies'
/Library/Ruby/Gems/2.6.0/gems/molinillo-0.8.0/lib/molinillo/delegates/specification_provider.rb:77:in `with_no_such_dependency_error_handling'
/Library/Ruby/Gems/2.6.0/gems/molinillo-0.8.0/lib/molinillo/delegates/specification_provider.rb:59:in `sort_dependencies'
/Library/Ruby/Gems/2.6.0/gems/molinillo-0.8.0/lib/molinillo/resolution.rb:754:in `push_state_for_requirements'
/Library/Ruby/Gems/2.6.0/gems/molinillo-0.8.0/lib/molinillo/resolution.rb:744:in `require_nested_dependencies_for'
/Library/Ruby/Gems/2.6.0/gems/molinillo-0.8.0/lib/molinillo/resolution.rb:727:in `activate_new_spec'
/Library/Ruby/Gems/2.6.0/gems/molinillo-0.8.0/lib/molinillo/resolution.rb:684:in `attempt_to_activate'
/Library/Ruby/Gems/2.6.0/gems/molinillo-0.8.0/lib/molinillo/resolution.rb:254:in `process_topmost_state'
/Library/Ruby/Gems/2.6.0/gems/molinillo-0.8.0/lib/molinillo/resolution.rb:182:in `resolve'
/Library/Ruby/Gems/2.6.0/gems/molinillo-0.8.0/lib/molinillo/resolver.rb:43:in `resolve'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/resolver.rb:94:in `resolve'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/installer/analyzer.rb:1078:in `block in resolve_dependencies'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/user_interface.rb:64:in `section'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/installer/analyzer.rb:1076:in `resolve_dependencies'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/installer/analyzer.rb:124:in `analyze'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/installer.rb:416:in `analyze'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/installer.rb:241:in `block in resolve_dependencies'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/user_interface.rb:64:in `section'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/installer.rb:240:in `resolve_dependencies'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/installer.rb:161:in `install!'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/command/install.rb:52:in `run'
/Library/Ruby/Gems/2.6.0/gems/claide-1.1.0/lib/claide/command.rb:334:in `run'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/lib/cocoapods/command.rb:52:in `run'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.11.3/bin/pod:55:in `<top (required)>'
/usr/local/bin/pod:23:in `load'
/usr/local/bin/pod:23:in `<main>'
```

――― TEMPLATE END ――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――

[!] Oh no, an error occurred.

Search for existing GitHub issues similar to yours:
https://github.com/CocoaPods/CocoaPods/search?q=dlopen%28%2FLibrary%2FRuby%2FGems%2F2.6.0%2Fgems%2Fffi-1.15.5%2Flib%2Fffi_c.bundle%2C+0x0009%29%3A+tried%3A+%27%2FLibrary%2FRuby%2FGems%2F2.6.0%2Fgems%2Fffi-1.15.5%2Flib%2Fffi_c.bundle%27+%28mach-o+file%2C+but+is+an+incompatible+architecture+%28have+%27x86_64%27%2C+need+%27arm64e%27%29%29+-+%2FLibrary%2FRuby%2FGems%2F2.6.0%2Fgems%2Fffi-1.15.5%2Flib%2Fffi_c.bundle&type=Issues

If none exists, create a ticket, with the template displayed above, on:
https://github.com/CocoaPods/CocoaPods/issues/new

Be sure to first read the contributing guide for details on how to properly submit a ticket:
https://github.com/CocoaPods/CocoaPods/blob/master/CONTRIBUTING.md

Don't forget to anonymize any private data!

Looking for related issues on cocoapods/cocoapods...

Error output from CocoaPods: ↳ /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/universal-darwin21/rbconfig.rb:230: warning: Insecure world writable dir /opt/homebrew/bin in PATH, mode 040777 Searching for inspections failed: undefined method `map' for nil:NilClass

[!] Automatically assigning platform `iOS` with version `9.0` on target `Runner` because no platform was specified. Please specify a platform for this target in your Podfile. See `https://guides.cocoapods.org/syntax/podfile.html#platform`.

Error running pod install Error launching application on iPhone 13 Pro Max.

frontmesh commented 2 years ago

@threells1939 This solved issue for me https://stackoverflow.com/a/66776160

filip-alexandrov commented 8 months ago

This issue and other similar cocoapods issues can be resolved by setting the same Minimum Deployment version throughout the xcode project.

Find the sqlflite min deployment version here: flutter_project/ios/.symlinks/plugins/sqflite/darwin/sqlflite.podspec under s.ios.deployment_target = '12.0'. For me that is 12.0, but for you it could be different.

If you are using VSCode: Right click on the ios folder -> Open in XCode -> Click on Runner at the top of the file tree -> Click on Runner under Targets -> General -> set to the sqflite deployment target: Minimum Deployments: 12.0.

Then flutter run has to resolve the issue. Hope this helps.

chandMessi10 commented 7 months ago

updated Podfile's platform to 12.

platform :ios, '12.0'

It worked.