0

On Ubuntu if I type man 2 time I get,

NAME
       time - get time in seconds

SYNOPSIS
       #include <time.h>

       time_t time(time_t *tloc);
...

I get that this works because time is the name of the function, but sometimes I don't know the name of the stuff, I just remember the file. Like say I know what I want is in stdint.h, but I can't remember the identifying thing -- or even worse it's not a function (as is the case when I wanted the docs for ptrdiff_t), how do I find the docs on this header file?

At the bottom of man 2 time it says,

COLOPHON This page is part of release 4.15 of the Linux man-pages project. A description of the project, information about reporting bugs, and the latest version of this page, can be found at https://www.kernel.org/doc/man-pages/.

The kernel.org has the page for stdint.h. What package has these man pages so I can peruse offline? Why do I have the page for time.h, but not for stdint.h?

Evan Carroll
  • 30,763
  • 48
  • 183
  • 315
  • Related - https://unix.stackexchange.com/questions/148426/how-to-install-make-the-kernel-section-9-manpages-which-document-its-functions-a – slm Jul 07 '18 at 03:55
  • @slm I actually think this is a duplicate of that one. I'm going to delete and ask for a refinement. – Evan Carroll Jul 07 '18 at 04:05
  • 1
    Actually let's dupe it because this specifically mentions headers and it's probably worth having it around since I didn't know headers were section 9. – Evan Carroll Jul 07 '18 at 04:06

0 Answers0