Typical MANPATH

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read how to get help
Jeff23
Level 1
Level 1
Posts: 5
Joined: Sat Aug 16, 2008 8:25 pm

Typical MANPATH

Postby Jeff23 » Thu Sep 04, 2008 10:01 pm

I'm sorry, but there doesn't seem to be a $MANPATH variable set by default. What directories should I include to hit all the possible man paths (including system calls and library stuff)?

Husse
Level 23
Level 23
Posts: 19593
Joined: Sun Feb 11, 2007 7:22 am
Location: Near Borås Sweden

Re: Typical MANPATH

Postby Husse » Fri Sep 05, 2008 8:20 am

I don't think you need it - the man command works well
Image
Don't fix it if it ain't broken, don't break it if you can't fix it

Jeff23
Level 1
Level 1
Posts: 5
Joined: Sat Aug 16, 2008 8:25 pm

Re: Typical MANPATH

Postby Jeff23 » Fri Sep 05, 2008 8:21 pm

I agree that it works fine for shell or executable programs. Example: man man. Unfortunately, we don't appear to get anything else:

Code: Select all

jeff@jeff-desktop:~$ man malloc
No manual entry for malloc
jeff@jeff-desktop:~$ man 2 malloc
No manual entry for malloc in section 2
jeff@jeff-desktop:~$ man 3 malloc
No manual entry for malloc in section 3

where is it then?
Thank you in advance for any help.

Husse
Level 23
Level 23
Posts: 19593
Joined: Sun Feb 11, 2007 7:22 am
Location: Near Borås Sweden

Re: Typical MANPATH

Postby Husse » Sat Sep 06, 2008 10:20 am

Are you sure there is a man page for malloc?
Image
Don't fix it if it ain't broken, don't break it if you can't fix it

Jeff23
Level 1
Level 1
Posts: 5
Joined: Sat Aug 16, 2008 8:25 pm

Re: Typical MANPATH

Postby Jeff23 » Sat Sep 06, 2008 1:08 pm

Yes, there are 9 standard sections to the man pages. The third section contains every single C function in any C library. It's usually a lot faster to check an obscure function by typing man obscure_function, than scouring the internet for it. To see everything you can go here: http://linux.die.net/man/ . Here is the specific page for malloc: http://linux.die.net/man/3/malloc . I was just using it as an example that should obviously be there. Maybe some less common things might not be.

Husse
Level 23
Level 23
Posts: 19593
Joined: Sun Feb 11, 2007 7:22 am
Location: Near Borås Sweden

Re: Typical MANPATH

Postby Husse » Sat Sep 06, 2008 4:29 pm

I am not sure, but I think man pages may differ between distros there simply might not be a man page in the Ubuntu package while you may have used some other package - just guessing...
Manuals are in /usr/share/man which is in the path
I used locate to search for malloc in my machine and got a bunch of hits - no manual though, but I have a standard install (in this respect)
Image
Don't fix it if it ain't broken, don't break it if you can't fix it


Return to “Newbie Questions”

Who is online

Users browsing this forum: leoandvicky, Oscar799 and 11 guests