CI revamp (#157)
* Azure try to fix certificates on windows * Split ASM / no asm * switch to stable in travis * Split ASM tests in all CI * workflow name * typo * PPC fails at download or when compiling Nim for unknown reason * try to fix curl
This commit is contained in:
parent
5806cc4638
commit
6a2b172bbc
|
@ -7,26 +7,32 @@ jobs:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
max-parallel: 20
|
max-parallel: 20
|
||||||
matrix:
|
matrix:
|
||||||
branch: [devel] # [version-1-2, devel] - # 1.2 doesn't compile https://github.com/mratsim/constantine/pull/20#issuecomment-646327952
|
branch: [version-1-4] # [version-1-4, devel]
|
||||||
target:
|
target:
|
||||||
- os: linux
|
- os: linux
|
||||||
cpu: amd64
|
cpu: amd64
|
||||||
TEST_LANG: c
|
TEST_LANG: c
|
||||||
|
BACKEND: NO_ASM
|
||||||
- os: linux
|
- os: linux
|
||||||
cpu: amd64
|
cpu: amd64
|
||||||
TEST_LANG: cpp
|
TEST_LANG: cpp
|
||||||
|
BACKEND: NO_ASM
|
||||||
- os: linux
|
- os: linux
|
||||||
cpu: i386
|
cpu: i386
|
||||||
TEST_LANG: c
|
TEST_LANG: c
|
||||||
|
BACKEND: NO_ASM
|
||||||
- os: linux
|
- os: linux
|
||||||
cpu: i386
|
cpu: i386
|
||||||
TEST_LANG: cpp
|
TEST_LANG: cpp
|
||||||
|
BACKEND: NO_ASM
|
||||||
- os: macos
|
- os: macos
|
||||||
cpu: amd64
|
cpu: amd64
|
||||||
TEST_LANG: c
|
TEST_LANG: c
|
||||||
|
BACKEND: NO_ASM
|
||||||
- os: macos
|
- os: macos
|
||||||
cpu: amd64
|
cpu: amd64
|
||||||
TEST_LANG: cpp
|
TEST_LANG: cpp
|
||||||
|
BACKEND: NO_ASM
|
||||||
# TODO:
|
# TODO:
|
||||||
# 1. Modulo/reduce bug on 32-bit
|
# 1. Modulo/reduce bug on 32-bit
|
||||||
# 2. ModInverse bug on all windows
|
# 2. ModInverse bug on all windows
|
||||||
|
@ -42,6 +48,31 @@ jobs:
|
||||||
# - os: windows
|
# - os: windows
|
||||||
# cpu: i386
|
# cpu: i386
|
||||||
# TEST_LANG: cpp
|
# TEST_LANG: cpp
|
||||||
|
# ----------------------------
|
||||||
|
- os: linux
|
||||||
|
cpu: amd64
|
||||||
|
TEST_LANG: c
|
||||||
|
BACKEND: ASM
|
||||||
|
- os: linux
|
||||||
|
cpu: amd64
|
||||||
|
TEST_LANG: cpp
|
||||||
|
BACKEND: ASM
|
||||||
|
- os: linux
|
||||||
|
cpu: i386
|
||||||
|
TEST_LANG: c
|
||||||
|
BACKEND: ASM
|
||||||
|
- os: linux
|
||||||
|
cpu: i386
|
||||||
|
TEST_LANG: cpp
|
||||||
|
BACKEND: ASM
|
||||||
|
- os: macos
|
||||||
|
cpu: amd64
|
||||||
|
TEST_LANG: c
|
||||||
|
BACKEND: ASM
|
||||||
|
- os: macos
|
||||||
|
cpu: amd64
|
||||||
|
TEST_LANG: cpp
|
||||||
|
BACKEND: ASM
|
||||||
include:
|
include:
|
||||||
- target:
|
- target:
|
||||||
os: linux
|
os: linux
|
||||||
|
@ -52,7 +83,7 @@ jobs:
|
||||||
# - target:
|
# - target:
|
||||||
# os: windows
|
# os: windows
|
||||||
# builder: windows-2019
|
# builder: windows-2019
|
||||||
name: '${{ matrix.target.os }}-${{ matrix.target.cpu }}-${{ matrix.target.TEST_LANG }} (${{ matrix.branch }})'
|
name: '${{ matrix.target.os }}-${{ matrix.target.cpu }}-${{ matrix.target.TEST_LANG }}-${{ matrix.target.BACKEND }} (${{ matrix.branch }})'
|
||||||
runs-on: ${{ matrix.builder }}
|
runs-on: ${{ matrix.builder }}
|
||||||
steps:
|
steps:
|
||||||
- name: Cancel Previous Runs
|
- name: Cancel Previous Runs
|
||||||
|
@ -203,28 +234,28 @@ jobs:
|
||||||
nimble refresh
|
nimble refresh
|
||||||
nimble install -y gmp stew jsony
|
nimble install -y gmp stew jsony
|
||||||
- name: Run Constantine tests (with Assembler & with GMP)
|
- name: Run Constantine tests (with Assembler & with GMP)
|
||||||
if: (runner.os == 'Linux' || runner.os == 'macOS') && matrix.target.cpu == 'amd64'
|
if: (runner.os == 'Linux' || runner.os == 'macOS') && matrix.target.BACKEND == 'ASM' && matrix.target.cpu != 'i386'
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
export UCPU="$cpu"
|
export UCPU="$cpu"
|
||||||
cd constantine
|
cd constantine
|
||||||
nimble test_parallel
|
nimble test_parallel
|
||||||
- name: Run Constantine tests (no Assembler & with GMP)
|
- name: Run Constantine tests (no Assembler & with GMP)
|
||||||
if: (runner.os == 'Linux' || runner.os == 'macOS') && matrix.target.cpu == 'amd64'
|
if: (runner.os == 'Linux' || runner.os == 'macOS') && matrix.target.BACKEND == 'NO_ASM' && matrix.target.cpu != 'i386'
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
export UCPU="$cpu"
|
export UCPU="$cpu"
|
||||||
cd constantine
|
cd constantine
|
||||||
nimble test_parallel_no_assembler
|
nimble test_parallel_no_assembler
|
||||||
- name: Run Constantine tests (without GMP)
|
- name: Run Constantine tests (without GMP)
|
||||||
if: runner.os == 'Linux' && matrix.target.cpu == 'i386'
|
if: runner.os == 'Linux' && matrix.target.BACKEND == 'ASM' && matrix.target.cpu == 'i386'
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
export UCPU="$cpu"
|
export UCPU="$cpu"
|
||||||
cd constantine
|
cd constantine
|
||||||
nimble test_parallel_no_gmp
|
nimble test_parallel_no_gmp
|
||||||
- name: Run Constantine tests (without Assembler or GMP)
|
- name: Run Constantine tests (without Assembler or GMP)
|
||||||
if: runner.os == 'Linux' && matrix.target.cpu == 'i386'
|
if: runner.os == 'Linux' && matrix.target.BACKEND == 'NO_ASM' && matrix.target.cpu == 'i386'
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
export UCPU="$cpu"
|
export UCPU="$cpu"
|
||||||
|
|
14
.travis.yml
14
.travis.yml
|
@ -22,15 +22,15 @@ matrix:
|
||||||
arch: arm64
|
arch: arm64
|
||||||
env:
|
env:
|
||||||
- ARCH=arm64
|
- ARCH=arm64
|
||||||
- CHANNEL=devel
|
- CHANNEL=stable
|
||||||
compiler: gcc
|
compiler: gcc
|
||||||
|
|
||||||
- dist: bionic
|
# - dist: bionic
|
||||||
arch: ppc64le
|
# arch: ppc64le
|
||||||
env:
|
# env:
|
||||||
- ARCH=powerpc64el
|
# - ARCH=powerpc64el
|
||||||
- CHANNEL=devel
|
# - CHANNEL=stable
|
||||||
compiler: gcc
|
# compiler: gcc
|
||||||
|
|
||||||
# "Unknown processor s390x"
|
# "Unknown processor s390x"
|
||||||
# - dist: bionic
|
# - dist: bionic
|
||||||
|
|
|
@ -10,26 +10,30 @@ strategy:
|
||||||
# UCPU: i686
|
# UCPU: i686
|
||||||
# CHANNEL: devel
|
# CHANNEL: devel
|
||||||
# TEST_LANG: c
|
# TEST_LANG: c
|
||||||
Windows_devel_64bit:
|
Windows_stable_noasm_64bit:
|
||||||
VM: 'windows-latest'
|
VM: 'windows-latest'
|
||||||
UCPU: amd64
|
UCPU: amd64
|
||||||
CHANNEL: devel
|
CHANNEL: stable
|
||||||
TEST_LANG: c
|
TEST_LANG: c
|
||||||
Windows_cpp_devel_64bit:
|
BACKEND: NO_ASM
|
||||||
|
Windows_cpp_stable_noasm_64bit:
|
||||||
VM: 'windows-latest'
|
VM: 'windows-latest'
|
||||||
UCPU: amd64
|
UCPU: amd64
|
||||||
CHANNEL: devel
|
CHANNEL: stable
|
||||||
TEST_LANG: cpp
|
TEST_LANG: cpp
|
||||||
Linux_devel_64bit:
|
BACKEND: NO_ASM
|
||||||
|
Linux_stable_noasm_64bit:
|
||||||
VM: 'ubuntu-18.04'
|
VM: 'ubuntu-18.04'
|
||||||
UCPU: amd64
|
UCPU: amd64
|
||||||
CHANNEL: devel
|
CHANNEL: stable
|
||||||
TEST_LANG: c
|
TEST_LANG: c
|
||||||
Linux_cpp_devel_64bit:
|
BACKEND: NO_ASM
|
||||||
|
Linux_cpp_stable_noasm_64bit:
|
||||||
VM: 'ubuntu-18.04'
|
VM: 'ubuntu-18.04'
|
||||||
UCPU: amd64
|
UCPU: amd64
|
||||||
CHANNEL: devel
|
CHANNEL: stable
|
||||||
TEST_LANG: cpp
|
TEST_LANG: cpp
|
||||||
|
BACKEND: NO_ASM
|
||||||
|
|
||||||
# Deactivated for now, this is cross-compilation and tricky to get right
|
# Deactivated for now, this is cross-compilation and tricky to get right
|
||||||
# Linux_devel_32bit:
|
# Linux_devel_32bit:
|
||||||
|
@ -38,11 +42,47 @@ strategy:
|
||||||
# CHANNEL: devel
|
# CHANNEL: devel
|
||||||
# TEST_LANG: c
|
# TEST_LANG: c
|
||||||
|
|
||||||
MacOS_devel_64bit:
|
MacOS_stable_noasm_64bit:
|
||||||
VM: 'macOS-10.15'
|
VM: 'macOS-10.15'
|
||||||
UCPU: amd64
|
UCPU: amd64
|
||||||
CHANNEL: devel
|
CHANNEL: stable
|
||||||
TEST_LANG: c
|
TEST_LANG: c
|
||||||
|
BACKEND: NO_ASM
|
||||||
|
|
||||||
|
# -------------------------------
|
||||||
|
|
||||||
|
# No assembly for windows
|
||||||
|
# Windows_devel_64bit:
|
||||||
|
# VM: 'windows-latest'
|
||||||
|
# UCPU: amd64
|
||||||
|
# CHANNEL: stable
|
||||||
|
# TEST_LANG: c
|
||||||
|
# BACKEND: ASM
|
||||||
|
# Windows_cpp_devel_64bit:
|
||||||
|
# VM: 'windows-latest'
|
||||||
|
# UCPU: amd64
|
||||||
|
# CHANNEL: stable
|
||||||
|
# TEST_LANG: cpp
|
||||||
|
# BACKEND: ASM
|
||||||
|
Linux_stable_asm_64bit:
|
||||||
|
VM: 'ubuntu-18.04'
|
||||||
|
UCPU: amd64
|
||||||
|
CHANNEL: stable
|
||||||
|
TEST_LANG: c
|
||||||
|
BACKEND: ASM
|
||||||
|
Linux_cpp_stable_asm_64bit:
|
||||||
|
VM: 'ubuntu-18.04'
|
||||||
|
UCPU: amd64
|
||||||
|
CHANNEL: stable
|
||||||
|
TEST_LANG: cpp
|
||||||
|
BACKEND: ASM
|
||||||
|
MacOS_stable_asm_64bit:
|
||||||
|
VM: 'macOS-10.15'
|
||||||
|
UCPU: amd64
|
||||||
|
CHANNEL: stable
|
||||||
|
TEST_LANG: c
|
||||||
|
BACKEND: ASM
|
||||||
|
|
||||||
pool:
|
pool:
|
||||||
vmImage: $(VM)
|
vmImage: $(VM)
|
||||||
|
|
||||||
|
@ -188,6 +228,12 @@ steps:
|
||||||
popd # exit NimBinaries
|
popd # exit NimBinaries
|
||||||
displayName: 'Building Nim'
|
displayName: 'Building Nim'
|
||||||
|
|
||||||
|
# https://forum.nim-lang.org/t/7494
|
||||||
|
- powershell: |
|
||||||
|
bitsadmin.exe /rawreturn /transfer "cURL-certicates" /priority FOREGROUND https://curl.se/ca/cacert.pem $pwd\NimBinaries\nim-$(CHANNEL)\bin\cacert.pem
|
||||||
|
displayName: 'cURL certificates (Windows)'
|
||||||
|
condition: eq(variables['Agent.OS'], 'Windows_NT')
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
echo "##vso[task.prependpath]$pwd\NimBinaries\nim-$(CHANNEL)\bin"
|
echo "##vso[task.prependpath]$pwd\NimBinaries\nim-$(CHANNEL)\bin"
|
||||||
displayName: 'Set env variable (Windows)'
|
displayName: 'Set env variable (Windows)'
|
||||||
|
@ -230,14 +276,14 @@ steps:
|
||||||
export ucpu=${UCPU}
|
export ucpu=${UCPU}
|
||||||
nimble test_parallel
|
nimble test_parallel
|
||||||
displayName: 'Testing Constantine with Assembler and with GMP'
|
displayName: 'Testing Constantine with Assembler and with GMP'
|
||||||
condition: ne(variables['Agent.OS'], 'Windows_NT')
|
condition: and(ne(variables['Agent.OS'], 'Windows_NT'), eq(variables['BACKEND'], 'ASM'))
|
||||||
|
|
||||||
- bash: |
|
- bash: |
|
||||||
echo "PATH=${PATH}"
|
echo "PATH=${PATH}"
|
||||||
export ucpu=${UCPU}
|
export ucpu=${UCPU}
|
||||||
nimble test_parallel_no_assembler
|
nimble test_parallel_no_assembler
|
||||||
displayName: 'Testing Constantine without Assembler and with GMP'
|
displayName: 'Testing Constantine without Assembler and with GMP'
|
||||||
condition: ne(variables['Agent.OS'], 'Windows_NT')
|
condition: and(ne(variables['Agent.OS'], 'Windows_NT'), eq(variables['BACKEND'], 'NO_ASM'))
|
||||||
|
|
||||||
- bash: |
|
- bash: |
|
||||||
echo "PATH=${PATH}"
|
echo "PATH=${PATH}"
|
||||||
|
|
Loading…
Reference in New Issue