Skip to content

Commit

Permalink
ci: check public headers compile with c89 pedantic errors
Browse files Browse the repository at this point in the history
  • Loading branch information
64 committed Oct 20, 2024
1 parent d83776b commit 6614f67
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,19 @@ jobs:
- name: Build mlibc
run: 'xbstrap install ${{matrix.builds}}'
working-directory: build/
- name: Check public headers conform to C89
if: ${{matrix.builds == 'mlibc-headers-only'}}
working-directory: build/
run: |
GCC_ARCH="${{matrix.arch}}"
case "$GCC_ARCH" in
"x86")
GCC_ARCH="i386"
;;
esac
printf -- '-include\0%s\0' packages/${{matrix.builds}}/usr/include/**.h | \
sed 's/complex.h/stdio.h/' | \
xargs -0 $GCC_ARCH-linux-mlibc-gcc -x c -S /dev/null -o /dev/null -I packages/${{matrix.builds}}/usr/include -I packages/linux-headers/usr/include -nostdlib -std=c89 -Wpedantic -Werror -D__MLIBC_PEDANTIC_HEADER_CHECKER=1
- name: Test mlibc
run: 'meson test -v -C pkg-builds/${{matrix.builds}}'
working-directory: build/
Expand Down

0 comments on commit 6614f67

Please sign in to comment.