Re: C Standard Libraries

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Bryon Quackenbush via Gcc kirjoitti 15.10.2024 klo 19.09:
Does anyone know where in the GCC hierarchy that I can find implementation
code for standard C library functions like fgetc / fputs, etc, or would
that be outside the scope of GCC?  I've been hunting around on the source
tree for the last few days and found the headers, but not the
implementation.
This is really a very old misunderstanding when one reads about a "free C compiler" for some familiar system which is missing this and buying it as a "Development System" addition looks too expensive. For me it happened with the "SCO Unix 386" for 32-bit PCs, the required "Standard C library" came with the "Development System" add-on for the "Basic System" so this sounded being a "Catch 22" situation : If you have the Development System you don't need any extra C compiler because you already have it. Meanwhile "GCC for MS-DOS" included the DJGPP C-library for DOS. Most Unix systems at that time included at least the Standard C libraries but sold the compilers as add-ons.

Ok, providing a "Standard C library for all possible systems" is quite impossible because it should communicate with the operating system, the provided firmware or the raw hardware on the target system. The well-known "newlib" for embedded systems includes many separate "glue libraries"("libgloss") for different embedded targets and boards :
https://sourceware.org/newlib/
For usual operating systems like the Linux distros, Oracle Solarises, different Unices, MS
Windows etc there are pre-made standard C libraries which are used with GCC.

Thanks for the help.

- Bryon



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux