Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change MonoAotCrossCompiler property into ItemGroup in installer project #53653

Closed
steveisok opened this issue Jun 3, 2021 · 1 comment · Fixed by #53685
Closed

Change MonoAotCrossCompiler property into ItemGroup in installer project #53653

steveisok opened this issue Jun 3, 2021 · 1 comment · Fixed by #53685
Assignees
Labels
area-Infrastructure-mono untriaged New issue has not been triaged by the area owner
Milestone

Comments

@steveisok
Copy link
Member

As of right now, we are including a MonoAotCrossCompilerPath property in each of the packs we ship.

<MonoAotCrossCompilerPath>$(MSBuildThisFileDirectory)..\tools\mono-aot-cross</MonoAotCrossCompilerPath>
<MonoAotCrossCompilerPath Condition="$([MSBuild]::IsOsPlatform('Windows'))">$(MonoAotCrossCompilerPath).exe</MonoAotCrossCompilerPath>

This creates a problem in the Mono workload because we import more than 1 for Android and iOS:

<ImportGroup Condition="'$(TargetPlatformIdentifier)' == 'android' and '$(RunAOTCompilation)' == 'true'">
<Import Project="Sdk.props" Sdk="Microsoft.NETCore.App.Runtime.AOT.Cross.android-x86" />
<Import Project="Sdk.props" Sdk="Microsoft.NETCore.App.Runtime.AOT.Cross.android-x64" />
<Import Project="Sdk.props" Sdk="Microsoft.NETCore.App.Runtime.AOT.Cross.android-arm" />
<Import Project="Sdk.props" Sdk="Microsoft.NETCore.App.Runtime.AOT.Cross.android-arm64" />
</ImportGroup>

To solve the problem, we should change into an ItemGroup and include the architecture. The consumers of the pack will need to pick which item to select.

Example:

<ItemGroup>
    <MonoAotCrossCompilerPath Include="(path)" RuntimeIdentifier="ios-x64" />
    <MonoAotCrossCompilerPath Include="(path)" RuntimeIdentifier="ios-arm64" />
</ItemGroup>

/cc @lewing @radical @akoeplinger

@steveisok steveisok added this to the 6.0.0 milestone Jun 3, 2021
@ghost
Copy link

ghost commented Jun 3, 2021

Tagging subscribers to this area: @directhex
See info in area-owners.md if you want to be subscribed.

Issue Details

As of right now, we are including a MonoAotCrossCompilerPath property in each of the packs we ship.

<MonoAotCrossCompilerPath>$(MSBuildThisFileDirectory)..\tools\mono-aot-cross</MonoAotCrossCompilerPath>
<MonoAotCrossCompilerPath Condition="$([MSBuild]::IsOsPlatform('Windows'))">$(MonoAotCrossCompilerPath).exe</MonoAotCrossCompilerPath>

This creates a problem in the Mono workload because we import more than 1 for Android and iOS:

<ImportGroup Condition="'$(TargetPlatformIdentifier)' == 'android' and '$(RunAOTCompilation)' == 'true'">
<Import Project="Sdk.props" Sdk="Microsoft.NETCore.App.Runtime.AOT.Cross.android-x86" />
<Import Project="Sdk.props" Sdk="Microsoft.NETCore.App.Runtime.AOT.Cross.android-x64" />
<Import Project="Sdk.props" Sdk="Microsoft.NETCore.App.Runtime.AOT.Cross.android-arm" />
<Import Project="Sdk.props" Sdk="Microsoft.NETCore.App.Runtime.AOT.Cross.android-arm64" />
</ImportGroup>

To solve the problem, we should change into an ItemGroup and include the architecture. The consumers of the pack will need to pick which item to select.

Example:

<ItemGroup>
    <MonoAotCrossCompilerPath Include="(path)" RuntimeIdentifier="ios-x64" />
    <MonoAotCrossCompilerPath Include="(path)" RuntimeIdentifier="ios-arm64" />
</ItemGroup>

/cc @lewing @radical @akoeplinger

Author: steveisok
Assignees: -
Labels:

area-Infrastructure-mono

Milestone: 6.0.0

@dotnet-issue-labeler dotnet-issue-labeler bot added the untriaged New issue has not been triaged by the area owner label Jun 3, 2021
directhex added a commit to directhex/runtime that referenced this issue Jun 3, 2021
Fixes dotnet#53653

Example:

```
sudo cat Sdk/Sdk.props
<Project>
  <ItemGroup>
    <MonoAotCrossCompilerPath Include="$(MSBuildThisFileDirectory)..\tools\mono-aot-cross" RuntimeIdentifier="iossimulator-arm64" />
  </ItemGroup>
</Project>
```
@ghost ghost added the in-pr There is an active PR which will close this issue when it is merged label Jun 3, 2021
directhex added a commit that referenced this issue Jun 7, 2021
* Create Sdk.props in AOT compilers with a template

Fixes #53653

Example:

```
sudo cat Sdk/Sdk.props
<Project>
  <ItemGroup>
    <MonoAotCrossCompilerPath Include="$(MSBuildThisFileDirectory)..\tools\mono-aot-cross" RuntimeIdentifier="iossimulator-arm64" />
  </ItemGroup>
</Project>
```
@ghost ghost removed the in-pr There is an active PR which will close this issue when it is merged label Jun 7, 2021
@ghost ghost locked as resolved and limited conversation to collaborators Jul 7, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-Infrastructure-mono untriaged New issue has not been triaged by the area owner
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants