| name: Release packages |
| on: |
| release: |
| types: [published] |
| |
| workflow_dispatch: |
| |
| jobs: |
| build-linux: |
| runs-on: ubuntu-latest |
| steps: |
| - name: Checkout code |
| uses: actions/checkout@v4 |
| |
| - name: Set up CMake |
| uses: jwlawson/actions-setup-cmake@v2 |
| |
| - name: Build PC Linux version of openAPV, generate packages and md5 file |
| run: | |
| cmake -S ${{github.workspace}} -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=Release |
| cmake --build ${{github.workspace}}/build |
| cd ${{github.workspace}}/build |
| cpack -C Release |
| |
| - name: 'Upload PC Linux artifacts' |
| uses: actions/upload-artifact@v4 |
| with: |
| name: openapv-linux-${{github.event.release.tag_name}} |
| path: | |
| ${{ github.workspace }}/build/*.deb |
| ${{ github.workspace }}/build/*.md5 |
| retention-days: 7 |
| |
| - name: Upload Linux assets to GitHub Release |
| uses: xresloader/upload-to-github-release@v1 |
| env: |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| with: |
| file: "build/*.deb; build/*.md5" |
| update_latest_release: true |
| draft: false |
| overwrite: true |
| |
| build-arm: |
| runs-on: ubuntu-latest |
| steps: |
| - name: Checkout code |
| uses: actions/checkout@v4 |
| |
| - name: Set up CMake |
| uses: jwlawson/actions-setup-cmake@v2 |
| |
| - name: Install ARM toolchain |
| run: | |
| sudo apt-get update |
| sudo apt-get install -y gcc-aarch64-linux-gnu binutils-aarch64-linux-gnu |
| |
| - name: Build ARM |
| run: | |
| cmake -S ${{github.workspace}} -B ${{github.workspace}}/build-arm -DCMAKE_TOOLCHAIN_FILE=${{github.workspace}}/arm64_toolchain.cmake -DCMAKE_BUILD_TYPE=Release |
| cmake --build ${{github.workspace}}/build-arm |
| cd ${{github.workspace}}/build-arm |
| cpack -C Release |
| |
| - name: 'Upload ARM artifacts' |
| uses: actions/upload-artifact@v4 |
| with: |
| name: openapv-arm-${{github.event.release.tag_name}} |
| path: | |
| ${{ github.workspace }}/build-arm/*.deb |
| ${{ github.workspace }}/build-arm/*.md5 |
| retention-days: 7 |
| |
| - name: Upload ARM assets to GitHub Release |
| uses: xresloader/upload-to-github-release@v1 |
| env: |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| with: |
| file: "build-arm/*.deb; build-arm/*.md5" |
| update_latest_release: true |
| draft: false |
| overwrite: true |
| |
| build-windows: |
| runs-on: ubuntu-latest |
| steps: |
| - name: Checkout code |
| uses: actions/checkout@v4 |
| |
| - name: Set up CMake |
| uses: jwlawson/actions-setup-cmake@v2 |
| |
| - name: Install Windows toolchain |
| run: | |
| sudo apt-get update |
| sudo apt-get install -y mingw-w64 mingw-w64-tools |
| |
| - name: Build (crosscmopile) PC Windows version of openAPV, generate packages and md5 file |
| run: | |
| cmake -S ${{github.workspace}} -B ${{github.workspace}}/build-windows -DCMAKE_TOOLCHAIN_FILE=${{github.workspace}}/windows_x86_64_toolchain.cmake -DCMAKE_BUILD_TYPE=Release |
| cmake --build ${{github.workspace}}/build-windows |
| cd ${{github.workspace}}/build-windows |
| cpack -G ZIP -C Release |
| |
| - name: 'Upload PC Windows artifacts' |
| uses: actions/upload-artifact@v4 |
| with: |
| name: openapv-windows-${{github.event.release.tag_name}} |
| path: | |
| ${{ github.workspace }}/build-windows/*.zip |
| ${{ github.workspace }}/build-windows/*.md5 |
| retention-days: 7 |
| |
| - name: Upload Windows assets to GitHub Release |
| uses: xresloader/upload-to-github-release@v1 |
| env: |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| with: |
| file: "build-windows/*.zip; build-windows/*.md5" |
| update_latest_release: true |
| draft: false |
| overwrite: true |