No such module 'location' when building on macos
See original GitHub issue`gintas-mac:mapphotos gintas$ flutter doctor Doctor summary (to see all details, run flutter doctor -v): [✓] Flutter (Channel master, v1.18.0-6.0.pre.106, on Mac OS X 10.15.4 19E287, locale en-GB) [✓] Android toolchain - develop for Android devices (Android SDK version 29.0.3) [✓] Xcode - develop for iOS and macOS (Xcode 11.4.1) [✓] Chrome - develop for the web [✓] Android Studio (version 3.6) [!] VS Code (version 1.43.2) ✗ Flutter extension not installed; install from https://marketplace.visualstudio.com/items?itemName=Dart-Code.flutter [✓] Connected device (3 available)
! Doctor found issues in 1 category.`
Trying to build on macos with location: 3.0.2
but I get this error:
` Launching lib/main.dart on macOS in debug mode… Running pod install… 8.1s Building macOS application… ** BUILD FAILED **
The following build commands failed: CompileSwift normal x86_64 /Users/gintas/Documents/AppProjects/mapphotos/macos/Runner/MainFlutterWindow.swift CompileSwift normal x86_64 /Users/gintas/Documents/AppProjects/mapphotos/macos/Runner/AppDelegate.swift CompileSwift normal x86_64 /Users/gintas/Documents/AppProjects/mapphotos/macos/Flutter/GeneratedPluginRegistrant.swift CompileSwiftSources normal x86_64 com.apple.xcode.tools.swift.compiler (4 failures) Exception: Build process failed `
full pubspec.yaml here: https://pastebin.com/RhCtc0LV
Issue Analytics
- State:
- Created 3 years ago
- Reactions:2
- Comments:9
The symlink trick is not working, you have to copy the .m file from ios to macos. Try:
Then run
flutter clean
Still nothing ?