Skip to content

Commit c1ea678

Browse files
committed
Fix FFMPEG dependency on macOS, and support arm64 versions, update versions
1 parent 5f22871 commit c1ea678

File tree

8 files changed

+156
-36
lines changed

8 files changed

+156
-36
lines changed

.github/workflows/linux_build.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -25,28 +25,28 @@ jobs:
2525

2626
steps:
2727
- name: "Checkout RetroHub"
28-
uses: actions/checkout@v3
28+
uses: actions/checkout@v4
2929
with:
3030
path: "retrohub"
3131

3232
- name: "Load cached objects (Godot editor)"
33-
uses: actions/cache@v3
33+
uses: actions/cache@v4
3434
id: "cache_editor"
3535
with:
3636
path: cached_builds/editor/godot
3737
key: editor-build
3838
continue-on-error: true
3939

4040
- name: "Load cached objects (Godot templates)"
41-
uses: actions/cache@v3
41+
uses: actions/cache@v4
4242
id: "cache_template"
4343
with:
4444
path: cached_builds/template/${{ matrix.template }}
4545
key: Linux-${{ matrix.arch }}-template-build
4646
continue-on-error: true
4747

4848
- name: "Load cached objects (Videodecoder)"
49-
uses: actions/cache@v3
49+
uses: actions/cache@v4
5050
id: "cache_videodecoder"
5151
with:
5252
path: cached_builds/videodecoder/${{ matrix.videodecoder }}
@@ -55,15 +55,15 @@ jobs:
5555

5656
- name: "Checkout Custom Godot"
5757
if: steps.cache_template.outputs.cache-hit != 'true'
58-
uses: actions/checkout@v3
58+
uses: actions/checkout@v4
5959
with:
6060
repository: retrohub-org/godot
6161
ref: retrohub_patches_4x
6262
path: "godot"
6363

6464
- name: "Checkout godot-videodecoder"
6565
if: steps.cache_videodecoder.outputs.cache-hit != 'true'
66-
uses: actions/checkout@v3
66+
uses: actions/checkout@v4
6767
with:
6868
repository: retrohub-org/godot-videodecoder
6969
submodules: recursive
@@ -154,7 +154,7 @@ jobs:
154154
chmod +x ../export/linux_${{ matrix.arch }}/RetroHub
155155
156156
- name: "Upload Artifacts"
157-
uses: actions/upload-artifact@v3
157+
uses: actions/upload-artifact@v4
158158
with:
159159
name: linux-${{ matrix.arch }}
160160
path: export/linux_${{ matrix.arch }}

.github/workflows/mac_build.yml

Lines changed: 34 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,12 @@ jobs:
1111
name: Extract SDK
1212
steps:
1313
- name: "Load cache"
14-
uses: actions/cache@v3
14+
uses: actions/cache@v4
1515
id: "cache"
1616
with:
1717
path: ~/cached_builds/sdk
1818
key: MacOS-sdk
19+
save-always: true
1920
continue-on-error: true
2021

2122
- name: "Checkout osxcross"
@@ -27,10 +28,6 @@ jobs:
2728
- name: "Extract SDK"
2829
if: steps.cache.outputs.cache-hit != 'true'
2930
run: |
30-
#ls /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs
31-
#sed 's/\^MacOSX13\.\*|//g' tools/gen_sdk_package.sh > tools/gen_sdk_package.sh.patched
32-
#mv tools/gen_sdk_package.sh.patched tools/gen_sdk_package.sh
33-
#chmod +x tools/gen_sdk_package.sh
3431
XCODEDIR=/Applications/Xcode_14.0.1.app ./tools/gen_sdk_package.sh
3532
mkdir -p -v ~/cached_builds/sdk
3633
mv MacOSX12.3.sdk.tar.xz ~/cached_builds/sdk
@@ -42,32 +39,35 @@ jobs:
4239

4340
steps:
4441
- name: "Load cache (SDK)"
45-
uses: actions/cache@v3
42+
uses: actions/cache@v4
4643
id: "cache-sdk"
4744
with:
4845
path: ~/cached_builds/sdk
4946
key: MacOS-sdk
5047
continue-on-error: false
5148

5249
- name: "Load cache (videodecoder)"
53-
uses: actions/cache@v3
50+
uses: actions/cache@v4
5451
id: "cache-videodecoder"
5552
with:
56-
path: cached_builds/videodecoder/macos
53+
path: |
54+
cached_builds/videodecoder/macos_x86
55+
cached_builds/videodecoder/macos_arm64
5756
key: MacOS-videodecoder-build
57+
save-always: true
5858
continue-on-error: true
5959

6060
- name: "Checkout godot-videodecoder"
6161
if: steps.cache-videodecoder.outputs.cache-hit != 'true'
62-
uses: actions/checkout@v3
62+
uses: actions/checkout@v4
6363
with:
6464
repository: retrohub-org/godot-videodecoder
6565
submodules: recursive
6666

6767
- name: "Compile"
6868
if: steps.cache-videodecoder.outputs.cache-hit != 'true'
6969
env:
70-
PLATFORMS: macos
70+
PLATFORMS: macos_x86,macos_arm64
7171
run: |
7272
mv ~/cached_builds/sdk/MacOSX12.3.sdk.tar.xz darwin_sdk
7373
./build_gdextension.sh
@@ -81,37 +81,39 @@ jobs:
8181

8282
steps:
8383
- name: "Checkout RetroHub"
84-
uses: actions/checkout@v3
84+
uses: actions/checkout@v4
8585
with:
8686
path: "retrohub"
8787

8888
- name: "Load cached objects (Godot editor)"
89-
uses: actions/cache@v3
89+
uses: actions/cache@v4
9090
id: "cache_editor"
9191
with:
9292
path: cached_builds/editor/Godot.app
9393
key: MacOS-editor-build
9494
continue-on-error: true
9595

9696
- name: "Load cached objects (Godot templates)"
97-
uses: actions/cache@v3
97+
uses: actions/cache@v4
9898
id: "cache_template"
9999
with:
100100
path: cached_builds/template/macos.zip
101101
key: MacOS-template-build
102102
continue-on-error: true
103103

104104
- name: "Load cached objects (Videodecoder)"
105-
uses: actions/cache@v3
105+
uses: actions/cache@v4
106106
id: "cache_videodecoder"
107107
with:
108-
path: cached_builds/videodecoder/macos
108+
path: |
109+
cached_builds/videodecoder/macos_x86
110+
cached_builds/videodecoder/macos_arm64
109111
key: MacOS-videodecoder-build
110112
continue-on-error: false
111113

112114
- name: "Checkout Custom Godot"
113115
if: steps.cache_template.outputs.cache-hit != 'true'
114-
uses: actions/checkout@v3
116+
uses: actions/checkout@v4
115117
with:
116118
repository: retrohub-org/godot
117119
ref: retrohub_patches_4x
@@ -180,6 +182,20 @@ jobs:
180182
unzip Godot_v4.1-stable_macos.universal.zip
181183
mkdir -p -v cached_builds/editor
182184
mv Godot.app cached_builds/editor/
185+
186+
- name: "[videodecoder] Bundle x86_64 and arm64 libraries"
187+
run: |
188+
mkdir -p -v cached_builds/videodecoder/macos
189+
ls -la cached_builds/videodecoder/
190+
echo "---"
191+
ls -la cached_builds/videodecoder/macos_x86
192+
echo "---"
193+
ls -la cached_builds/videodecoder/macos_arm64
194+
echo "---"
195+
for f in cached_builds/videodecoder/macos_x86/*.dylib; do
196+
lipo -create $f cached_builds/videodecoder/macos_arm64/$(basename $f) -output cached_builds/videodecoder/macos/$(basename $f)
197+
done
198+
file cached_builds/videodecoder/macos/*.dylib
183199
184200
- name: "Setup templates and libraries"
185201
env:
@@ -196,7 +212,7 @@ jobs:
196212
- name: "Exporting RetroHub"
197213
working-directory: retrohub
198214
run: |
199-
../cached_builds/editor/Godot.app/Contents/MacOS/Godot --headless --export-release "macOS" ../export/macos/RetroHub.app
215+
../cached_builds/editor/Godot.app/Contents/MacOS/Godot --headless --verbose --export-release "macOS" ../export/macos/RetroHub.app
200216
201217
- name: "Sign executable"
202218
working-directory: export/macos
@@ -205,7 +221,7 @@ jobs:
205221
codesign -s - --force --deep "RetroHub.app"
206222
207223
- name: "Upload Artifacts"
208-
uses: actions/upload-artifact@v3
224+
uses: actions/upload-artifact@v4
209225
with:
210226
name: macos
211227
path: export/macos

.github/workflows/windows_build.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -25,28 +25,28 @@ jobs:
2525

2626
steps:
2727
- name: "Checkout RetroHub"
28-
uses: actions/checkout@v3
28+
uses: actions/checkout@v4
2929
with:
3030
path: "retrohub"
3131

3232
- name: "Load cached objects (Godot editor)"
33-
uses: actions/cache@v3
33+
uses: actions/cache@v4
3434
id: "cache_editor"
3535
with:
3636
path: cached_builds/editor/godot
3737
key: editor-build
3838
continue-on-error: true
3939

4040
- name: "Load cached objects (Godot templates)"
41-
uses: actions/cache@v3
41+
uses: actions/cache@v4
4242
id: "cache_template"
4343
with:
4444
path: cached_builds/template/${{ matrix.template }}
4545
key: Windows-${{ matrix.arch }}-template-build
4646
continue-on-error: true
4747

4848
- name: "Load cached objects (Videodecoder)"
49-
uses: actions/cache@v3
49+
uses: actions/cache@v4
5050
id: "cache_videodecoder"
5151
with:
5252
path: cached_builds/videodecoder/${{ matrix.videodecoder }}
@@ -55,15 +55,15 @@ jobs:
5555

5656
- name: "Checkout Custom Godot"
5757
if: steps.cache_template.outputs.cache-hit != 'true'
58-
uses: actions/checkout@v3
58+
uses: actions/checkout@v4
5959
with:
6060
repository: retrohub-org/godot
6161
ref: retrohub_patches_4x
6262
path: "godot"
6363

6464
- name: "Checkout godot-videodecoder"
6565
if: steps.cache_videodecoder.outputs.cache-hit != 'true'
66-
uses: actions/checkout@v3
66+
uses: actions/checkout@v4
6767
with:
6868
repository: retrohub-org/godot-videodecoder
6969
submodules: recursive
@@ -164,7 +164,7 @@ jobs:
164164
../cached_builds/editor/godot --headless --export-release "Windows (${{ matrix.arch }})" ../export/windows_${{ matrix.arch }}/RetroHub.exe
165165
166166
- name: "Upload Artifacts"
167-
uses: actions/upload-artifact@v3
167+
uses: actions/upload-artifact@v4
168168
with:
169169
name: windows-${{ matrix.arch }}
170170
path: export/windows_${{ matrix.arch }}
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3+
<plist version="1.0">
4+
<dict>
5+
<key>CFBundleExecutable</key>
6+
<string>libblurhash.template_debug</string>
7+
<key>CFBundleIdentifier</key>
8+
<string>com.github.rsubtil.godot-blurhash</string>
9+
<key>CFBundleInfoDictionaryVersion</key>
10+
<string>6.0</string>
11+
<key>CFBundleName</key>
12+
<string>libblurhash.macos.template_debug</string>
13+
<key>CFBundlePackageType</key>
14+
<string>FMWK</string>
15+
<key>CFBundleShortVersionString</key>
16+
<string>1.0.0</string>
17+
<key>CFBundleSupportedPlatforms</key>
18+
<array>
19+
<string>MacOSX</string>
20+
</array>
21+
<key>CFBundleVersion</key>
22+
<string>1.0.0</string>
23+
<key>LSMinimumSystemVersion</key>
24+
<string>10.12</string>
25+
</dict>
26+
</plist>
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3+
<plist version="1.0">
4+
<dict>
5+
<key>CFBundleExecutable</key>
6+
<string>libblurhash.template_release</string>
7+
<key>CFBundleIdentifier</key>
8+
<string>com.github.rsubtil.godot-blurhash</string>
9+
<key>CFBundleInfoDictionaryVersion</key>
10+
<string>6.0</string>
11+
<key>CFBundleName</key>
12+
<string>libblurhash.macos.template_release</string>
13+
<key>CFBundlePackageType</key>
14+
<string>FMWK</string>
15+
<key>CFBundleShortVersionString</key>
16+
<string>1.0.0</string>
17+
<key>CFBundleSupportedPlatforms</key>
18+
<array>
19+
<string>MacOSX</string>
20+
</array>
21+
<key>CFBundleVersion</key>
22+
<string>1.0.0</string>
23+
<key>LSMinimumSystemVersion</key>
24+
<string>10.12</string>
25+
</dict>
26+
</plist>
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3+
<plist version="1.0">
4+
<dict>
5+
<key>CFBundleExecutable</key>
6+
<string>librcheevos-rhash.template_debug</string>
7+
<key>CFBundleIdentifier</key>
8+
<string>org.retrohub.godot-rcheevos-rhash</string>
9+
<key>CFBundleInfoDictionaryVersion</key>
10+
<string>6.0</string>
11+
<key>CFBundleName</key>
12+
<string>librcheevos-rhash.macos.template_debug</string>
13+
<key>CFBundlePackageType</key>
14+
<string>FMWK</string>
15+
<key>CFBundleShortVersionString</key>
16+
<string>1.0.0</string>
17+
<key>CFBundleSupportedPlatforms</key>
18+
<array>
19+
<string>MacOSX</string>
20+
</array>
21+
<key>CFBundleVersion</key>
22+
<string>1.0.0</string>
23+
<key>LSMinimumSystemVersion</key>
24+
<string>10.12</string>
25+
</dict>
26+
</plist>
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3+
<plist version="1.0">
4+
<dict>
5+
<key>CFBundleExecutable</key>
6+
<string>librcheevos-rhash.template_release</string>
7+
<key>CFBundleIdentifier</key>
8+
<string>org.retrohub.godot-rcheevos-rhash</string>
9+
<key>CFBundleInfoDictionaryVersion</key>
10+
<string>6.0</string>
11+
<key>CFBundleName</key>
12+
<string>librcheevos-rhash.macos.template_release</string>
13+
<key>CFBundlePackageType</key>
14+
<string>FMWK</string>
15+
<key>CFBundleShortVersionString</key>
16+
<string>1.0.0</string>
17+
<key>CFBundleSupportedPlatforms</key>
18+
<array>
19+
<string>MacOSX</string>
20+
</array>
21+
<key>CFBundleVersion</key>
22+
<string>1.0.0</string>
23+
<key>LSMinimumSystemVersion</key>
24+
<string>10.12</string>
25+
</dict>
26+
</plist>

0 commit comments

Comments
 (0)