web-dev-qa-db-ja.com

Flutter 'Pod Installの実行中のエラー' 'Pods-Runner'ターゲットには推移的な依存関係があります。

私のFlutterプロジェクトを実行しようとしているとき、私は得る:

PODインストールの実行中にエラーが発生しました

(私は別の非常によく似た 投稿 が同じ問題を抱えているかどうかわからない。)

私はMacOS Mojaveバージョン10.14.6のフラッタでダーツコードを書いています。

私はもう試した:

  • flutter clean _
  • flutter doctor _
  • flutter upgrade _
  • `flutter Pastache
  • flutter run _

私はすべての可能なすべての組み合わせですべてのFlutterコマンドを試しましたが、それでも同じエラーを得ました。

フラッタドクター

Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel beta, v1.9.1+hotfix.4, on Mac OS X 10.14.6 18G103, locale en-US)

[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[✓] Xcode - develop for iOS and macOS (Xcode 11.0)
[✓] Android Studio (version 3.5)
[✓] IntelliJ IDEA Ultimate Edition (version 2019.1.2)
[✓] Connected device (1 available)

• No issues found!
 _

Flutter Run

Launching lib/main.Dart on iPhone 11 Pro Max in debug mode...
Running pod install...                                              1.3s
CocoaPods' output:
↳
      Preparing

    Analyzing dependencies

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

    Finding Podfile changes
      M Flutter
      - barcode_scan
      - flutter_webview_plugin
      - google_sign_in
      - path_provider
      - shared_preferences
      - sqflite
      - url_launcher

    Fetching external sources
    -> Fetching podspec for `Flutter` from `.symlinks/flutter/ios`
    -> Fetching podspec for `barcode_scan` from
    `.symlinks/plugins/barcode_scan/ios`
    -> Fetching podspec for `flutter_webview_plugin` from
    `.symlinks/plugins/flutter_webview_plugin/ios`
    -> Fetching podspec for `google_sign_in` from
    `.symlinks/plugins/google_sign_in/ios`
    -> Fetching podspec for `path_provider` from
    `.symlinks/plugins/path_provider/ios`
    -> Fetching podspec for `shared_preferences` from
    `.symlinks/plugins/shared_preferences/ios`
    -> Fetching podspec for `sqflite` from `.symlinks/plugins/sqflite/ios`
    -> Fetching podspec for `url_launcher` from
    `.symlinks/plugins/url_launcher/ios`

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

    Comparing resolved specification to the sandbox manifest
      A FMDB
      A Flutter
      A GTMSessionFetcher
      A GoogleSignIn
      A GoogleToolboxForMac
      A MTBBarcodeScanner
      A barcode_scan
      A flutter_webview_plugin
      A google_sign_in
      A path_provider
      A shared_preferences
      A sqflite
      A url_launcher




Downloading dependencies

    -> Installing FMDB (2.7.5)
      > Copying FMDB from
      `~/Library/Caches/CocoaPods/Pods/Release/FMDB/2.7.5-2ce
      00` to `Pods/FMDB`

    -> Installing Flutter (1.0.0)

    -> Installing GTMSessionFetcher (1.2.2)
      > Copying GTMSessionFetcher from
      `~/Caches/CocoaPods/Pods/Release/GTMSessionFetc
      her/1.2.2-61bb0` to `Pods/GTMSessionFetcher`

    -> Installing GoogleSignIn (4.4.0)
      > Copying GoogleSignIn from
      `~/Library/Caches/CocoaPods/Pods/Release/GoogleSignIn/4
      .4.0-7ff24` to `Pods/GoogleSignIn`

    -> Installing GoogleToolboxForMac (2.2.1)
      > Copying GoogleToolboxForMac from
      `~/Library/Caches/CocoaPods/Pods/Release/GoogleToolboxF
      orMac/2.2.1-b3553` to `Pods/GoogleToolboxForMac`

    -> Installing MTBBarcodeScanner (5.0.11)
      > Copying MTBBarcodeScanner from
      `~/Library/Caches/CocoaPods/Pods/Release/MTBBarcodeScan
      ner/5.0.11-f453b` to `Pods/MTBBarcodeScanner`

    -> Installing barcode_scan (0.0.1)

    -> Installing flutter_webview_plugin (0.0.1)

    -> Installing google_sign_in (0.0.1)

    -> Installing path_provider (0.0.1)

    -> Installing shared_preferences (0.0.1)

    -> Installing sqflite (0.0.1)

    -> Installing url_launcher (0.0.1)
      - Running pre install hooks
    [!] The 'Pods-Runner' target has transitive dependencies that include
    statically linked binaries:
    (<flutter_project_repo>/ios/.symlinks/flutter/ios/Flutte
    r.framework)

    /Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.1/lib/cocoapods/installer/xcode/
    target_validator.rb:84:in `block (2 levels) in
    verify_no_static_framework_transitive_dependencies'
    /Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.1/lib/cocoapods/installer/xcode/
    target_validator.rb:74:in `each_key'
    /Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.1/lib/cocoapods/installer/xcode/
    target_validator.rb:74:in `block in
    verify_no_static_framework_transitive_dependencies'
    /Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.1/lib/cocoapods/installer/xcode/
    target_validator.rb:73:in `each'
    /Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.1/lib/cocoapods/installer/xcode/
    target_validator.rb:73:in
    `verify_no_static_framework_transitive_dependencies'
    /Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.1/lib/cocoapods/installer/xcode/
    target_validator.rb:38:in `validate!'
    /Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.1/lib/cocoapods/installer.rb:590
    :in `validate_targets'
    /Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.1/lib/cocoapods/installer.rb:158
    :in `install!'
    /Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.1/lib/cocoapods/command/install.
    rb:52:in `run'
    /Library/Ruby/Gems/2.3.0/gems/claide-1.0.3/lib/claide/command.rb:334:in
    `run'
    /Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.1/lib/cocoapods/command.rb:52:in
    `run'
    /Library/Ruby/Gems/2.3.0/gems/cocoapods-1.8.1/bin/pod:55:in `<top
    (required)>'
    /usr/local/bin/pod:23:in `load'
    /usr/local/bin/pod:23: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 11 Pro Max.

 _

CocoApodsやRubyGemsのような異なるプログラムの束を更新しました。

私はそれがこれらのインストールのいずれかと関係があると思います:

-> Installing MTBBarcodeScanner (5.0.11)
      > Copying MTBBarcodeScanner from
      `~/Library/Caches/CocoaPods/Pods/Release/MTBBarcodeScan
      ner/5.0.11-f453b` to `Pods/MTBBarcodeScanner`

    -> Installing barcode_scan (0.0.1)
 _

Pubspec.yamlのバージョンを使用してから、何らかの理由で0.0.1を使用し始めます。

pubspec.yaml

...
version: 1.0.0+1

environment:
  sdk: ">=2.2.0 <3.0.0"

dependencies:
  flutter:
    sdk: flutter
  easy_localization: ^1.3.1
...
 _

flutter runError running pod install _

より良いエラーメッセージを受けるために私ができることがわからない...

10
William Nesham

CocoApodsからのエラーがあなたが言語を追加することを提案しているように見えます。

  1. Flutter Appディレクトリでios/Podfileの先頭に追加

    platform :ios, '9.0'
    
  2. IOSフォルダからpodfile.lockファイルを削除します。

  3. pod installを実行する

    pod installがエラーを与える場合は、これを試してください

    pod install --repo-update 
    
  4. flutter run

1
  1. cD iOS /
  2. rM Podfile.lock.
  3. ポッドインストール
  4. pod Repo Update.
0
Lucas Santos