-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Partially implement build-fnalibs-apple.sh
- Loading branch information
1 parent
d02dfc4
commit 8590f25
Showing
2 changed files
with
61 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,49 @@ | ||
#!/bin/bash | ||
|
||
# TODO: Draw the rest of the owl | ||
set -ex | ||
|
||
mkdir fnalibs-apple | ||
workflow_id=$(gh -R libsdl-org/SDL run list -b main --json databaseId --jq '.[0].databaseId') | ||
gh -R libsdl-org/SDL run download ${workflow_id} -p 'SDL-macos-framework' | ||
gh -R libsdl-org/SDL run download ${workflow_id} -p 'SDL-ios-arm64' | ||
gh -R libsdl-org/SDL run download ${workflow_id} -p 'SDL-tvos-arm64' | ||
|
||
workflow_id=$(gh -R FNA-XNA/FAudio run list -b master --json databaseId --jq '.[0].databaseId') | ||
gh -R FNA-XNA/FAudio run download ${workflow_id} -p 'FAudio-SDL3-osx' | ||
gh -R FNA-XNA/FAudio run download ${workflow_id} -p 'FAudio-SDL3-iphoneos' | ||
gh -R FNA-XNA/FAudio run download ${workflow_id} -p 'FAudio-SDL3-appletvos' | ||
|
||
workflow_id=$(gh -R FNA-XNA/FNA3D run list -b master --json databaseId --jq '.[0].databaseId') | ||
gh -R FNA-XNA/FNA3D run download ${workflow_id} -p 'FNA3D-SDL3-osx' | ||
gh -R FNA-XNA/FNA3D run download ${workflow_id} -p 'FNA3D-SDL3-iphoneos' | ||
gh -R FNA-XNA/FNA3D run download ${workflow_id} -p 'FNA3D-SDL3-appletvos' | ||
|
||
workflow_id=$(gh -R FNA-XNA/Theorafile run list -b master --json databaseId --jq '.[0].databaseId') | ||
gh -R FNA-XNA/Theorafile run download ${workflow_id} -p 'Theorafile-osx' | ||
gh -R FNA-XNA/Theorafile run download ${workflow_id} -p 'Theorafile-iphoneos' | ||
gh -R FNA-XNA/Theorafile run download ${workflow_id} -p 'Theorafile-appletvos' | ||
|
||
mkdir -p fnalibs-apple | ||
cp fnalibs-apple.README fnalibs-apple/README.txt | ||
|
||
mkdir -p fnalibs-apple/osx | ||
# TODO: Extract the dmg for SDL, copy to osx/, install_name_tool | ||
mv FAudio-SDL3-osx/libFAudio.0.dylib fnalibs-apple/osx/ | ||
mv FNA3D-SDL3-osx/libFNA3D.0.dylib fnalibs-apple/osx/ | ||
mv Theorafile-osx/libtheorafile.dylib fnalibs-apple/osx/ | ||
#xattr -c fnalibs-apple/osx/*.dylib | ||
|
||
mkdir -p fnalibs-apple/iphoneos | ||
tar xvfz SDL-ios-arm64/dist/SDL3-3.1.5-iOS.tar.gz SDL3-3.1.5-iOS/lib/libSDL3.a | ||
mv SDL3-3.1.5-iOS/lib/libSDL3.a fnalibs-apple/iphoneos/ | ||
mv FAudio-SDL3-iphoneos/libFAudio.a fnalibs-apple/iphoneos/ | ||
mv FNA3D-SDL3-iphoneos/libFNA3D.a fnalibs-apple/iphoneos/ | ||
mv FNA3D-SDL3-iphoneos/libmojoshader.a fnalibs-apple/iphoneos/ | ||
mv Theorafile-iphoneos/libtheorafile.a fnalibs-apple/iphoneos/ | ||
|
||
mkdir -p fnalibs-apple/appletvos | ||
tar xvfz SDL-tvos-arm64/dist/SDL3-3.1.5-tvOS.tar.gz SDL3-3.1.5-tvOS/lib/libSDL3.a | ||
mv SDL3-3.1.5-tvOS/lib/libSDL3.a fnalibs-apple/appletvos/ | ||
mv FAudio-SDL3-appletvos/libFAudio.a fnalibs-apple/appletvos/ | ||
mv FNA3D-SDL3-appletvos/libFNA3D.a fnalibs-apple/appletvos/ | ||
mv FNA3D-SDL3-appletvos/libmojoshader.a fnalibs-apple/appletvos/ | ||
mv Theorafile-appletvos/libtheorafile.a fnalibs-apple/appletvos/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
This is fnalibs-apple, an archive containing the native libraries used by FNA | ||
to target Apple platforms. | ||
|
||
These are the folders included: | ||
|
||
- osx: macOS Universal dynamic libraries, requires version 10.9 or newer | ||
- iphoneos: iOS static libraries (arm64 only), requires version 13 or newer | ||
- appletvos: tvOS static libraries (arm64 only), requires version 13 or newer | ||
|
||
The library dependency list is as follows: | ||
|
||
- SDL3, used as the platform layer | ||
- FNA3D, used in the Graphics namespace | ||
- For static libraries, mojoshader.a is used by libFNA3D.a | ||
- FAudio, used in the Audio/Media namespaces | ||
- libtheorafile, only used for VideoPlayer |