klibc

klibc
Developer(s) H. Peter Anvin
Stable release 2.0.4 / July 9, 2014 (2014-07-09)[1]
Written in C[2]
Operating system Linux
Type Runtime library
License GNU General Public License or BSD licence
Website ftp.kernel.org/pub/linux/libs/klibc/

In computing, klibc is a minimalistic subset of the standard C library developed by H. Peter Anvin. It was developed mainly to be used during the Linux startup process, and it is part of the early user space, i.e. components used during kernel startup, but which do not run in kernel mode.[3] These components do not have access to the standard library (usually glibc) used by normal userspace programs.

The development of klibc library was part of the 2002 effort to move some Linux initialization code out of the kernel.[4][5][6] According to its documentation, the klibc library is optimized for correctness and small size.[3] Because of its design, klibc is also technically suitable for embedded software in general, and even some full-featured programmes such as the MirBSD Korn Shell. klibc is licensed under the full GPL license, which (unlike LGPL) imposes itself on any code linked with it. (This only applies to klibc as a whole due to embedding some Linux kernel derived files; most of the library source code is actually[7] available under a BSD licence from UCB or the Historical Permission Notice and Disclaimer.) This may limit its applicability to commercial embedded software.[8]

During the Linux startup process, klibc is loaded from within a temporary RAM file system, initramfs. It is incorporated by default into initial RAM file systems that are created by the mkinitramfs script in Debian[9] and Ubuntu. Furthermore it has a set of small Unix utilities that are useful in early user space: cpio, dash, fstype, mkdir, mknod, mount, nfsmount, run-init, etc. all using the klibc library.[10] An alternate strategy is to include everything in one executable, like BusyBox, which determines the program via arguments or a symlink.

See also

Other C standard libraries

References

External links

This article is issued from Wikipedia - version of the Monday, May 02, 2016. The text is available under the Creative Commons Attribution/Share Alike but additional terms may apply for the media files.