image: registry.gitlab.com/mgerhardy/engine-docker:master stages: - build - test - analyse variables: CCACHE_BASEDIR: ${CI_PROJECT_DIR} CCACHE_DIR: ${CI_PROJECT_DIR}/ccache BUILD_DIR: ${CI_PROJECT_DIR}/build cache: paths: - ccache/ - build/ build-unity: stage: build script: - cmake -H. -B${BUILD_DIR}/default - make -j 4 all -C ${BUILD_DIR}/default artifacts: paths: - build/compile_commands.json build-non-unity: stage: build script: - cmake -H. -B${BUILD_DIR}/non-unity -DDISABLE_UNITY=On - make -j 4 all -C ${BUILD_DIR}/non-unity artifacts: paths: - build/compile_commands.json .test: variables: POSTGRES_DB: enginetest POSTGRES_USER: engine POSTGRES_PASSWORD: engine DB_HOST: postgres DB_USER: engine DB_PASSWORD: engine DB_NAME: enginetest services: - postgres:latest stage: test dependencies: - build script: - make -j 4 tests-run artifacts: reports: junit: build/*/gtest.xml .analyse:cppcheck: stage: analyse script: - cppcheck --xml-version=2 -j 4 --enable=all --config-exclude=contrib/libs/ --project=build/compile_commands.json src 2> cppcheck.xml artifacts: paths: - cppcheck.xml .analyse:valgrind: stage: analyse dependencies: - build script: - make -j 4 tests-memcheck artifacts: paths: - build/memcheck*.xml .pages: script: - make doc - mv build/html/ public/ artifacts: paths: - public only: - master