ios打包报错 cannot load such file — sqlite3 (LoadError)

ios打包报错 cannot load such file — sqlite3 (LoadError),第1张

错误信息

cannot load such file — sqlite3 (LoadError)
xcode kernel_require rb require usr/bin/ipatool:24
The data couldn’t be read because it isn’t in the correct format

[+14639 ms] 2021-12-27 17:25:00.807 xcodebuild[13713:54898] [MT] IDEDistribution: -[IDEDistributionLogging _createLoggingBundleAtPath:]: Created bundle at path
“/var/folders/_1/qbgn6bsx0952vtr7s1mhn57c0000gn/T/Runner_2021-12-27_17-25-00.806.xcdistributionlogs”.
2021-12-27 17:25:01.163 xcodebuild[13713:54975] CFURLRequestSetHTTPCookieStorageAcceptPolicy_block_invoke: no longer implemented and should not be called
2021-12-27 17:25:11.099 xcodebuild[13713:54898] -[NSNull path]: unrecognized selector sent to instance 0x7fff80768eb0
** INTERNAL ERROR: Uncaught exception **
Uncaught Exception: -[NSNull path]: unrecognized selector sent to instance 0x7fff80768eb0
Stack:
0 __exceptionPreprocess (in CoreFoundation)
1 objc_exception_throw (in libobjc.A.dylib)
2 -[NSObject(NSObject) __retain_OA] (in CoreFoundation)
3 forwarding (in CoreFoundation)
4 _CF_forwarding_prep_0 (in CoreFoundation)
5 -[IDEDistributionProcessingPipeline process:] (in IDEFoundation)
6 -[IDEDistributionPackagingStep loadFromExportOptions:error:] (in IDEFoundation)
7 -[IDEDistributionDriver runWithDestinationPath:error:] (in IDEFoundation)
8 -[Xcode3CommandLineBuildTool _distributeArchiveAndExit] (in Xcode3Core)
9 -[Xcode3CommandLineBuildTool run] (in Xcode3Core)
10 main (in xcodebuild)
11 start (in libdyld.dylib)
[ +1 ms] Building IPA… (completed in 14.6s)
[ +7 ms] “flutter ipa” took 251,318ms.
[ +9 ms] Encountered error while building IPA:
[ ]
#0 throwToolExit (package:flutter_tools/src/base/common.dart:10:3)
#1 BuildIOSArchiveCommand.runCommand (package:flutter_tools/src/commands/build_ios.dart:176:7)

#2 FlutterCommand.run. (package:flutter_tools/src/runner/flutter_command.dart:1140:27)

#3 AppContext.run. (package:flutter_tools/src/base/context.dart:150:19)

#4 CommandRunner.runCommand (package:args/command_runner.dart:209:13)

#5 FlutterCommandRunner.runCommand. (package:flutter_tools/src/runner/flutter_command_runner.dart:288:9)

#6 AppContext.run. (package:flutter_tools/src/base/context.dart:150:19)

#7 FlutterCommandRunner.runCommand (package:flutter_tools/src/runner/flutter_command_runner.dart:236:5)

#8 run.. (package:flutter_tools/runner.dart:62:9)

#9 AppContext.run. (package:flutter_tools/src/base/context.dart:150:19)

#10 main (package:flutter_tools/executable.dart:94:3)

[ +254 ms] ensureAnalyticsSent: 253ms
[ +134 ms] Running shutdown hooks
[ ] Shutdown hooks complete

在 Flutter 打 ipa 包的时候出现了问题
如果用 Xcode 会出现 The data couldn’t be read because it isn’t in the correct format ,
跟踪错误日志,会提示找不到 sqlite3,虽然查询本地已经安装了,但还是找不到。

解决办法 安装 CFPropertyList
sudo gem install CFPropertyList
安装 sqlite3
sudo gem install sqlite3
更新环境
rvm use system --defaul
重启电脑

如果不确定有没有安装 ,可以通过下面命令检查。

sudo gem list | grep sqlite3

欢迎分享,转载请注明来源:内存溢出

原文地址: http://www.outofmemory.cn/web/993916.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2022-05-21
下一篇 2022-05-21

发表评论

登录后才能评论

评论列表(0条)

保存