Woops, forgot the location counter moves in bytes not longs ;-) should be in ld/scripttempl/pe.sc .reloc ${RELOCATING+BLOCK(__section_alignment__)} : { reloc_start_addr__ = .; *(.reloc) reloc_end_addr__ = .; . += ( reloc_end_addr__ - reloc_start_addr__ ) ? 5 * 4 : 0 ; } =0x0000