diff options
author | Tom de Vries <tdevries@suse.de> | 2023-08-17 17:09:39 +0200 |
---|---|---|
committer | Tom de Vries <tdevries@suse.de> | 2023-08-17 17:09:39 +0200 |
commit | 0c9546b152f6b01756475ce259c895d3fa446774 (patch) | |
tree | 61172f8639952924a57edee07bc7d828c07a6c83 /gdb/Makefile.in | |
parent | 05fbbeacaa761976fea5580d993aa6cb7f5342a0 (diff) | |
download | fsf-binutils-gdb-0c9546b152f6b01756475ce259c895d3fa446774.zip fsf-binutils-gdb-0c9546b152f6b01756475ce259c895d3fa446774.tar.gz fsf-binutils-gdb-0c9546b152f6b01756475ce259c895d3fa446774.tar.bz2 |
[gdb/build] Fix yysymbol_kind_t odr violation
When building gdb with -O2 -flto on openSUSE Tumbleweed (using bison 3.8.2) I
run into:
...
ada-exp.c.tmp:653: warning: type 'yysymbol_kind_t' violates the C++ One \
Definition Rule [-Wodr]
c-exp.c.tmp:398: note: an enum with different value name is defined in \
another translation unit
ada-exp.c.tmp:660: note: name 'YYSYMBOL_NULL_PTR' differs from name \
'YYSYMBOL_COMPLEX_INT' defined in another translation unit
c-exp.c.tmp:405: note: mismatching definition
...
Fix this by renaming to ada_exp_yysymbol_kind_t and likewise for other .y
files.
Tested on x86_64-linux.
PR build/22395
Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=22395
Diffstat (limited to 'gdb/Makefile.in')
-rw-r--r-- | gdb/Makefile.in | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/gdb/Makefile.in b/gdb/Makefile.in index ccdd84b..54c5312 100644 --- a/gdb/Makefile.in +++ b/gdb/Makefile.in @@ -2511,6 +2511,7 @@ po/$(PACKAGE).pot: force -e 's/YY_NULL/YY_NULLPTR/g' \ -e "s/YYSTYPE/$(subst -,_,$*)_YYSTYPE/g" \ -e "s/yyalloc/$(subst -,_,$*)_yyalloc/g" \ + -e "s/yysymbol_kind_t/$(subst -,_,$*)_yysymbol_kind_t/g" \ < $@.tmp > $@.new && \ rm -f $@.tmp && \ mv $@.new $@ |