Skip to content

Remove unused header #725

Remove unused header

Remove unused header #725

Workflow file for this run

name: C/C++ CI
on: [push, pull_request]
jobs:
build:
strategy:
matrix:
platform: [ubuntu-latest, macos-latest]
runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@v4
- name: CPU Information
run: lscpu || sysctl -a|grep cpu || echo "CPU information not available"
- name: make check C99
run: make clean && make check -j 2 CC="cc -std=c99 -Wno-unknown-warning-option -Werror"
- name: make check C11
working-directory: ./tests
run: make clean && make check -j 2 CC="cc -std=c11 -Wno-unknown-warning-option -Werror"
- name: make check C++
working-directory: ./tests
run: make clean && make check -j 2 CC="c++ -std=c++11"
build_linux32:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: update package list
run: sudo apt-get update
- name: install multilib
run: sudo apt-get install gcc-multilib g++-multilib
- name: CPU Information
run: lscpu || echo "CPU information not available"
- name: make check C99 (32bits)
working-directory: ./tests
run: make clean && make check -j 2 CC="gcc -m32 -std=c99 -Wno-unknown-warning-option -Werror"
- name: make check C11 (32bits)
working-directory: ./tests
run: make clean && make check -j 2 CC="gcc -m32 -std=c11 -Wno-unknown-warning-option -Werror"
- name: make check C++ (32 bits)
working-directory: ./tests
run: make clean && make check -j 2 CC="g++ -m32 -std=c++11 -Wno-unknown-warning-option "
- name: make check against C++ STL
working-directory: ./tests
run: make clean && make check-stl -j 2
build_linux_tcc:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: CPU Information
run: lscpu || echo "CPU information not available"
- name: Clone TCC
shell: bash
run: git clone https://repo.or.cz/tinycc.git
- name: Configure, build & install TCC
shell: bash
run: cd tinycc && ./configure --prefix=/tmp/tcc && make && make install
- name: make depend
shell: bash
run: make depend
- name: make check
shell: bash
run: make CC="/tmp/tcc/bin/tcc -std=c99" check -j4 || make CC="/tmp/tcc/bin/tcc -std=c99" check -j2 || make CC="/tmp/tcc/bin/tcc -std=c99" check
build_linux_sanitize:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: make sanitize
working-directory: ./tests
run: make sanitize -j 2
build_windows_mingw:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: make check
shell: bash
run: mingw32-make -j 2 CC="gcc -std=c99 -D__USE_MINGW_ANSI_STDIO=1" check
build_windows_msys2:
runs-on: windows-latest
defaults:
run:
shell: msys2 {0}
steps:
- uses: actions/checkout@v4
- uses: msys2/setup-msys2@v2
with:
msystem: MINGW64
update: true
install: git mingw-w64-x86_64-toolchain make
- name: make check
run: make -j 2 CC="gcc -std=c99 -D__USE_MINGW_ANSI_STDIO=1" check
build_windows_visual:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: make check
shell: cmd
working-directory: ./tests
run: Make-check-cl.bat cl
build_windows_clang_cl:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: make check
shell: cmd
working-directory: ./tests
run: Make-check-cl.bat clang-cl
# The host should always be linux
build_freebsd:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Test in FreeBSD
id: test
uses: vmactions/freebsd-vm@v1
timeout-minutes: 60
with:
usesh: true
run: |
freebsd-version
cd tests
make check -j 2 CC="cc -std=c99 -Wno-unknown-warning-option -Werror" && make clean && make check -j 2 CC="cc -std=c11 -Wno-unknown-warning-option -Werror" LDFLAGS="-lstdthreads" && make clean
# The host should always be linux
build_aarch64:
runs-on: ubuntu-latest
name: Build on aarch64
steps:
- uses: actions/checkout@v4
- uses: uraimo/run-on-arch-action@v2.5.0
name: Run commands on aarch64
id: make
timeout-minutes: 60
with:
arch: aarch64
distro: bullseye
shell: /bin/sh
run: |
apt-get update -q -y
apt-get install -q -y build-essential git gcc
lscpu
cd tests && make check -j 2 && make clean