builds godot
Diffstat (limited to '.github/actions/build-godot/action.yml')
-rw-r--r--.github/actions/build-godot/action.yml18
1 files changed, 7 insertions, 11 deletions
diff --git a/.github/actions/build-godot/action.yml b/.github/actions/build-godot/action.yml
index 88ec767..e30436e 100644
--- a/.github/actions/build-godot/action.yml
+++ b/.github/actions/build-godot/action.yml
@@ -11,15 +11,12 @@ inputs:
target:
description: Target (template_release, template_debug, editor)
required: true
- tools:
- description: Tools!
- default: "no"
runs:
using: "composite"
steps:
- name: Setup
- uses: bend-n/godot-builds/.github/actions/setup@main
+ uses: bend-n/godot-builds/.github/actions/[email protected]
with:
ref: ${{ env.ref }}
@@ -51,14 +48,13 @@ runs:
run: |
echo ::group::Compilation
cd godot
- scons_flags="${{ env.flags }} ${{ inputs.flags }} tools=${{ inputs.tools }}"
+ scons_flags=${{ env.flags }}
cores=$(nproc) || cores=$(sysctl -n hw.ncpu)
- [[ ${{ inputs.tools }} == "yes" ]] && scons_flags="${scons_flags//disable_3d=yes/}" # remove disable_3d=yes if editor
- [[ ${{ inputs.tools }} == "yes" ]] && scons_flags="$scons_flags debug_symbols=no"
- [[ ${{ inputs.target }} ]] && scons_flags="$scons_flags deprecated=no"
- scons -j$((cores+2)) p=${{ inputs.platform }} target=${{ inputs.target }} verbose=yes udev=yes dev_build=no lto=auto $scons_flags
- echo "compile done"
- [[ ${{ inputs.target}} != "editor" ]] && strip -v bin/* || true
+ [[ -n "${{ inputs.flags }}" ]] && scons_flags="${{ inputs.flags }}"
+ [[ ${{ env.tools }} == "yes" ]] && scons_flags="${scons_flags//disable_3d=yes/}" # remove disable_3d=yes if editor
+ echo "Running `scons -j$((cores+2)) p=${{ inputs.platform }} target=${{ inputs.target }} use_lto=yes udev=yes tools=${{ env.tools }} $scons_flags`"
+ scons -j$((cores+2)) p=${{ inputs.platform }} target=${{ inputs.target }} use_lto=yes udev=yes "tools=${{ env.tools }}" $scons_flags
+ strip bin/* || true
ls bin
echo ::endgroup::
shell: bash