gpt4 book ai didi

ios - libcurl 不支持或禁用协议(protocol) "https"

转载 作者:技术小花猫 更新时间:2023-10-29 10:10:14 26 4
gpt4 key购买 nike

这是我的 Podfile 内容:

platform :ios, ‘8.0’
use_frameworks!

target 'Project-Name' do

pod 'Firebase/Core'
pod 'Firebase/Messaging'

end

pod 'GoogleMaps' 添加到 Podfile 时发生同样的错误。

在终端上运行 pod install --verbose 命令 时出错:

[!] Error installing Firebase
[!] /usr/local/bin/curl -f -L -o /var/folders/1t/102_4r0x1_3_5dlq8zdbm27r0000gn/T/d20160902-4388-1omozrn/file.tgz https://www.gstatic.com/cpdc/cc5f7aac07ccdd0a/Firebase-3.5.0.tar.gz --create-dirs --netrc-optional

curl: (1) Protocol "https" not supported or disabled in libcurl

编辑 1: How do I enable curl SSL on Mac OS X?

./configure --with-darwinssl 不工作。

-bash: ./configure: No such file or directory


编辑 2: How do I enable https support in libcurl?

此命令 brew install curl --with-libssh2 在终端上执行,但不知道下一步要做什么:

UB:lib aspl$ brew install curl --with-libssh2 --verbose
==> Auto-updated Homebrew!
Updated 1 tap (homebrew/core).
No changes to formulae.

Warning: curl-7.50.1 already installed
UB:lib aspl$ curl --version
curl 7.48.0 (x86_64-apple-darwin14.5.0) libcurl/7.48.0 zlib/1.2.5
Protocols: dict file ftp gopher http imap ldap ldaps pop3 rtsp smtp telnet tftp
Features: IPv6 Largefile libz UnixSockets

此命令无效:

$ otool -L /usr/local/git/libexec/git-core/git-http-push | grep curl
/usr/lib/libcurl.4.dylib

/Applications/Xcode-beta.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/objdump: '/usr/local/bin/git/libexec/git-core/git-http-push': Not a directory. fatal error: /Applications/Xcode-beta.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/otool: internal objdump command failed Binary file /usr/lib/libcurl.4.dylib matches


Edit:3 终端命令 which git 显示 /usr/local/bin/git


编辑:4 Enabling HTTPS Support in Curl Installed Through MacPorts on OSX

运行 sudo port install curl +sslsudo port uninstall curl 说:

sudo: port: command not found

并使用以下链接安装端口 (MacPorts),这也是一个 HTTPS 链接:

$ curl -O https://distfiles.macports.org/MacPorts/MacPorts-2.3.4.tar.bz2

还有MacPort文件夹的下载选项?

但是如何处理下载的 MacPorts-2.3.4 文件夹?

编辑 5: 强制卸载 curl 并再次安装无效 :(

$ brew uninstall curl
Uninstalling /usr/local/Cellar/curl/7.50.1... (366 files, 2.6M)
curl 7.46.0 is still installed.
Remove them all with `brew uninstall --force curl`.
$ brew uninstall --force curl
Uninstalling curl... (360 files, 2.6M)
$ brew install curl --with-libssh2 --verbose
Error: curl 7.50.2 did not build
Logs:
/Users/aspl/Library/Logs/Homebrew/curl/01.configure
/Users/aspl/Library/Logs/Homebrew/curl/01.configure.cc
/Users/aspl/Library/Logs/Homebrew/curl/02.make
/Users/aspl/Library/Logs/Homebrew/curl/config.log

These open issues may also help:
curl: migrate to openssl@1.1 https://github.com/Homebrew/homebrew-core/pull/4591

最佳答案

在我安装 macOS High Sierra 之后,我在通过 pod 安装 firebase 时遇到了同样的问题。

诀窍是删除 curl 并重新安装:

curl --version // you will see the https protocol is missing, and the version would be 7.56.1 if you did try to update it before  
brew remove curl
brew install curl --with-darwinssl // install with darwin instead of openssl
echo 'export PATH="/usr/local/opt/curl/bin:$PATH"' >> ~/.zshrc // run this

在你应该关闭并退出所有终端或 iTerm 之后,然后再次打开它运行 brew doctor 然后运行 ​​curl --version 你应该看到 https

那你就可以开始了:)

关于ios - libcurl 不支持或禁用协议(protocol) "https",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39287906/

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