gpt4 book ai didi

macos - 如何使用 Homebrew 在 macOS Catalina (10.15) 上安装 Valgrind?

转载 作者:行者123 更新时间:2023-12-01 17:53:30 28 4
gpt4 key购买 nike

我尝试使用命令“brew install valgrind”安装 Valgrind,并收到一条消息:

"valgrind: This formula either does not compile or function as expected on macOS versions newer than Sierra due to an upstream incompatibility. Error: An unsatisfied requirement failed this build."

我还尝试“brew edit valgrind”并在代码的头部部分将“sourceware.org/git/valgrind.git”替换为“git://sourceware.org/git/valgrind.git”,然后编写在 Iterm“brew install --HEAD valgrind”上,但它给了我:

Last 15 lines from /Users/m/Library/Logs/Homebrew/valgrind/02.configure:
checking for gcc-ar... no
checking for perl... /usr/bin/perl
checking for gdb... /no/gdb/was/found/at/configure/time
checking dependency style of clang... none
checking for diff -u... yes
checking for clang option to accept ISO C99... none needed
checking for a supported version of gcc... ok (clang-11.0.0)
checking build system type... x86_64-pc-darwin
checking host system type... x86_64-pc-darwin
checking for a supported CPU... ok (x86_64)
checking for a 64-bit only build... yes
checking for a 32-bit only build... no
checking for a supported OS... ok (darwin)
checking for the kernel version... unsupported (19.0.0)
configure: error: Valgrind works on Darwin 10.x, 11.x, 12.x, 13.x, 14.x, 15.x, 16.x and 17.x (Mac OS X 10.6/7/8/9/10/11 and macOS 10.12/13)

READ THIS: https://docs.brew.sh/Troubleshooting

最佳答案

参见https://github.com/LouisBrunner/valgrind-macos/ .

要么尝试

brew tap LouisBrunner/valgrind
brew install --HEAD LouisBrunner/valgrind/valgrind

如果上述方法不起作用,或者从源代码编译它。 (但是他们最近应该有 fixed 上述方法。)

git clone https://github.com/LouisBrunner/valgrind-macos.git
cd valgrind-macos
./autogen.sh
./configure --prefix=/where/you/want/it/installed --enable-only64bit
make
sudo make install

享受吧!

关于macos - 如何使用 Homebrew 在 macOS Catalina (10.15) 上安装 Valgrind?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/58360093/

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