C Library: Difference between revisions
Jump to navigation
Jump to search
Add a bit of relativism to the "my C library"; generally update the page to reflect forum sentiments.
[unchecked revision] | [unchecked revision] |
mNo edit summary |
(Add a bit of relativism to the "my C library"; generally update the page to reflect forum sentiments.) |
||
Line 18:
{{Main|Creating a C Library}}
One of the more obvious solutions is to roll your own. You can get seamless integration with your kernel and the rest of the operating system, without portability layers. You also get the ability to progress with function implementations in step with the hardware functionality you add to your kernel. You can effectively write the standard and append custom interfaces to be available to all apps. It is also the one and only option if you happen to be one of the purists out there. It also serves as quite the learning experience.
On the flipside, the C library requires a significant amount of time, and using an existing version allows you to spend more effort on your own kernel. In addition, there are a great many caveats hidden in the C language specification, and it is exceedingly easy to write a non-compliant implementation that will later on cause unexpected issues when porting other third part software - or it so happens that your version is actually compliant and whatever you try to port has a hard dependency on glibc quirks.
Here are some existing C libraries for you to pursue:
=== [https://www.gnu.org/software/libc/ Glibc] ===
Line 29:
* Supports almost every architecture
* Generates large programs
* Is not written with anything other than Linux in mind, making it a hard port.
=== [https://www.etalabs.net/musl/ Musl] ===
|