Skip to content

fix SetLimitedFade to use correct code. #484

fix SetLimitedFade to use correct code.

fix SetLimitedFade to use correct code. #484

Workflow file for this run

name: Build RSDKv3
on:
push:
branches:
- master
env:
GENERAL_FLAGS: "-DRETRO_DISABLE_PLUS=ON -DCMAKE_BUILD_TYPE=Release"
# Normally you would use $VCPKG_INSTALLATION_PATH, but it's broken...so hardcode C:/vcpkg
GENERAL_WIN_FLAGS: "-DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake"
WIN32_FLAGS: "-DVCPKG_TARGET_TRIPLET=x86-windows-static -DCMAKE_PREFIX_PATH=C:/vcpkg/installed/x86-windows-static/ -A Win32"
WIN64_FLAGS: "-DVCPKG_TARGET_TRIPLET=x64-windows-static -DCMAKE_PREFIX_PATH=C:/vcpkg/installed/x64-windows-static/"
# FIXME: For some reason ubuntu enables _FORTIFY_SOURCE by default, so let's override it to prevent IO bugs
GENERAL_LINUX_FLAGS: "-DCMAKE_CXX_FLAGS='-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=0'"
GENERAL_MACOS_FLAGS: "OTHER_CFLAGS='-DRSDK_AUTOBUILD=1 -DRETRO_DEV_EXTRA=\\\"Darwin\\ -\\ AppleClang\\\"'"
jobs:
v3-windows:
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive
- name: Install dependencies
run: vcpkg install glew sdl2 libogg libtheora libvorbis --triplet=x86-windows-static
- name: Build RSDKv3
run: |
cmake -B build ${{env.GENERAL_FLAGS}} ${{env.GENERAL_WIN_FLAGS}} ${{env.WIN32_FLAGS}}
cmake --build build --parallel --config Release
- name: Move artifacts
run: |
mkdir artifacts
mv ./build/Release/*.exe ./artifacts
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: v3-windows
path: artifacts
v3-windows-x64:
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive
- name: Install dependencies
run: vcpkg install glew sdl2 libogg libtheora libvorbis --triplet=x64-windows-static
- name: Build RSDKv3
run: |
cmake -B build ${{env.GENERAL_FLAGS}} ${{env.GENERAL_WIN_FLAGS}} ${{env.WIN64_FLAGS}}
cmake --build build --parallel --config Release
- name: Move artifacts
run: |
mkdir artifacts
mv ./build/Release/*.exe ./artifacts
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: v3-windows-x64
path: artifacts
v3-android:
runs-on: windows-latest
steps:
- name: Checkout repository Android
uses: actions/checkout@v4
with:
submodules: recursive
- name: Setup MSBuild
uses: microsoft/setup-msbuild@v2
- name: Download libogg, libvorbis, and libtheora for easier includes
run: |
Invoke-WebRequest -Uri "https://ftp.osuosl.org/pub/xiph/releases/vorbis/libvorbis-1.3.7.zip" -OutFile "libvorbis.zip"
Expand-Archive -Path libvorbis.zip -DestinationPath ./dependencies/android/
Rename-Item ./dependencies/android/libvorbis-1.3.7 libvorbis
Invoke-WebRequest -Uri "https://ftp.osuosl.org/pub/xiph/releases/ogg/libogg-1.3.5.zip" -OutFile "libogg.zip"
Expand-Archive -Path libogg.zip -DestinationPath ./dependencies/android/app/jni/src/dependencies/android/
Rename-Item ./dependencies/android/app/jni/src/dependencies/android/libogg-1.3.5 libogg
Invoke-WebRequest -Uri "https://ftp.osuosl.org/pub/xiph/releases/theora/libtheora-1.1.1.zip" -OutFile "libtheora.zip"
Expand-Archive -Path libtheora.zip -DestinationPath ./dependencies/android
Rename-Item ./dependencies/android/libtheora-1.1.1 libtheora
- name: Download GLEW
run: |
Invoke-WebRequest -Uri "https://github.com/nigels-com/glew/releases/download/glew-2.2.0/glew-2.2.0-win32.zip" -OutFile "GLEW.zip"
Expand-Archive -Path GLEW.zip -DestinationPath ./dependencies/android/
Rename-Item ./dependencies/android/glew-2.2.0 glew
- name: Download SDL2
run: |
Invoke-WebRequest -Uri "https://libsdl.org/release/SDL2-2.28.3.zip" -OutFile "SDL2.zip"
Expand-Archive -Path SDL2.zip -DestinationPath ./android/app/jni/
Rename-Item ./android/app/jni/SDL2-2.28.3 SDL
- name: Move & Copy stuff
run: |
Copy-Item -Path ./dependencies/all/theoraplay -Destination ./dependencies/android/app/jni/src/dependencies/android/
Copy-Item -Path ./dependencies/android/app/jni/src/dependencies/android\* -Destination ./dependencies/
Copy-Item -Path ./dependencies/android/app/jni/src/dependencies/android/libogg/ -Destination ./dependencies/android/ -recurse
Copy-Item -Path ./dependencies/android/config_types.h -Destination ./dependencies/android/libogg/include/ogg/
- name: Set up Java
uses: actions/setup-java@v4
with:
distribution: "zulu"
java-version: 11
- name: Build RSDKv3 Android
working-directory: ./android
run: |
./gradlew.bat assembleDebug --no-daemon -PABIFILTERS="armeabi-v7a;arm64-v8a" -PRETRO_DISABLE_PLUS
- name: Upload artifact Android
uses: actions/upload-artifact@v4
with:
name: v3-android
path: ./android/app/build/outputs/apk
v3-linux:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive
- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install libglew-dev libglfw3-dev libsdl2-dev libogg-dev libtheora-dev libvorbis-dev
- name: Build RSDKv3
run: |
cmake -B build ${{env.GENERAL_FLAGS}} ${{env.GENERAL_LINUX_FLAGS}}
cmake --build build --parallel
# tar the executables so that they don't lose exec permissions
# see: https://github.com/actions/upload-artifact?tab=readme-ov-file#permission-loss
- name: Move artifacts
run: |
mkdir artifacts
mv ./build/RSDKv3* ./artifacts
tar -czvf linux.tar.gz -C ./artifacts .
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: v3-linux
path: linux.tar.gz
v3-macOS:
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive
- name: Download libogg, libvorbis, and libtheora for easier includes
run: |
curl "https://ftp.osuosl.org/pub/xiph/releases/ogg/libogg-1.3.5.zip" --output "libogg.zip"
unzip libogg.zip -d ./dependencies/mac/
mv ./dependencies/mac/libogg-1.3.5 ./dependencies/mac/libogg
curl "https://ftp.osuosl.org/pub/xiph/releases/vorbis/libvorbis-1.3.7.zip" --output "libvorbis.zip"
unzip libvorbis.zip -d ./dependencies/mac/
mv ./dependencies/mac/libvorbis-1.3.7 ./dependencies/mac/libvorbis
curl "https://ftp.osuosl.org/pub/xiph/releases/theora/libtheora-1.1.1.zip" --output "libtheora.zip"
unzip libtheora.zip -d ./dependencies/mac/
mv ./dependencies/mac/libtheora-1.1.1 ./dependencies/mac/libtheora
- name: Download SDL2
run: |
curl "https://libsdl.org/release/SDL2-2.30.7.dmg" --output "SDL2.dmg"
hdiutil attach SDL2.dmg
cp -r /Volumes/SDL2/SDL2.framework ./dependencies/mac
- name: Generate Vorbis headers
working-directory: ./dependencies/mac/libogg/
run: |
./configure
- name: Build RSDKv3
run: |
xcodebuild -project RSDKv3.xcodeproj -scheme RSDKv3 DSTROOT="./build" -configuration Release DEPLOYMENT_LOCATION=YES ${{env.GENERAL_MACOS_FLAGS}}
- name: Zip the app ourselves (Important step to retain symlinks)
run: |
cd ./build/Applications/
echo 'From this folder, run `xattr -cr RSDKv3.app` in Terminal to allow MacOS to open it.' > README.txt
zip -r RSDKv3.zip .
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: v3-mac
path: build/Applications/RSDKv3.zip