This is the mail archive of the
libffi-discuss@sourceware.org
mailing list for the libffi project.
Re: libffi/configure.ac does not correctly determine writable eh_frame
- From: Anthony Green <green at redhat dot com>
- To: Ian Lance Taylor <iant at google dot com>
- Cc: libffi-discuss at sourceware dot org, doko at ubuntu dot com
- Date: Thu, 03 Feb 2011 17:45:43 -0500
- Subject: Re: libffi/configure.ac does not correctly determine writable eh_frame
- References: <mcr7heca0t3.fsf@google.com>
Ian Lance Taylor <iant@google.com> writes:
> In the version of libffi distributed with gcc, I see this in
> configure.ac:
>
> echo 'extern void foo (void); void bar (void) { foo (); foo (); }' > conftest.c
> if $CC $CFLAGS -S -fpic -fexceptions -o conftest.s conftest.c > /dev/null 2>&1; then
> if grep '.section.*eh_frame.*"a"' conftest.s > /dev/null; then
> libffi_cv_ro_eh_frame=yes
> elif grep '.section.*eh_frame.*#alloc' conftest.c \
> | grep -v '#write' > /dev/null; then
> libffi_cv_ro_eh_frame=yes
> fi
> fi
>
> This does not work with current gcc. When that code is compiled, no
> .eh_frame section is generated. Therefore the configure script assumes
> that a writable .eh_frame section is appropriate, even when it is not.
>
> This was detected due to a bug in gold; see http://gcc.gnu.org/PR47248
> for more details. However, this issue in libffi should be fixed
> independently of the gold bug fix.
Thanks Ian. Any suggestions on what do I need to do to now to force an
.eh_frame section?
AG
>
> Ian