This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH 07/11] [C++/mingw] Define __STDC_CONSTANT_MACROS / __STDC_LIMIT_MACROS for stdint.h


On 15-11-02 03:47 PM, Simon Marchi wrote:
> FYI, I stumbled on the same problem when building for various architectures this weekend.  I
> generated some toolchains by using some of the Buildroot included configurations, which use
> uclibc.  I ended up defining those macros as well in CFLAGS.  So that change can help for more
> configurations than just mingw.

Actually, would it be better to add ifndefs?

#ifndef __STDC_CONSTANT_MACROS
#define __STDC_CONSTANT_MACROS
#endif

(same for __STDC_LIMIT_MACROS)

I tried to build the latest version of the branch, but since I had specified those in CFLAGS, I get:


In file included from /home/simark/src/binutils-gdb/gdb/defs.h:28:0,
                 from /home/simark/src/binutils-gdb/gdb/gdb.c:19:
/home/simark/src/binutils-gdb/gdb/common/common-defs.h:47:0: error: "__STDC_CONSTANT_MACROS" redefined [-Werror]
 #define __STDC_CONSTANT_MACROS
 ^
<command-line>:0:0: note: this is the location of the previous definition
In file included from /home/simark/src/binutils-gdb/gdb/defs.h:28:0,
                 from /home/simark/src/binutils-gdb/gdb/gdb.c:19:
/home/simark/src/binutils-gdb/gdb/common/common-defs.h:48:0: error: "__STDC_LIMIT_MACROS" redefined [-Werror]
 #define __STDC_LIMIT_MACROS
 ^
<command-line>:0:0: note: this is the location of the previous definition
cc1plus: all warnings being treated as errors


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]