- update continuous integration workflow

Added tests for library installation, sample compilation and its launching
Added installation of ALSA development package
This commit is contained in:
alexey.lysiuk 2020-01-07 13:17:42 +02:00
parent af79a0bec0
commit b415394560

View file

@ -42,20 +42,46 @@ jobs:
steps: steps:
- uses: actions/checkout@v1 - uses: actions/checkout@v1
- name: Install Dependencies
shell: bash
run: |
if [[ "${{ runner.os }}" == 'Linux' ]]; then
sudo apt update
sudo apt install libasound2-dev
fi
- name: Configure - name: Configure
shell: bash shell: bash
run: | run: |
mkdir build mkdir build
cd build cd build
cmake -DCMAKE_BUILD_TYPE=${{ matrix.config.build_type }} ${{ matrix.config.extra_options }} .. cmake -DCMAKE_BUILD_TYPE=${{ matrix.config.build_type }} -DCMAKE_INSTALL_PREFIX=../build_install ${{ matrix.config.extra_options }} ..
- name: Build - name: Build
shell: bash shell: bash
run: | run: |
cd build cd build
if [[ "${{ runner.os }}" == 'Windows' ]]; then if [[ "${{ runner.os }}" == 'Windows' ]]; then
cmake --build . --config ${{ matrix.config.build_type }} -- -maxcpucount -verbosity:minimal cmake --build . --target install --config ${{ matrix.config.build_type }} -- -maxcpucount -verbosity:minimal
else else
cmake --build . -- --jobs=2 --keep-going cmake --build . --target install -- --jobs=2 --keep-going
fi fi
- name: Test
shell: bash
run: |
cd samples/list_midi_devices
mkdir build
cd build
declare -x PREFIX=`pwd`/../../../build_install
cmake -DCMAKE_PREFIX_PATH=${PREFIX} ${{ matrix.config.extra_options }} ..
cmake --build . --config ${{ matrix.config.build_type }}
if [[ "${{ runner.os }}" == 'macOS' ]]; then
declare -x DYLD_LIBRARY_PATH=${DYLD_LIBRARY_PATH}:${PREFIX}
fi
if [[ "${{ runner.os }}" == 'Windows' ]]; then
cp ${PREFIX}/bin/zmusic.dll ${{ matrix.config.build_type }}
${{ matrix.config.build_type }}/list_midi_devices.exe
else
./list_midi_devices
fi