Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Are Unix/Linux system calls part of POSIX library functions?

Are Unix/Linux system calls all or mostly in POSIX?

Many Linux/Unix programming books say that POSIX library functions may be wrappers of OS system calls, or may be not. E.g. http://www.makelinux.net/books/lkd2/ch05lev1sec1, and https://www.safaribooksonline.com/library/view/understanding-the-linux/0596005652/ch10s01.html

A part (called the Single UNIX Specification) of POSIX defines UNIX. Therefore I think POSIX defines the system calls of Unix (and of Linux).

Then are Unix/Linux system calls part of POSIX library functions?

Thanks.

like image 778
Tim Avatar asked Dec 01 '22 14:12

Tim


1 Answers

Linux system calls are listed in syscalls(2). Most are POSIX, but some are specific to Linux (e.g. signalfd(2), etc...). POSIX is a specification and does not "know" about syscalls (which, in the POSIX view, are an implementation detail).

Some functions are standardized in POSIX but implemented in Linux library code, e.g. dlopen(3) (see POSIX dlopen) built above mmap(2)...

like image 155
Basile Starynkevitch Avatar answered Dec 06 '22 13:12

Basile Starynkevitch