Skip to content

Commit 1ac029c

Browse files
Build Android targets on Linux
1 parent 3bab125 commit 1ac029c

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

samples/Sentry.Samples.Maui/Sentry.Samples.Maui.csproj

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,13 @@
22

33
<PropertyGroup>
44
<!--
5-
On Mac, we'll build for Android, iOS, and MacCatalyst.
6-
On Windows, we'll build for Android and Windows 10
5+
We can build for Android from all build platforms.
6+
On Mac, we'll also build for iOS and MacCatalyst.
7+
On Windows, we'll also build for Windows 10.
78
-->
8-
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('windows'))">net6.0-android;net6.0-windows10.0.19041.0</TargetFrameworks>
9-
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('OSX'))">net6.0-android;net6.0-ios;net6.0-maccatalyst</TargetFrameworks>
9+
<TargetFrameworks>net6.0-android</TargetFrameworks>
10+
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('windows'))">$(TargetFrameworks);net6.0-windows10.0.19041.0</TargetFrameworks>
11+
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('OSX'))">$(TargetFrameworks);net6.0-ios;net6.0-maccatalyst</TargetFrameworks>
1012
<OutputType>Exe</OutputType>
1113
<RootNamespace>Sentry.Samples.Maui</RootNamespace>
1214
<UseMaui>true</UseMaui>

src/Sentry/Sentry.csproj

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFrameworks>net6.0;net5.0;netcoreapp3.0;netstandard2.1;netstandard2.0;net461</TargetFrameworks>
5-
<!-- .NET Android Workload doesn't support Linux -->
6-
<TargetFrameworks Condition="!$([MSBuild]::IsOSPlatform('Linux'))">$(TargetFrameworks);net6.0-android</TargetFrameworks>
4+
<TargetFrameworks>net6.0;net5.0;netcoreapp3.0;netstandard2.1;netstandard2.0;net461;net6.0-android</TargetFrameworks>
75
<!-- We'll pin to C# 9 and ImplicitUsings false to allow us to compile within Unity -->
86
<LangVersion>9</LangVersion>
97
<ImplicitUsings>false</ImplicitUsings>

0 commit comments

Comments
 (0)