Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

UNIX System Call Listing?

I have an assignment where I need to use some system calls in UNIX, like mktime() and fnmatch(), to complete some operations. We're given only the names of the man pages to look up to find the functions.

Now, this is fine for the purpose of the assignment. But in the future when I do UNIX programming, I may not know the exact name (I never would have known fnmatch exists without knowing its name first).

So the question is: how can I get a comprehensive list of ALL UNIX system functions? I really don't care if it's categorized or sorted (though it would be nice), but I'd like to have the list include the descriptions so it's searchable. That way when I need a function, I can do a few searches to locate potential candidates, then I can man them to find the exact usage.

like image 434
Justin Mrkva Avatar asked Dec 29 '22 02:12

Justin Mrkva


2 Answers

There's also a useful utility called "apropos"

$ whatis apropos
apropos (1)          - search the manual page names and descriptions


$ apropos filename
...
fnmatch (3)          - match filename or pathname
...
like image 135
vmpstr Avatar answered Jan 14 '23 11:01

vmpstr


System calls are documented in section 2 of the man documentation. Depending on your version of Unix, you should be able to find these pages in the man data directory.

On Linux, this directory is /usr/share/man/man2; your version of Unix may differ. Also man man should tell you what is in the other sections.

like image 31
Kevin Lacquement Avatar answered Jan 14 '23 11:01

Kevin Lacquement