Remove conditional check for Ubuntu in dependency installation step #119
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: C/C++ CI | |
on: | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master ] | |
jobs: | |
build: | |
strategy: | |
matrix: | |
os: [ubuntu-latest] | |
configuration: [ Release, Debug ] | |
compiler: [ gcc, clang ] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install dependencies on Ubuntu | |
if: matrix.os == 'ubuntu-latest' | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y autoconf automake autopoint gettext git libtool make texinfo | |
if [ "${{ matrix.compiler }}" == "gcc" ]; then sudo apt-get install -y g++; fi | |
if [ "${{ matrix.compiler }}" == "clang" ]; then sudo apt-get install -y clang; fi | |
- name: Run autogen | |
run: ./autogen.sh | |
- name: Configure | |
run: | | |
if [ "${{ matrix.compiler }}" == "gcc" ]; then export CC=gcc CXX=g++; fi | |
if [ "${{ matrix.compiler }}" == "clang" ]; then export CC=clang CXX=clang++; fi | |
if [ "${{ matrix.configuration }}" == "Release" ]; then | |
export CFLAGS="-O2" CXXFLAGS="-O2"; | |
else | |
export CFLAGS="-g -O0" CXXFLAGS="-g -O0"; | |
fi | |
./configure | |
- name: Build | |
run: make | |
- name: Run checks | |
run: make check |