From 5b10a0198188d43fc07c271bc29ff1033e2ac9d3 Mon Sep 17 00:00:00 2001 From: Anthony Green Date: Wed, 15 Mar 2017 09:34:01 -0400 Subject: [PATCH] Work around dejagnu/clang problems --- testsuite/lib/libffi.exp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/testsuite/lib/libffi.exp b/testsuite/lib/libffi.exp index 6e5f7a47..1dcbecb3 100644 --- a/testsuite/lib/libffi.exp +++ b/testsuite/lib/libffi.exp @@ -175,7 +175,7 @@ proc libffi_target_compile { source dest type options } { global libffi_link_flags global libffi_include global target_triplet - + global compiler_vendor if { [target_info needs_status_wrapper]!="" && [info exists gluefile] } { lappend options "libs=${gluefile}" @@ -218,8 +218,11 @@ proc libffi_target_compile { source dest type options } { lappend options "libs= -lpthread" } + # this may be required for g++, but just confused clang. if { [string match "*.cc" $source] } { - lappend options "c++" + if { [string match $compiler_vendor "gnu"] } + lappend options "c++" + } } if { [string match "arc*-*-linux*" $target_triplet] } {