Lukas Tenbrink 2024-10-28 18:00:37 +00:00 committed by GitHub
commit cb7d44b441
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 17 additions and 11 deletions

View File

@ -15,14 +15,20 @@ inputs:
default: 'template_debug' default: 'template_debug'
description: Build type (template_debug or template_release). description: Build type (template_debug or template_release).
scons-cache: scons-cache:
default: .scons-cache/ default: '.scons-cache/'
description: Scons cache location. description: Scons cache folder name, relative to each scons directory. Must not contain relative path signifiers (. or ..). Must be a transparent path part (empty or 'path/to/folder/', ending in a slash).
em_version: em_version:
default: 3.1.62 default: 3.1.62
description: Emscripten version. description: Emscripten version.
em_cache_folder: em-cache-directory:
default: emsdk-cache default: emsdk-cache
description: Emscripten cache folder. description: Emscripten cache directory.
godot-cpp-directory:
default: 'godot-cpp/'
description: Location of godot-cpp in the repository. Must not contain relative path signifiers (. or ..). Must be a transparent path part (empty or 'path/to/directory/', ending in a slash).
gdextension-directory:
default: ''
description: Location of the gdextension project within the repository. Must not contain relative path signifiers (. or ..). Must be a transparent path part (empty or 'path/to/directory/', ending in a slash).
runs: runs:
using: composite using: composite
@ -67,7 +73,7 @@ runs:
uses: mymindstorm/setup-emsdk@v13 uses: mymindstorm/setup-emsdk@v13
with: with:
version: ${{ inputs.em_version }} version: ${{ inputs.em_version }}
actions-cache-folder: ${{ inputs.em_cache_folder }}.${{ inputs.float-precision }}.${{ inputs.build-target-type }} actions-cache-folder: ${{ inputs.em-cache-directory }}.${{ inputs.float-precision }}.${{ inputs.build-target-type }}
- name: Web - Verify Emscripten setup - name: Web - Verify Emscripten setup
if: ${{ inputs.platform == 'web' }} if: ${{ inputs.platform == 'web' }}
shell: sh shell: sh
@ -99,22 +105,22 @@ runs:
uses: actions/cache@v4 uses: actions/cache@v4
with: with:
path: | path: |
${{ github.workspace }}/${{ inputs.gdextension-location }}/${{ inputs.scons-cache }}/ ${{ github.workspace }}/${{ inputs.gdextension-directory }}${{ inputs.scons-cache }}
${{ github.workspace }}/${{ inputs.godot-cpp }}/${{ inputs.scons-cache }}/ ${{ github.workspace }}/${{ inputs.godot-cpp-directory }}${{ inputs.scons-cache }}
key: ${{ inputs.platform }}_${{ inputs.arch }}_${{ inputs.float-precision }}_${{ inputs.build-target-type }}_cache key: ${{ inputs.platform }}_${{ inputs.arch }}_${{ inputs.float-precision }}_${{ inputs.build-target-type }}_cache
# Build godot-cpp # Build godot-cpp
- name: Build godot-cpp Debug Build - name: Build godot-cpp Debug Build
shell: sh shell: sh
env: env:
SCONS_CACHE: ${{ github.workspace }}/${{ inputs.godot-cpp }}/${{ inputs.scons-cache }}/ SCONS_CACHE: ${{ github.workspace }}/${{ inputs.godot-cpp-directory }}${{ inputs.scons-cache }}
run: | run: |
scons target=${{ inputs.build-target-type }} platform=${{ inputs.platform }} arch=${{ inputs.arch }} generate_bindings=yes precision=${{ inputs.float-precision }} scons target=${{ inputs.build-target-type }} platform=${{ inputs.platform }} arch=${{ inputs.arch }} generate_bindings=yes precision=${{ inputs.float-precision }}
working-directory: ${{ inputs.godot-cpp }} working-directory: ${{ inputs.godot-cpp-directory }}
# Build gdextension # Build gdextension
- name: Build GDExtension Debug Build - name: Build GDExtension Debug Build
shell: sh shell: sh
env: env:
SCONS_CACHE: ${{ github.workspace }}/${{ inputs.gdextension-location }}/${{ inputs.scons-cache }}/ SCONS_CACHE: ${{ github.workspace }}/${{ inputs.gdextension-directory }}${{ inputs.scons-cache }}
run: | run: |
scons target=${{ inputs.build-target-type }} platform=${{ inputs.platform }} arch=${{ inputs.arch }} precision=${{ inputs.float-precision }} scons target=${{ inputs.build-target-type }} platform=${{ inputs.platform }} arch=${{ inputs.arch }} precision=${{ inputs.float-precision }}
working-directory: ${{ inputs.gdextension-location }} working-directory: ${{ inputs.gdextension-directory }}