name: C/C++ CI

on:
  push:
    branches: [ master, develop ]
  pull_request:
    branches: [ master, develop ]

jobs:
  build:

    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@v3
    - name: dependencies
      run: sudo DEBIAN_FRONTEND=noninteractive apt-get install -y yaggo gettext swig python3-dev ruby-dev libperl-dev
    - name: autotools
      run: autoreconf -fi
    - name: configure
      run: ./configure --enable-all-binding --enable-swig
    - name: make
      run: make -j2
    - name: make check
      run: make -j2 check
    - name: make distcheck
      run: make -j2 distcheck
