mintware-de / flutter_barcode_reader

A flutter plugin for reading 2D barcodes and QR codes.
MIT License
628 stars 464 forks source link

cannot build on iOS #44

Closed 3ace closed 4 years ago

3ace commented 6 years ago
While building module 'barcode_scan' imported from /Users/ace/dev/flutter/gro/ios/Runner/GeneratedPluginRegistrant.m:6:
In file included from <module-includes>:1:
In file included from /Users/ace/Library/Developer/Xcode/DerivedData/Runner-emrtiqllpcjivvembdtxzijbcdvu/Build/Products/Debug-iphoneos/barcode_scan/barcode_scan.framework/Headers/barcode_scan-umbrella.h:15:
/Users/ace/Library/Developer/Xcode/DerivedData/Runner-emrtiqllpcjivvembdtxzijbcdvu/Build/Products/Debug-iphoneos/barcode_scan/barcode_scan.framework/Headers/BarcodeScanPlugin.h:12:1: error: retain'ed block property does not copy the block - use copy attribute instead [-Werror,-Wobjc-noncopy-retain-block-property]
@property(nonatomic, retain) FlutterResult result;
^
1 error generated.
/Users/ace/dev/project/appios/Runner/GeneratedPluginRegistrant.m:6:9: fatal error: could not build module 'barcode_scan'
#import <barcode_scan/BarcodeScanPlugin.h>
 ~~~~~~~^
2 errors generated.
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel dev, v0.7.5, on Mac OS X 10.13.6 17G65, locale en-ID)
[✓] Android toolchain - develop for Android devices (Android SDK 27.0.3)
[✓] iOS toolchain - develop for iOS devices (Xcode 9.4.1)
[✓] Android Studio (version 3.1)
[✓] VS Code (version 1.26.1)
[✓] Connected devices (1 available)
Pushan-Gupta commented 6 years ago

@3ace Steps to reproduce?

eddywm commented 6 years ago

Got the same issue here BarcodeScanPlugin.h can't be found

tudor07 commented 5 years ago

Same for me

tudor07 commented 5 years ago

If you open the workspace file in Xcode it seems to work.

marplx commented 5 years ago

It sounds silly but I have been opening the app with Xcode wrong all the time.

Open the complete Workspace (not the workspace file) with Xcode like so:

cd ios
open -a Xcode .
gotirahul96 commented 4 years ago

Did anyone found how to solve this ??

tqcenglish commented 4 years ago

on Xcode->Target->Build Setting setting Build Active Architecture Only => YES, Vaild Architecture => [arm64, arm64e]

devtronic commented 4 years ago

Please update to the latest version and try it again. Also try to remove all generated data (Pods, packages, lock files etc.)