gpt4 book ai didi

ios - 找不到 Plugin.h 文件 : flutter and xcode

转载 作者:行者123 更新时间:2023-12-01 17:03:26 24 4
gpt4 key购买 nike

当我尝试在 xcode 中运行我的项目时,出现以下错误:

'auto_orientation/AutoOrientationPlugin.h' file not found.

如果我删除这个插件,它将转到下一个插件并在该插件的 .h 文件上失败,依此类推每个插件。

以前,这个问题只在我尝试制作存档时发生,但它始终可以正常运行。现在它甚至不会运行。

有很多关于此的话题,我已经遍历了这些话题,但到目前为止还找不到任何有效的建议。

Pubspec.yaml 文件,根据要求:

name: app_name
description: My application.

# The following defines the version and build number for your application.
# A version number is three numbers separated by dots, like 1.2.43
# followed by an optional build number separated by a +.
# Both the version and the builder number may be overridden in flutter
# build by specifying --build-name and --build-number, respectively.
# Read more about versioning at semver.org.
version: 6.0.0

environment:
sdk: ">=2.3.0-dev.0.5 <3.0.0"


dependencies:
flutter:
sdk: flutter

# The following adds the Cupertino Icons font to your application.
# Use with the CupertinoIcons class for iOS style icons.
cupertino_icons: 0.1.2
firebase_admob: 0.5.5
screen: 0.0.5
image_picker: 0.6.1
firebase_auth: 0.11.1+7
shared_preferences: 0.4.3
rflutter_alert: 1.0.2
url_launcher: 5.0.3
in_app_purchase: 0.2.0
firebase_dynamic_links: 0.4.0+4
app_review: 1.1.0+1
auto_orientation: 1.0.4
vibration: 1.2.1

dev_dependencies:
flutter_test:
sdk: flutter



# For information on the generic Dart part of this file, see the
# following page: https://www.dartlang.org/tools/pub/pubspec

# The following section is specific to Flutter.

flutter:
assets:
- lib/images/
- lib/images/example1.png
- lib/images/example2.png
- lib/images/example3.png

uses-material-design: true

Cenk 的屏幕截图:

enter image description here

最佳答案

您绝对不需要清除整个 ios/文件夹。

1) flutter clean原因不对

2) rm ios/Podfile.lock

3) rm -rf ios/Pods

4) rm -rf ~/.pub-cache/hosted/pub.dartlang.org/(或者你设置它的任何地方)

5) flutter packages get

然后按照您通常的方式运行/构建您的应用程序。

关于ios - 找不到 Plugin.h 文件 : flutter and xcode,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/60816511/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com