diff options
author | Dimitry Andric <dimitry@andric.com> | 2016-12-20 07:58:49 +0000 |
---|---|---|
committer | Dimitry Andric <dimitry@andric.com> | 2016-12-20 07:58:49 +0000 |
commit | 7e560a2ba19f8f41764ddf9ad6fc7b39350f1529 (patch) | |
tree | 333f6708dc583fd9176e36e49b555a5bfe2eeb78 /lib/sanitizer_common/sanitizer_platform_limits_posix.h | |
parent | 43f4b1380839f26a7f7790c32884c796396a8caf (diff) |
Fix build breakage on FreeBSD after rL289878/rL289881
Summary:
After rL289878/rL289881, the build on FreeBSD is broken, because
sanitizer_platform_limits_posix.cc attempts to include <utmp.h> and use
`struct utmp`, neither of which are supported anymore on FreeBSD.
Fix this by adding `&& !SANITIZER_FREEBSD` in a few places, and stop
intercepting utmp functions altogether for FreeBSD.
Reviewers: kubabrecka, emaste, eugenis, ed
Subscribers: ed, llvm-commits
Differential Revision: https://reviews.llvm.org/D27902
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@290167 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/sanitizer_common/sanitizer_platform_limits_posix.h')
-rw-r--r-- | lib/sanitizer_common/sanitizer_platform_limits_posix.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/sanitizer_common/sanitizer_platform_limits_posix.h b/lib/sanitizer_common/sanitizer_platform_limits_posix.h index e647cec0e..477a0ecbe 100644 --- a/lib/sanitizer_common/sanitizer_platform_limits_posix.h +++ b/lib/sanitizer_common/sanitizer_platform_limits_posix.h @@ -862,7 +862,9 @@ namespace __sanitizer { extern int shmctl_shm_stat; #endif +#if !SANITIZER_MAC && !SANITIZER_FREEBSD extern unsigned struct_utmp_sz; +#endif #if !SANITIZER_ANDROID extern unsigned struct_utmpx_sz; #endif |