https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64839
--- Comment #1 from Harald van Dijk <harald at gigawatt dot nl> --- FWIW, libsanitizer builds just fine if the rpc references are forcibly removed, like so: --- a/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cc +++ b/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cc @@ -131,7 +131,6 @@ #include <netax25/ax25.h> #include <netipx/ipx.h> #include <netrom/netrom.h> -#include <rpc/xdr.h> #include <scsi/scsi.h> #include <sys/mtio.h> #include <sys/kd.h> @@ -1148,19 +1147,6 @@ CHECK_SIZE_AND_OFFSET(group, gr_gid); CHECK_SIZE_AND_OFFSET(group, gr_mem); #if SANITIZER_LINUX && !SANITIZER_ANDROID -CHECK_TYPE_SIZE(XDR); -CHECK_SIZE_AND_OFFSET(XDR, x_op); -CHECK_SIZE_AND_OFFSET(XDR, x_ops); -CHECK_SIZE_AND_OFFSET(XDR, x_public); -CHECK_SIZE_AND_OFFSET(XDR, x_private); -CHECK_SIZE_AND_OFFSET(XDR, x_base); -CHECK_SIZE_AND_OFFSET(XDR, x_handy); -COMPILER_CHECK(__sanitizer_XDR_ENCODE == XDR_ENCODE); -COMPILER_CHECK(__sanitizer_XDR_DECODE == XDR_DECODE); -COMPILER_CHECK(__sanitizer_XDR_FREE == XDR_FREE); -#endif - -#if SANITIZER_LINUX && !SANITIZER_ANDROID COMPILER_CHECK(sizeof(__sanitizer_FILE) <= sizeof(FILE)); CHECK_SIZE_AND_OFFSET(FILE, _flags); CHECK_SIZE_AND_OFFSET(FILE, _IO_read_ptr); But that's clearly not acceptable :)