diff --git a/.github/actions/godot-build/action.yml b/.github/actions/godot-build/action.yml index 2405cc22be22..5d31f5bd912e 100644 --- a/.github/actions/godot-build/action.yml +++ b/.github/actions/godot-build/action.yml @@ -5,25 +5,24 @@ inputs: target: description: Build target (editor, template_release, template_debug). default: editor - tests: - description: Unit tests. - default: false - required: false + type: choice + options: [editor, template_debug, template_release] platform: description: Target platform. - required: false + type: string sconsflags: description: Additional SCons flags. - default: "" - required: false + type: string scons-cache: description: The SCons cache path. default: ${{ github.workspace }}/.scons_cache/ + type: string scons-cache-limit: description: The SCons cache size limit. # actions/cache has 10 GiB limit, and GitHub runners have a 14 GiB disk. # Limit to 7 GiB to avoid having the extracted cache fill the disk. default: 7 + type: number runs: using: composite @@ -33,7 +32,7 @@ runs: env: SCONSFLAGS: ${{ inputs.sconsflags }} run: | - echo "Building with flags:" platform=${{ inputs.platform }} target=${{ inputs.target }} tests=${{ inputs.tests }} ${{ env.SCONSFLAGS }} "cache_path=${{ inputs.scons-cache }}" cache_limit=${{ inputs.scons-cache-limit }} + echo "Building with flags:" platform=${{ inputs.platform }} target=${{ inputs.target }} ${{ env.SCONSFLAGS }} "cache_path=${{ inputs.scons-cache }}" cache_limit=${{ inputs.scons-cache-limit }} if [ "${{ inputs.target }}" != "editor" ]; then # Ensure we don't include editor code in export template builds. @@ -47,5 +46,5 @@ runs: export BUILD_NAME="gh" fi - scons platform=${{ inputs.platform }} target=${{ inputs.target }} tests=${{ inputs.tests }} ${{ env.SCONSFLAGS }} "cache_path=${{ inputs.scons-cache }}" cache_limit=${{ inputs.scons-cache-limit }} + scons platform=${{ inputs.platform }} target=${{ inputs.target }} ${{ env.SCONSFLAGS }} "cache_path=${{ inputs.scons-cache }}" cache_limit=${{ inputs.scons-cache-limit }} ls -l bin/ diff --git a/.github/workflows/android_builds.yml b/.github/workflows/android_builds.yml index bb4ee25f7c22..1238a87f5a1b 100644 --- a/.github/workflows/android_builds.yml +++ b/.github/workflows/android_builds.yml @@ -6,7 +6,11 @@ on: env: # Used for the cache key. Add version suffix to force clean build. GODOT_BASE_BRANCH: master - SCONSFLAGS: verbose=yes warnings=extra werror=yes debug_symbols=no module_text_server_fb_enabled=yes strict_checks=yes + SCONSFLAGS: >- + dev_mode=yes + module_text_server_fb_enabled=yes + tests=no + swappy=yes jobs: build-android: @@ -20,23 +24,19 @@ jobs: - name: Editor (target=editor) cache-name: android-editor target: editor - tests: false - sconsflags: arch=arm64 production=yes swappy=yes - cache-limit: 1 + sconsflags: >- + arch=arm64 + production=yes - name: Template arm32 (target=template_release, arch=arm32) cache-name: android-template-arm32 target: template_release - tests: false - sconsflags: arch=arm32 swappy=yes - cache-limit: 1 + sconsflags: arch=arm32 - name: Template arm64 (target=template_release, arch=arm64) cache-name: android-template-arm64 target: template_release - tests: false - sconsflags: arch=arm64 swappy=yes - cache-limit: 1 + sconsflags: arch=arm64 steps: - name: Checkout @@ -76,8 +76,7 @@ jobs: sconsflags: ${{ env.SCONSFLAGS }} ${{ matrix.sconsflags }} platform: android target: ${{ matrix.target }} - tests: ${{ matrix.tests }} - scons-cache-limit: ${{ matrix.cache-limit }} + scons-cache-limit: 1 - name: Save Godot build cache uses: ./.github/actions/godot-cache-save diff --git a/.github/workflows/ios_builds.yml b/.github/workflows/ios_builds.yml index f5a4f755dedd..24a396fa30fc 100644 --- a/.github/workflows/ios_builds.yml +++ b/.github/workflows/ios_builds.yml @@ -6,7 +6,11 @@ on: env: # Used for the cache key. Add version suffix to force clean build. GODOT_BASE_BRANCH: master - SCONSFLAGS: verbose=yes warnings=extra werror=yes debug_symbols=no module_text_server_fb_enabled=yes strict_checks=yes + SCONSFLAGS: >- + dev_mode=yes + module_text_server_fb_enabled=yes + tests=no + debug_symbols=no jobs: ios-template: @@ -33,7 +37,6 @@ jobs: sconsflags: ${{ env.SCONSFLAGS }} platform: ios target: template_release - tests: false scons-cache-limit: 1 - name: Save Godot build cache diff --git a/.github/workflows/linux_builds.yml b/.github/workflows/linux_builds.yml index 4d0a215c8010..20917ba4fb8c 100644 --- a/.github/workflows/linux_builds.yml +++ b/.github/workflows/linux_builds.yml @@ -6,7 +6,9 @@ on: env: # Used for the cache key. Add version suffix to force clean build. GODOT_BASE_BRANCH: master - SCONSFLAGS: verbose=yes warnings=extra werror=yes module_text_server_fb_enabled=yes strict_checks=yes + SCONSFLAGS: >- + dev_mode=yes + module_text_server_fb_enabled=yes DOTNET_NOLOGO: true DOTNET_CLI_TELEMETRY_OPTOUT: true TSAN_OPTIONS: suppressions=misc/error_suppressions/tsan.txt @@ -28,68 +30,75 @@ jobs: sconsflags: module_mono_enabled=yes bin: ./bin/godot.linuxbsd.editor.x86_64.mono build-mono: true - tests: false # Disabled due freeze caused by mix Mono build and CI doc-test: true proj-conv: true api-compat: true artifact: true cache-limit: 1 - - name: Editor with doubles and GCC sanitizers (target=editor, tests=yes, dev_build=yes, scu_build=yes, precision=double, use_asan=yes, use_ubsan=yes, linker=gold) + - name: Editor with doubles and GCC sanitizers (target=editor, dev_build=yes, scu_build=yes, precision=double, use_asan=yes, use_ubsan=yes, linker=gold) cache-name: linux-editor-double-sanitizers target: editor # Debug symbols disabled as they're huge on this build and we hit the 14 GB limit for runners. - sconsflags: dev_build=yes scu_build=yes debug_symbols=no precision=double use_asan=yes use_ubsan=yes linker=gold + sconsflags: >- + dev_build=yes + scu_build=yes + debug_symbols=no + precision=double + use_asan=yes + use_ubsan=yes + linker=gold bin: ./bin/godot.linuxbsd.editor.dev.double.x86_64.san - build-mono: false - tests: true proj-test: true # Generate an API dump for godot-cpp tests. api-dump: true - # Skip 2GiB artifact speeding up action. - artifact: false cache-limit: 7 - - name: Editor with clang sanitizers (target=editor, tests=yes, dev_build=yes, use_asan=yes, use_ubsan=yes, use_llvm=yes, linker=lld) + - name: Editor with clang sanitizers (target=editor, dev_build=yes, use_asan=yes, use_ubsan=yes, use_llvm=yes, linker=lld) cache-name: linux-editor-llvm-sanitizers target: editor - sconsflags: dev_build=yes use_asan=yes use_ubsan=yes use_llvm=yes linker=lld + sconsflags: >- + dev_build=yes + use_asan=yes + use_ubsan=yes + use_llvm=yes + linker=lld bin: ./bin/godot.linuxbsd.editor.dev.x86_64.llvm.san - build-mono: false - tests: true - # Skip 2GiB artifact speeding up action. - artifact: false # Test our oldest supported SCons/Python versions on one arbitrary editor build. legacy-scons: true cache-limit: 7 - - name: Editor with ThreadSanitizer (target=editor, tests=yes, dev_build=yes, use_tsan=yes, use_llvm=yes, linker=lld) + - name: Editor with ThreadSanitizer (target=editor, dev_build=yes, use_tsan=yes, use_llvm=yes, linker=lld) cache-name: linux-editor-thread-sanitizer target: editor - tests: true - sconsflags: dev_build=yes use_tsan=yes use_llvm=yes linker=lld + sconsflags: >- + dev_build=yes + use_tsan=yes + use_llvm=yes + linker=lld bin: ./bin/godot.linuxbsd.editor.dev.x86_64.llvm.san - build-mono: false - # Skip 2GiB artifact speeding up action. - artifact: false cache-limit: 5 - - name: Template w/ Mono (target=template_release, tests=yes) + - name: Template w/ Mono (target=template_release) cache-name: linux-template-mono target: template_release sconsflags: module_mono_enabled=yes bin: ./bin/godot.linuxbsd.template_release.x86_64.mono - build-mono: false - tests: true artifact: true cache-limit: 1 - - name: Minimal template (target=template_release, tests=yes, everything disabled) + - name: Minimal template (target=template_release, everything disabled) cache-name: linux-template-minimal target: template_release - sconsflags: modules_enabled_by_default=no disable_3d=yes disable_advanced_gui=yes deprecated=no minizip=no + sconsflags: >- + modules_enabled_by_default=no + module_text_server_fb_enabled=no + disable_3d=yes + disable_advanced_gui=yes + deprecated=no + minizip=no + brotli=no bin: ./bin/godot.linuxbsd.template_release.x86_64 - tests: true artifact: true cache-limit: 1 @@ -155,7 +164,6 @@ jobs: sconsflags: ${{ env.SCONSFLAGS }} ${{ matrix.sconsflags }} platform: linuxbsd target: ${{ matrix.target }} - tests: ${{ matrix.tests }} scons-cache-limit: ${{ matrix.cache-limit }} - name: Save Godot build cache @@ -194,7 +202,6 @@ jobs: bin: ${{ matrix.bin }} - name: Unit tests - if: matrix.tests run: | ${{ matrix.bin }} --version ${{ matrix.bin }} --help diff --git a/.github/workflows/macos_builds.yml b/.github/workflows/macos_builds.yml index 3923b918f49e..0e5c37ae9252 100644 --- a/.github/workflows/macos_builds.yml +++ b/.github/workflows/macos_builds.yml @@ -6,7 +6,9 @@ on: env: # Used for the cache key. Add version suffix to force clean build. GODOT_BASE_BRANCH: master - SCONSFLAGS: verbose=yes warnings=extra werror=yes module_text_server_fb_enabled=yes strict_checks=yes + SCONSFLAGS: >- + dev_mode=yes + module_text_server_fb_enabled=yes jobs: build-macos: @@ -17,17 +19,15 @@ jobs: fail-fast: false matrix: include: - - name: Editor (target=editor, tests=yes) + - name: Editor (target=editor) cache-name: macos-editor target: editor - tests: true bin: ./bin/godot.macos.editor.universal cache-limit: 1 - - name: Template (target=template_release, tests=yes) + - name: Template (target=template_release) cache-name: macos-template target: template_release - tests: true sconsflags: debug_symbols=no bin: ./bin/godot.macos.template_release.universal cache-limit: 1 @@ -57,7 +57,6 @@ jobs: sconsflags: ${{ env.SCONSFLAGS }} arch=x86_64 platform: macos target: ${{ matrix.target }} - tests: ${{ matrix.tests }} scons-cache-limit: 0 # Only cap on second run to avoid purging unnecessarily - name: Compilation (arm64) @@ -66,7 +65,6 @@ jobs: sconsflags: ${{ env.SCONSFLAGS }} arch=arm64 platform: macos target: ${{ matrix.target }} - tests: ${{ matrix.tests }} scons-cache-limit: ${{ matrix.cache-limit }} - name: Save Godot build cache @@ -88,7 +86,6 @@ jobs: name: ${{ matrix.cache-name }} - name: Unit tests - if: matrix.tests run: | ${{ matrix.bin }} --version ${{ matrix.bin }} --help diff --git a/.github/workflows/web_builds.yml b/.github/workflows/web_builds.yml index 2f08d8c2f956..ad617017cfd8 100644 --- a/.github/workflows/web_builds.yml +++ b/.github/workflows/web_builds.yml @@ -6,7 +6,11 @@ on: env: # Used for the cache key. Add version suffix to force clean build. GODOT_BASE_BRANCH: master - SCONSFLAGS: verbose=yes warnings=extra werror=yes debug_symbols=no use_closure_compiler=yes strict_checks=yes + SCONSFLAGS: >- + dev_mode=yes + tests=no + debug_symbols=no + use_closure_compiler=yes EM_VERSION: 3.1.64 jobs: @@ -22,14 +26,12 @@ jobs: cache-name: web-template target: template_release sconsflags: threads=yes - tests: false artifact: true - name: Template w/o threads (target=template_release, threads=no) cache-name: web-nothreads-template target: template_release sconsflags: threads=no - tests: false artifact: true steps: @@ -63,7 +65,6 @@ jobs: sconsflags: ${{ env.SCONSFLAGS }} ${{ matrix.sconsflags }} platform: web target: ${{ matrix.target }} - tests: ${{ matrix.tests }} scons-cache-limit: 0.5 - name: Save Godot build cache diff --git a/.github/workflows/windows_builds.yml b/.github/workflows/windows_builds.yml index 8d5ff5ec38ec..a46298202155 100644 --- a/.github/workflows/windows_builds.yml +++ b/.github/workflows/windows_builds.yml @@ -7,7 +7,12 @@ on: env: # Used for the cache key. Add version suffix to force clean build. GODOT_BASE_BRANCH: master - SCONSFLAGS: verbose=yes warnings=extra werror=yes module_text_server_fb_enabled=yes d3d12=yes strict_checks=yes "angle_libs=${{ github.workspace }}/" + SCONSFLAGS: >- + dev_mode=yes + module_text_server_fb_enabled=yes + debug_symbols=no + d3d12=yes + "angle_libs=${{ github.workspace }}/" SCONS_CACHE_MSVC_CONFIG: true jobs: @@ -20,40 +25,39 @@ jobs: fail-fast: false matrix: include: - - name: Editor (target=editor, tests=yes) + - name: Editor (target=editor) cache-name: windows-editor target: editor - tests: true - # Skip debug symbols, they're way too big with MSVC. - sconsflags: debug_symbols=no vsproj=yes vsproj_gen_only=no windows_subsystem=console + sconsflags: >- + windows_subsystem=console + vsproj=yes + vsproj_gen_only=no bin: ./bin/godot.windows.editor.x86_64.exe compiler: msvc cache-limit: 2 - - name: Editor w/ clang-cl (target=editor, tests=yes, use_llvm=yes) + - name: Editor w/ clang-cl (target=editor, use_llvm=yes) cache-name: windows-editor-clang target: editor - tests: true - sconsflags: debug_symbols=no windows_subsystem=console use_llvm=yes + sconsflags: >- + windows_subsystem=console + use_llvm=yes bin: ./bin/godot.windows.editor.x86_64.llvm.exe compiler: clang cache-limit: 1 - - name: Template (target=template_release, tests=yes) + - name: Template (target=template_release) cache-name: windows-template target: template_release - tests: true - sconsflags: debug_symbols=no bin: ./bin/godot.windows.template_release.x86_64.console.exe compiler: msvc cache-limit: 2 - - name: Template w/ GCC (target=template_release, tests=yes, use_mingw=yes) + - name: Template w/ GCC (target=template_release, use_mingw=yes) cache-name: windows-template-gcc # MinGW takes MUCH longer to compile; save time by only targeting Template. target: template_release - tests: true - sconsflags: debug_symbols=no use_mingw=yes + sconsflags: use_mingw=yes bin: ./bin/godot.windows.template_release.x86_64.console.exe compiler: gcc cache-limit: 1 @@ -93,7 +97,6 @@ jobs: sconsflags: ${{ env.SCONSFLAGS }} ${{ matrix.sconsflags }} platform: windows target: ${{ matrix.target }} - tests: ${{ matrix.tests }} scons-cache-limit: ${{ matrix.cache-limit }} - name: Save Godot build cache @@ -114,7 +117,6 @@ jobs: name: ${{ matrix.cache-name }} - name: Unit tests - if: matrix.tests run: | ${{ matrix.bin }} --version ${{ matrix.bin }} --help