diff options
author | Richard Henderson <rth@redhat.com> | 2010-09-02 17:02:53 -0700 |
---|---|---|
committer | Richard Henderson <rth@gcc.gnu.org> | 2010-09-02 17:02:53 -0700 |
commit | 92053f386a9561363151ae55fe3432c91366e1f4 (patch) | |
tree | 95dd2cc73ee9ca3c75943b817385d49ae016490c /gcc/configure.ac | |
parent | 36d9e52fff7f2bf5efff6c9e56b7bcd40b7d7963 (diff) | |
download | gcc-92053f386a9561363151ae55fe3432c91366e1f4.zip gcc-92053f386a9561363151ae55fe3432c91366e1f4.tar.gz gcc-92053f386a9561363151ae55fe3432c91366e1f4.tar.bz2 |
configure.ac (gcc_cv_as_cfi_advance_working): Use objdump instead of readelf in the test.
* configure.ac (gcc_cv_as_cfi_advance_working): Use objdump
instead of readelf in the test.
(gcc_cv_as_cfi_sections_directive): Check for correct relocation
in the .debug_frame section for coff targets.
* configure: Rebuild.
From-SVN: r163793
Diffstat (limited to 'gcc/configure.ac')
-rw-r--r-- | gcc/configure.ac | 24 |
1 files changed, 20 insertions, 4 deletions
diff --git a/gcc/configure.ac b/gcc/configure.ac index 1fcb87a..3308667 100644 --- a/gcc/configure.ac +++ b/gcc/configure.ac @@ -2405,7 +2405,7 @@ gcc_GAS_CHECK_FEATURE([cfi directives], gcc_cv_as_cfi_directive, gcc_cv_as_cfi_directive=yes ;; esac]) -if test $gcc_cv_as_cfi_directive = yes && test x$gcc_cv_readelf != x; then +if test $gcc_cv_as_cfi_directive = yes && test x$gcc_cv_objdump != x; then gcc_GAS_CHECK_FEATURE([working cfi advance], gcc_cv_as_cfi_advance_working, ,, [ .text @@ -2415,13 +2415,13 @@ gcc_GAS_CHECK_FEATURE([working cfi advance], gcc_cv_as_cfi_advance_working, .cfi_adjust_cfa_offset 128 .cfi_endproc], [[ -if $gcc_cv_readelf -wf conftest.o 2>/dev/null \ +if $gcc_cv_objdump -Wf conftest.o 2>/dev/null \ | grep 'DW_CFA_advance_loc[24]:[ ][ ]*75040[ ]' >/dev/null; then gcc_cv_as_cfi_advance_working=yes fi ]]) else - # no readelf, err on the side of caution + # no objdump, err on the side of caution gcc_cv_as_cfi_advance_working=no fi AC_DEFINE_UNQUOTED(HAVE_GAS_CFI_DIRECTIVE, @@ -2445,7 +2445,23 @@ gcc_GAS_CHECK_FEATURE([cfi sections directive], [ .text .cfi_sections .debug_frame, .eh_frame .cfi_startproc - .cfi_endproc]) + .cfi_endproc], +[case $target_os in + win32 | pe | cygwin* | mingw32* | uwin*) + # Need to check that we generated the correct relocation for the + # .debug_frame section. This was fixed for binutils 2.21. + gcc_cv_as_cfi_sections_directive=no + if test "x$gcc_cv_objdump" != x; then + if $gcc_cv_objdump -j .debug_frame -r conftest.o 2>/dev/null | \ + grep secrel > /dev/null; then + gcc_cv_as_cfi_sections_directive=yes + fi + fi + ;; + *) + gcc_cv_as_cfi_sections_directive=yes + ;; +esac]) AC_DEFINE_UNQUOTED(HAVE_GAS_CFI_SECTIONS_DIRECTIVE, [`if test $gcc_cv_as_cfi_sections_directive = yes; then echo 1; else echo 0; fi`], |