Current-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: build issue: _REENTRANT redefined
On Sat, Sep 07, 2019 at 12:36:49AM +0200, Kamil Rytarowski wrote:
> Sanitizing compiler is available without MKSANITIZER.
I tried (on 9.99.10 from Aug 26):
wiz@yt:~> clang -fsanitize=address -g memory-leak.c
wiz@yt:~> ASAN_OPTIONS=detect_leaks=1 ./a.out
==16509==AddressSanitizer: detect_leaks is not supported on this platform.
> libutil is built with a sanitizer.
>
> This means that the code in libutil is instrumented and contains calls
> to sanitizer runtime.
>
> The runtime is linked into programs, not libraries.
>
> This means that there is need to build each program in this setup with a
> sanitizer.
Ok, thanks for the explanation.
> Every application that dynamically links with an instrumented library
> has to be prebuilt with a sanitizer.
>
> > Do I have to recompile all of pkgsrc, and if yes, why?
>
> Basically yes, there is need to recompile all of pkgsrc.
Do I need to use any particular settings or will this automatically
work in such a userland?
> However ASan and UBSan can be often used on the top of non-sanitized
> libraries and this will work decently finding problems in an
> application, but skipping issues called in libraries.
>
> MSan and TSan are more sensitive here and need full sanitization.
I'm currently mostly interested in the leak sanitizer.
But perhaps that's not available yet, or at least not in 9.99.10?
Thomas
Home |
Main Index |
Thread Index |
Old Index