Skip to content

Use function pointers instead of delegates to clear object pool in C#9. #687

Use function pointers instead of delegates to clear object pool in C#9.

Use function pointers instead of delegates to clear object pool in C#9. #687

Workflow file for this run

# This workflow is to make sure builds work properly in all runtimes and with all configurations.
# This is done because WebGL is currently not possible to run platform tests in cloud CI.
# Only building for WebGL because it does the full IL2CPP process plus an extra emscripten process.
# Standalone is built in IL2CPP tests, and other platforms do the same IL2CPP process.
# We do not need to test Mono builds here because that is already done with the Editor tests.
name: Unity WebGL Builds
on: [pull_request]
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
build:
name: Build (${{ matrix.scriptingRuntime.name }}, ${{ matrix.mode.name }}, ${{ matrix.progress.name }})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
scriptingRuntime:
- {
name: Net3.5,
version: 0,
apiCompatibilityLevel: 2
}
- {
name: Net4.x,
version: 1,
apiCompatibilityLevel: 6
}
mode:
- {
name: Release,
symbol: PROTO_PROMISE_DEBUG_DISABLE
}
- {
name: Debug,
symbol: PROTO_PROMISE_DEBUG_ENABLE
}
progress:
- {
name: Progress_Enabled,
symbol: PROTO_PROMISE_PROGRESS_ENABLE
}
- {
name: Progress_Disabled,
symbol: PROTO_PROMISE_PROGRESS_DISABLE
}
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Rewrite ProjectSettings
run: |
DefineSymbols="${{ matrix.mode.symbol }};${{ matrix.progress.symbol }}"
DefineOriginal=" scriptingDefineSymbols: {}"
DefineReplace=" scriptingDefineSymbols: \\n 13: $DefineSymbols"
sed -i "{s/$DefineOriginal/$DefineReplace/g}" ProtoPromise_Unity/ProjectSettings/ProjectSettings.asset
RuntimeOriginal=" scriptingRuntimeVersion: 0"
RuntimeReplace=" scriptingRuntimeVersion: ${{ matrix.scriptingRuntime.version }}"
sed -i "{s/$RuntimeOriginal/$RuntimeReplace/g}" ProtoPromise_Unity/ProjectSettings/ProjectSettings.asset
ApiOriginal=" apiCompatibilityLevel: 2"
ApiReplace=" apiCompatibilityLevel: ${{ matrix.scriptingRuntime.apiCompatibilityLevel }}"
sed -i "{s/$ApiOriginal/$ApiReplace/g}" ProtoPromise_Unity/ProjectSettings/ProjectSettings.asset
- name: Build Project
uses: game-ci/unity-builder@v2
env:
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE_2018_4_36F1_UBUNTU }}
with:
projectPath: ProtoPromise_Unity
targetPlatform: WebGL
buildMethod: UnityBuilderAction.BuildScript.Build
allowDirtyBuild: true
timeout-minutes: 90