summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-11-03 23:10:57 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-11-03 23:10:57 +0000
commit0f28fe2bcdc04126ea23bf92304585981adeda97 (patch)
tree9f9f68e857cf3e5fd8a9581bf1da9a012516a7bd /configure.ac
parent7b845212071d231139195cb7a8fed076dc38983f (diff)
configure.ac: set CC_WRAPPER by checking message
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65520 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac9
1 files changed, 4 insertions, 5 deletions
diff --git a/configure.ac b/configure.ac
index 70d8ed9..622850e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -257,14 +257,13 @@ AS_CASE(["$build_os"],
# Xcode linker warns for deprecated architecture and wrongly
# installed TBD files.
CC_WRAPPER=""
- AS_IF([! $CC -E -xc - <<SRC >/dev/null 2>&1], [
- @%:@if defined __APPLE_CC__ && defined __clang_major__ && __clang_major__ >= 10
- @%:@error ignore linker warnings
- @%:@endif
-SRC
+ echo 'int main(void) {return 0;}' > conftest.c
+ AS_IF([$CC -framework Foundation -o conftest conftest.c 2>&1 |
+ grep '^ld: warning: text-based stub file' >/dev/null], [
CC_WRAPPER=`cd -P "$srcdir/tool" && pwd`/darwin-cc
CC="$CC_WRAPPER $CC"
])
+ rm -fr conftest*
])
cc_version=