[Bug 276597] cannot build world with WITH_ASAN configured

From: <bugzilla-noreply_at_freebsd.org>
Date: Sat, 27 Jan 2024 15:48:47 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=276597

--- Comment #5 from Dimitry Andric <dim@FreeBSD.org> ---
(In reply to Mark Johnston from comment #4)
The optimization to avoid building some cpp files works often, but not always,
due to subtle reasons. In some cases, if you turn on debug information, or
change optimization levels, previously unreferenced symbols now do get
referenced.

In any case, I'm getting different errors here:

--- all_subdir_libexec ---
ld: error: undefined symbol: __asan_option_detect_stack_use_after_return
>>> referenced by reloc.c:64 (/home/dim/src/freebsd/src/libexec/rtld-elf/amd64/reloc.c:64)
>>>               reloc.o:(do_copy_relocations)
>>> referenced by reloc.c:129 (/home/dim/src/freebsd/src/libexec/rtld-elf/amd64/reloc.c:129)
>>>               reloc.o:(reloc_non_plt)
>>> referenced by reloc.c:361 (/home/dim/src/freebsd/src/libexec/rtld-elf/amd64/reloc.c:361)
>>>               reloc.o:(reloc_jmpslots)
>>> referenced 53 more times

ld: error: undefined symbol: __asan_stack_malloc_1
>>> referenced by reloc.c:64 (/home/dim/src/freebsd/src/libexec/rtld-elf/amd64/reloc.c:64)
>>>               reloc.o:(do_copy_relocations)
>>> referenced by rtld.c:1976 (/home/dim/src/freebsd/src/libexec/rtld-elf/rtld.c:1976)
>>>               rtld.o:(find_symdef)
>>> referenced by rtld.c:4028 (/home/dim/src/freebsd/src/libexec/rtld-elf/rtld.c:4028)
>>>               rtld.o:(dlvsym)
>>> referenced 10 more times

ld: error: undefined symbol: __asan_report_load8_noabort
>>> referenced by reloc.c:70 (/home/dim/src/freebsd/src/libexec/rtld-elf/amd64/reloc.c:70)
>>>               reloc.o:(do_copy_relocations)
>>> referenced by reloc.c:70 (/home/dim/src/freebsd/src/libexec/rtld-elf/amd64/reloc.c:70)
>>>               reloc.o:(do_copy_relocations)
>>> referenced by reloc.c:72 (/home/dim/src/freebsd/src/libexec/rtld-elf/amd64/reloc.c:72)
>>>               reloc.o:(do_copy_relocations)
>>> referenced 1769 more times

in stage 4.4: building everything.

-- 
You are receiving this mail because:
You are the assignee for the bug.