2021-10-26 16:10:30 -06:00
|
|
|
name: Build (RISC OS)
|
|
|
|
|
|
|
|
on: [push, pull_request]
|
|
|
|
|
2022-12-04 10:06:06 -07:00
|
|
|
concurrency:
|
2022-12-28 14:06:46 -07:00
|
|
|
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.run_id }}
|
2022-12-04 10:06:06 -07:00
|
|
|
cancel-in-progress: true
|
|
|
|
|
2021-10-26 16:10:30 -06:00
|
|
|
jobs:
|
2022-06-03 11:24:20 -06:00
|
|
|
Build:
|
|
|
|
name: ${{ matrix.platform.name }}
|
2021-10-26 16:10:30 -06:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
container: riscosdotinfo/riscos-gccsdk-4.7:latest
|
|
|
|
|
2022-06-03 11:24:20 -06:00
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
platform:
|
|
|
|
- { name: CMake }
|
|
|
|
|
2021-10-26 16:10:30 -06:00
|
|
|
steps:
|
|
|
|
- name: Setup dependencies
|
|
|
|
run: apt-get update && apt-get install -y cmake ninja-build
|
2024-01-25 18:33:20 -07:00
|
|
|
- uses: actions/checkout@v4
|
2022-06-03 11:24:20 -06:00
|
|
|
- name: Configure (CMake)
|
|
|
|
if: ${{ contains(matrix.platform.name, 'CMake') }}
|
|
|
|
run: |
|
|
|
|
cmake -S . -B build -G Ninja \
|
2023-01-23 21:30:24 -07:00
|
|
|
-Wdeprecated -Wdev -Werror \
|
2022-06-03 11:24:20 -06:00
|
|
|
-DCMAKE_TOOLCHAIN_FILE=/home/riscos/env/toolchain-riscos.cmake \
|
2023-07-22 13:19:14 -06:00
|
|
|
-DCMAKE_DISABLE_PRECOMPILE_HEADERS=ON \
|
2022-11-30 15:38:50 -07:00
|
|
|
-DRISCOS:BOOL=ON \
|
2022-06-03 11:24:20 -06:00
|
|
|
-DSDL_GCC_ATOMICS=OFF \
|
2022-05-08 10:08:41 -06:00
|
|
|
-DSDL_TESTS=ON \
|
|
|
|
-DSDL_INSTALL_TESTS=ON \
|
2022-10-20 13:02:21 -06:00
|
|
|
-DSDL_VENDOR_INFO="Github Workflow" \
|
2022-06-03 11:24:20 -06:00
|
|
|
-DCMAKE_BUILD_TYPE=Release \
|
|
|
|
-DCMAKE_INSTALL_PREFIX=${{ github.workspace }}/prefix_cmake
|
|
|
|
- name: Build (CMake)
|
|
|
|
if: ${{ contains(matrix.platform.name, 'CMake') }}
|
|
|
|
run: cmake --build build --verbose
|
|
|
|
- name: Install (CMake)
|
|
|
|
if: ${{ contains(matrix.platform.name, 'CMake') }}
|
|
|
|
run: |
|
2022-11-21 22:36:19 -07:00
|
|
|
echo "SDL3_DIR=${{ github.workspace }}/prefix_cmake" >> $GITHUB_ENV
|
2022-06-03 11:24:20 -06:00
|
|
|
cmake --install build/
|
|
|
|
( cd ${{ github.workspace }}/prefix_cmake; find ) | LC_ALL=C sort -u
|
2023-01-28 22:12:40 -07:00
|
|
|
- name: Package (CPack)
|
|
|
|
run: |
|
|
|
|
cmake --build build/ --config Release --target package
|
2022-06-03 11:24:20 -06:00
|
|
|
- name: Verify CMake configuration files
|
|
|
|
run: |
|
|
|
|
cmake -S cmake/test -B cmake_config_build -G Ninja \
|
2023-02-16 12:29:36 -07:00
|
|
|
-DTEST_SHARED=OFF \
|
2022-06-03 11:24:20 -06:00
|
|
|
-DCMAKE_TOOLCHAIN_FILE=/home/riscos/env/toolchain-riscos.cmake \
|
2022-11-21 22:36:19 -07:00
|
|
|
-DCMAKE_PREFIX_PATH=${{ env.SDL3_DIR }} \
|
2022-06-03 11:24:20 -06:00
|
|
|
-DCMAKE_BUILD_TYPE=Release \
|
|
|
|
${{ matrix.platform.test_args }}
|
|
|
|
cmake --build cmake_config_build --verbose
|
2024-01-25 18:33:20 -07:00
|
|
|
- uses: actions/upload-artifact@v4
|
2023-01-28 22:12:40 -07:00
|
|
|
with:
|
|
|
|
if-no-files-found: error
|
|
|
|
name: SDL-riscos
|
|
|
|
path: build/dist/SDL3*
|