Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ The .NET Foundation licenses this file to you under the MIT license.
<Target Name="SetupOSSpecificProps" DependsOnTargets="$(IlcDynamicBuildPropertyDependencies)">

<PropertyGroup>
<!-- API level specified here MUST be the same as the one used by .NET for Android. .NET for Android targets will
take care to always set this property. -->
Comment thread
grendello marked this conversation as resolved.
<CrossCompileAndroidApiLevel Condition="'$(CrossCompileAndroidApiLevel)' == ''">21</CrossCompileAndroidApiLevel>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ The default here is 21, but the PR description states the change "makes the API level configurable and default to 24." The code preserves the prior hardcoded 21 default. If keeping 21 is intentional (to avoid changing behavior for existing NativeAOT consumers that don't set the property, with .NET for Android supplying 24 via its targets), that's a reasonable choice — but please reconcile the PR description so it matches the code. If the intent really was to default to 24, this value should be updated. The inline comment above also says the value "MUST be the same as the one used by .NET for Android," which is confusing given that .NET for Android overrides it anyway; consider clarifying that 21 is only the fallback when no consumer sets the property.


<UseSystemZlib Condition="'$(UseSystemZlib)' == '' and !Exists('$(IlcFrameworkNativePath)libz.a')">true</UseSystemZlib>
<!-- Use libbrotlicommon.a as the sentinel for the three brotli libs. -->
<UseSystemBrotli Condition="'$(UseSystemBrotli)' == '' and !Exists('$(IlcFrameworkNativePath)libbrotlicommon.a')">true</UseSystemBrotli>
Expand All @@ -48,10 +52,10 @@ The .NET Foundation licenses this file to you under the MIT license.
<CrossCompileArch Condition="$(CrossCompileRid.EndsWith('-arm'))">armv7</CrossCompileArch>

<CrossCompileAbi>gnu</CrossCompileAbi>
<CrossCompileAbi Condition="$(CrossCompileRid.StartsWith('linux-bionic-')) or $(CrossCompileRid.StartsWith('android-'))">android21</CrossCompileAbi>
<CrossCompileAbi Condition="$(CrossCompileRid.StartsWith('linux-bionic-')) or $(CrossCompileRid.StartsWith('android-'))">android$(CrossCompileAndroidApiLevel)</CrossCompileAbi>
<CrossCompileAbi Condition="$(CrossCompileRid.StartsWith('linux-musl-')) or $(CrossCompileRid.StartsWith('alpine-'))">musl</CrossCompileAbi>
<CrossCompileAbi Condition="'$(CrossCompileRid)' == 'linux-arm'">gnueabihf</CrossCompileAbi>
<CrossCompileAbi Condition="'$(CrossCompileRid)' == 'linux-bionic-arm' or '$(CrossCompileRid)' == 'android-arm'">androideabi21</CrossCompileAbi>
<CrossCompileAbi Condition="'$(CrossCompileRid)' == 'linux-bionic-arm' or '$(CrossCompileRid)' == 'android-arm'">androideabi$(CrossCompileAndroidApiLevel)</CrossCompileAbi>
<CrossCompileAbi Condition="'$(CrossCompileRid)' == 'linux-musl-arm'">musleabihf</CrossCompileAbi>
</PropertyGroup>

Expand Down
Loading