私は例としてUbuntu(Linux)+ gccを使用しています。Cヘッダファイルは誰が提供しましたか?
stdio.h
(GCCがインストールされている)のUbuntu Linux上で、それぞれどの組織によって提供される
pthread.h
sys/socket.h
poll.h
? GNU? Linux? ISO? Ubuntu? 対応するライブラリはどうですか?
私は例としてUbuntu(Linux)+ gccを使用しています。Cヘッダファイルは誰が提供しましたか?
stdio.h
pthread.h
sys/socket.h
poll.h
? GNU? Linux? ISO? Ubuntu? 対応するライブラリはどうですか?
にインストールされていますどんなシステムGNUコンパイラです。
オンUbuntu glibc実装が使用されています(GNU Cライブラリ)。 Cライブラリの他のいくつかの例:
uClibcを(埋め込み)、AVR-libcの(埋め込み)、dietlibc、klibc、elibc_FreeBSD ...
ISO/IECは、標準を作成しており、これらのライブラリは、それに従ってください。
~ head -n 20 /usr/include/stdio.h
/* Define ISO C stdio on top of C++ iostreams.
Copyright (C) 1991, 1994-2010, 2011 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
The GNU C Library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with the GNU C Library; if not, write to the Free
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307 USA. */
UbuntuはCanonicalによって管理されているため、パッケージを組み立てるのはUbuntuです。
標準的なCライブラリヘッダーは、C標準ライブラリのGNU実装の一部として、GNU.orgによって維持管理されているので、Canonicalがそれを取得するソースです。
実際にはヘッダー(実装も)もgccバンドルには含まれていません(canonical/ubuntuはgcc-develなどと呼ばれます)。 ほとんどのLinuxディストリビューションでは、これらを含むgnu Cライブラリ(glibc)を使用しています。 – AoeAoe
@AoeAoe、ありがとうございました。 –
これらはGNUによって提供されています。 /usr/include/stdio.h
の
ファーストライン:
/* Define ISO C stdio on top of C++ iostreams.
Copyright (C) 1991, 1994-2008, 2009, 2010 Free Software Foundation, Inc.
This file is part of the GNU C Library...
gccが、それはこれらのシステムにインストールCライブラリの一部であるライブラリのヘッダーです
どのヘッダ?どのライブラリですか? –
各ヘッダーには通常著作権表示があります。どのヘッダファイルが使用されているかを理解するには、gcc -Hを使います。 –