Merge branch 'cb/ci-build-pedantic'

CI update.

* cb/ci-build-pedantic:
  ci: run a pedantic build as part of the GitHub workflow
This commit is contained in:
Junio C Hamano 2021-09-10 11:46:32 -07:00
Родитель 9762646ee4 cebead1ebf
Коммит 613204b948
3 изменённых файлов: 13 добавлений и 3 удалений

2
.github/workflows/main.yml поставляемый
Просмотреть файл

@ -259,6 +259,8 @@ jobs:
image: alpine image: alpine
- jobname: Linux32 - jobname: Linux32
image: daald/ubuntu32:xenial image: daald/ubuntu32:xenial
- jobname: pedantic
image: fedora
env: env:
jobname: ${{matrix.vector.jobname}} jobname: ${{matrix.vector.jobname}}
runs-on: ubuntu-latest runs-on: ubuntu-latest

Просмотреть файл

@ -15,4 +15,8 @@ linux-musl)
apk add --update build-base curl-dev openssl-dev expat-dev gettext \ apk add --update build-base curl-dev openssl-dev expat-dev gettext \
pcre2-dev python3 musl-libintl perl-utils ncurses >/dev/null pcre2-dev python3 musl-libintl perl-utils ncurses >/dev/null
;; ;;
pedantic)
dnf -yq update >/dev/null &&
dnf -yq install make gcc findutils diffutils perl python3 gettext zlib-devel expat-devel openssl-devel curl-devel pcre2-devel >/dev/null
;;
esac esac

Просмотреть файл

@ -10,6 +10,11 @@ windows*) cmd //c mklink //j t\\.prove "$(cygpath -aw "$cache_dir/.prove")";;
*) ln -s "$cache_dir/.prove" t/.prove;; *) ln -s "$cache_dir/.prove" t/.prove;;
esac esac
if test "$jobname" = "pedantic"
then
export DEVOPTS=pedantic
fi
make make
case "$jobname" in case "$jobname" in
linux-gcc) linux-gcc)
@ -35,10 +40,9 @@ linux-clang)
export GIT_TEST_DEFAULT_HASH=sha256 export GIT_TEST_DEFAULT_HASH=sha256
make test make test
;; ;;
linux-gcc-4.8) linux-gcc-4.8|pedantic)
# Don't run the tests; we only care about whether Git can be # Don't run the tests; we only care about whether Git can be
# built with GCC 4.8, as it errors out on some undesired (C99) # built with GCC 4.8 or with pedantic
# constructs that newer compilers seem to quietly accept.
;; ;;
*) *)
make test make test