Skip to content

Commit 707a12c

Browse files
authored
Merge pull request #14 from janusw/gha_linux
GHA: add Linux build
2 parents e2f1eb2 + 7aa5960 commit 707a12c

File tree

3 files changed

+27
-4
lines changed

3 files changed

+27
-4
lines changed

.github/workflows/dotnet.yml

+23-2
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ jobs:
4343
path: ./Source/*/nuget/*.nupkg
4444

4545
macBuild:
46-
runs-on: macos-13
46+
runs-on: macos-14
4747
steps:
4848
- uses: actions/checkout@v4
4949
with:
@@ -55,7 +55,7 @@ jobs:
5555
- name: Setup XCode
5656
uses: maxim-lobanov/setup-xcode@v1
5757
with:
58-
xcode-version: '15.1'
58+
xcode-version: '15'
5959
- name: Install .NET MAUI
6060
run: |
6161
dotnet nuget locals all --clear
@@ -65,3 +65,24 @@ jobs:
6565
run: dotnet build ./Source/OxyPlot.Maui.Skia/OxyPlot.Maui.Skia.csproj /p:Configuration=Release /t:restore,build,pack /p:Version=$(git describe) /p:ContinuousIntegrationBuild=true /p:DeterministicSourcePaths=false
6666
- name: Build sample
6767
run: dotnet build ./Source/OxyplotMauiSample/OxyplotMauiSample.csproj /p:Configuration=Release /t:restore,build /p:Version=$(git describe) /p:ContinuousIntegrationBuild=true /p:DeterministicSourcePaths=false
68+
69+
linuxBuild:
70+
runs-on: ubuntu-latest
71+
steps:
72+
- uses: actions/checkout@v4
73+
with:
74+
fetch-depth: 0
75+
- name: Setup .NET
76+
uses: actions/setup-dotnet@v4
77+
with:
78+
dotnet-version: 8.0.x
79+
- name: Install workloads
80+
run: dotnet workload install android wasm-tools maui-android
81+
- name: Install Android tools
82+
run: |
83+
${ANDROID_SDK_ROOT}/cmdline-tools/latest/bin/sdkmanager \
84+
--sdk_root=$ANDROID_SDK_ROOT "platform-tools"
85+
- name: Build library (with nuget package)
86+
run: dotnet build ./Source/OxyPlot.Maui.Skia/OxyPlot.Maui.Skia.csproj /p:Configuration=Release /t:restore,build,pack /p:Version=$(git describe) /p:ContinuousIntegrationBuild=true /p:DeterministicSourcePaths=false
87+
- name: Build sample
88+
run: dotnet build ./Source/OxyplotMauiSample/OxyplotMauiSample.csproj /p:Configuration=Release /t:restore,build /p:Version=$(git describe) /p:ContinuousIntegrationBuild=true /p:DeterministicSourcePaths=false

Source/OxyPlot.Maui.Skia/OxyPlot.Maui.Skia.csproj

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFrameworks>net8.0;net8.0-android34.0;net8.0-ios;net8.0-maccatalyst</TargetFrameworks>
4+
<TargetFrameworks>net8.0;net8.0-android34.0</TargetFrameworks>
5+
<TargetFrameworks Condition="!$([MSBuild]::IsOSPlatform('linux'))">$(TargetFrameworks);net8.0-ios;net8.0-maccatalyst</TargetFrameworks>
56
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('windows'))">$(TargetFrameworks);net8.0-windows10.0.19041.0</TargetFrameworks>
67
<!-- Uncomment to also build the tizen app. You will need to install tizen by following this: https://github.com/Samsung/Tizen.NET -->
78
<!-- <TargetFrameworks>$(TargetFrameworks);net7.0-tizen</TargetFrameworks> -->

Source/OxyplotMauiSample/OxyplotMauiSample.csproj

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFrameworks>net8.0-android34.0;net8.0-ios;net8.0-maccatalyst</TargetFrameworks>
4+
<TargetFrameworks>net8.0-android34.0</TargetFrameworks>
5+
<TargetFrameworks Condition="!$([MSBuild]::IsOSPlatform('linux'))">$(TargetFrameworks);net8.0-ios;net8.0-maccatalyst</TargetFrameworks>
56
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('windows'))">$(TargetFrameworks);net8.0-windows10.0.19041.0</TargetFrameworks>
67
<!-- Uncomment to also build the tizen app. You will need to install tizen by following this: https://github.com/Samsung/Tizen.NET -->
78
<!-- <TargetFrameworks>$(TargetFrameworks);net6.0-tizen</TargetFrameworks> -->

0 commit comments

Comments
 (0)