On Wed, Nov 23, 2011 at 02:24:34PM -0700, Tom Tromey wrote: > >>>>> "Jakub" == Jakub Jelinek <ja...@redhat.com> writes: > > Jakub> As discussed in the PR, libjava fails to build against latest > Jakub> glibc, because prims.cc is compiled with -fnon-call-exceptions, > Jakub> uses ctype.h and libgcj isn't linked against -lsupc++ or -lstdc++. > Jakub> isspace in latest glibc is a throw() inline that calls a throw() > Jakub> function pointer. Unfortunately, with -fnon-call-exceptions > Jakub> the compiler doesn't have a guarantee that the function pointer > Jakub> that is being called is always valid (it is in glibc) and thus adds > Jakub> a __cxa_call_unexpected call if the call would throw and that symbol > Jakub> isn't satisfied during linking of libgcj and apps against it. > > BTW, it seems odd to me that this function is marked throw() instead of > __attribute__((nothrow)). The latter would avoid this problem entirely.
Well, appart from -fnon-call-exceptions it should make zero difference. I guess glibc uses throw() because it is a C++ standard feature, not an extension. Jakub