PThread库的源代码?

发布于 2024-09-09 04:15:48 字数 1539 浏览 8 评论 0原文

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

°如果伤别离去 2024-09-16 04:15:48

pthreads 在 Linux 上的 libc 中实现。通常的 libc 是 glibc - glibc pthreads 实现称为 NPTL,并且 源代码可在 gitweb 中找到。

pthreads are implemented on Linux in libc. The usual libc is glibc - the glibc pthreads implementation is called NPTL, and the source is available in gitweb.

等数载,海棠开 2024-09-16 04:15:48

你看过 GNU libc 吗?

在我的 Debian 盒子上,我看到

edd@mccoy:~$ dpkg -S /usr/lib/libpthread.so 
libc6-dev: /usr/lib/libpthread.so
edd@mccoy:~$ apt-cache show libc6-dev
Package: libc6-dev
Priority: optional
Section: libdevel
Installed-Size: 13172
Maintainer: GNU Libc Maintainers <[email protected]>
Architecture: i386
Source: glibc
Version: 2.7-18lenny4
Replaces: man-db (<= 2.3.10-41), gettext (<= 0.10.26-1), ppp (<= 2.2.0f-24), 
          libgdbmg1-dev (<= 1.7.3-24)
Provides: libc-dev
Depends: libc6 (= 2.7-18lenny4), linux-libc-dev
Recommends: gcc | c-compiler
Suggests: glibc-doc, manpages-dev
Conflicts: libstdc++2.10-dev (<< 1:2.95.2-15), gcc-2.95 (<< 1:2.95.3-9), 
           binutils (<< 2.17cvs20070426-1), libc-dev
Filename: pool/updates/main/g/glibc/libc6-dev_2.7-18lenny4_i386.deb
Size: 3387248
MD5sum: 9cdb8401cead8afdd9f3e5da7bf673f8
SHA1: 01049f981a24dc0e5da8a3a1e57a8f2e91d7e57a
SHA256: 89c222ece39c417ee91f24d9f5619f58be330b111092379e4f09b93bcbfe834b
Description: GNU C Library: Development Libraries and Header Files
 Contains the symlinks, headers, and object files needed to compile
 and link programs which use the standard C library.
Build-Essential: yes
Tag: devel::lang:c, devel::library, implemented-in::c, role::devel-lib, suite::gnu

edd@mccoy:~$ 

Did you look at GNU libc?

On my Debian box, I see

edd@mccoy:~$ dpkg -S /usr/lib/libpthread.so 
libc6-dev: /usr/lib/libpthread.so
edd@mccoy:~$ apt-cache show libc6-dev
Package: libc6-dev
Priority: optional
Section: libdevel
Installed-Size: 13172
Maintainer: GNU Libc Maintainers <[email protected]>
Architecture: i386
Source: glibc
Version: 2.7-18lenny4
Replaces: man-db (<= 2.3.10-41), gettext (<= 0.10.26-1), ppp (<= 2.2.0f-24), 
          libgdbmg1-dev (<= 1.7.3-24)
Provides: libc-dev
Depends: libc6 (= 2.7-18lenny4), linux-libc-dev
Recommends: gcc | c-compiler
Suggests: glibc-doc, manpages-dev
Conflicts: libstdc++2.10-dev (<< 1:2.95.2-15), gcc-2.95 (<< 1:2.95.3-9), 
           binutils (<< 2.17cvs20070426-1), libc-dev
Filename: pool/updates/main/g/glibc/libc6-dev_2.7-18lenny4_i386.deb
Size: 3387248
MD5sum: 9cdb8401cead8afdd9f3e5da7bf673f8
SHA1: 01049f981a24dc0e5da8a3a1e57a8f2e91d7e57a
SHA256: 89c222ece39c417ee91f24d9f5619f58be330b111092379e4f09b93bcbfe834b
Description: GNU C Library: Development Libraries and Header Files
 Contains the symlinks, headers, and object files needed to compile
 and link programs which use the standard C library.
Build-Essential: yes
Tag: devel::lang:c, devel::library, implemented-in::c, role::devel-lib, suite::gnu

edd@mccoy:~$ 
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文