DEV Community

Discussion on: Writing My Own Boot Loader

Collapse
 
liam824css profile image
liam824css

what is this erld: warning: cannot find entry symbol start; defaulting to 0000000000001000
ld: kernel.o: in function main':
kernel.c:(.text+0x10): undefined reference to
_GLOBAL_OFFSET_TABLE
'
make: *** [Makefile:9: kernel.bin] Error 1
ror?

Collapse
 
frosnerd profile image
Frank Rosner

I don't know? What did you do?

Collapse
 
liam824css profile image
liam824css

I do start makefile

Thread Thread
 
frosnerd profile image
Frank Rosner

I wrote and tested this only on Mac. Are you using Linux?

Thread Thread
 
liam824css profile image
liam824css

yes

Thread Thread
 
luidenkagolden profile image
Luidenka-Golden

same problem in macOS

Collapse
 
codinggeek1711 profile image
Maheswaran Parameswaran

I know its late but add -fno-pie to gcc compilation

Collapse
 
luidenkagolden profile image
Luidenka-Golden

May I know the code with -fno-pie added?

Thread Thread
 
hecker2007 profile image
Parambir Singh

its --no-pie and not -fno-pie

Collapse
 
havanduc2002 profile image
HaVanDuc2002

Adding -fno-pie in gcc fix the problem to me
gcc -fno-pie -m32 -ffreestanding -c kernel.c -o kernel.o