Unix/Linux系统调用是POSIX库功能的一部分吗? [英] Are Unix/Linux system calls part of POSIX library functions?

查看:184
本文介绍了Unix/Linux系统调用是POSIX库功能的一部分吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Unix/Linux系统是否全部或主要在POSIX中调用?

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

许多Linux/Unix编程书籍都说POSIX库函数可以是OS系统调用的包装,也可以不是.例如. http://www.makelinux.net/books/lkd2/ch05lev1sec1 https://www.safaribooksonline.com/library/view/understanding -the-linux/0596005652/ch10s01.html

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

POSIX的一部分(称为单一UNIX规范")定义UNIX.因此,我认为POSIX定义了Unix(和Linux)的系统调用.

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

那么Unix/Linux系统调用是POSIX库功能的一部分吗?

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

谢谢.

推荐答案

系统调用(2).大多数是POSIX,但有些是特定于Linux的(例如 signalfd(2)等). POSIX是规范,它不了解" 系统调用( ,在POSIX视图中,是一个实现细节).

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).

某些功能在POSIX中已标准化,但在Linux库代码中得以实现,例如 dlopen(3)(请参阅POSIX

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

这篇关于Unix/Linux系统调用是POSIX库功能的一部分吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆