mirror of
https://gitlab.com/openconnect/ocserv.git
synced 2026-02-10 08:46:58 +08:00
183 lines
4.9 KiB
YAML
183 lines
4.9 KiB
YAML
stages:
|
|
- testing
|
|
- deploy
|
|
|
|
variables:
|
|
BUILD_IMAGES_PROJECT: ocserv/build-images
|
|
DEBIAN_BUILD: buildenv-debian-stretch
|
|
FEDORA_BUILD: buildenv-fedora
|
|
CENTOS7_BUILD: buildenv-centos7
|
|
CENTOS6_BUILD: buildenv-centos6
|
|
|
|
Build/Debian:
|
|
stage: testing
|
|
image: $CI_REGISTRY/$BUILD_IMAGES_PROJECT:$DEBIAN_BUILD
|
|
script:
|
|
- git submodule update --init && autoreconf -fvi &&
|
|
./configure --without-nuttcp-tests --without-docker-tests && make -j$(nproc) && make check -j$(nproc)
|
|
tags:
|
|
- shared
|
|
except:
|
|
- tags
|
|
artifacts:
|
|
expire_in: 1 week
|
|
when: on_failure
|
|
paths:
|
|
- ./*.log
|
|
- ./tests/*.log
|
|
|
|
Build/Centos7:
|
|
stage: testing
|
|
image: $CI_REGISTRY/$BUILD_IMAGES_PROJECT:$CENTOS7_BUILD
|
|
script:
|
|
- git submodule update --init && autoreconf -fvi &&
|
|
./configure --without-docker-tests && make -j$(nproc) && make check -j$(nproc)
|
|
tags:
|
|
- shared
|
|
except:
|
|
- tags
|
|
artifacts:
|
|
expire_in: 1 week
|
|
when: on_failure
|
|
paths:
|
|
- ./*.log
|
|
- ./tests/*.log
|
|
|
|
Build/Fedora:
|
|
stage: testing
|
|
image: $CI_REGISTRY/$BUILD_IMAGES_PROJECT:$FEDORA_BUILD
|
|
script:
|
|
- git submodule update --init && autoreconf -fvi &&
|
|
./configure --disable-maintainer-mode --without-docker-tests --with-werror --enable-code-coverage && make -j$(nproc) && make check
|
|
&& make files-update && make dist && make local-code-coverage-output
|
|
tags:
|
|
- shared
|
|
except:
|
|
- tags
|
|
artifacts:
|
|
expire_in: 1 day
|
|
untracked: true
|
|
when: always
|
|
|
|
Build/Centos6:
|
|
stage: testing
|
|
image: $CI_REGISTRY/$BUILD_IMAGES_PROJECT:$CENTOS6_BUILD
|
|
script:
|
|
- sed -i 's/AM_PROG_AR//g' configure.ac
|
|
- git submodule update --init && autoreconf -fvi
|
|
- CFLAGS="$CFLAGS -I/usr/include/libev -I/usr/include/gnutls30" LIBGNUTLS_LIBS="-L/usr/lib64/gnutls30/ -lgnutls" PKG_CONFIG_LIBDIR="/usr/lib64/gnutls30/pkgconfig:/usr/lib64/pkgconfig" ./configure --disable-systemd --enable-local-libopts --without-docker-tests && make && make check -j$(nproc)
|
|
tags:
|
|
- shared
|
|
except:
|
|
- tags
|
|
artifacts:
|
|
expire_in: 1 week
|
|
when: on_failure
|
|
paths:
|
|
- ./*.log
|
|
- ./tests/*.log
|
|
|
|
Build/minimal:
|
|
stage: testing
|
|
image: $CI_REGISTRY/$BUILD_IMAGES_PROJECT:$CENTOS7_BUILD
|
|
script:
|
|
- git submodule update --init && autoreconf -fvi &&
|
|
./configure --without-docker-tests --without-libnl --without-liboath --without-pam --without-radius --without-utmp --without-libwrap --without-http-parser --without-lz4 --without-gssapi --without-pcl-lib --without-protobuf && make -j$(nproc) && make check -j$(nproc)
|
|
tags:
|
|
- shared
|
|
except:
|
|
- tags
|
|
artifacts:
|
|
expire_in: 1 week
|
|
when: on_failure
|
|
paths:
|
|
- ./*.log
|
|
- tests/*.log
|
|
|
|
asan/Fedora:
|
|
stage: testing
|
|
image: $CI_REGISTRY/$BUILD_IMAGES_PROJECT:$FEDORA_BUILD
|
|
script:
|
|
- git submodule update --init && autoreconf -fvi && CFLAGS="-fsanitize=address -g -O2" LDFLAGS="-static-libasan" &&
|
|
./configure --without-docker-tests && make -j$(nproc) && make check -j$(nproc)
|
|
tags:
|
|
- shared
|
|
except:
|
|
- tags
|
|
artifacts:
|
|
expire_in: 1 week
|
|
when: on_failure
|
|
paths:
|
|
- ./*.log
|
|
- tests/*.log
|
|
|
|
ubsan/Fedora:
|
|
stage: testing
|
|
image: $CI_REGISTRY/$BUILD_IMAGES_PROJECT:$FEDORA_BUILD
|
|
script:
|
|
- git submodule update --init && autoreconf -fvi && CFLAGS="-fsanitize=undefined -fsanitize=bool -fsanitize=alignment -fsanitize=null -fsanitize=bounds-strict -fsanitize=enum -fno-sanitize-recover -g -O2" LDFLAGS="-static-libuban" &&
|
|
./configure --without-docker-tests && make -j$(nproc) && make check -j$(nproc)
|
|
tags:
|
|
- shared
|
|
except:
|
|
- tags
|
|
artifacts:
|
|
expire_in: 1 week
|
|
when: on_failure
|
|
paths:
|
|
- ./*.log
|
|
- tests/*.log
|
|
|
|
static-analyzers/Fedora:
|
|
stage: testing
|
|
image: $CI_REGISTRY/$BUILD_IMAGES_PROJECT:$FEDORA_BUILD
|
|
script:
|
|
- autoreconf -fvi
|
|
- scan-build ./configure
|
|
- scan-build --status-bugs -o scan-build-src make -j$(nproc)
|
|
- cppcheck --force -q -Isrc/ -Isrc/occtl -Igl/ -I. --error-exitcode=1 src/ -i src/inih
|
|
tags:
|
|
- shared
|
|
except:
|
|
- tags
|
|
artifacts:
|
|
expire_in: 1 week
|
|
when: on_failure
|
|
paths:
|
|
- scan-build-src/*
|
|
|
|
Build/FreeBSD:
|
|
stage: testing
|
|
script:
|
|
- git submodule update --init && sh autogen.sh && mkdir build
|
|
- cd build && LIBS="-L/usr/local/lib" ../configure --disable-nls --without-root-tests &&
|
|
gmake -j$(sysctl hw.ncpu | awk '{print $2}') && gmake check -j$(sysctl hw.ncpu | awk '{print $2}')
|
|
tags:
|
|
- freebsd
|
|
only:
|
|
- branches@ocserv/ocserv
|
|
except:
|
|
- tags
|
|
artifacts:
|
|
expire_in: 1 week
|
|
when: on_failure
|
|
paths:
|
|
- build/*.log
|
|
- build/tests/*.log
|
|
|
|
pages:
|
|
stage: deploy
|
|
image: $CI_REGISTRY/$BUILD_IMAGES_PROJECT:$FEDORA_BUILD
|
|
script:
|
|
mkdir -p public/coverage && make V=1 CODE_COVERAGE_OUTPUT_DIRECTORY=public/coverage CODE_COVERAGE_BRANCH_COVERAGE=1 code-coverage-capture &&
|
|
make CODE_COVERAGE_OUTPUT_DIRECTORY=public/coverage local-code-coverage-output
|
|
tags:
|
|
- shared
|
|
dependencies:
|
|
- Build/Fedora
|
|
only:
|
|
- master
|
|
artifacts:
|
|
paths:
|
|
- public
|