Skip to content

Commit c06fa58

Browse files
committed
Fix CI
build error in if_ruby.c: ``` if_ruby.c:1069:9: error: use of unknown builtin '__builtin_alloca_with_align' [-Wimplicit-function-declaration] buff = ALLOCA_N(char, RSTRING_LEN(str) + 1); ^ /usr/local/Cellar/ruby/2.6.0/include/ruby-2.6.0/ruby/ruby.h:1666:12: note: expanded from macro 'ALLOCA_N' (type*)__builtin_alloca_with_align((sizeof(type)*(n)), \ ^ if_ruby.c:1069:9: warning: cast to 'char *' from smaller integer type 'int' [-Wint-to-pointer-cast] /usr/local/Cellar/ruby/2.6.0/include/ruby-2.6.0/ruby/ruby.h:1666:5: note: expanded from macro 'ALLOCA_N' (type*)__builtin_alloca_with_align((sizeof(type)*(n)), \ ^ ``` Homebrew's ruby bottle for sierra has built by Xcode 9.x, which supports '__builtin_alloca_with_align' so 'ALLOCA_N' macro in ruby.h uses it, but Xcode 8.x doesn't support it then causes the above error. For workaround, should reinstall ruby from source in xcode8.3.
1 parent ddef471 commit c06fa58

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

.travis.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ sudo: false
4040

4141
script:
4242
- set -e
43+
- if [ "$TRAVIS_OSX_IMAGE" = "xcode8.3" ]; then brew reinstall --build-from-source ruby; fi
4344
- echo "Configuring MacVim" && echo -en "travis_fold:start:config\\r"
4445
- NPROC=$(getconf _NPROCESSORS_ONLN)
4546
- ./configure $CONFOPT --enable-fail-if-missing

0 commit comments

Comments
 (0)