Skip to content

Commit a7b3f00

Browse files
committed
Build both x86_64 and arm64 for editor, build app bundle
1 parent 5b20c51 commit a7b3f00

File tree

1 file changed

+78
-80
lines changed

1 file changed

+78
-80
lines changed

.github/workflows/all_builds.yml

Lines changed: 78 additions & 80 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ jobs:
6666
id: macos-editor
6767
platform: macos
6868
target: editor
69-
sconsflags: debug_symbols=no tests=yes use_volk=no vulkan_sdk_path=$VULKAN_SDK_PATH
69+
sconsflags: debug_symbols=no tests=yes use_volk=no vulkan_sdk_path=$VULKAN_SDK_PATH use_lto=yes generate_bundle=yes
7070
bin: ./bin/godot.macos.editor.arm64
7171

7272
steps:
@@ -111,37 +111,35 @@ jobs:
111111
run: |
112112
sh misc/scripts/install_vulkan_sdk_macos.sh
113113
114-
- name: Compile Editor
114+
- name: Compile Editor (x86_64)
115115
if: matrix.target == 'editor'
116116
id: compile-editor
117117
uses: ./.github/actions/godot-build
118118
with:
119-
sconsflags: ${{ env.SCONSFLAGS }} ${{ matrix.sconsflags }}
119+
sconsflags: arch=x86_64 ${{ env.SCONSFLAGS }} ${{ matrix.sconsflags }}
120120
platform: ${{ matrix.platform }}
121121
target: editor
122122
tests: false
123123
scons-cache-limit: 4096
124124

125-
- name: Compile godot export template (x86_64)
126-
if: matrix.target == 'template_release'
127-
id: compile-template
125+
- name: Compile Editor for macos arm64
128126
uses: ./.github/actions/godot-build
127+
if: matrix.platform == 'macos' && matrix.target == 'editor'
129128
with:
130-
sconsflags: arch=x86_64 ${{ env.SCONSFLAGS }} ${{ env.SCONSFLAGS_TEMPLATE }} ${{ matrix.sconsflags }}
129+
sconsflags: arch=arm64 ${{ env.SCONSFLAGS }} ${{ matrix.sconsflags }}
131130
platform: ${{ matrix.platform }}
132-
target: template_release
131+
target: editor
133132
tests: false
134133
scons-cache-limit: 4096
135134

136-
- name: Compile godot export template for macos arm64
137-
uses: ./.github/actions/godot-build
138-
if: matrix.platform == 'macos' && matrix.target == 'template_release'
139-
with:
140-
sconsflags: arch=arm64 ${{ env.SCONSFLAGS }} ${{ env.SCONSFLAGS_TEMPLATE }} ${{ matrix.sconsflags }}
141-
platform: ${{ matrix.platform }}
142-
target: template_release
143-
tests: false
144-
scons-cache-limit: 4096
135+
- name: create universal macos editor
136+
if: matrix.platform == 'macos' && matrix.target == 'editor'
137+
shell: bash
138+
run: |
139+
lipo -create ./bin/godot.macos.${{ matrix.target }}.x86_64 ./bin/godot.macos.${{ matrix.target }}.arm64 -output ./bin/godot.macos.${{ matrix.target }}.universal
140+
rm ./bin/godot.macos.${{ matrix.target }}.x86_64 ./bin/godot.macos.${{ matrix.target }}.arm64
141+
strip bin/godot.*
142+
chmod +x bin/godot.*
145143
146144
- name: Save Godot build cache
147145
# if: success() || (steps.restore-cache.outputs.cache-hit == 'false' && (steps.compile-editor.outcome != 'skipped' || steps.compile-template.outcome != 'skipped'))
@@ -153,21 +151,21 @@ jobs:
153151
- name: Prepare template artifact
154152
uses: ./.github/actions/godot-prepare-artifact
155153

156-
- name: Make macOS template
157-
if: matrix.platform == 'macos' && matrix.target == 'template_release'
158-
run: |
159-
cp -R "misc/dist/macos_template.app" "bin/"
160-
mkdir -p "bin/macos_template.app/Contents/MacOS"
161-
lipo -create bin/godot.macos.template_release.x86_64 bin/godot.macos.template_release.arm64 -output bin/godot.macos.template_release.universal
162-
cp "bin/godot.macos.template_release.universal" "bin/macos_template.app/Contents/MacOS/godot_macos_debug.universal"
163-
cp "bin/godot.macos.template_release.universal" "bin/macos_template.app/Contents/MacOS/godot_macos_release.universal"
164-
cd bin/
165-
zip -r9 "macos.zip" "macos_template.app/"
166-
rm -f godot.macos.template_release.universal
167-
rm -f godot.macos.template_release.x86_64
168-
rm -f godot.macos.template_release.arm64
169-
rm -rf "macos_template.app/"
170-
cd ..
154+
# - name: Make macOS template
155+
# if: matrix.platform == 'macos' && matrix.target == 'template_release'
156+
# run: |
157+
# cp -R "misc/dist/macos_tools.app" "bin/"
158+
# mkdir -p "bin/macos_tools.app/Contents/MacOS"
159+
# lipo -create bin/godot.macos.template_release.x86_64 bin/godot.macos.template_release.arm64 -output bin/godot.macos.template_release.universal
160+
# cp "bin/godot.macos.e.universal" "bin/macos_tools.app/Contents/MacOS/godot_macos_debug.universal"
161+
# cp "bin/godot.macos.template_release.universal" "bin/macos_tools.app/Contents/MacOS/godot_macos_release.universal"
162+
# cd bin/
163+
# zip -r9 "macos.zip" "macos_tools.app/"
164+
# rm -f godot.macos.template_release.universal
165+
# rm -f godot.macos.template_release.x86_64
166+
# rm -f godot.macos.template_release.arm64
167+
# rm -rf "macos_tools.app/"
168+
# cd ..
171169

172170
- uses: actions/upload-artifact@v4
173171
if: matrix.id != 'linux-sanitizers'
@@ -176,62 +174,62 @@ jobs:
176174
path: ${{github.workspace}}/bin/*
177175
retention-days: 90
178176

179-
test:
180-
needs: build
181-
runs-on: ${{ matrix.os }}
182-
name: ${{ matrix.name }} test
183-
strategy:
184-
fail-fast: false
185-
matrix:
186-
include:
187-
- name: "Windows"
188-
os: "windows-latest"
189-
platform: windows
190-
bin: ./bin/godot.windows.editor.x86_64.exe
177+
# test:
178+
# needs: build
179+
# runs-on: ${{ matrix.os }}
180+
# name: ${{ matrix.name }} test
181+
# strategy:
182+
# fail-fast: false
183+
# matrix:
184+
# include:
185+
# - name: "Windows"
186+
# os: "windows-latest"
187+
# platform: windows
188+
# bin: ./bin/godot.windows.editor.x86_64.exe
191189

192-
- name: "🐧 Linux"
193-
os: "ubuntu-24.04"
194-
platform: linux
195-
bin: ./bin/godot.linuxbsd.editor.x86_64
190+
# - name: "🐧 Linux"
191+
# os: "ubuntu-24.04"
192+
# platform: linux
193+
# bin: ./bin/godot.linuxbsd.editor.x86_64
196194

197-
- name: "🍎 macOS"
198-
os: "macos-latest"
199-
platform: macos
200-
bin: ./bin/godot.macos.editor.arm64
195+
# - name: "🍎 macOS"
196+
# os: "macos-latest"
197+
# platform: macos
198+
# bin: ./bin/godot.macos.editor.arm64
201199

202-
steps:
203-
- name: checkout-godot
204-
uses: actions/checkout@v4
205-
with:
206-
repository: godotengine/godot
207-
ref: ${{env.GODOT_MAIN_SYNC_REF}}
200+
# steps:
201+
# - name: checkout-godot
202+
# uses: actions/checkout@v4
203+
# with:
204+
# repository: godotengine/godot
205+
# ref: ${{env.GODOT_MAIN_SYNC_REF}}
208206

209-
- name: checkout-patchwork_editor
210-
uses: actions/checkout@v4
211-
with:
212-
path: modules/patchwork_editor
213-
fetch-depth: 0
207+
# - name: checkout-patchwork_editor
208+
# uses: actions/checkout@v4
209+
# with:
210+
# path: modules/patchwork_editor
211+
# fetch-depth: 0
214212

215-
- name: copy actions
216-
shell: bash
217-
run: |
218-
cp -R modules/patchwork_editor/.github/actions/* .github/actions/
213+
# - name: copy actions
214+
# shell: bash
215+
# run: |
216+
# cp -R modules/patchwork_editor/.github/actions/* .github/actions/
219217

220-
- name: Download patchwork_editor artifacts
221-
uses: actions/download-artifact@v4
222-
with:
223-
name: patchwork_editor-editor-${{ matrix.platform }}
224-
path: bin
218+
# - name: Download patchwork_editor artifacts
219+
# uses: actions/download-artifact@v4
220+
# with:
221+
# name: patchwork_editor-editor-${{ matrix.platform }}
222+
# path: bin
225223

226-
- name: set permissions
227-
shell: bash
228-
run: |
229-
chmod a+x bin/godot*
224+
# - name: set permissions
225+
# shell: bash
226+
# run: |
227+
# chmod a+x bin/godot*
230228

231-
- name: run tests
232-
shell: bash
233-
run: |
234-
${{matrix.bin}} --headless --test --force-colors "--test-case=[patchwork_editor]*"
229+
# - name: run tests
230+
# shell: bash
231+
# run: |
232+
# ${{matrix.bin}} --headless --test --force-colors "--test-case=[patchwork_editor]*"
235233

236234
release:
237235
if: startsWith(github.ref, 'refs/tags/')

0 commit comments

Comments
 (0)