Açıklama Yok
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.

cmake.yml 1.9KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. # https://github.com/raspberrypi/pico-examples/blob/master/.github/workflows/cmake.yml
  2. name: Firmware
  3. # build for each push and pull request
  4. on: [push, pull_request]
  5. env:
  6. BUILD_TYPE: Release
  7. jobs:
  8. build:
  9. runs-on: ubuntu-latest
  10. permissions:
  11. contents: write
  12. steps:
  13. - name: Install dependencies
  14. run: sudo apt-get install -y cxxtest build-essential gcc-arm-none-eabi mtools zip
  15. - name: Checkout repo
  16. uses: actions/checkout@v4
  17. with:
  18. path: repo
  19. fetch-depth: 0
  20. - name: Checkout repo submodules
  21. working-directory: ${{github.workspace}}/repo
  22. run: git submodule update --init
  23. - name: Checkout pico-sdk submodules
  24. working-directory: ${{github.workspace}}/repo/firmware/pico-sdk
  25. run: git submodule update --init
  26. - name: Create Build Environment
  27. working-directory: ${{github.workspace}}/repo/firmware
  28. run: cmake -E make_directory ${{github.workspace}}/repo/firmware/build
  29. - name: Configure CMake
  30. shell: bash
  31. working-directory: ${{github.workspace}}/repo/firmware/build
  32. run: cmake .. -DCMAKE_BUILD_TYPE=$BUILD_TYPE
  33. - name: Get core count
  34. id: core_count
  35. run : cat /proc/cpuinfo | grep processor | wc -l
  36. - name: Build
  37. working-directory: ${{github.workspace}}/repo/firmware/build
  38. shell: bash
  39. run: cmake --build . --config $BUILD_TYPE --parallel $(nproc)
  40. - name: Upload a Build Artifact
  41. uses: actions/upload-artifact@v4.0.0
  42. with:
  43. name: dispensy.uf2
  44. path: ${{github.workspace}}/repo/firmware/build/dispensy.uf2
  45. if-no-files-found: error
  46. - name: Upload release files
  47. if: startsWith(github.ref, 'refs/tags/')
  48. uses: softprops/action-gh-release@v1
  49. with:
  50. files: ${{github.workspace}}/repo/firmware/build/dispensy.uf2