gpt4 book ai didi

xcode - 在 OS X mojave 上安装 Haskell 时出现 "macOS_SDK_headers_for_macOS_10.14.pkg is incompatible with this version of macOS"

转载 作者:行者123 更新时间:2023-12-03 15:22:19 25 4
gpt4 key购买 nike

在运行以下代码块时,

$ cd /Library/Developer/CommandLineTools/Packages/
$ open macOS_SDK_headers_for_macOS_10.14.pkg

安装程序警告

This package is incompatible with this version of macOS and may fail to install.



当我选择“无论如何安装”时,它失败了。

我怎么可能让它工作?

一些可能相关的环境版本:
操作系统:macOS 10.14.5
xcodebuild-版本:Xcode 11.2.1
gcc --version: gcc (自制 GCC 9.2.0_1) 9.2.0

更大的背景:
我按照 https://docs.haskellstack.org/en/stable/install_and_upgrade/ 上的说明设置了 haskellstack

运行时 $ stack setup我遇到了

configure: error: in '~/.stack/programs/x86_64-osx/ghc-8.6.5.temp/ghc-8.6.5':
configure: error: C compiler cannot create executables
See 'config.log' for more details
Received ExitFailure 77 when running



根据说明的注释部分,我跑了
$ xcode-select --install

它说

xcode-select: error: command line tools are already installed, use "Software Update" to install updates



然后(按照相同的说明)我跑了
$ cd /Library/Developer/CommandLineTools/Packages/
$ open macOS_SDK_headers_for_macOS_10.14.pkg

最佳答案

我的 MacOS 是 10.14.6

我在 MacrossEO 的另一个网站上找到了解决方案,请参阅 https://donatstudios.com/MojaveMissingHeaderFiles

我不得不使用“sudo rm -rf/Library/Developer/CommandLineTools”删除命令行工具

sudo rm -rf /Library/Developer/CommandLineTools
xcode-select --install
cd /Library/Developer/CommandLineTools/Packages/
open macOS_SDK_headers_for_macOS_10.14.pkg

关于xcode - 在 OS X mojave 上安装 Haskell 时出现 "macOS_SDK_headers_for_macOS_10.14.pkg is incompatible with this version of macOS",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/58897928/

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