[compiler-rt] 52f2df1 - [Sanitizers] Get link map on FreeBSD and NetBSD via documented API

Kamil Rytarowski via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 11 01:59:37 PST 2020


On 11.02.2020 10:47, Jeremy Morse via llvm-commits wrote:
> Hi,
> 
> On Tue, Feb 11, 2020 at 3:29 AM Yung, Douglas via llvm-commits
> <llvm-commits at lists.llvm.org> wrote:
>> This change is failing to build on our internal linux build bot. The machine is an x86_64 linux machine running ubuntu 18.04 with glibc 2.27-3ubuntu1 and is getting this error when trying to build:
>>
>> FAILED: projects/compiler-rt/lib/sanitizer_common/tests/Sanitizer-x86_64-Test-Nolibc
>> cd /home/siadmin/jenkins/w/opensource/opensource_build/build/projects/compiler-rt/lib/sanitizer_common/tests && /home/siadmin/jenkins/w/opensource/opensource_build/build/./bin/clang sanitizer_nolibc_test_main.x86_64.o -Wl,-whole-archive libRTSanitizerCommon.test.nolibc.x86_64.a -Wl,-no-whole-archive -o /home/siadmin/jenkins/w/opensource/opensource_build/build/projects/compiler-rt/lib/sanitizer_common/tests/./Sanitizer-x86_64-Test-Nolibc -fuse-ld=gold -Wl,-allow-shlib-undefined -static -nostdlib -m64
>> /home/siadmin/jenkins/w/opensource/opensource_build/compiler-rt/lib/sanitizer_common/sanitizer_linux.cpp:741: error: undefined reference to 'dlinfo'
>> clang-11: error: linker command failed with exit code 1 (use -v to see invocation)
>>
>> Manually adding "-ldl" to the command line results in an undefined reference to '__dlinfo' instead of 'dlinfo'. Any idea why this isn't linking properly?
> 
> It looks like this failure-mode is now appearing on public buildbots:
> 
>   http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux/builds/25660
>   http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux/builds/25660/steps/check-sanitizer%20in%20gcc%20build/logs/stdio
> 
> Without any context, it would appear that the patch adds a dependency
> on dlinfo on linux, which is finding its way into the nolibc
> sanitizer?
> 
> --
> Thanks,
> Jeremy
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at lists.llvm.org
> https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits
> 

A fix landed:

commit f8370d6c8ab89875cdc2fc1638aa6f1732be7e99 (HEAD -> master)
Author: Kamil Rytarowski <n54 at gmx.com>
Date:   Tue Feb 11 10:57:16 2020 +0100

    [compiler-rt] Restrict sanitizer_linux.cpp dlinfo(3) to FreeBSD

    FreeBSD is currently the only user in this file.
    Accessing this symbol on Linux does not work as is.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200211/66cbbe69/attachment.sig>


More information about the llvm-commits mailing list