#243·mold

SECTIONS doesn't seem to be implemented ?

Author: dcb314Created Jan 4, 2022Updated May 23, 2026

Package kvm-unit-tests seems to have a linker script as follows:

SECTIONS { . = 4M + SIZEOF_HEADERS; stext = .; .text : { *(.init) *(.text) (.text.) } . = ALIGN(4K); .data : { *(.data) exception_table_start = .; *(.data.ex) exception_table_end = .; } . = ALIGN(16); .rodata : { *(.rodata) } . = ALIGN(16); .bss : { *(.bss) } . = ALIGN(4K); edata = .; }

ENTRY(start)

mold says:

mold: /home/dcb35/rpmbuild/BUILD/kvm-unit-tests-1edfa966328dfc824e9b0351087bbfaf699dce04/x86/flat.lds:1: SECTIONS ^ unknown linker script token