gitlab-ci, build: Fail on warnings on Clang builds making them more useful
Thanks to various improvements on babl and GEGL repos they now build cleanly. So, let's take advantage of Clang senstive semantic analysis on future builds. For now, this is limited to such projects and on GNU Clang and Apple Clang, since there is still a bit of work to do on Clang-CL (MSVC) side.
This commit is contained in:
parent
24f8f6f68b
commit
6e8928e823
2 changed files with 5 additions and 3 deletions
|
|
@ -122,6 +122,7 @@ stages:
|
|||
CC_LD: lld
|
||||
CXX_LD: lld
|
||||
TOOLCHAIN: "clang lld"
|
||||
WARN_AS_ERROR_ON_CI: '-Dwerror=true'
|
||||
VARIANT: -clang
|
||||
- if: '$GIMP_CI_RASTER_ICONS != null || "$[[ inputs.test_pipeline ]]" =~ /.*GIMP_CI_RASTER_ICONS.*/'
|
||||
variables:
|
||||
|
|
@ -244,14 +245,14 @@ deps-debian-nonreloc:
|
|||
## Build babl
|
||||
- echo "RUN printf \"\e[0Ksection_start:\`date +%s\`:babl_build[collapsed=true]\r\e[0KBuilding babl\n\"" >> Dockerfile2;
|
||||
- echo "RUN git clone --branch \"\$([ \"$CI_COMMIT_TAG\" ] && echo \"\$(git ls-remote --tags --exit-code --refs https://gitlab.gnome.org/GNOME/babl.git | grep -oi \"BABL_[0-9]*_[0-9]*_[0-9]*\" | sort --version-sort | tail -1)\" || echo \"master\")\" --depth=${GIT_DEPTH} https://gitlab.gnome.org/GNOME/babl.git" babl >> Dockerfile2;
|
||||
- echo "RUN meson setup babl/_build-${RUNNER} babl -Dprefix=\"${GIMP_PREFIX}\" $RELOCATABLE_OPTION $PKGCONF_RELOCATABLE_OPTION" >> Dockerfile2;
|
||||
- echo "RUN meson setup babl/_build-${RUNNER} babl -Dprefix=\"${GIMP_PREFIX}\" $RELOCATABLE_OPTION $PKGCONF_RELOCATABLE_OPTION $WARN_AS_ERROR_ON_CI" >> Dockerfile2;
|
||||
- echo "RUN ninja -C babl/_build-${RUNNER}" >> Dockerfile2;
|
||||
- echo "RUN ninja -C babl/_build-${RUNNER} install" >> Dockerfile2;
|
||||
- echo "RUN printf \"\e[0Ksection_end:\`date +%s\`:babl_build\r\e[0K\n\"" >> Dockerfile2;
|
||||
## Build GEGL
|
||||
- echo "RUN printf \"\e[0Ksection_start:\`date +%s\`:gegl_build[collapsed=true]\r\e[0KBuilding gegl\n\"" >> Dockerfile2;
|
||||
- echo "RUN git clone --branch \"\$([ \"$CI_COMMIT_TAG\" ] && echo \"\$(git ls-remote --tags --exit-code --refs https://gitlab.gnome.org/GNOME/gegl.git | grep -oi \"GEGL_[0-9]*_[0-9]*_[0-9]*\" | sort --version-sort | tail -1)\" || echo \"master\")\" --depth=${GIT_DEPTH} https://gitlab.gnome.org/GNOME/gegl.git" gegl >> Dockerfile2;
|
||||
- echo "RUN meson setup gegl/_build-${RUNNER} gegl -Dprefix=\"${GIMP_PREFIX}\" $RELOCATABLE_OPTION $PKGCONF_RELOCATABLE_OPTION" >> Dockerfile2;
|
||||
- echo "RUN meson setup gegl/_build-${RUNNER} gegl -Dprefix=\"${GIMP_PREFIX}\" $RELOCATABLE_OPTION $PKGCONF_RELOCATABLE_OPTION $WARN_AS_ERROR_ON_CI" >> Dockerfile2;
|
||||
- echo "RUN ninja -C gegl/_build-${RUNNER}" >> Dockerfile2;
|
||||
- echo "RUN ninja -C gegl/_build-${RUNNER} install" >> Dockerfile2;
|
||||
- echo "RUN printf \"\e[0Ksection_end:\`date +%s\`:gegl_build\r\e[0K\n\"" >> Dockerfile2;
|
||||
|
|
@ -660,6 +661,7 @@ gimp-win-eol:
|
|||
- if: '($GIMP_CI_MESON_APPLECLANG != null || "$[[ inputs.test_pipeline ]]" =~ /.*GIMP_CI_MESON_APPLECLANG.*/) && $CI_JOB_NAME !~ /.*-part.*/ && $CI_JOB_NAME !~ /.*dist-mac-.*/'
|
||||
variables:
|
||||
OPT_PREFIX: /opt/homebrew
|
||||
WARN_AS_ERROR_ON_CI: '-Dwerror=true'
|
||||
VARIANT: -homebrew
|
||||
tags:
|
||||
- macos
|
||||
|
|
|
|||
|
|
@ -100,7 +100,7 @@ self_build()
|
|||
|
||||
# Configure and build
|
||||
if [ ! -f "_build-$(uname -m)/build.ninja" ]; then
|
||||
meson setup _build-$(uname -m) -Dprefix="$GIMP_PREFIX" $PKGCONF_RELOCATABLE_OPTION \
|
||||
meson setup _build-$(uname -m) -Dprefix="$GIMP_PREFIX" $PKGCONF_RELOCATABLE_OPTION $WARN_AS_ERROR_ON_CI \
|
||||
-Dbuildtype=debugoptimized \
|
||||
-Dc_args="-I${OPT_PREFIX}/include" -Dcpp_args="-I${OPT_PREFIX}/include" -Dc_link_args="-L${OPT_PREFIX}/lib" -Dcpp_link_args="-L${OPT_PREFIX}/lib"
|
||||
fi
|
||||
|
|
|
|||
Loading…
Reference in a new issue