Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/arm/include Add a check for minimum compiler compat...



details:   https://anonhg.NetBSD.org/src/rev/cc51cfc8e656
branches:  trunk
changeset: 326420:cc51cfc8e656
user:      matt <matt%NetBSD.org@localhost>
date:      Wed Jan 29 00:20:54 2014 +0000

description:
Add a check for minimum compiler compatible with gcc 4.1
__ARM_PCS_AAPCS64 also requires __ALIGNBYTES to be 7

diffstat:

 sys/arch/arm/include/cdefs.h |  8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diffs (26 lines):

diff -r 5e80f18019a4 -r cc51cfc8e656 sys/arch/arm/include/cdefs.h
--- a/sys/arch/arm/include/cdefs.h      Wed Jan 29 00:18:32 2014 +0000
+++ b/sys/arch/arm/include/cdefs.h      Wed Jan 29 00:20:54 2014 +0000
@@ -1,8 +1,12 @@
-/*     $NetBSD: cdefs.h,v 1.10 2014/01/28 21:17:12 matt Exp $  */
+/*     $NetBSD: cdefs.h,v 1.11 2014/01/29 00:20:54 matt Exp $  */
 
 #ifndef        _ARM_CDEFS_H_
 #define        _ARM_CDEFS_H_
 
+#if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || __GNUC__ > 4
+#error GCC 4.1 or compatible required.
+#endif
+
 #if defined (__ARM_ARCH_8A__)
 #define _ARM_ARCH_8            /* ARMv8 64-bit in AARCH32 */
 #endif
@@ -45,7 +49,7 @@
 #define        _ARM_ARCH_DWORD_OK
 #endif
 
-#ifdef __ARM_EABI__
+#if defined(__ARM_EABI__) || defined(__ARM_PCS_AAPCS64)
 #define __ALIGNBYTES           (8 - 1)
 #else
 #define __ALIGNBYTES           (sizeof(int) - 1)



Home | Main Index | Thread Index | Old Index