xref: /petsc/.gitlab-ci.yml (revision c592e2e15309d837d58840f5fc09b29b7f1ba248)
1stages:
2  - test
3  - ci-status
4
5variables:
6  GIT_STRATEGY: fetch
7  #GIT_DEPTH: 1
8  GIT_CLEAN_FLAGS: -ffdxq
9
10.test:
11  stage: test
12  image: jedbrown/mpich
13  before_script:
14    - echo nproc=$(nproc)
15    - cat /proc/cpuinfo
16  script:
17    - git config user.email "petsc@gitlab.none"
18    - git config user.name "petsc gitlab-ci"
19    - git fetch origin master
20    - git merge -m "test" FETCH_HEAD
21    - python3 ./configure --with-debugging=0 COPTFLAGS='-O -march=native' CXXOPTFLAGS='-O -march=native' FOPTFLAGS='-O -march=native' ${CONFIG_OPTS}
22    - make -j$(nproc) -l$(nproc)
23    - make -j$(nproc) -l$(nproc) -f gmakefile test search="${TEST_SEARCH}"
24
25mpich:
26  extends: .test
27  variables:
28    CONFIG_OPTS: --with-mpi-dir=/usr/local --with-fc=0
29    TEST_SEARCH: snes_tutorials-ex48%
30
31uni-complex-float-int64:
32  extends: .test
33  variables:
34    CONFIG_OPTS: <
35      --with-mpi=0
36      --with-scalar-type=complex --with-precision=single --with-64-bit-indices
37    TEST_SEARCH: ts_tutorials-ex11_adv_2d_quad_%
38
39.mcs_test:
40  stage: test
41  script:
42    - git config user.email "petsc@gitlab.none"
43    - git config user.name "petsc gitlab-ci"
44    - git fetch origin master
45    - git merge -m "test" FETCH_HEAD
46    - ./config/examples/${TEST_ARCH}.py
47    - make
48    - make check
49    - make cleantest allgtests-tap TIMEOUT=300
50
51.linux_mcs_test:
52  extends: .mcs_test
53  tags:
54    - mcs
55    - linux
56  before_script:
57    - hostname
58    - grep PRETTY_NAME /etc/os-release
59    - echo $(nproc)
60
61.freebsd_mcs_test:
62  extends: .mcs_test
63  tags:
64    - mcs
65    - freebsd
66  before_script:
67    - hostname
68    - freebsd-version
69    - echo $(sysctl -n hw.ncpu)
70
71linux-gcc-complex-opt:
72  extends: .linux_mcs_test
73  variables:
74    TEST_ARCH: arch-jenkins-linux-gcc-complex-opt
75
76linux-gcc-pkgs-opt:
77  extends: .linux_mcs_test
78  variables:
79    TEST_ARCH: arch-jenkins-linux-gcc-pkgs-opt
80
81linux-gcc-quad-64idx-dbg:
82  extends: .linux_mcs_test
83  variables:
84    TEST_ARCH: arch-jenkins-linux-gcc-quad-64idx-dbg
85
86freebsd-c-single-opt:
87  extends: .freebsd_mcs_test
88  variables:
89    TEST_ARCH: arch-jenkins-freebsd-c-single-opt
90
91freebsd-cxx-cmplx-64idx-dbg:
92  extends: .freebsd_mcs_test
93  stage: test
94  variables:
95    TEST_ARCH: arch-jenkins-freebsd-cxx-cmplx-64idx-dbg
96
97.status:
98  stage: ci-status
99  image: jedbrown/alpine-curl
100  script:
101    - BUILD_KEY=push BITBUCKET_NAMESPACE=petsc ./.gitlab-build-status.sh
102
103success:
104  extends: .status
105  variables:
106    BUILD_STATUS: passed
107  when: on_success
108
109failure:
110  extends: .status
111  variables:
112    BUILD_STATUS: failed
113  when: on_failure
114