Skip to content

Commit

Permalink
Replaced Travis CI with Github Actions
Browse files Browse the repository at this point in the history
  • Loading branch information
ncorgan committed Sep 19, 2021
1 parent 21f809b commit fb67058
Show file tree
Hide file tree
Showing 3 changed files with 189 additions and 56 deletions.
188 changes: 188 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,188 @@
name: CI
on: [push, pull_request]
jobs:
linux-ci:
name: Linux
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- cc: gcc-9
cxx: g++-9
build_type: Release
- cc: gcc-9
cxx: g++-9
build_type: Debug

- cc: gcc-10
cxx: g++-10
build_type: Release
- cc: gcc-10
cxx: g++-10
build_type: Debug

- cc: clang-10
cxx: clang++-10
build_type: Release
- cc: clang-10
cxx: clang++-10
build_type: Debug

- cc: clang-11
cxx: clang++-11
build_type: Release
- cc: clang-11
cxx: clang++-11
build_type: Debug

- cc: clang-12
cxx: clang++-12
build_type: Release
- cc: clang-12
cxx: clang++-12
build_type: Debug
env:
CC: ${{matrix.cc}}
CXX: ${{matrix.cxx}}
INSTALL_PREFIX: /usr/local
steps:
- uses: actions/checkout@v2
- name: Install dependencies
run: |
sudo apt install -y libavahi-client-dev libavahi-common-dev
cd ${{runner.workspace}}
# Build against earliest supported SoapySDR
git clone https://github.com/pothosware/SoapySDR -b soapy-sdr-0.4.0
mkdir SoapySDR/build
cd SoapySDR/build
cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} -DCMAKE_BUILD_TYPE=${{matrix.build_type}} -DENABLE_PYTHON=OFF -DENABLE_PYTHON3=OFF ..
make
sudo make install
sudo ldconfig
- name: Build SoapyRemote
run: |
mkdir ${{github.workspace}}/build
cd ${{github.workspace}}/build
cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} -DCMAKE_BUILD_TYPE=${{matrix.build_type}} ${{github.workspace}}
make
- name: Install
run: |
cd ${{github.workspace}}/build
sudo make install
- name: Test module registration
run: |
SoapySDRUtil --check=remote
osx-ci:
name: OS X
runs-on: macos-latest
strategy:
fail-fast: false
matrix:
include:
- cc: clang
cxx: clang++
build_type: Release
- cc: clang
cxx: clang++
build_type: Debug
env:
CC: ${{matrix.cc}}
CXX: ${{matrix.cxx}}
INSTALL_PREFIX: /usr/local
steps:
- uses: actions/checkout@v2
- name: Install SoapySDR
run: |
cd ${{runner.workspace}}
# Build against earliest supported SoapySDR
git clone https://github.com/pothosware/SoapySDR -b soapy-sdr-0.4.0
mkdir SoapySDR/build
cd SoapySDR/build
cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} -DCMAKE_BUILD_TYPE=${{matrix.build_type}} -DENABLE_PYTHON=OFF -DENABLE_PYTHON3=OFF ..
make
sudo make install
- name: Build SoapyRemote
run: |
mkdir ${{github.workspace}}/build
cd ${{github.workspace}}/build
cmake -DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} -DCMAKE_BUILD_TYPE=${{matrix.build_type}} ${{github.workspace}}
make
- name: Install
run: |
cd ${{github.workspace}}/build
sudo make install
- name: Test module registration
run: |
SoapySDRUtil --check=remote
windows-ci:
name: Windows
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
# Note: keeping cmake_config general enough for non-MSVC later
include:
- cmake_config: -G "Visual Studio 14 2015" -A "Win32"
arch: win32
build_type: Release
- cmake_config: -G "Visual Studio 14 2015" -A "Win32"
arch: win32
build_type: Debug

- cmake_config: -G "Visual Studio 14 2015" -A "x64"
arch: x64
build_type: Release
- cmake_config: -G "Visual Studio 14 2015" -A "x64"
arch: x64
build_type: Debug

# Note: skipping VS2017, possible bugginess in parallel installs

- cmake_config: -G "Visual Studio 16 2019" -A "Win32"
arch: win32
build_type: Release
- cmake_config: -G "Visual Studio 16 2019" -A "Win32"
arch: win32
build_type: Debug

- cmake_config: -G "Visual Studio 16 2019" -A "x64"
arch: x64
build_type: Release
- cmake_config: -G "Visual Studio 16 2019" -A "x64"
arch: x64
build_type: Release
env:
INSTALL_PREFIX: 'C:\Program Files\SoapySDR'
steps:
- uses: actions/checkout@v2
- uses: ilammy/msvc-dev-cmd@v1
with:
arch: ${{matrix.arch}}
- name: Install SoapySDR
run: |
cd ${{runner.workspace}}
# Build against earliest supported SoapySDR
git clone https://github.com/pothosware/SoapySDR -b soapy-sdr-0.4.0
mkdir SoapySDR\build
cd SoapySDR\build
cmake -DCMAKE_INSTALL_PREFIX="$Env:INSTALL_PREFIX" -DCMAKE_BUILD_TYPE=${{matrix.build_type}} -DENABLE_PYTHON=OFF -DENABLE_PYTHON3=OFF ..
cmake --build . --config ${{matrix.build_type}}
cmake --install . --config ${{matrix.build_type}}
- name: Build SoapyRemote
run: |
mkdir ${{github.workspace}}/build
cd ${{github.workspace}}/build
cmake -DCMAKE_PREFIX_PATH="$Env:INSTALL_PREFIX" -DCMAKE_INSTALL_PREFIX="$Env:INSTALL_PREFIX" -DCMAKE_BUILD_TYPE=${{matrix.build_type}} ${{github.workspace}}
cmake --build . --config ${{matrix.build_type}}
- name: Install
run: |
cd ${{github.workspace}}/build
cmake --install . --config ${{matrix.build_type}}
- name: Test module registration
run: |
$Env:PATH += ";$Env:INSTALL_PREFIX\bin"
SoapySDRUtil --check=remote
55 changes: 0 additions & 55 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Build Status

- Travis: [![Travis Build Status](https://travis-ci.org/pothosware/SoapyRemote.svg?branch=master)](https://travis-ci.org/pothosware/SoapyRemote)
![Build Status](https://github.com/pothosware/SoapyRemote/actions/workflows/ci.yml/badge.svg)

## Dependencies

Expand Down

0 comments on commit fb67058

Please sign in to comment.