From 5c26fecb6f7dae69c878c2ecdeb81636e571593c Mon Sep 17 00:00:00 2001 From: Andreas Jaeger Date: Tue, 8 Jan 2002 10:19:35 +0000 Subject: [PATCH] Prevent double inclusion. --- bits/byteswap.h | 7 ++++++- sysdeps/generic/bits/byteswap.h | 7 ++++++- sysdeps/i386/bits/byteswap.h | 7 ++++++- sysdeps/ia64/bits/byteswap.h | 7 ++++++- sysdeps/m68k/bits/byteswap.h | 7 ++++++- sysdeps/s390/s390-32/bits/byteswap.h | 7 ++++++- sysdeps/s390/s390-64/bits/byteswap.h | 9 ++++++--- 7 files changed, 42 insertions(+), 9 deletions(-) diff --git a/bits/byteswap.h b/bits/byteswap.h index 7866abe..38d8540 100644 --- a/bits/byteswap.h +++ b/bits/byteswap.h @@ -1,5 +1,5 @@ /* Macros to swap the order of bytes in integer values. - Copyright (C) 1997, 1998, 2000, 2001 Free Software Foundation, Inc. + Copyright (C) 1997, 1998, 2000, 2001, 2002 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -21,6 +21,9 @@ # error "Never use directly; include instead." #endif +#ifndef _BITS_BYTESWAP_H +#define _BITS_BYTESWAP_H 1 + /* Swap bytes in 16 bit value. */ #ifdef __GNUC__ # define __bswap_16(x) \ @@ -77,3 +80,5 @@ __bswap_32 (unsigned int __bsx) } \ __r.__ll; })) #endif + +#endif /* _BITS_BYTESWAP_H */ diff --git a/sysdeps/generic/bits/byteswap.h b/sysdeps/generic/bits/byteswap.h index 7866abe..38d8540 100644 --- a/sysdeps/generic/bits/byteswap.h +++ b/sysdeps/generic/bits/byteswap.h @@ -1,5 +1,5 @@ /* Macros to swap the order of bytes in integer values. - Copyright (C) 1997, 1998, 2000, 2001 Free Software Foundation, Inc. + Copyright (C) 1997, 1998, 2000, 2001, 2002 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -21,6 +21,9 @@ # error "Never use directly; include instead." #endif +#ifndef _BITS_BYTESWAP_H +#define _BITS_BYTESWAP_H 1 + /* Swap bytes in 16 bit value. */ #ifdef __GNUC__ # define __bswap_16(x) \ @@ -77,3 +80,5 @@ __bswap_32 (unsigned int __bsx) } \ __r.__ll; })) #endif + +#endif /* _BITS_BYTESWAP_H */ diff --git a/sysdeps/i386/bits/byteswap.h b/sysdeps/i386/bits/byteswap.h index c76b081..d08a342 100644 --- a/sysdeps/i386/bits/byteswap.h +++ b/sysdeps/i386/bits/byteswap.h @@ -1,5 +1,5 @@ /* Macros to swap the order of bytes in integer values. - Copyright (C) 1997, 1998, 2000 Free Software Foundation, Inc. + Copyright (C) 1997, 1998, 2000, 2002 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -21,6 +21,9 @@ # error "Never use directly; include instead." #endif +#ifndef _BITS_BYTESWAP_H +#define _BITS_BYTESWAP_H 1 + /* Swap bytes in 16 bit value. */ #define __bswap_constant_16(x) \ ((((x) >> 8) & 0xff) | (((x) & 0xff) << 8)) @@ -108,3 +111,5 @@ } \ __r.__ll; })) #endif + +#endif /* _BITS_BYTESWAP_H */ diff --git a/sysdeps/ia64/bits/byteswap.h b/sysdeps/ia64/bits/byteswap.h index 012a40e..285102c 100644 --- a/sysdeps/ia64/bits/byteswap.h +++ b/sysdeps/ia64/bits/byteswap.h @@ -1,5 +1,5 @@ /* Macros to swap the order of bytes in integer values. - Copyright (C) 1997, 1998, 2000 Free Software Foundation, Inc. + Copyright (C) 1997, 1998, 2000, 2002 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -21,6 +21,9 @@ # error "Never use directly; include instead." #endif +#ifndef _BITS_BYTESWAP_H +#define _BITS_BYTESWAP_H 1 + /* Swap bytes in 16 bit value. */ #define __bswap_constant_16(x) \ ((((x) >> 8) & 0xff) | (((x) & 0xff) << 8)) @@ -91,3 +94,5 @@ #else # define __bswap_64(x) __bswap_constant_64 (x) #endif + +#endif /* _BITS_BYTESWAP_H */ diff --git a/sysdeps/m68k/bits/byteswap.h b/sysdeps/m68k/bits/byteswap.h index ea6aa96..549d445 100644 --- a/sysdeps/m68k/bits/byteswap.h +++ b/sysdeps/m68k/bits/byteswap.h @@ -1,5 +1,5 @@ /* Macros to swap the order of bytes in integer values. m68k version. - Copyright (C) 1997 Free Software Foundation, Inc. + Copyright (C) 1997, 2002 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -21,6 +21,9 @@ # error "Never use directly; include instead." #endif +#ifndef _BITS_BYTESWAP_H +#define _BITS_BYTESWAP_H 1 + /* Swap bytes in 16 bit value. We don't provide an assembler version because GCC is smart enough to generate optimal assembler output, and this allows for better cse. */ @@ -60,3 +63,5 @@ __bswap_64_r.__l[1] = __bswap_32 (__bswap_64_v.__l[0]); \ __bswap_64_r.__ll; }) #endif + +#endif /* _BITS_BYTESWAP_H */ diff --git a/sysdeps/s390/s390-32/bits/byteswap.h b/sysdeps/s390/s390-32/bits/byteswap.h index 0f2de09..ae12804 100644 --- a/sysdeps/s390/s390-32/bits/byteswap.h +++ b/sysdeps/s390/s390-32/bits/byteswap.h @@ -1,5 +1,5 @@ /* Macros to swap the order of bytes in integer values. s390 version. - Copyright (C) 2000, 2001 Free Software Foundation, Inc. + Copyright (C) 2000, 2001, 2002 Free Software Foundation, Inc. Contributed by Martin Schwidefsky (schwidefsky@de.ibm.com). This file is part of the GNU C Library. @@ -22,6 +22,9 @@ # error "Never use directly; include instead." #endif +#ifndef _BITS_BYTESWAP_H +#define _BITS_BYTESWAP_H 1 + #define __bswap_constant_16(x) \ ((((x) >> 8) & 0xff) | (((x) & 0xff) << 8)) @@ -84,3 +87,5 @@ __r.__l[1] = __bswap_32 (__w.__l[0]); \ __r.__ll; }) #endif + +#endif /* _BITS_BYTESWAP_H */ diff --git a/sysdeps/s390/s390-64/bits/byteswap.h b/sysdeps/s390/s390-64/bits/byteswap.h index 3af2cce..b8cfdb2 100644 --- a/sysdeps/s390/s390-64/bits/byteswap.h +++ b/sysdeps/s390/s390-64/bits/byteswap.h @@ -1,5 +1,5 @@ /* Macros to swap the order of bytes in integer values. 64 bit S/390 version. - Copyright (C) 2001 Free Software Foundation, Inc. + Copyright (C) 2001, 2002 Free Software Foundation, Inc. Contributed by Martin Schwidefsky (schwidefsky@de.ibm.com). This file is part of the GNU C Library. @@ -22,6 +22,9 @@ # error "Never use directly; include instead." #endif +#ifndef _BITS_BYTESWAP_H +#define _BITS_BYTESWAP_H 1 + #define __bswap_constant_16(x) \ ((((x) >> 8) & 0xff) | (((x) & 0xff) << 8)) @@ -29,7 +32,7 @@ #if defined __GNUC__ && __GNUC__ >= 2 # define __bswap_16(x) \ (__extension__ \ - ({ unsigned short int __v; \ + ({ unsigned short int __v; \ if (__builtin_constant_p (x)) \ __v = __bswap_constant_16 (x); \ else { \ @@ -90,4 +93,4 @@ # define __bswap_64(x) __bswap_constant_64 (x) #endif - +#endif /* _BITS_BYTESWAP_H */ -- 2.7.4