summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author卜部昌平 <shyouhei@ruby-lang.org>2020-08-22 14:41:06 +0900
committer卜部昌平 <shyouhei@ruby-lang.org>2020-08-23 21:45:46 +0900
commit2c4c088aa377b46ba4209524b0188591a9736324 (patch)
tree53df6c4adda46321e15f2315bc2a60998f800d9c
parent2ddc67ffb6bd62550343db909bf5672d6d523682 (diff)
.github/workflows/compilers.yml: more compilers
Added some cross compilers that we can run on GitHub Workflow runner environments. Because they are cross compilers we cannot run the generated binary. The added matrix are compile-only.
Notes
Notes: Merged: https://github.com/ruby/ruby/pull/3447
-rw-r--r--.github/workflows/compilers.yml29
1 files changed, 24 insertions, 5 deletions
diff --git a/.github/workflows/compilers.yml b/.github/workflows/compilers.yml
index a744ce1022b..47ec2c3d3ac 100644
--- a/.github/workflows/compilers.yml
+++ b/.github/workflows/compilers.yml
@@ -8,12 +8,13 @@ on: [push, pull_request]
env:
default_cc: clang-11
append_cc: ''
+ crosshost: ''
# -O1 is faster than -O3 in our tests... Majority of time are consumed trying
# to optimize binaries. Also Github Actions runs on a relatively modern CPU
# compared to, say, GCC 4 or Clang 3. We don't specify `-march=native`
# because compilers tend not understand what the CPU is.
- optflags: '-O1 -march=x86-64 -mtune=generic'
+ optflags: '-O1'
# -g0 disables backtraces when SEGV. Do not set that.
debugflags: '-ggdb3'
@@ -64,6 +65,15 @@ jobs:
- { key: default_cc, name: clang-4.0, value: clang-4.0 }
- { key: default_cc, name: clang-3.9, value: clang-3.9 }
+ - { key: crosshost, name: aarch64-linux-gnu, value: aarch64-linux-gnu }
+# - { key: crosshost, name: arm-linux-gnueabi, value: arm-linux-gnueabi }
+# - { key: crosshost, name: arm-linux-gnueabihf, value: arm-linux-gnueabihf }
+# - { key: crosshost, name: i686-w64-mingw32, value: i686-w64-mingw32 }
+# - { key: crosshost, name: powerpc-linux-gnu, value: powerpc-linux-gnu }
+ - { key: crosshost, name: powerpc64le-linux-gnu, value: powerpc64le-linux-gnu }
+ - { key: crosshost, name: s390x-linux-gnu, value: s390x-linux-gnu }
+ - { key: crosshost, name: x86_64-w64-mingw32, value: x86_64-w64-mingw32 }
+
- { key: append_cc, name: c99, value: '-std=c99 -Werror=pedantic -pedantic-errors' }
- { key: append_cc, name: c11, value: '-std=c11 -Werror=pedantic -pedantic-errors' }
- { key: append_cc, name: c17, value: '-std=c17 -Werror=pedantic -pedantic-errors' }
@@ -162,10 +172,19 @@ jobs:
- name: Run configure
working-directory: build
run: |
- ../src/configure -C \
- ${default_configure} \
- ${append_configure} \
- --with-gcc="${default_cc} ${append_cc}"
+ if [ -n "${crosshost}" ]; then
+ ../src/configure -C \
+ ${default_configure} \
+ ${append_configure} \
+ --host="${crosshost}"
+ else
+ ../src/configure -C \
+ ${default_configure} \
+ ${append_configure} \
+ --with-gcc="${default_cc} ${append_cc}"
+ fi
+ - run: $make extract-extlibs
+ working-directory: build
- run: $make incs
working-directory: build
- run: $make