aboutsummaryrefslogtreecommitdiff
path: root/libffi/configure
diff options
context:
space:
mode:
authorRainer Orth <ro@TechFak.Uni-Bielefeld.DE>2008-12-19 14:59:42 +0000
committerRainer Orth <ro@gcc.gnu.org>2008-12-19 14:59:42 +0000
commit4d3d40782b52309b18aa2ae7f99a82d58044d5ad (patch)
tree0015f236039dc18cb0d69c465abfae9a5714bac7 /libffi/configure
parentfda2cea18b1db62338a5868bdf5ee2c9509a1752 (diff)
downloadgcc-4d3d40782b52309b18aa2ae7f99a82d58044d5ad.zip
gcc-4d3d40782b52309b18aa2ae7f99a82d58044d5ad.tar.gz
gcc-4d3d40782b52309b18aa2ae7f99a82d58044d5ad.tar.bz2
re PR libffi/26048 (libffi doesn't build on Solaris 10/x86 with native assembler)
PR libffi/26048 * configure.ac (HAVE_AS_X86_PCREL): New test. * configure: Regenerate. * fficonfig.h.in: Regenerate. * src/x86/sysv.S [!FFI_NO_RAW_API]: Precalculate RAW_CLOSURE_CIF_OFFSET, RAW_CLOSURE_FUN_OFFSET, RAW_CLOSURE_USER_DATA_OFFSET for the Solaris 10/x86 assembler. (.eh_frame): Only use SYMBOL-. iff HAVE_AS_X86_PCREL. * src/x86/unix64.S (.Lstore_table): Move to .text section. (.Lload_table): Likewise. (.eh_frame): Only use SYMBOL-. iff HAVE_AS_X86_PCREL. From-SVN: r142835
Diffstat (limited to 'libffi/configure')
-rwxr-xr-xlibffi/configure25
1 files changed, 25 insertions, 0 deletions
diff --git a/libffi/configure b/libffi/configure
index aaf3b81..c40a859 100755
--- a/libffi/configure
+++ b/libffi/configure
@@ -13263,6 +13263,31 @@ _ACEOF
fi
fi
+if test x$TARGET = xX86 || test x$TARGET = xX86_64; then
+ echo "$as_me:$LINENO: checking assembler supports pc related relocs" >&5
+echo $ECHO_N "checking assembler supports pc related relocs... $ECHO_C" >&6
+if test "${libffi_cv_as_x86_pcrel+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+
+ libffi_cv_as_x86_pcrel=yes
+ echo '.text; foo: nop; .data; .long foo-.; .text' > conftest.s
+ if $CC $CFLAGS -c conftest.s 2>&1 | grep -i warning > /dev/null; then
+ libffi_cv_as_x86_pcrel=no
+ fi
+
+fi
+echo "$as_me:$LINENO: result: $libffi_cv_as_x86_pcrel" >&5
+echo "${ECHO_T}$libffi_cv_as_x86_pcrel" >&6
+ if test "x$libffi_cv_as_x86_pcrel" = xyes; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_AS_X86_PCREL 1
+_ACEOF
+
+ fi
+fi
+
echo "$as_me:$LINENO: checking whether .eh_frame section should be read-only" >&5
echo $ECHO_N "checking whether .eh_frame section should be read-only... $ECHO_C" >&6
if test "${libffi_cv_ro_eh_frame+set}" = set; then