Porting Glibc

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
Jush
Posts: 6
Joined: Fri Jan 11, 2019 7:59 am

Porting Glibc

Post by Jush »

How do I link glibc into my Operating system? I tried a couple of times but I keep getting errors from the actual source from headers and .c files.

And the glibc headers had missing header files that exist in the glibc-build folder containing everything, how do I contain every folder that has glibc *.o files, *.c and *.h properly without any issues?
Korona
Member
Member
Posts: 1000
Joined: Thu May 17, 2007 1:27 pm
Contact:

Re: Porting Glibc

Post by Korona »

glibc is known to be hard to port. It only runs on Linux (and maybe GNU Hurd). If you do not want to invest massive amounts of time into porting it, I'd suggest to look for other, more portable C libraries.
managarm: Microkernel-based OS capable of running a Wayland desktop (Discord: https://discord.gg/7WB6Ur3). My OS-dev projects: [mlibc: Portable C library for managarm, qword, Linux, Sigma, ...] [LAI: AML interpreter] [xbstrap: Build system for OS distributions].
Jush
Posts: 6
Joined: Fri Jan 11, 2019 7:59 am

Re: Porting Glibc

Post by Jush »

What good portable C libraries do you recommend? (And include how easy it is port them)
mallard
Member
Member
Posts: 280
Joined: Tue May 13, 2014 3:02 am
Location: Private, UK

Re: Porting Glibc

Post by mallard »

Jush wrote:What good portable C libraries do you recommend? (And include how easy it is port them)
https://wiki.osdev.org/C_Library

(Although ignore the poetry under "MyOS libc"; what's "best" and "most in the osdev spirit" is entirely up to you.)
Image
User avatar
Combuster
Member
Member
Posts: 9301
Joined: Wed Oct 18, 2006 3:45 am
Libera.chat IRC: [com]buster
Location: On the balcony, where I can actually keep 1½m distance
Contact:

Re: Porting Glibc

Post by Combuster »

mallard wrote:Although ignore the poetry under "MyOS libc"; what's "best" and "most in the osdev spirit" is entirely up to you.
I've updated the wiki accordingly :wink:
"Certainly avoid yourself. He is a newbie and might not realize it. You'll hate his code deeply a few years down the road." - Sortie
[ My OS ] [ VDisk/SFS ]
Post Reply