fix: make workflow clone into ${{github.workspace}}/build/smaster4s-inis #32
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: Test for Ubuntu | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
env: | |
BUILD_TYPE: Release | |
jobs: | |
build: | |
strategy: | |
matrix: | |
c_compiler: [gcc, clang] | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install dependencies | |
run: > | |
sudo apt-get update && | |
sudo apt-get install -y libgtk-4-dev | |
- name: Building smaster4s-inis | |
run: | | |
git clone https://github.com/SMASTER4/smaster4s-inis ${{github.workspace}}/build/smaster4s-inis | |
cd ${{github.workspace}}/build/smaster4s-inis | |
cmake -DCMAKE_C_COMPILER=${{matrix.c_compiler}} -B ${{github.workspace}}/build/smaster4s-inis -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} | |
cmake --build ${{github.workspace}}/build/smaster4s-inis --config ${{env.BUILD_TYPE}} | |
sudo make install | |
- name: Configure CMake | |
run: cmake -DCMAKE_C_COMPILER=${{matrix.c_compiler}} -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} | |
- name: Build | |
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} |