diff options
author | Tom de Vries <tdevries@suse.de> | 2020-06-12 18:36:56 +0200 |
---|---|---|
committer | Tom de Vries <tdevries@suse.de> | 2020-06-12 18:36:56 +0200 |
commit | 8118159c69a957292ce701b3d2937f19a0d0f973 (patch) | |
tree | 2f1a307851b989e0203ecb1fab5bf6002de03e8a /zlib/aclocal.m4 | |
parent | a29d5112814e7a6744f03bddfe6756e2aa5e7a50 (diff) | |
download | gdb-8118159c69a957292ce701b3d2937f19a0d0f973.zip gdb-8118159c69a957292ce701b3d2937f19a0d0f973.tar.gz gdb-8118159c69a957292ce701b3d2937f19a0d0f973.tar.bz2 |
[gdbserver] Fix Wlto-type-mismatch for debug_agent
When building gdb including gdbserver with CFLAGS/CXXFLAGS -O2 -g -flto=auto,
I run into:
...
src/gdbserver/../gdbsupport/agent.h:47:13: error: type of 'debug_agent' \
does not match original declaration [-Werror=lto-type-mismatch]
extern bool debug_agent;
^
src/gdbserver/ax.cc:28:5: note: type 'int' should match type 'bool'
int debug_agent = 0;
^
src/gdbserver/ax.cc:28:5: note: 'debug_agent' was previously declared here
src/gdbserver/ax.cc:28:5: note: code may be misoptimized unless \
-fno-strict-aliasing is used
...
Fix this by changing the type of debug_agent in ax.cc from int to bool.
Tested on x86_64-linux.
Diffstat (limited to 'zlib/aclocal.m4')
0 files changed, 0 insertions, 0 deletions