Page 1 of 1

PE-kernel and BSS section...

Posted: Sun Feb 07, 2010 9:53 pm
by mutex
Hi,

I tried out compiling my kernel with VC++ after reading all the interresting posts here last days,

In my GCC make system i use LD with a script for defining the link layout and also make pointers for code,data and bss.

Bss is actually the only one that is a bit important for me because i use this to zero the bss just after grub gives control to my code.

As you probably have understood by now the problem is i dont have any method of making any info like this with VC++ linker and therefore i am unable to clear the bss resulting in a problem..

Is there any quick-fix for this or do i need to start hardcoding or do pe-header processing to get it figured out?

-- EDIT --

Actually i found a way that might work using #pragma bss_seg(".bss$order"). Linker will use order when placing segments in final output file.. This might work.. *experimenting with it now*

best regards
Thomas