I am trying to use address sanitization when calling my program with clang, however it doesn't seem to be installed. If I type which llvm-symbolizer I get llvm-symbolizer not found. I also checked under /usr/bin and /usr/local/bin and under the location where clang is installed /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin but still I can't find llvm-symbolizer (though there are other llvm-* executables in the last path).
which llvm-symbolizer
llvm-symbolizer not found
/usr/bin
/usr/local/bin
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
Is there a way I can install this on macos? Also, I couldn't find it in brew. I am using clang built in macos: Apple clang version 12.0.0 (clang-1200.0.32.21).
Apple clang version 12.0.0 (clang-1200.0.32.21)
My version of llvm-symbolizer was installed with Homebrew. You have to install llvm with brew install llvm to get it. It then shows up as:
% which llvm-symbolizer /usr/local/Cellar/llvm/11.0.0/bin/llvm-symbolizer
1.4m articles
1.4m replys
5 comments
57.0k users