Hello,
Basically, we need to know how you are using GCC (and LD) to build the kernel. This is important given that the kernel needs to be built a specific way to be compatible with the boot loader and to be proper for a freestanding environment. We need to know what you are currently using to build the kernel, and -- precisely -- how you are using them.
We suggested the GCC Cross Compiler since it is the recommended approach when using GCC tool chains in order to avoid potential compatibility issues - however we are not sure how well it works with the GCC port in Mingw. We don't use GCC nor Mingw, so if anyone here can verify that the GCC Cross Compiler specified in the Wiki also works with Mingw, then you can certainly give it a try.
In any case, we need to know how you are calling GCC and LD, as well as the linker script you are using. If you aren't sure, please compare what you have with the Bare Bones tutorial in the Wiki here.
You are building the kernel binary incorrectly. However we cannot help if you are not able to tell us how you are trying to build it. i.e. How are you using GCC and/or LD? What does your linker script look like?
Loading kernel made in GCC from bootloader.
Re: Loading kernel made in GCC from bootloader.
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}