Address: http://www.cnblogs.com/jiqiubo/archive/2011/08/03/2126117.html
What is glibc and Its Relationship with GCC?
Glibc is the libc library released by GNU, that is, the C Runtime Library. Glibc is the most underlying API in Linux (ApplicationProgramDevelopment Interface), almost any other Runtime Library will rely on glibc. Glibc not only encapsulates the system services provided by the Linux operating system, but also provides implementation of many other necessary functional services, mainly as follows:
(1) string, string processing
(2) signal, signal processing
(3) manage dynamic loading of shared libraries in dlfcn
(4) Direct, file directory operations
(5) Elf, the dynamic loader of the shared library, that is, Interpreter
(6) iconv, encoding conversion of different character sets
(7) Implementation of Inet and socket Interfaces
(8) Intl, international, that is, the implementation of gettext
(9) IO
(10) linuxthreads
(11) locale, Localization
(12) login, virtual terminal device management, and secure system access
(13) malloc: Allocation and Management of dynamic memory
(14) NIS
(15) stdlib, other basic functions
GCC is a compiler. Basically, all programs (including the kernel) in Linux are compiled by GCC, and so is libc.
GCC and libc are mutually dependent software. They work together in a way similar to the Linux system's "self-lifting ". First, compile a new version of GCC + Old libc with the old GCC on a system that can run with the old libc and GCC, use this new GCC to compile a new GCC + new libc, and then use this set of stuff to compile the entire new system.
Check glibc version
4.9. howcan I find out which version of glibc I am using in the moment? {UD} if you want to find out about theversion from the command line simplyrun the libc binary. this is probably not possible on allplatforms Butwhere it is simply locate the libc dsoand start it as an application. onlinux like/lib/libc. so.6 this will produce all the informationyou need. what always will work is to use the apiglibc provides. compile and run thefollowing little program to get theve Rsion information: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ # Include <stdio. h >#include <GNU/libc-version.h> int main (void) {puts (gnu_get_libc_version (); Return 0 ;} ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ This interface can also obviusly beused to perform tests at runtime ifthis shoshould be necessary.
Just execute: LDD -- versionwhich comes with glibc package
* However, on the arm board, you cannot use the 1)/lib/libc. so.6) LDD -- version command to view the glibc version. How can you directly use the command to view the glibc version?