Skip to content

Fix warnings in macos-26 CI build #474

Fix warnings in macos-26 CI build

Fix warnings in macos-26 CI build #474

Workflow file for this run

#
# boxes - Command line filter to draw/remove ASCII boxes around text
# SPDX-FileCopyrightText: Copyright (c) 1999-2026 Thomas Jensen and the boxes contributors
# SPDX-License-Identifier: GPL-3.0-only
#
# This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
# License, version 3, as published by the Free Software Foundation.
# This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
# details.
# You should have received a copy of the GNU General Public License along with this program.
# If not, see <https://www.gnu.org/licenses/>.
#____________________________________________________________________________________________________________________
#====================================================================================================================
name: build
on: [push, pull_request, workflow_dispatch]
env:
TERM: xterm-color
jobs:
build-linux:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: add-packages
run: |
sudo apt-get update -y
sudo apt-get install -y git flex bison libunistring-dev libpcre2-dev libncurses-dev diffutils vim-common lcov libcmocka-dev
- name: make cov
run: make cov
- name: Run white-box tests
run: make utest
- name: Run sunny-day tests
run: make covtest-sunny
- name: Run black-box tests
run: make covtest
- name: Coveralls
uses: coverallsapp/github-action@v2
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
file: out/lcov-total.info
format: lcov
flag-name: run-linux
parallel: true
build-macos:
runs-on: macos-26
env:
BX_LEX: /opt/homebrew/opt/flex/bin/flex
BX_YACC: /opt/homebrew/opt/bison/bin/bison
CFLAGS_ADDTL: -I/opt/homebrew/include
LDFLAGS_ADDTL: -L/opt/homebrew/lib
steps:
- uses: actions/checkout@v6
# We need to use GNU grep, sed, and xargs on macOS
- name: add-packages
run: |
brew trust coverallsapp/coveralls
brew install flex bison diffutils lcov cmocka grep gnu-sed findutils
echo '/opt/homebrew/opt/grep/libexec/gnubin' >> $GITHUB_PATH
echo '/opt/homebrew/opt/gnu-sed/libexec/gnubin' >> $GITHUB_PATH
echo '/opt/homebrew/opt/findutils/libexec/gnubin' >> $GITHUB_PATH
- name: make cov
run: make cov
- name: Run white-box tests
run: make utest
- name: Run sunny-day tests
run: make covtest-sunny
- name: Run black-box tests
run: make covtest
- name: Coveralls
uses: coverallsapp/github-action@v2
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
file: out/lcov-total.info
format: lcov
flag-name: run-macos
parallel: true
build-windows:
runs-on: windows-2022
env:
LANG: en_US.UTF-8
LC_CTYPE: en_US.UTF-8
TERM: xterm-color
WIN32_PCRE2_INCLUDE: /mingw32/include
WIN32_PCRE2_LDFLAGS: -L/mingw32/lib
WIN32_LEX: flex
WIN32_YACC: bison
WIN32_CMOCKA_DLL: /mingw32/bin/libcmocka.dll
WIN32_CMOCKA_INCLUDE: /mingw32/include
WIN32_CMOCKA_LDFLAGS: -L/mingw32/lib
defaults:
run:
shell: msys2 {0}
steps:
- uses: actions/checkout@v6
- name: add-packages
uses: msys2/setup-msys2@v2
with:
msystem: MINGW32
update: true
install: >-
bison
diffutils
dos2unix
flex
git
make
mingw-w64-i686-cmocka
mingw-w64-i686-gcc
mingw-w64-i686-libiconv
mingw-w64-i686-libunistring
mingw-w64-i686-pcre2
unzip
vim
zip
- name: Build boxes.exe
run: make win32
- name: Run white-box tests
run: make win32.utest
- name: Run sunny-day tests
run: make test-sunny
- name: Run black-box tests
run: make test
- name: Save boxes.exe artifact
if: ${{ always() && hashFiles('out/boxes.exe') != '' }}
uses: actions/upload-artifact@v7
with:
name: boxes.exe
path: out/boxes.exe
retention-days: 30
finish:
needs: [build-linux, build-macos, build-windows]
if: ${{ always() }}
runs-on: ubuntu-latest
steps:
- name: Coveralls Finished
uses: coverallsapp/github-action@v2
with:
parallel-finished: true
carryforward: "run-linux,run-macos"