1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-11-03 10:26:39 +00:00

Merge branch 'coverity' into 'master'

Fix coverity builds

See merge request OpenMW/openmw!4826
This commit is contained in:
psi29a 2025-08-04 06:55:06 +00:00
commit ef3f52d6a4
2 changed files with 26 additions and 9 deletions

View file

@ -108,8 +108,8 @@ Coverity:
- ccache/
variables:
CCACHE_SIZE: 2G
CC: clang-12
CXX: clang++-12
CC: clang
CXX: clang++
CMAKE_BUILD_TYPE: Debug
CMAKE_CXX_FLAGS_DEBUG: -O0
before_script:
@ -125,18 +125,34 @@ Coverity:
- ccache -z -M "${CCACHE_SIZE}"
- CI/before_script.linux.sh
- cov-analysis-linux64-*/bin/cov-configure --template --comptype prefix --compiler ccache
# Remove the specific targets and build everything once we can do it under 3h
- cov-analysis-linux64-*/bin/cov-build --dir cov-int cmake --build build -- -j $(nproc)
- ccache -svv
after_script:
- tar cfz cov-int.tar.gz cov-int
- curl https://scan.coverity.com/builds?project=$COVERITY_SCAN_PROJECT_NAME
--form token=$COVERITY_SCAN_TOKEN --form email=$GITLAB_USER_EMAIL
--form file=@cov-int.tar.gz --form version="$CI_COMMIT_REF_NAME:$CI_COMMIT_SHORT_SHA"
--form description="CI_COMMIT_SHORT_SHA / $CI_COMMIT_TITLE / $CI_COMMIT_REF_NAME:$CI_PIPELINE_ID"
- echo "OPENMW_JOB_ID=$CI_JOB_ID" >> build.env
artifacts:
expire_in: 1 day
paths:
- /builds/OpenMW/openmw/cov-int/build-log.txt
- /builds/OpenMW/openmw/cov-int.tar.gz
reports:
dotenv: build.env
Coverity_Upload:
image: ubuntu:24.04
stage: build
rules:
- if: $CI_PIPELINE_SOURCE == "schedule"
before_script:
- CI/install_debian_deps.sh coverity_upload
script:
- echo "$CI_API_V4_URL/projects/$CI_PROJECT_ID/jobs/$OPENMW_JOB_ID/artifacts/cov-int.tar.gz"
- curl https://scan.coverity.com/builds?project=$COVERITY_SCAN_PROJECT_NAME
--form token=$COVERITY_SCAN_TOKEN --form email=$GITLAB_USER_EMAIL
--form version="$CI_COMMIT_REF_NAME:$CI_COMMIT_SHORT_SHA"
--form description="CI_COMMIT_SHORT_SHA / $CI_COMMIT_TITLE / $CI_COMMIT_REF_NAME:$CI_PIPELINE_ID"
--form url="$CI_API_V4_URL/projects/$CI_PROJECT_ID/jobs/$OPENMW_JOB_ID/artifacts/cov-int.tar.gz"
needs:
- Coverity
Ubuntu_GCC:
extends: .Ubuntu

View file

@ -11,7 +11,8 @@ print_help() {
declare -rA GROUPED_DEPS=(
[gcc]="binutils gcc build-essential cmake ccache curl unzip git pkg-config mold"
[clang]="binutils clang make cmake ccache curl unzip git pkg-config mold"
[coverity]="binutils clang-12 make cmake ccache curl unzip git pkg-config"
[coverity]="binutils clang make cmake ccache curl unzip git pkg-config file"
[coverity_upload]="curl"
[gcc_preprocess]="
binutils
build-essential