svn commit: r363778 - projects/clang1100-import/contrib/llvm-project/compiler-rt/lib/builtins

Dimitry Andric dim at FreeBSD.org
Sun Aug 2 18:30:30 UTC 2020


Author: dim
Date: Sun Aug  2 18:30:29 2020
New Revision: 363778
URL: https://svnweb.freebsd.org/changeset/base/363778

Log:
  Reapply r326600 (by imp):
  
  Since this is contrib code, create an upstreamable version of my
  change. Now on FreeBSD and NetBSD if _STANDALONE is defined, we
  include the kernel version with alloances for the quirky differences
  between the two.
  
  Sponsored by: Netflix

Modified:
  projects/clang1100-import/contrib/llvm-project/compiler-rt/lib/builtins/int_lib.h

Modified: projects/clang1100-import/contrib/llvm-project/compiler-rt/lib/builtins/int_lib.h
==============================================================================
--- projects/clang1100-import/contrib/llvm-project/compiler-rt/lib/builtins/int_lib.h	Sun Aug  2 18:27:59 2020	(r363777)
+++ projects/clang1100-import/contrib/llvm-project/compiler-rt/lib/builtins/int_lib.h	Sun Aug  2 18:30:29 2020	(r363778)
@@ -72,12 +72,16 @@
 #error Unsupported target
 #endif
 
-#if defined(__NetBSD__) && (defined(_KERNEL) || defined(_STANDALONE))
+#if (defined(__FreeBSD__) || defined(__NetBSD__)) && (defined(_KERNEL) || defined(_STANDALONE))
 //
 // Kernel and boot environment can't use normal headers,
 // so use the equivalent system headers.
 //
+#ifdef __FreeBSD__
+#include <sys/limits.h>
+#else
 #include <machine/limits.h>
+#endif
 #include <sys/stdint.h>
 #include <sys/types.h>
 #else


More information about the svn-src-projects mailing list