Page 1 of 1

GCC switches

Posted: Wed Feb 19, 2003 4:19 pm
by Unspoken_Magi
What switches should I use with GCC for compiling the C code of my Kernel?
What switches should I use for LD, and what should I have in my linker script?

I already have these, but things have been going wrong and I think I have the compiler/linker doing something wrong...

Re:GCC switches

Posted: Thu Feb 20, 2003 1:12 am
by Pype.Clicker
ld -T $(linker-script) -o $(targetfile) -s -n $(every-.o-file) -Map kernel.map


cflags=-I ($include directory) -fno-builtin -O2 -g

%.o: %.c
gcc -c -o $@ $< $(cflags)


[attachment deleted by admin]