ci: use pre built docker containers for musl (#5759)
parent
c0fa31e75a
commit
2790890bc2
|
@ -2,6 +2,7 @@ name: CI
|
||||||
on: [push, pull_request]
|
on: [push, pull_request]
|
||||||
jobs:
|
jobs:
|
||||||
|
|
||||||
|
|
||||||
# v-fmt:
|
# v-fmt:
|
||||||
# runs-on: ubuntu-18.04
|
# runs-on: ubuntu-18.04
|
||||||
# steps:
|
# steps:
|
||||||
|
@ -51,25 +52,27 @@ jobs:
|
||||||
# - name: Test v binaries
|
# - name: Test v binaries
|
||||||
# run: ./v -silent build-vbinaries
|
# run: ./v -silent build-vbinaries
|
||||||
|
|
||||||
|
# Alpine docker pre-built container
|
||||||
alpine-docker-musl-gcc:
|
alpine-docker-musl-gcc:
|
||||||
name: alpine-musl
|
name: alpine-musl
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
container:
|
||||||
|
image: thevlang/vlang:alpine-build
|
||||||
env:
|
env:
|
||||||
V_CI_MUSL: 1
|
V_CI_MUSL: 1
|
||||||
steps:
|
|
||||||
|
|
||||||
|
volumes:
|
||||||
|
- ${{github.workspace}}:/opt/vlang
|
||||||
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
- name: Build V
|
- name: Build V
|
||||||
uses: spytheman/docker_alpine_v@v7.0
|
run: |
|
||||||
with:
|
make CC=clang
|
||||||
entrypoint: .github/workflows/alpine.build.sh
|
- name: Test V fixed tests
|
||||||
|
run: |
|
||||||
- name: Test V
|
v test-fixed
|
||||||
uses: spytheman/docker_alpine_v@v7.0
|
|
||||||
with:
|
|
||||||
entrypoint: .github/workflows/alpine.test.sh
|
|
||||||
|
|
||||||
macos:
|
macos:
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
|
@ -196,28 +199,52 @@ jobs:
|
||||||
- name: V self compilation with -autofree
|
- name: V self compilation with -autofree
|
||||||
run: ./v -o v2 -autofree cmd/v && ./v2 -o v3 -autofree cmd/v && ./v3 -o v4 -autofree cmd/v
|
run: ./v -o v2 -autofree cmd/v && ./v2 -o v3 -autofree cmd/v && ./v3 -o v4 -autofree cmd/v
|
||||||
|
|
||||||
|
|
||||||
|
# Ubuntu docker pre-built container
|
||||||
ubuntu-musl:
|
ubuntu-musl:
|
||||||
runs-on: ubuntu-18.04
|
name: ubuntu-musl
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
container:
|
||||||
|
image: thevlang/vlang:ubuntu-build
|
||||||
env:
|
env:
|
||||||
VFLAGS: -cc musl-gcc
|
|
||||||
V_CI_MUSL: 1
|
V_CI_MUSL: 1
|
||||||
|
V_CI_UBUNTU_MUSL: 1
|
||||||
|
VFLAGS: -cc musl-gcc
|
||||||
|
volumes:
|
||||||
|
- ${{github.workspace}}:/opt/vlang
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- name: Checkout
|
||||||
- uses: actions/setup-node@v1
|
uses: actions/checkout@v2
|
||||||
with:
|
|
||||||
node-version: 12.x
|
- name: Build V
|
||||||
- name: Install dependencies
|
run: |
|
||||||
run: sudo rm -f /etc/apt/sources.list.d/dotnetdev.list /etc/apt/sources.list.d/microsoft-prod.list; sudo apt-get update; sudo apt-get install --quiet -y musl musl-tools libssl-dev sqlite3 libsqlite3-dev libsdl2-dev libsdl2-ttf-dev libsdl2-mixer-dev libsdl2-image-dev valgrind
|
echo $VFLAGS && make -j4 && ./v -cg -o v cmd/v
|
||||||
- name: Build v
|
- name: Test V fixed tests
|
||||||
run: echo $VFLAGS && make -j4 && ./v -cg -o v cmd/v
|
run: |
|
||||||
# - name: Test v binaries
|
v test-fixed
|
||||||
# run: ./v -silent build-vbinaries
|
|
||||||
## - name: Test v->js
|
# ubuntu-musl:
|
||||||
## run: ./v -o hi.js examples/hello_v_js.v && node hi.js
|
# runs-on: ubuntu-18.04
|
||||||
- name: quick debug
|
# env:
|
||||||
run: ./v -stats vlib/strconv/format_test.v
|
# VFLAGS: -cc musl-gcc
|
||||||
- name: Fixed tests
|
# V_CI_MUSL: 1
|
||||||
run: ./v test-fixed
|
# steps:
|
||||||
|
# - uses: actions/checkout@v2
|
||||||
|
# - uses: actions/setup-node@v1
|
||||||
|
# with:
|
||||||
|
# node-version: 12.x
|
||||||
|
# - name: Install dependencies
|
||||||
|
# run: sudo rm -f /etc/apt/sources.list.d/dotnetdev.list /etc/apt/sources.list.d/microsoft-prod.list; sudo apt-get update; sudo apt-get install --quiet -y musl musl-tools libssl-dev sqlite3 libsqlite3-dev libsdl2-dev libsdl2-ttf-dev libsdl2-mixer-dev libsdl2-image-dev valgrind
|
||||||
|
# - name: Build v
|
||||||
|
# run: echo $VFLAGS && make -j4 && ./v -cg -o v cmd/v
|
||||||
|
# # - name: Test v binaries
|
||||||
|
# # run: ./v -silent build-vbinaries
|
||||||
|
# ## - name: Test v->js
|
||||||
|
# ## run: ./v -o hi.js examples/hello_v_js.v && node hi.js
|
||||||
|
# - name: quick debug
|
||||||
|
# run: ./v -stats vlib/strconv/format_test.v
|
||||||
|
# - name: Fixed tests
|
||||||
|
# run: ./v test-fixed
|
||||||
|
|
||||||
ubuntu-llvm-mingw:
|
ubuntu-llvm-mingw:
|
||||||
runs-on: ubuntu-18.04
|
runs-on: ubuntu-18.04
|
||||||
|
|
|
@ -8,14 +8,16 @@ const (
|
||||||
skip_test_files = [
|
skip_test_files = [
|
||||||
'vlib/net/http/http_httpbin_test.v',
|
'vlib/net/http/http_httpbin_test.v',
|
||||||
]
|
]
|
||||||
skip_on_musl = [
|
skip_on_musl = []string{}
|
||||||
'vlib/net/http/http_test.v',
|
skip_on_ubuntu_musl =
|
||||||
|
[
|
||||||
'vlib/net/http/cookie_test.v',
|
'vlib/net/http/cookie_test.v',
|
||||||
|
'vlib/net/http/http_test.v',
|
||||||
'vlib/net/websocket/ws_test.v'
|
'vlib/net/websocket/ws_test.v'
|
||||||
'vlib/sqlite/sqlite_test.v',
|
'vlib/sqlite/sqlite_test.v',
|
||||||
'vlib/orm/orm_test.v',
|
'vlib/orm/orm_test.v',
|
||||||
'vlib/clipboard/clipboard_test.v',
|
'vlib/clipboard/clipboard_test.v',
|
||||||
'vlib/v/gen/js/jsgen_test.v',
|
// 'vlib/v/gen/js/jsgen_test.v',
|
||||||
]
|
]
|
||||||
skip_on_linux = []string{}
|
skip_on_linux = []string{}
|
||||||
skip_on_non_linux = [
|
skip_on_non_linux = [
|
||||||
|
@ -49,6 +51,9 @@ fn main() {
|
||||||
if os.getenv('V_CI_MUSL').len > 0 {
|
if os.getenv('V_CI_MUSL').len > 0 {
|
||||||
tsession.skip_files << skip_on_musl
|
tsession.skip_files << skip_on_musl
|
||||||
}
|
}
|
||||||
|
if os.getenv('V_CI_UBUNTU_MUSL').len > 0 {
|
||||||
|
tsession.skip_files << skip_on_ubuntu_musl
|
||||||
|
}
|
||||||
$if !linux {
|
$if !linux {
|
||||||
tsession.skip_files << skip_on_non_linux
|
tsession.skip_files << skip_on_non_linux
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,7 +13,7 @@ fn test_all() {
|
||||||
eprintln('You can still do it by setting FORCE_VALGRIND_TEST=1 .')
|
eprintln('You can still do it by setting FORCE_VALGRIND_TEST=1 .')
|
||||||
exit(0)
|
exit(0)
|
||||||
}
|
}
|
||||||
if os.getenv('V_CI_MUSL').len > 0 {
|
if os.getenv('V_CI_UBUNTU_MUSL').len > 0 {
|
||||||
eprintln('This test is disabled for musl.')
|
eprintln('This test is disabled for musl.')
|
||||||
exit(0)
|
exit(0)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue