Skip to content

Commit

Permalink
Merge branch 'master' into hacky-circle
Browse files Browse the repository at this point in the history
  • Loading branch information
EVAST9919 committed Aug 28, 2024
2 parents bcac4ac + a4a2b68 commit f77f946
Show file tree
Hide file tree
Showing 128 changed files with 2,400 additions and 1,621 deletions.
117 changes: 116 additions & 1 deletion .github/workflows/build-ffmpeg.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,80 @@ jobs:

- name: Combine
run: osu.Framework.NativeLibs/scripts/ffmpeg/combine_dylibs.sh
env:
platform: macOS

- name: Upload
uses: actions/upload-artifact@v4
with:
name: macOS-universal
path: macOS-universal

build-iOS:
name: Build iOS
runs-on: macos-12
strategy:
matrix:
arch: [arm64, simulator-arm64, simulator-x86_64]

steps:
- name: Checkout
uses: actions/checkout@v4

- uses: ilammy/setup-nasm@v1
if: matrix.arch == 'simulator-x86_64'

- name: Setup gas-preprocessor
run: |
git clone --depth=1 https://github.com/FFmpeg/gas-preprocessor
echo "GAS_PREPROCESSOR=$PWD/gas-preprocessor/gas-preprocessor.pl" >> $GITHUB_ENV
- name: Build
run: osu.Framework.NativeLibs/scripts/ffmpeg/build-iOS.sh
env:
arch: ${{ matrix.arch }}

- name: Upload
uses: actions/upload-artifact@v4
with:
name: iOS-${{ matrix.arch }}
path: iOS-${{ matrix.arch }}

combine-iOS:
name: Combine iOS libs
runs-on: macos-12
needs: build-iOS
steps:
- name: Checkout
uses: actions/checkout@v4

- uses: actions/download-artifact@v4
with:
name: iOS-simulator-x86_64
path: iOS-simulator-x86_64
- uses: actions/download-artifact@v4
with:
name: iOS-simulator-arm64
path: iOS-simulator-arm64
- uses: actions/download-artifact@v4
with:
name: iOS-arm64
path: iOS-arm64

- name: Combine dylibs
run: osu.Framework.NativeLibs/scripts/ffmpeg/combine_dylibs.sh
env:
platform: iOS-simulator

- name: Create XCFrameworks
run: osu.Framework.NativeLibs/scripts/ffmpeg/create-xcframeworks.sh

- name: Upload
uses: actions/upload-artifact@v4
with:
name: iOS-xcframework
path: iOS-xcframework

build-win:
name: Build Windows
runs-on: ubuntu-22.04
Expand Down Expand Up @@ -112,7 +179,7 @@ jobs:
- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install nasm libva-dev libvdpau-dev
sudo apt-get install nasm
- name: Checkout
uses: actions/checkout@v4
Expand All @@ -126,14 +193,42 @@ jobs:
name: linux-x64
path: linux-x64

build-android:
name: Build Android
runs-on: ubuntu-22.04
strategy:
matrix:
arch:
- armeabi-v7a
- arm64-v8a
- x86
- x86_64

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Build
run: osu.Framework.NativeLibs/scripts/ffmpeg/build-android.sh
env:
arch: ${{ matrix.arch }}

- name: Upload
uses: actions/upload-artifact@v4
with:
name: android-${{ matrix.arch }}
path: android-${{ matrix.arch }}

make-pr:
name: Create pull request
runs-on: ubuntu-22.04
needs:
- combine-macos
- combine-iOS
- build-win
- build-win-arm64
- build-linux
- build-android
steps:
- name: Checkout
uses: actions/checkout@v4
Expand All @@ -142,6 +237,10 @@ jobs:
with:
name: macOS-universal
path: osu.Framework.NativeLibs/runtimes/osx/native
- uses: actions/download-artifact@v4
with:
name: iOS-xcframework
path: osu.Framework.iOS/runtimes/ios/native
- uses: actions/download-artifact@v4
with:
name: linux-x64
Expand All @@ -158,6 +257,22 @@ jobs:
with:
name: win-x86
path: osu.Framework.NativeLibs/runtimes/win-x86/native
- uses: actions/download-artifact@v4
with:
name: android-armeabi-v7a
path: osu.Framework.Android/armeabi-v7a
- uses: actions/download-artifact@v4
with:
name: android-arm64-v8a
path: osu.Framework.Android/arm64-v8a
- uses: actions/download-artifact@v4
with:
name: android-x86
path: osu.Framework.Android/x86
- uses: actions/download-artifact@v4
with:
name: android-x86_64
path: osu.Framework.Android/x86_64

- uses: peter-evans/create-pull-request@v6
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ jobs:
run: dotnet build -c ${{matrix.os.configuration}} -warnaserror osu-framework.Desktop.slnf

- name: Test
run: dotnet test $pwd/**/*.Tests/bin/${{matrix.os.configuration}}/*/*.Tests.dll --no-build --settings $pwd/build/vstestconfig.runsettings --logger "trx;LogFileName=TestResults-${{matrix.os.prettyname}}-${{matrix.threadingMode}}-${{matrix.os.configuration}}.trx"
run: dotnet test $pwd/**/*.Tests/bin/${{matrix.os.configuration}}/*/*.Tests.dll --no-build --logger "trx;LogFileName=TestResults-${{matrix.os.prettyname}}-${{matrix.threadingMode}}-${{matrix.os.configuration}}.trx" -- NUnit.ConsoleOut=0
shell: pwsh

# Attempt to upload results even if test fails.
Expand Down
16 changes: 12 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -308,12 +308,15 @@ fabric.properties
# Reference: https://github.com/JetBrains/resharper-rider-samples/blob/master/.gitignore

# User specific
**/.idea/**/workspace.xml
**/.idea/**/tasks.xml
**/.idea/shelf/*
**/.idea/dictionaries
**/.idea/httpRequests/
**/.idea/**/usage.statistics.xml
**/.idea/**/workspace.xml
.idea/**/tasks.xml
.idea/**/usage.statistics.xml
.idea/**/dictionaries
.idea/**/shelf
.idea/*/.idea/projectSettingsUpdater.xml
.idea/*/.idea/encodings.xml

# Sensitive or high-churn files
**/.idea/**/dataSources/
Expand All @@ -339,3 +342,8 @@ inspectcode

.idea/.idea.osu-framework.Desktop/.idea/misc.xml
.idea/.idea.osu-framework.Android/.idea/deploymentTargetDropDown.xml

# NativeLibs build folders and tarballs
osu.Framework.NativeLibs/scripts/ffmpeg/*/
osu.Framework.NativeLibs/scripts/ffmpeg/*.tar.gz

This file was deleted.

4 changes: 0 additions & 4 deletions .idea/.idea.osu-framework.Desktop/.idea/encodings.xml

This file was deleted.

This file was deleted.

This file was deleted.

6 changes: 0 additions & 6 deletions .idea/.idea.osu-framework/.idea/projectSettingsUpdater.xml

This file was deleted.

4 changes: 2 additions & 2 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
"${workspaceRoot}/SampleGame.Desktop/bin/Debug/net8.0/SampleGame.Desktop.dll",
],
"cwd": "${workspaceRoot}",
"preLaunchTask": "Build (Debug)",
"preLaunchTask": "Build SampleGame (Debug)",
"linux": {
"env": {
"LD_LIBRARY_PATH": "${workspaceRoot}/SampleGame.Desktop/bin/Debug/net8.0:${env:LD_LIBRARY_PATH}"
Expand All @@ -75,7 +75,7 @@
"${workspaceRoot}/SampleGame.Desktop/bin/Release/net8.0/SampleGame.Desktop.dll",
],
"cwd": "${workspaceRoot}",
"preLaunchTask": "Build (Release)",
"preLaunchTask": "Build SampleGame (Release)",
"linux": {
"env": {
"LD_LIBRARY_PATH": "${workspaceRoot}/SampleGame.Desktop/bin/Release/net8.0:${env:LD_LIBRARY_PATH}"
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@ This framework is intended to take steps beyond what you would normally expect f

## Requirements

- A desktop platform with the [.NET 6.0 SDK](https://dotnet.microsoft.com/download).
- A desktop platform with the [.NET 8.0 SDK](https://dotnet.microsoft.com/download).
- When running on linux, please have a system-wide ffmpeg installation available to support video decoding.
- When running on Windows 7 or 8.1, *[additional prerequisites](https://docs.microsoft.com/en-us/dotnet/core/install/windows?tabs=net60&pivots=os-windows#dependencies)** may be required to correctly run .NET 6 applications if your operating system is not up-to-date with the latest service packs.
- When running on Windows 7 or 8.1, *[additional prerequisites](https://docs.microsoft.com/en-us/dotnet/core/install/windows?tabs=net60&pivots=os-windows#dependencies)** may be required to correctly run .NET 8 applications if your operating system is not up-to-date with the latest service packs.
- When working with the codebase, we recommend using an IDE with intellisense and syntax highlighting, such as [Visual Studio 2019+](https://visualstudio.microsoft.com/vs/), [Jetbrains Rider](https://www.jetbrains.com/rider/), or [Visual Studio Code](https://code.visualstudio.com/) with the [EditorConfig](https://marketplace.visualstudio.com/items?itemName=EditorConfig.EditorConfig) and [C#](https://marketplace.visualstudio.com/items?itemName=ms-dotnettools.csharp) plugin installed.

### Building
Expand Down
6 changes: 0 additions & 6 deletions build/vstestconfig.runsettings

This file was deleted.

2 changes: 1 addition & 1 deletion osu-framework.iOS.slnf
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@
"SampleGame\\SampleGame.csproj"
]
}
}
}
Loading

0 comments on commit f77f946

Please sign in to comment.