简体   繁体   中英

Flutter build ios bitcode problem, how to fix bitcode error

i try to build ios with my phone connected or flutter build ios i got this error

ld: '/Users/Library/Developer/Xcode/DerivedData/Runner-dwvxvkkosgpgqncynmszqlholtde/Build/Products/Debug-iphoneos/BoringSSL-GRPC/libBoringSSL-GRPC.a(BoringSSL-GRPC-dummy.o)' does not contain bitcode. You must rebuild it with bitcode enabled (Xcode setting ENABLE_BITCODE), obtain an updated library from the vendor, or disable bitcode for this target. file '/Users/Library/Developer/Xcode/DerivedData/Runner-dwvxvkkosgpgqncynmszqlholtde/Build/Products/Debug-iphoneos/BoringSSL-GRPC/libBoringSSL-GRPC.a' for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

if i run with simulator its work, the problem occure when build whit pshyscal device connected or flutter build how to fix this ?

doctor -v

[✓] Flutter (Channel stable, v1.12.13+hotfix.5, on Mac OS X 10.15.2 19C57, locale en)
    • Flutter version 1.12.13+hotfix.5 at /Users/user/Development/flutter
    • Framework revision 27321ebbad (4 weeks ago), 2019-12-10 18:15:01 -0800
    • Engine revision 2994f7e1e6
    • Dart version 2.7.0


[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
    • Android SDK at /Users/User/Library/Android/sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-29, build-tools 29.0.2
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
    • All Android licenses accepted.

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

[✓] Android Studio (version 3.5)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 42.1.1
    • Dart plugin version 191.8593
    • Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)

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

[✓] Connected device (1 available)
    • RIFAL’s iPhone • 8c498b6246bf8191b049a9253b87ff2604b85671 • ios • iOS 13.3

• No issues found!

I had a similar problem after installing one library which was dependent on the bitcode. Please change Enable Bitcode to all of the targets on the project Pods like in the image,

在此处输入图片说明

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM