ENTRY(_start) SECTIONS { . = 4M + SIZEOF_HEADERS; .text ALIGN(16) : { *(.text) } :text .rodata ALIGN(16) : { *(.rodata) } :text . += 4K; /* put .data in the next page in memory while not actually moving it in the file */ .data ALIGN(16) : { *(.data) } :data .bss ALIGN(4K) : { *(COMMON) *(.bss) } :bss } PHDRS { text PT_LOAD FILEHDR PHDRS FLAGS(5); data PT_LOAD FLAGS(6); bss PT_LOAD; }