* sanitizer_common/sanitizer_platform_limits_linux.cc: Include
<sys/stat.h>, instead of <asm/stat.h>, if __x86_64__ is defined.
(struct___old_kernel_stat_sz): Don't check if __x86_64__ is defined.
From-SVN: r205736
+2013-12-06 H.J. Lu <hongjiu.lu@intel.com>
+
+ * sanitizer_common/sanitizer_platform_limits_linux.cc: Include
+ <sys/stat.h>, instead of <asm/stat.h>, if __x86_64__ is defined.
+ (struct___old_kernel_stat_sz): Don't check if __x86_64__ is defined.
+
2013-12-05 H.J. Lu <hongjiu.lu@intel.com>
* configure.ac (link_sanitizer_common): Add -lm.
// are not defined anywhere in userspace headers. Fake them. This seems to work
// fine with newer headers, too.
#include <asm/posix_types.h>
+#if defined(__x86_64__)
+#include <sys/stat.h>
+#else
#define ino_t __kernel_ino_t
#define mode_t __kernel_mode_t
#define nlink_t __kernel_nlink_t
#undef uid_t
#undef gid_t
#undef off_t
+#endif
#include <linux/aio_abi.h>
unsigned struct_statfs64_sz = sizeof(struct statfs64);
} // namespace __sanitizer
-#if !defined(__powerpc64__)
+#if !defined(__powerpc64__) && !defined(__x86_64__)
COMPILER_CHECK(struct___old_kernel_stat_sz == sizeof(struct __old_kernel_stat));
#endif