]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Fix MicroBlaze bits/setjmp.h for C++.
authorJoseph Myers <joseph@codesourcery.com>
Wed, 4 Jan 2017 18:12:14 +0000 (18:12 +0000)
committerJoseph Myers <joseph@codesourcery.com>
Wed, 4 Jan 2017 18:12:14 +0000 (18:12 +0000)
For MicroBlaze, setjmp/check-installed-headers-cxx fails with:

../setjmp/setjmp.h:34:8: error: '__jmp_buf_tag' has a field '__jmp_buf_tag::__jmpbuf' whose type depends on the type '<unnamed struct>' which has no linkage [-Werror=subobject-linkage]

This patch fixes this in the same way as for some other architectures:
the struct used for the internal __jmp_buf type is given the tag
__jmp_buf_internal_tag.

Tested (compilation tests) with build-many-glibcs.py.

* sysdeps/microblaze/bits/setjmp.h (__jmp_buf): Give struct tag
__jmp_buf_internal_tag.

ChangeLog
sysdeps/microblaze/bits/setjmp.h

index 0278dff4cc9dcef1801abc4c49f922fcc1012af9..7ab73a7814485c36a1fe8bab9b8f29a3d716e87e 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2017-01-04  Joseph Myers  <joseph@codesourcery.com>
 
+       * sysdeps/microblaze/bits/setjmp.h (__jmp_buf): Give struct tag
+       __jmp_buf_internal_tag.
+
        * sysdeps/mips/mips32/sfp-machine.h (_FP_CHOOSENAN): Always
        preserve NaN payload if [__mips_nan2008].
        * sysdeps/mips/mips64/sfp-machine.h (_FP_CHOOSENAN): Likewise.
index d54db9c12c6475fcdf94d12efff89ebacc85dc05..fd175dac2b28c49c0d6bd3d8ffd403c67bc4d741 100644 (file)
@@ -25,7 +25,7 @@
 # error "Never include <bits/setjmp.h> directly; use <setjmp.h> instead."
 #endif
 
-typedef struct
+typedef struct __jmp_buf_internal_tag
   {
     /* There are 21 4-byte registers that should be saved:
        r1, r2, r13-r31. Actually, there seems no need to save