新的flutter项目无法在mac os intel芯片上构建

14ifxucb  于 2023-02-05  发布在  Flutter
关注(0)|答案(1)|浏览(363)

新的Flutter项目无法在Mac mini英特尔芯片中成功构建输出:

Launching lib/main.dart on iPhone 14 Pro Max in debug mode...
lib/main.dart:1
Xcode build done.                                           17.2s
Failed to build iOS app
Error (Xcode): ../../flutter/packages/flutter/lib/src/material/bottom_navigation_bar.dart:9:8: Error: Error when reading '../../.pub-cache/hosted/pub.dev/vector_math-2.1.4/lib/vector_math_64.dart': Permission denied
../…/material/bottom_navigation_bar.dart:9
Could not build the application for the simulator.
Error launching application on iPhone 14 Pro Max.
Exited```

`flutter doctor` seems to be fine

I tried delete SDK and create new one but didnt work, i hope someone can help.
jobtbby3

jobtbby31#

尝试运行flutter clean,然后在根目录下运行flutter create .。这应该会重置插件。另外,检查pubspec.yaml文件中是否有过时的插件。

相关问题