Skip to content

Fix build warnings in this repo #10279

@jonathanpeppers

Description

@jonathanpeppers

Android framework version

net10.0-android (Preview)

Affected platform version

.NET 10

Description

Review Directory.Build.props.

The following lines can be removed, and the resulting build warnings fixed:

    <_AllowProjectWarnings Condition=" '$(MSBuildProjectFile)' == 'Microsoft.Android.Sdk.ILLink.csproj' ">true</_AllowProjectWarnings>
    <_AllowProjectWarnings Condition=" '$(MSBuildProjectFile)' == 'Microsoft.Android.Templates.csproj' ">true</_AllowProjectWarnings>
    <_AllowProjectWarnings Condition=" '$(MSBuildProjectFile)' == 'MSBuildDeviceIntegration.csproj' ">true</_AllowProjectWarnings>
    <_AllowProjectWarnings Condition=" '$(MSBuildProjectFile)' == 'Xamarin.Android.Build.Tasks.csproj' ">true</_AllowProjectWarnings>
    <_AllowProjectWarnings Condition=" '$(MSBuildProjectFile)' == 'Xamarin.Android.Build.Tests.csproj' ">true</_AllowProjectWarnings>
    <_AllowProjectWarnings Condition=" '$(MSBuildProjectFile)' == 'Xamarin.ProjectTools.csproj' ">true</_AllowProjectWarnings>

To see the warnings (as errors), you can build with:

./dotnet-local.sh build Xamarin.Android.sln -p:_AndroidTreatWarningsAsErrors=true

If you can't fix some of these, restore the lines and report what went wrong.

We should fix as many of these that are simple & straightforward to solve.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions