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.
I'm now converting from Windows to Linux and I tried to compile my kernel the other day... not very good results :/
Everything worked well, except when I tried to link files that used files assembled by nasm.
Well Im not very good at linkers stuff but I cannot see what you are linking -the object *.o files- while calling ld.
I mean
ld -T kernel.ld
should be like:
ld -T kernel.ld sched.o kernel.o process.o foo.o
another thing that might be of importance is that DjGpp usually prepends some underscore before any C name while linux gcc doesn't. Don't complain about it: they're from different worlds and respect different ABI standards.
The easiest workaround for you is to edit your ASM sources and remove any underscore (you'll now have "call main" rather than "call _main") and use the -f-no-leading-underscore flag for GCC if you ever want to compile under DjGpp again...