Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[sanitizer_common] Only use NT_GNU_BUILD_ID in sanitizer_linux_libcde…
…p.cpp if supported D114294 <https://reviews.llvm.org/D114294> broke the Solaris buildbots: /opt/llvm-buildbot/home/solaris11-amd64/clang-solaris11-amd64/llvm/compiler-rt/lib/sanitizer_common/sanitizer_linux_libcdep.cpp:613:29: error: use of undeclared identifier 'NT_GNU_BUILD_ID' if (nhdr->n_type == NT_GNU_BUILD_ID && nhdr->n_namesz == kGnuNamesz) { ^ Like D107556 <https://reviews.llvm.org/D107556>, it forgot that `NT_GNU_BUILD_ID` is an unportable GNU extension. Fixed by making the code conditional on the definition of the macro. Tested on `amd64-pc-solaris2.11` and `sparcv9-sun-solaris2.11`. Differential Revision: https://reviews.llvm.org/D117051
- Loading branch information