Many tools related with binaries, such otools, gcc, don't have manpages on my macOS (10.13.6). Is there a way to install the manpages for them?

  • See this. You can use man clang Dec 31, 2018 at 6:25
  • Note gcc on current macOS is a link to clang i is not gcc If you are asked to use gcc the requester is not teaching you macOS things an so some things will just not work on macOS (There are reasons to use gcc but for advanced use only)
    – mmmmmm
    Dec 31, 2018 at 10:48
  • ALso man otool shows a page
    – mmmmmm
    Dec 31, 2018 at 16:01
  • I don't find the manpage for otool. In which directory is it installed in your Mac OS X? $ man otool No manual entry for otool Dec 31, 2018 at 19:54

2 Answers 2


This answer from stackoverflow says that gcc is not installed by default on mac. Instead it installs clang and calls it gcc.

usxxplayegm1:~ grady$ which gcc

usxxplayegm1:~ grady$ /usr/bin/gcc --version

Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
Apple LLVM version 5.1 (clang-503.0.38) (based on LLVM 3.4svn)
Target: x86_64-apple-darwin13.0.2
Thread model: posix

you need man clang. Alternatively, if you want help regarding gcc, you can use gcc --help

  • I don't find the manpage for clang. In which directory is it installed in your Mac OS X? $ man clang No manual entry for clang Dec 31, 2018 at 19:53
  • @user1424739 - clang is there. I just double checked with the command man clang and it brought up the man page - this is on a clean High Sierra install.
    – Allan
    Dec 31, 2018 at 20:50
  • Could you check your output of man -w clang? Also, my machine was upgraded from a lower version OS. I am wondering that could be the reason. Dec 31, 2018 at 21:25

The manpage search path on macOS can be complicated. You need to set the pathname for all manpages in the MANPATH variable.

One way to find out where a man page is located is to use mdfind(1) to locate the directory that houses the man page. In this case, clang is a command line tool so the associated manpage will have a .1 suffix. Here's how to find it on your system.

mdfind clang.1

On my system this returns


To get these manpages you'll then need to add the directory


to your MANPATH.

Below is my MANPATH (which I set in ~/.bash_profile). Note that the "/usr/local/share/man" is where I store the manpages from my own projects; this is also the default location for homebrew packages.

export MANPATH=/usr/local/share/man:/usr/share/man:/Library/Apple/usr/share/man:/usr/lib/*/man:/usr/share/*/man:/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/share/man/:/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/share/man:/Library/Developer/CommandLineTools/usr/share/man/

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .