🛠️🐜 Antkeeper superbuild with dependencies included https://antkeeper.com
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

68 lines
2.5 KiB

  1. name: Build (RISC OS)
  2. on: [push, pull_request]
  3. jobs:
  4. Build:
  5. name: ${{ matrix.platform.name }}
  6. runs-on: ubuntu-latest
  7. container: riscosdotinfo/riscos-gccsdk-4.7:latest
  8. strategy:
  9. fail-fast: false
  10. matrix:
  11. platform:
  12. - { name: autotools, test_args: '-DTEST_SHARED=FALSE' } # FIXME: autotools should build and install shared libraries
  13. - { name: CMake }
  14. steps:
  15. - name: Setup dependencies
  16. run: apt-get update && apt-get install -y cmake ninja-build
  17. - uses: actions/checkout@v3
  18. - name: Configure (autotools)
  19. if: ${{ contains(matrix.platform.name, 'autotools') }}
  20. run: |
  21. mkdir build_autotools
  22. cd build_autotools
  23. ../configure \
  24. --host=arm-unknown-riscos \
  25. --disable-gcc-atomics \
  26. --prefix=${{ github.workspace }}/prefix_autotools
  27. - name: Build (autotools)
  28. if: ${{ contains(matrix.platform.name, 'autotools') }}
  29. run: make -C build_autotools -j`nproc` V=1
  30. - name: Install (autotools)
  31. if: ${{ contains(matrix.platform.name, 'autotools') }}
  32. run: |
  33. echo "SDL2_DIR=${{ github.workspace }}/prefix_autotools" >> $GITHUB_ENV
  34. make -C build_autotools install
  35. ( cd ${{ github.workspace }}/prefix_autotools; find ) | LC_ALL=C sort -u
  36. - name: Configure (CMake)
  37. if: ${{ contains(matrix.platform.name, 'CMake') }}
  38. run: |
  39. cmake -S . -B build -G Ninja \
  40. -DCMAKE_TOOLCHAIN_FILE=/home/riscos/env/toolchain-riscos.cmake \
  41. -DRISCOS=ON \
  42. -DSDL_GCC_ATOMICS=OFF \
  43. -DSDL_TESTS=ON \
  44. -DSDL_INSTALL_TESTS=ON \
  45. -DSDL_VENDOR_INFO="Github Workflow" \
  46. -DCMAKE_BUILD_TYPE=Release \
  47. -DCMAKE_INSTALL_PREFIX=${{ github.workspace }}/prefix_cmake
  48. - name: Build (CMake)
  49. if: ${{ contains(matrix.platform.name, 'CMake') }}
  50. run: cmake --build build --verbose
  51. - name: Install (CMake)
  52. if: ${{ contains(matrix.platform.name, 'CMake') }}
  53. run: |
  54. echo "SDL2_DIR=${{ github.workspace }}/prefix_cmake" >> $GITHUB_ENV
  55. cmake --install build/
  56. ( cd ${{ github.workspace }}/prefix_cmake; find ) | LC_ALL=C sort -u
  57. - name: Verify CMake configuration files
  58. run: |
  59. cmake -S cmake/test -B cmake_config_build -G Ninja \
  60. -DCMAKE_TOOLCHAIN_FILE=/home/riscos/env/toolchain-riscos.cmake \
  61. -DCMAKE_PREFIX_PATH=${{ env.SDL2_DIR }} \
  62. -DCMAKE_BUILD_TYPE=Release \
  63. ${{ matrix.platform.test_args }}
  64. cmake --build cmake_config_build --verbose