|
|
|
|
#1 |
|
Triple-A Player
Join Date: Jun 2006
Posts: 51
|
Terminal App
Okay I'm trying to look up a man page on a mac pro running 10.7.4.
man 3 time and get... no entry for time in section 3 of the manual I tried this on another mac running 10.6.8 and it works fine. Do I need to do something to get this working on 10.7??? Don't understand why it is not available on my new system. |
|
|
|
|
|
#2 |
|
League Commissioner
Join Date: Aug 2006
Posts: 5,040
|
It works for me. What do you get as the results of "echo $MANPATH"
|
|
|
|
|
|
#3 | |||||||||||||||||||||||
|
League Commissioner
Join Date: Jan 2002
Posts: 7,958
|
I get no results, just a prompt. What should be the result? |
|||||||||||||||||||||||
|
|
|
|
|
#4 | |||||||||||||||||||||||
|
Moderator
Join Date: Jun 2003
Location: Boulder, CO USA
Posts: 19,550
|
Really, it depends on how you set your MANPATH, but my computer running 10.6.8 shows: Code:
% echo $MANPATH /sw/share/man:/usr/share/man:/usr/bin/man:/usr/local/man:/usr/local/share/man:/usr/X11/man:/usr/man
__________________
How to ask questions the smart way |
|||||||||||||||||||||||
|
|
|
|
|
#5 |
|
League Commissioner
Join Date: Jan 2002
Posts: 7,958
|
Looks like there's no section 3 in the man for the time command in Lion.
Has it been replaced by the date command in Lion? Looks like many manuals have been changed in Lion, eh? |
|
|
|
|
|
#6 |
|
Triple-A Player
Join Date: May 2008
Location: Down by the river
Posts: 190
|
It works for me as well on 10.7.4.
|
|
|
|
|
|
#7 |
|
MVP
Join Date: Aug 2009
Posts: 1,119
|
Keep in mind section 3 of time talks about the libc function time(), not about the command time. The latter is in section 1.
Also keep in mind time is also a shell build-in. |
|
|
|
|
|
#8 |
|
League Commissioner
Join Date: Aug 2006
Posts: 5,040
|
Now I think on it a bit, I seem to remember that MANPATH may be deprecated in OS X. Ah yes, here it:
http://hints.macworld.com/article.ph...31014053111192 It's dynamically constructed from PATH. From days of yore, I still have it set it in my .profile. I might comment it out. So, what do you get as the results of "echo $PATH"? I also seem to remember that there was an issue with Leopard upgrades from Tiger, where a lot of old Tiger man files were not deleted, leading to old man pages being used. But I digress. Last edited by benwiggy; 07-10-2012 at 04:26 AM. |
|
|
|
|
|
#9 |
|
Triple-A Player
Join Date: Jun 2006
Posts: 51
|
When I run this code I get...
Steven001737:~ svalenti$ echo $PATH /usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin running manpath returns nothing... Steven001737:~ svalenti$ echo $MANPATH Steven001737:~ svalenti$ If these pages are missing how do I install them??? |
|
|
|
|
|
#10 |
|
Triple-A Player
Join Date: Jun 2006
Posts: 51
|
I should add that this is a new mac that came with 10.7 so I didn't upgrade from a different lower OS.
|
|
|
|
|
|
#11 |
|
League Commissioner
Join Date: Aug 2006
Posts: 5,040
|
It's much more likely that the man pages are installed, but not being found.
Reading further, it seems that if the $MANPATH variable is set, then those paths are used. If it isn't, then the paths are derived from the /etc/man.config file. However, it's not clear if that includes everything or everywhere by default. You may want to uncomment the following lines: Code:
# Uncomment if you want to include one of these by default # # MANPATH /opt/*/man # MANPATH /usr/lib/*/man # MANPATH /usr/share/*/man # MANPATH /usr/kerberos/man Last edited by benwiggy; 07-10-2012 at 09:41 AM. |
|
|
|
|
|
#12 |
|
Triple-A Player
Join Date: Jun 2006
Posts: 51
|
Comparing my two macs I see I only have 3 files in use/share/man/man3 folder on the machine that doesn't display the man pages running 10.7 where as there are lots of files on the other mac running 10.6 and contains many files beginning with Time....
Here are the only files in mac running 10.7... Guard_Malloc.3.gz guardmalloc.3.gz libgmalloc.3.gz If I do man 3 libgmalloc I get that page.... Where should the man pages for section 3 reside???? |
|
|
|
|
|
#13 |
|
League Commissioner
Join Date: Aug 2006
Posts: 5,040
|
Interestingly, "man 3 time" doesn't work on my 2009 MacBook.
It doesn't have a man 3 folder in /usr/share/man. (man 1, man 4 to man 9.) Might the difference be an Xcode installation? |
|
|
|
|
|
#14 |
|
Triple-A Player
Join Date: Jun 2006
Posts: 51
|
I have Xcode installed on both. The 10.7 mac was install thru the app store. I didn't have a choice where or how to install it... It just does whatever....
|
|
|
|
|
|
#15 |
|
MVP
Join Date: Apr 2008
Location: Berkeley CA USA
Posts: 1,009
|
I wonder if this is part of what Xcode considers "command line tools". Many files that are only useful to a programmer are not installed with OS X by default. The Xcode installer installs many of them (like the compilers themselves, and the header files in /System/Library/Frameworks). Then Xcode itself asks whether you want to "install the command line tools", which you would want it to do if you want to do any of your development outside the Xcode walled garden.
The man 3 pages would seem to fit that description. If you're writing a call to time(3) from within Xcode, Xcode can tell you all about it by consulting its private help files. You only need the files in /usr/share/man/man3 if you're programming outside Xcode. I can't tell. I have Xcode installed on all my bootable volumes. Look in Xcode→Preferences...→Downloads→Components and see if "Command Line Tools" is marked "Installed". Click (Install) if it isn't. |
|
|
|
|
|
#16 |
|
Triple-A Player
Join Date: Jun 2006
Posts: 51
|
That was exactly it!!! Installed the command line tools and the /usr/share/man/man3/ folder was populated with files. I now have access to the documents in terminal app.
Thanks!!! |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|