🛠️🐜 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.

55 lines
1.9 KiB

  1. name: Build (Nintendo 3DS)
  2. on: [push, pull_request]
  3. jobs:
  4. n3ds:
  5. runs-on: ubuntu-latest
  6. container:
  7. image: devkitpro/devkitarm:latest
  8. steps:
  9. - uses: actions/checkout@v3
  10. - name: Install build requirements
  11. run: |
  12. apt update
  13. apt install ninja-build
  14. - name: Configure CMake
  15. run: |
  16. cmake -S . -B build -G Ninja \
  17. -DCMAKE_TOOLCHAIN_FILE=${DEVKITPRO}/cmake/3DS.cmake \
  18. -DSDL_WERROR=ON \
  19. -DSDL_TESTS=ON \
  20. -DSDL_INSTALL_TESTS=ON \
  21. -DSDL_VENDOR_INFO="Github Workflow" \
  22. -DCMAKE_BUILD_TYPE=Release \
  23. -DCMAKE_INSTALL_PREFIX=prefix
  24. - name: Build
  25. run: cmake --build build --verbose
  26. - name: Install CMake
  27. run: |
  28. echo "SDL2_DIR=$(pwd)/prefix" >> $GITHUB_ENV
  29. cmake --install build/
  30. ( cd prefix; find ) | LC_ALL=C sort -u
  31. - name: Verify CMake configuration files
  32. run: |
  33. cmake -S cmake/test -B cmake_config_build -G Ninja \
  34. -DCMAKE_TOOLCHAIN_FILE=${DEVKITPRO}/cmake/3DS.cmake \
  35. -DTEST_SHARED=FALSE \
  36. -DCMAKE_PREFIX_PATH=${{ env.SDL2_DIR }} \
  37. -DCMAKE_BUILD_TYPE=Release
  38. cmake --build cmake_config_build --verbose
  39. - name: Extract CC/CXX/CFLAGS/CXXFLAGS from CMake toolchain
  40. run: |
  41. cmake -S .github/cmake -B /tmp/cmake_extract \
  42. -DCMAKE_TOOLCHAIN_FILE=${DEVKITPRO}/cmake/3DS.cmake \
  43. -DCMAKE_BUILD_TYPE=Release \
  44. -DVAR_PATH=/tmp/n3ds_env.txt
  45. cat /tmp/n3ds_env.txt >> $GITHUB_ENV
  46. - name: Verify sdl2-config
  47. run: |
  48. export PATH=${{ env.SDL2_DIR }}/bin:$PATH
  49. cmake/test/test_sdlconfig.sh
  50. - name: Verify sdl2.pc
  51. run: |
  52. export PKG_CONFIG_PATH=${{ env.SDL2_DIR }}/lib/pkgconfig
  53. cmake/test/test_pkgconfig.sh