2

I've installed mac-ports which puts everything under /opt/local. The corresponding man pages are in /opt/local/man. I added the following line to /private/etc/man.conf representing the man search path for port:

MANPATH /opt/local/man/man1

However, when I invoke man on its own:

> man port

I get the following error:

No manual entry for port

Is this the correct way to add a new search path for man?

Chealion
  • 5,753
Ben Lever
  • 145

2 Answers2

2

You have to point to the root, so:

MANPATH=/opt/local/man man port

should work.

You should add any additional paths you have to /etc/manpath.config so that they'll work for everyone.

brian-brazil
  • 3,992
1

You're very close. You should have added this:

MANPATH /opt/local/man/

Not with /man1 appended to it. In /private/etc/man.conf, there's a line commented that you simply have to uncomment:

# Uncomment if you want to include one of these by default
#
# MANPATH       /opt/*/man
# MANPATH       /usr/lib/*/man

The /opt/*/man is your...man.

jth
  • 126