mirror of
https://github.com/mod-playerbots/mod-playerbots
synced 2025-11-29 15:58:20 +08:00
33
.github/workflows/core_build.yml
vendored
33
.github/workflows/core_build.yml
vendored
@@ -50,18 +50,35 @@ jobs:
|
|||||||
path: 'modules/mod-playerbots'
|
path: 'modules/mod-playerbots'
|
||||||
|
|
||||||
- name: Cache
|
- name: Cache
|
||||||
uses: actions/cache@v3
|
uses: actions/cache@v4
|
||||||
with:
|
with:
|
||||||
path: |
|
path: ${{ github.workspace }}/var/ccache
|
||||||
/var/cache/apt
|
key: ccache:${{ matrix.os }}:${{ matrix.c_compiler }}:${{ github.ref }}:${{ github.sha }}
|
||||||
/var/lib/apt
|
|
||||||
key: ccache:${{ matrix.os }}:${{ github.ref }}:${{ github.sha }}
|
|
||||||
restore-keys: |
|
restore-keys: |
|
||||||
ccache:${{ matrix.os }}:${{ github.ref }}
|
ccache:${{ matrix.os }}:${{ matrix.c_compiler }}:${{ github.ref }}
|
||||||
|
ccache:${{ matrix.os }}:${{ matrix.c_compiler }}
|
||||||
ccache:${{ matrix.os }}
|
ccache:${{ matrix.os }}
|
||||||
|
|
||||||
- name: Install Requirements
|
- name: Install Requirements
|
||||||
run: sudo apt-get update && sudo apt-get install git cmake make gcc g++ clang libmysqlclient-dev libssl-dev libbz2-dev libreadline-dev libncurses-dev mysql-server libboost-all-dev
|
run: sudo apt-get update && sudo apt-get install ccache git cmake make gcc g++ clang libmysqlclient-dev libssl-dev libbz2-dev libreadline-dev libncurses-dev mysql-server libboost-all-dev
|
||||||
|
|
||||||
|
- name: setup ccache
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
CCACHE_DIR: $GITHUB_WORKSPACE/var/ccache
|
||||||
|
run: |
|
||||||
|
cat <<EOF >> $GITHUB_ENV
|
||||||
|
CCACHE_DIR=${{ env.CCACHE_DIR }}
|
||||||
|
CCACHE_MAXSIZE=1000MB
|
||||||
|
CCACHE_SLOPPINESS=pch_defines,time_macros,include_file_mtime
|
||||||
|
CCACHE_CPP2=true
|
||||||
|
CCACHE_COMPRESS=1
|
||||||
|
CCACHE_COMPRESSLEVEL=9
|
||||||
|
CCACHE_COMPILERCHECK=content
|
||||||
|
CCACHE_LOGFILE=$CCACHE_DIR/cache.debug
|
||||||
|
CC=${{ inputs.CC }}
|
||||||
|
CXX=${{ inputs.CXX }}
|
||||||
|
EOF
|
||||||
|
|
||||||
- name: Configure CMake
|
- name: Configure CMake
|
||||||
run: >
|
run: >
|
||||||
@@ -69,6 +86,8 @@ jobs:
|
|||||||
-DCMAKE_CXX_COMPILER=${{ matrix.cpp_compiler }}
|
-DCMAKE_CXX_COMPILER=${{ matrix.cpp_compiler }}
|
||||||
-DCMAKE_C_COMPILER=${{ matrix.c_compiler }}
|
-DCMAKE_C_COMPILER=${{ matrix.c_compiler }}
|
||||||
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
|
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
|
||||||
|
-DCMAKE_CXX_COMPILER_LAUNCHER="ccache"
|
||||||
|
-DCMAKE_C_COMPILER_LAUNCHER="ccache"
|
||||||
-S ${{ github.workspace }}
|
-S ${{ github.workspace }}
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
|
|||||||
10
.github/workflows/windows_build.yml
vendored
10
.github/workflows/windows_build.yml
vendored
@@ -26,14 +26,8 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
repository: 'liyunfan1223/mod-playerbots'
|
repository: 'liyunfan1223/mod-playerbots'
|
||||||
path: 'modules/mod-playerbots'
|
path: 'modules/mod-playerbots'
|
||||||
- name: Cache
|
- name: ccache
|
||||||
uses: actions/cache@v3
|
uses: hendrikmuhs/ccache-action@v1.2.13
|
||||||
with:
|
|
||||||
path: C:\ProgramData\chocolatey\cache
|
|
||||||
key: ccache:${{ matrix.os }}:${{ github.ref }}:${{ github.sha }}
|
|
||||||
restore-keys: |
|
|
||||||
ccache:${{ matrix.os }}:${{ github.ref }}
|
|
||||||
ccache:${{ matrix.os }}
|
|
||||||
- name: Configure OS
|
- name: Configure OS
|
||||||
shell: bash
|
shell: bash
|
||||||
env:
|
env:
|
||||||
|
|||||||
Reference in New Issue
Block a user