build.yml 1006 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. name: build
  2. on:
  3. push:
  4. tags:
  5. - 'v*'
  6. jobs:
  7. build:
  8. runs-on: ubuntu-latest
  9. permissions:
  10. contents: write
  11. steps:
  12. -
  13. name: Checkout
  14. uses: actions/checkout@v4
  15. with:
  16. fetch-depth: 0
  17. -
  18. name: Setup Go
  19. uses: actions/setup-go@v4
  20. with:
  21. go-version: 'stable'
  22. -
  23. name: Read tag
  24. id: tag
  25. run: echo "tag=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
  26. -
  27. name: Build
  28. run: >-
  29. make -j $(nproc) allplus
  30. NDK_CC_ARM64="$ANDROID_NDK/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android21-clang"
  31. NDK_CC_ARM="$ANDROID_NDK/toolchains/llvm/prebuilt/linux-x86_64/bin/armv7a-linux-androideabi21-clang"
  32. VERSION=${{steps.tag.outputs.tag}}
  33. -
  34. name: Release
  35. uses: softprops/action-gh-release@v1
  36. with:
  37. files: bin/*
  38. fail_on_unmatched_files: true
  39. generate_release_notes: true