Hello everyone,
I've the followed this tutorial, but when compiling, I got errors:
main.c:49: warning: return type of 'main' is not 'int'
main.c: In function 'main':
main.c:63: warning: pointer targets in passing argument 1 of 'puts' differ in signedness
main.c:51: warning: unused variable 'i'
scrn.c: In function 'puts':
scrn.c:14: warning: pointer targets in passing argument 1 of 'strlen' differ in signedness
c:/djgpp/bin/ld.exe: scrn.o: No such file: No such file or directory (ENOENT)
What can I do? Last one is logic, because there were errors in scrn.c. But what about the others?
I use djgpp and nasm 2.05
Errors while compiling Bran's Kernel
Errors while compiling Bran's Kernel
Last edited by Dhaann on Sun Mar 22, 2009 6:01 am, edited 1 time in total.
Re: Erros while compiling Bran's Kernel
did you add the gcc line to compile the scrn.c?
Re: Erros while compiling Bran's Kernel
yeah... else it wouldn't give an error for scrn.c
Re: Errors while compiling Bran's Kernel
Maybe the linker can't find scrn.o.
Do you specified the path correctly?
Also give us your Makefile.
Do you specified the path correctly?
Also give us your Makefile.
OS for PowerPC Macs: https://github.com/narke/Einherjar
Operating system: colorForth computing environment for x86.: https://github.com/narke/Roentgenium
Operating system: colorForth computing environment for x86.: https://github.com/narke/Roentgenium
Re: Errors while compiling Bran's Kernel
Did you pass -Werror to gcc? As far as I can see it only outputs warnings, and unless warnings are treated as errors it should produce an object file. Make sure that the command to compile scrn.c actually outputs to scrn.o. Also, make sure that all the files are in the correct directory.
Re: Errors while compiling Bran's Kernel
Sorry, forgot the build.bat! But now I even get or errors:
Re: Errors while compiling Bran's Kernel
It looks like the tutorial compiled successfully - I don't see any compilation-terminating errors, just warnings. (Note the little "Done!" message at the end.)
These warnings, are probably caused by... I'll call them "oversights"... in the actual code (such as not using the same unsigned types or casting pointers to integers). Shame on Bran's tutorial! SHAAAAME!!! </standards nazi>
I'm pretty sure editing the code would fix most, if not all of these warnings.
Good luck!
These warnings, are probably caused by... I'll call them "oversights"... in the actual code (such as not using the same unsigned types or casting pointers to integers). Shame on Bran's tutorial! SHAAAAME!!! </standards nazi>
I'm pretty sure editing the code would fix most, if not all of these warnings.
Good luck!
"Sufficiently advanced stupidity is indistinguishable from malice."