Skip to content

ci: Verify configure and CMake builds at the makefile warning levels - #983

Open
inverteum wants to merge 1 commit into
pnggroup:libpng18from
inverteum:677-verify-warnings
Open

inverteum wants to merge 1 commit into
pnggroup:libpng18from
inverteum:677-verify-warnings

Conversation

@inverteum

Copy link
Copy Markdown

Adds a Linux GitHub Actions workflow that runs the existing configure and CMake verification scripts with the warning flags already used by scripts/makefile.gcc and scripts/makefile.clang.

On pull requests and pushes to libpng16, libpng18, and develop, .github/workflows/verify-warnings.yml runs ci/ci_verify_configure.sh and ci/ci_verify_cmake.sh with CI_CC=gcc and:

-O2 -pedantic-errors -Wall -Wextra -Wundef -Wcast-align -Wconversion -Wshadow -Wpointer-arith -Wwrite-strings -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes

That is the makefiles' -O2 plus STDC, WARN, and WARNMORE. Those makefiles do not pass -Werror, and this workflow does not either. -pedantic-errors is the only flag that fails the build. The current tree still prints other warnings and still links and tests.

This is the configure and CMake warning-level check requested in #677 on 10 Jul 2025. The Linux, macOS, and Windows workflows added later already build and test, and they do not pass these flags. This workflow does not replace them. It is Ubuntu only, two jobs, and it runs the scripts' usual build, test, install, and clean steps.

Checked locally against 5408ee7a2e56555cc4b0acc4051ae241fee38cf3 with gcc 13.3.0: configure make check 37/37, CMake ctest 38/38, including install and clean. The same flags also passed with clang 18.1.3. The workflow pins gcc, which is the compiler on ubuntu-latest.

Refs #677

Run the existing configure and CMake verification scripts on Linux
for pull requests and pushes, passing the warning flags from
scripts/makefile.gcc and scripts/makefile.clang.

Refs: pnggroup#677
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant