tanersener / flutter-ffmpeg

FFmpeg plugin for Flutter. Not maintained anymore. Superseded by FFmpegKit.
GNU Lesser General Public License v3.0
643 stars 132 forks source link

[Build on iOS fails] CocoaPods could not find compatible versions for pod "flutter_ffmpeg" #151

Closed JRamos29 closed 4 years ago

JRamos29 commented 4 years ago

Hi, i'm trying to use the video_trimmer package, and getting an error during the build due the flutter_ffmpeg dependency. Removing the video_trimmer package from the app and testing with only the flutter_ffmpeg: ^0.2.10 the app build fails at the same way and i get the same error.

I saw some similar issues at #8 and #103 that was solved with pod update (and the difference that the name of the package has a suffix). And possibly the same for #145 and #30 .

But regards the #103, it needs to specify the package when install via pub?

I already tried the solutions proposed here, but the problem persists.

Expected behavior The build should complete without errors.

Current behavior

Launching lib/main.dart on iPhone 8 in debug mode...
Running pod install...                                              1.2s
CocoaPods' output:
↳
      Preparing

    Analyzing dependencies

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

    Finding Podfile changes
      A flutter_ffmpeg
      - Flutter
      - bitmap
      - flutter_absolute_path
      - flutter_plugin_android_lifecycle
      - image_picker
      - media_gallery
      - path_provider
      - path_provider_macos
      - sqflite

    Fetching external sources
    -> Fetching podspec for `Flutter` from `Flutter`
    -> Fetching podspec for `bitmap` from `.symlinks/plugins/bitmap/ios`
    -> Fetching podspec for `flutter_absolute_path` from `.symlinks/plugins/flutter_absolute_path/ios`
    -> Fetching podspec for `flutter_ffmpeg` from `.symlinks/plugins/flutter_ffmpeg/ios`
    -> Fetching podspec for `flutter_plugin_android_lifecycle` from `.symlinks/plugins/flutter_plugin_android_lifecycle/ios`
    -> Fetching podspec for `image_picker` from `.symlinks/plugins/image_picker/ios`
    -> Fetching podspec for `media_gallery` from `.symlinks/plugins/media_gallery/ios`
    -> Fetching podspec for `path_provider` from `.symlinks/plugins/path_provider/ios`
    -> Fetching podspec for `path_provider_macos` from `.symlinks/plugins/path_provider_macos/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
    [!] CocoaPods could not find compatible versions for pod "flutter_ffmpeg":
      In Podfile:
        flutter_ffmpeg (from `.symlinks/plugins/flutter_ffmpeg/ios`)

    Specs satisfying the `flutter_ffmpeg (from `.symlinks/plugins/flutter_ffmpeg/ios`)` dependency were found, but they required a higher minimum deployment target.

    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolution.rb:328:in `raise_error_unless_state'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolution.rb:310:in `block in unwind_for_conflict'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolution.rb:308:in `tap'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolution.rb:308:in `unwind_for_conflict'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolution.rb:684:in `attempt_to_activate'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolution.rb:254:in `process_topmost_state'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolution.rb:182:in `resolve'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolver.rb:43:in `resolve'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/cocoapods-1.9.3/lib/cocoapods/resolver.rb:94:in `resolve'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/cocoapods-1.9.3/lib/cocoapods/installer/analyzer.rb:1065:in `block in resolve_dependencies'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/cocoapods-1.9.3/lib/cocoapods/user_interface.rb:64:in `section'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/cocoapods-1.9.3/lib/cocoapods/installer/analyzer.rb:1063:in `resolve_dependencies'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/cocoapods-1.9.3/lib/cocoapods/installer/analyzer.rb:124:in `analyze'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/cocoapods-1.9.3/lib/cocoapods/installer.rb:410:in `analyze'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/cocoapods-1.9.3/lib/cocoapods/installer.rb:235:in `block in resolve_dependencies'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/cocoapods-1.9.3/lib/cocoapods/user_interface.rb:64:in `section'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/cocoapods-1.9.3/lib/cocoapods/installer.rb:234:in `resolve_dependencies'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/cocoapods-1.9.3/lib/cocoapods/installer.rb:156:in `install!'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/cocoapods-1.9.3/lib/cocoapods/command/install.rb:52:in `run'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/claide-1.0.2/lib/claide/command.rb:334:in `run'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/cocoapods-1.9.3/lib/cocoapods/command.rb:52:in `run'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/lib/ruby/gems/2.6.0/gems/cocoapods-1.9.3/bin/pod:55:in `<top (required)>'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/bin/pod:23:in `load'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/bin/pod:23:in `<main>'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/bin/ruby_executable_hooks:24:in `eval'
    /Users/junioramos/.rvm/rubies/ruby-2.6.3/bin/ruby_executable_hooks:24:in `<main>'

Error output from CocoaPods:
↳

    [!] 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`.

Error running pod install
Error launching application on iPhone 8.

Other - pod update output

$ pod update
Update all pods
Updating local specs repositories
Analyzing dependencies
[!] CocoaPods could not find compatible versions for pod "flutter_ffmpeg":
  In Podfile:
    flutter_ffmpeg (from `.symlinks/plugins/flutter_ffmpeg/ios`)

Specs satisfying the `flutter_ffmpeg (from `.symlinks/plugins/flutter_ffmpeg/ios`)` dependency were found, but they required a higher minimum deployment target.

Screenshots No screenshots

Logs No logs.

Environment

$ flutter doctor -v
[✓] Flutter (Channel stable, v1.17.3, on Mac OS X 10.15.5 19F96, locale en-BR)
    • Flutter version 1.17.3 at /Users/junioramos/Development/MobileDev/FlutterDev/flutter
    • Framework revision b041144f83 (5 days ago), 2020-06-04 09:26:11 -0700
    • Engine revision ee76268252
    • Dart version 2.8.4

[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.0-rc2)
    • Android SDK at /Users/junioramos/Library/Android/sdk
    • Platform android-29, build-tools 29.0.0-rc2
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b4-5784211)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 11.5)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 11.5, Build version 11E608c
    • CocoaPods version 1.9.3

[✓] Android Studio (version 3.6)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 45.1.1
    • Dart plugin version 192.7761
    • Java version OpenJDK Runtime Environment (build 1.8.0_212-release-1586-b4-5784211)

[✓] VS Code (version 1.45.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.11.0

[✓] Connected device (1 available)
    • iPhone 8 • D77D8DB6-83F9-4A00-817F-5619D834E242 • ios • com.apple.CoreSimulator.SimRuntime.iOS-13-5 (simulator)

• No issues found!
JRamos29 commented 4 years ago

Well, it works installing using the Podfile install. But can't figure it out why doesn't work installing via pubspec.yaml.

  # 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)
    if name == 'flutter_ffmpeg'
        pod name+'/full', :path => File.join(symlink, 'ios')
    else
        pod name, :path => File.join(symlink, 'ios')
    end
  end
end
JRamos29 commented 4 years ago

Correction: Actually it doesn't work. The comment above it was because i went "too smart" to configure the Podfile but don't import the package. If i import the video_trimmer or the flutter_ffmpeg itself, the error continues.

JRamos29 commented 4 years ago

From the error message from my first post. I just changed the iOS version according to this table and it works. Sorry for the inconvenience.

Specs satisfying the flutter_ffmpeg (from.symlinks/plugins/flutter_ffmpeg/ios) dependency were found, but they required a higher minimum deployment target. ... 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.