This is the mail archive of the
newlib@sourceware.org
mailing list for the newlib project.
Re: UINT32_C redefined [PATCH]
- From: "Shaun Jackman" <sjackman at gmail dot com>
- To: newlib at sources dot redhat dot com
- Date: Fri, 17 Mar 2006 13:26:37 -0700
- Subject: Re: UINT32_C redefined [PATCH]
- References: <7f45d9390511171537o4497248eu@mail.gmail.com>
- Reply-to: "Shaun Jackman" <sjackman at gmail dot com>
Ping?
newlib/libc/include/stdint.h (UINT32_C) is redefined in
libc/sys/linux/linuxthreads/config.h.
--- newlib/libc/sys/linux/linuxthreads/config.h 28 May 2003 22:04:37 -0000 1.1
+++ newlib/libc/sys/linux/linuxthreads/config.h 17 Mar 2006 20:26:23 -0000
@@ -11,4 +11,4 @@
while (__result == -1L && errno == EINTR); \
__result; }))
-#define UINT32_C(c) c ## U
+#define UINT32_C(x) x##U
-- sdj
On 11/17/05, Shaun Jackman <sjackman@gmail.com> wrote:
> linuxthreads/config.h redefines UINT32_C. A few possible solutions come to mind:
> * Remove this line and include stdint.h in the file that includes config.h.
> * #ifndef UINT32_C / #define UINT32_C ... / #endif
> * #include <stdint.h>
> * #define UINT32_C(x) x##U
>
> The patch below takes the last approach, because it's the least
> invasive. One of the alternatives may be the `better' solution.
>
> Cheers,
> Shaun
>
> 2005-11-17 Shaun Jackman <sjackman@gmail.com>
>
> * libc/sys/linux/linuxthreads/config.h (UINT32_C): Use the same
> definition as stdint.h.
>
> Index: newlib/libc/sys/linux/linuxthreads/config.h
> ===================================================================
> RCS file: /cvs/src/src/newlib/libc/sys/linux/linuxthreads/config.h,v
> retrieving revision 1.1
> diff -u -r1.1 config.h
> --- newlib/libc/sys/linux/linuxthreads/config.h 28 May 2003 22:04:37 -0000 1.1
> +++ newlib/libc/sys/linux/linuxthreads/config.h 17 Nov 2005 23:32:12 -0000
> @@ -11,4 +11,4 @@
> while (__result == -1L && errno == EINTR); \
> __result; }))
>
> -#define UINT32_C(c) c ## U
> +#define UINT32_C(x) x##U