build_servers_gcc.yml 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. name: Build servers with GCC
  2. # build_servers_gcc.yml
  3. concurrency:
  4. group: ${{ github.repository }}-${{ github.workflow }}-${{ github.ref }}
  5. cancel-in-progress: ${{ github.ref != 'refs/heads/master' }}
  6. on:
  7. push:
  8. branches:
  9. - master
  10. pull_request:
  11. paths:
  12. # Always trigger all Github Actions if an action or something CI related was changed
  13. - '.github/workflows/**'
  14. - 'tools/ci/**'
  15. # This workflow should run when a file in a source directory has been modified.
  16. - 'src/**'
  17. - '3rdparty/**'
  18. jobs:
  19. build:
  20. # Github Actions checks for '[ci skip]', '[skip ci]', '[no ci]', '[skip actions]', or '[actions skip]' but not a hyphenated version.
  21. # It's a catch-all incase a Pull Request has been opened and someone is on auto-pilot.
  22. if: "!contains(github.event.head_commit.message, 'ci-skip')"
  23. runs-on: ${{ matrix.os }}
  24. strategy:
  25. matrix:
  26. # The ubuntu-latest label currently points to ubuntu-22.04.
  27. # Available: ubuntu-22.04, ubuntu-20.04
  28. os: [ubuntu-latest]
  29. # Older versions of GCC are not available via unaltered aptitude repo lists.
  30. gcc: ['9', '10', '11']
  31. steps:
  32. - uses: actions/checkout@v2
  33. - name: Update & Install packages
  34. # Ubuntu runners already have most of the packages rAthena requires to build.
  35. # https://github.com/actions/virtual-environments/blob/main/images/linux/Ubuntu2004-Readme.md
  36. run: |
  37. sudo apt update
  38. sudo apt install zlib1g-dev libpcre3-dev gcc-${{ matrix.gcc }} g++-${{ matrix.gcc }}
  39. - name: Command - configure
  40. env:
  41. CONFIGURE_FLAGS: 'CC=gcc-${{ matrix.gcc }} CXX=g++-${{ matrix.gcc }} --enable-buildbot=yes'
  42. run: ./configure $CONFIGURE_FLAGS
  43. - name: Command - make clean
  44. run: make clean
  45. - name: Command - make all
  46. run: make all