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

NETSDK1203: Ahead-of-time compilation is not supported for the target runtime identifier 'ios-arm64'. #95958

Closed
rolfbjarne opened this issue Dec 13, 2023 · 5 comments

Comments

@rolfbjarne
Copy link
Member

From @rsanford-hh2 on Wed, 13 Dec 2023 04:09:26 GMT

Steps to Reproduce

Following the instructions at https://github.com/dotnet/samples/tree/main/core/nativeaot/NativeLibrary.

  • dotnet new classlib -o NativeLibrary
  • add the PublishAOT true flag to the .csproj file
  • dotnet publish /p:NativeLib=Shared --use-current-runtime succeeds
  • `dotnet publish -r:ios-arm64' fails with the error message in the title of the issue and in the Actual Behavior section

Expected Behavior

I expect that I will get an AOT library for iOS. iOS for ARM64 is experimental according to...
https://learn.microsoft.com/en-us/dotnet/core/deploying/native-aot/?tabs=net8plus%2Cwindows

Actual Behavior

NETSDK1203: Ahead-of-time compilation is not supported for the target runtime identifier 'ios-arm64'. [/Users/myusername/Projects/MyNetProject/NativeLib/NativeLib.csproj::TargetFramework=net8.0]

Environment

Version information ``` Visual Studio Professional 2022 for Mac Version 17.6.7 (build 417) Installation UUID: da5a6a50-0b52-4e5f-8830-f56890f8cecd

Runtime
.NET 7.0.3 (64-bit)
Architecture: Arm64
Microsoft.macOS.Sdk 13.1.1007; git-rev-head:8afca776a0a96613dfb7200e0917bb57f9ed5583; git-branch:release/7.0.1xx-xcode14.2

Roslyn (Language Service)
4.6.0-3.23180.6+99e956e42697a6dd886d1e12478ea2b27cceacfa

NuGet
Version: 6.4.0.117

.NET SDK (Arm64)
SDK: /usr/local/share/dotnet/sdk/8.0.100/Sdks
SDK Versions:
8.0.100
7.0.311
6.0.417
6.0.416
MSBuild SDKs: /Applications/Visual Studio.app/Contents/MonoBundle/MSBuild/Current/bin/Sdks

.NET Runtime (Arm64)
Runtime: /usr/local/share/dotnet/dotnet
Runtime Versions:
8.0.0
7.0.14
6.0.25
6.0.24

Xamarin.Profiler
Version: 1.8.0.49
Location: /Applications/Xamarin Profiler.app/Contents/MacOS/Xamarin Profiler

Updater
Version: 11

Apple Developer Tools
Xcode: 15.1 22502
Build: 15C65

Xamarin.Mac
Version: 9.3.0.23 Visual Studio Professional
Hash: 9defd91b3
Branch: xcode14.3
Build date: 2023-10-23 16:14:59-0400

Xamarin.iOS
Version: 16.4.0.23 Visual Studio Professional
Hash: 9defd91b3
Branch: xcode14.3
Build date: 2023-10-23 16:15:00-0400

Xamarin Designer
Version: 17.6.3.9
Hash: 2648399ae8
Branch: remotes/origin/d17-6
Build date: 2023-11-10 12:19:46 UTC

Xamarin.Android
Version: 13.2.2.0 (Visual Studio Professional)
Commit: xamarin-android/d17-5/45b0e14
Android SDK: /Users/ebenezer/Library/Developer/Xamarin/android-sdk-macosx
Supported Android versions:
12.0 (API level 31)
13.0 (API level 33)

SDK Command-line Tools Version: 7.0
SDK Platform Tools Version: 34.0.3
SDK Build Tools Version: 32.0.0

Build Information:
Mono: d9a6e87
Java.Interop: xamarin/java.interop/d17-5@149d70fe
SQLite: xamarin/sqlite@68c69d8
Xamarin.Android Tools: xamarin/xamarin-android-tools/d17-5@ca1552d

Microsoft Build of OpenJDK
Java SDK: /Library/Java/JavaVirtualMachines/microsoft-11.jdk
11.0.16.1
Android Designer EPL code available here:
https://github.com/xamarin/AndroidDesigner.EPL

Eclipse Temurin JDK
Java SDK: /Library/Java/JavaVirtualMachines/temurin-8.jdk
1.8.0.302
Android Designer EPL code available here:
https://github.com/xamarin/AndroidDesigner.EPL

Android SDK Manager
Version: 17.6.0.50
Hash: a715dca
Branch: HEAD
Build date: 2023-11-10 12:19:52 UTC

Android Device Manager
Version: 0.0.0.1309
Hash: 06e3e77
Branch: HEAD
Build date: 2023-11-10 12:19:52 UTC

Build Information
Release ID: 1706070417
Git revision: 179aa48a5702754e41a8218d0403ddc3be46706f
Build date: 2023-11-10 12:18:09+00
Build branch: release-17.6
Build lane: release-17.6

Operating System
Mac OS X 14.2.0
Darwin 23.2.0 Darwin Kernel Version 23.2.0
Wed Nov 15 21:55:06 PST 2023
root:xnu-10002.61.3~2/RELEASE_ARM64_T6020 arm64

Enabled user installed extensions
Project System Tools 0.13


</details>

### Build Logs

<!--
1. How to get a build log: https://github.com/xamarin/xamarin-macios/wiki/Diagnosis#build-logs
2. Place the cursor below this comment block.
3. Drag and drop the build log.
-->

### Example Project (If Possible)

<!--
1. Place cursor below this comment block.
2. Drag and drop the compressed project or files needed to reproduce.
-->
[NativeLib_Debug_Build_2023-12-13T04_04_13.5060410Z.msbuild.log](https://github.com/xamarin/xamarin-macios/files/13655816/NativeLib_Debug_Build_2023-12-13T04_04_13.5060410Z.msbuild.log)

<!--
Switch to the "Preview" tab to ensure your issue renders correctly.
-->


_Copied from original issue xamarin/xamarin-macios#19626_
@dotnet-issue-labeler dotnet-issue-labeler bot added the needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners label Dec 13, 2023
@ghost ghost added the untriaged New issue has not been triaged by the area owner label Dec 13, 2023
@rolfbjarne
Copy link
Member Author

CC @steveisok I believe this is what you've been working on for .NET 8

@ghost
Copy link

ghost commented Dec 13, 2023

Tagging subscribers to this area: @agocke, @MichalStrehovsky, @jkotas
See info in area-owners.md if you want to be subscribed.

Issue Details

From @rsanford-hh2 on Wed, 13 Dec 2023 04:09:26 GMT

Steps to Reproduce

Following the instructions at https://github.com/dotnet/samples/tree/main/core/nativeaot/NativeLibrary.

  • dotnet new classlib -o NativeLibrary
  • add the PublishAOT true flag to the .csproj file
  • dotnet publish /p:NativeLib=Shared --use-current-runtime succeeds
  • `dotnet publish -r:ios-arm64' fails with the error message in the title of the issue and in the Actual Behavior section

Expected Behavior

I expect that I will get an AOT library for iOS. iOS for ARM64 is experimental according to...
https://learn.microsoft.com/en-us/dotnet/core/deploying/native-aot/?tabs=net8plus%2Cwindows

Actual Behavior

NETSDK1203: Ahead-of-time compilation is not supported for the target runtime identifier 'ios-arm64'. [/Users/myusername/Projects/MyNetProject/NativeLib/NativeLib.csproj::TargetFramework=net8.0]

Environment

Version information ``` Visual Studio Professional 2022 for Mac Version 17.6.7 (build 417) Installation UUID: da5a6a50-0b52-4e5f-8830-f56890f8cecd

Runtime
.NET 7.0.3 (64-bit)
Architecture: Arm64
Microsoft.macOS.Sdk 13.1.1007; git-rev-head:8afca776a0a96613dfb7200e0917bb57f9ed5583; git-branch:release/7.0.1xx-xcode14.2

Roslyn (Language Service)
4.6.0-3.23180.6+99e956e42697a6dd886d1e12478ea2b27cceacfa

NuGet
Version: 6.4.0.117

.NET SDK (Arm64)
SDK: /usr/local/share/dotnet/sdk/8.0.100/Sdks
SDK Versions:
8.0.100
7.0.311
6.0.417
6.0.416
MSBuild SDKs: /Applications/Visual Studio.app/Contents/MonoBundle/MSBuild/Current/bin/Sdks

.NET Runtime (Arm64)
Runtime: /usr/local/share/dotnet/dotnet
Runtime Versions:
8.0.0
7.0.14
6.0.25
6.0.24

Xamarin.Profiler
Version: 1.8.0.49
Location: /Applications/Xamarin Profiler.app/Contents/MacOS/Xamarin Profiler

Updater
Version: 11

Apple Developer Tools
Xcode: 15.1 22502
Build: 15C65

Xamarin.Mac
Version: 9.3.0.23 Visual Studio Professional
Hash: 9defd91b3
Branch: xcode14.3
Build date: 2023-10-23 16:14:59-0400

Xamarin.iOS
Version: 16.4.0.23 Visual Studio Professional
Hash: 9defd91b3
Branch: xcode14.3
Build date: 2023-10-23 16:15:00-0400

Xamarin Designer
Version: 17.6.3.9
Hash: 2648399ae8
Branch: remotes/origin/d17-6
Build date: 2023-11-10 12:19:46 UTC

Xamarin.Android
Version: 13.2.2.0 (Visual Studio Professional)
Commit: xamarin-android/d17-5/45b0e14
Android SDK: /Users/ebenezer/Library/Developer/Xamarin/android-sdk-macosx
Supported Android versions:
12.0 (API level 31)
13.0 (API level 33)

SDK Command-line Tools Version: 7.0
SDK Platform Tools Version: 34.0.3
SDK Build Tools Version: 32.0.0

Build Information:
Mono: d9a6e87
Java.Interop: xamarin/java.interop/d17-5@149d70fe
SQLite: xamarin/sqlite@68c69d8
Xamarin.Android Tools: xamarin/xamarin-android-tools/d17-5@ca1552d

Microsoft Build of OpenJDK
Java SDK: /Library/Java/JavaVirtualMachines/microsoft-11.jdk
11.0.16.1
Android Designer EPL code available here:
https://github.com/xamarin/AndroidDesigner.EPL

Eclipse Temurin JDK
Java SDK: /Library/Java/JavaVirtualMachines/temurin-8.jdk
1.8.0.302
Android Designer EPL code available here:
https://github.com/xamarin/AndroidDesigner.EPL

Android SDK Manager
Version: 17.6.0.50
Hash: a715dca
Branch: HEAD
Build date: 2023-11-10 12:19:52 UTC

Android Device Manager
Version: 0.0.0.1309
Hash: 06e3e77
Branch: HEAD
Build date: 2023-11-10 12:19:52 UTC

Build Information
Release ID: 1706070417
Git revision: 179aa48a5702754e41a8218d0403ddc3be46706f
Build date: 2023-11-10 12:18:09+00
Build branch: release-17.6
Build lane: release-17.6

Operating System
Mac OS X 14.2.0
Darwin 23.2.0 Darwin Kernel Version 23.2.0
Wed Nov 15 21:55:06 PST 2023
root:xnu-10002.61.3~2/RELEASE_ARM64_T6020 arm64

Enabled user installed extensions
Project System Tools 0.13


</details>

### Build Logs

<!--
1. How to get a build log: https://github.com/xamarin/xamarin-macios/wiki/Diagnosis#build-logs
2. Place the cursor below this comment block.
3. Drag and drop the build log.
-->

### Example Project (If Possible)

<!--
1. Place cursor below this comment block.
2. Drag and drop the compressed project or files needed to reproduce.
-->
[NativeLib_Debug_Build_2023-12-13T04_04_13.5060410Z.msbuild.log](https://github.com/xamarin/xamarin-macios/files/13655816/NativeLib_Debug_Build_2023-12-13T04_04_13.5060410Z.msbuild.log)

<!--
Switch to the "Preview" tab to ensure your issue renders correctly.
-->


_Copied from original issue xamarin/xamarin-macios#19626_

<table>
  <tr>
    <th align="left">Author:</th>
    <td>rolfbjarne</td>
  </tr>
  <tr>
    <th align="left">Assignees:</th>
    <td>-</td>
  </tr>
  <tr>
    <th align="left">Labels:</th>
    <td>

`untriaged`, `area-NativeAOT-coreclr`, `needs-area-label`

</td>
  </tr>
  <tr>
    <th align="left">Milestone:</th>
    <td>-</td>
  </tr>
</table>
</details>

@jkotas jkotas added the os-ios Apple iOS label Dec 13, 2023
@ghost
Copy link

ghost commented Dec 13, 2023

Tagging subscribers to 'os-ios': @steveisok, @akoeplinger, @kotlarmilos
See info in area-owners.md if you want to be subscribed.

Issue Details

From @rsanford-hh2 on Wed, 13 Dec 2023 04:09:26 GMT

Steps to Reproduce

Following the instructions at https://github.com/dotnet/samples/tree/main/core/nativeaot/NativeLibrary.

  • dotnet new classlib -o NativeLibrary
  • add the PublishAOT true flag to the .csproj file
  • dotnet publish /p:NativeLib=Shared --use-current-runtime succeeds
  • `dotnet publish -r:ios-arm64' fails with the error message in the title of the issue and in the Actual Behavior section

Expected Behavior

I expect that I will get an AOT library for iOS. iOS for ARM64 is experimental according to...
https://learn.microsoft.com/en-us/dotnet/core/deploying/native-aot/?tabs=net8plus%2Cwindows

Actual Behavior

NETSDK1203: Ahead-of-time compilation is not supported for the target runtime identifier 'ios-arm64'. [/Users/myusername/Projects/MyNetProject/NativeLib/NativeLib.csproj::TargetFramework=net8.0]

Environment

Version information ``` Visual Studio Professional 2022 for Mac Version 17.6.7 (build 417) Installation UUID: da5a6a50-0b52-4e5f-8830-f56890f8cecd

Runtime
.NET 7.0.3 (64-bit)
Architecture: Arm64
Microsoft.macOS.Sdk 13.1.1007; git-rev-head:8afca776a0a96613dfb7200e0917bb57f9ed5583; git-branch:release/7.0.1xx-xcode14.2

Roslyn (Language Service)
4.6.0-3.23180.6+99e956e42697a6dd886d1e12478ea2b27cceacfa

NuGet
Version: 6.4.0.117

.NET SDK (Arm64)
SDK: /usr/local/share/dotnet/sdk/8.0.100/Sdks
SDK Versions:
8.0.100
7.0.311
6.0.417
6.0.416
MSBuild SDKs: /Applications/Visual Studio.app/Contents/MonoBundle/MSBuild/Current/bin/Sdks

.NET Runtime (Arm64)
Runtime: /usr/local/share/dotnet/dotnet
Runtime Versions:
8.0.0
7.0.14
6.0.25
6.0.24

Xamarin.Profiler
Version: 1.8.0.49
Location: /Applications/Xamarin Profiler.app/Contents/MacOS/Xamarin Profiler

Updater
Version: 11

Apple Developer Tools
Xcode: 15.1 22502
Build: 15C65

Xamarin.Mac
Version: 9.3.0.23 Visual Studio Professional
Hash: 9defd91b3
Branch: xcode14.3
Build date: 2023-10-23 16:14:59-0400

Xamarin.iOS
Version: 16.4.0.23 Visual Studio Professional
Hash: 9defd91b3
Branch: xcode14.3
Build date: 2023-10-23 16:15:00-0400

Xamarin Designer
Version: 17.6.3.9
Hash: 2648399ae8
Branch: remotes/origin/d17-6
Build date: 2023-11-10 12:19:46 UTC

Xamarin.Android
Version: 13.2.2.0 (Visual Studio Professional)
Commit: xamarin-android/d17-5/45b0e14
Android SDK: /Users/ebenezer/Library/Developer/Xamarin/android-sdk-macosx
Supported Android versions:
12.0 (API level 31)
13.0 (API level 33)

SDK Command-line Tools Version: 7.0
SDK Platform Tools Version: 34.0.3
SDK Build Tools Version: 32.0.0

Build Information:
Mono: d9a6e87
Java.Interop: xamarin/java.interop/d17-5@149d70fe
SQLite: xamarin/sqlite@68c69d8
Xamarin.Android Tools: xamarin/xamarin-android-tools/d17-5@ca1552d

Microsoft Build of OpenJDK
Java SDK: /Library/Java/JavaVirtualMachines/microsoft-11.jdk
11.0.16.1
Android Designer EPL code available here:
https://github.com/xamarin/AndroidDesigner.EPL

Eclipse Temurin JDK
Java SDK: /Library/Java/JavaVirtualMachines/temurin-8.jdk
1.8.0.302
Android Designer EPL code available here:
https://github.com/xamarin/AndroidDesigner.EPL

Android SDK Manager
Version: 17.6.0.50
Hash: a715dca
Branch: HEAD
Build date: 2023-11-10 12:19:52 UTC

Android Device Manager
Version: 0.0.0.1309
Hash: 06e3e77
Branch: HEAD
Build date: 2023-11-10 12:19:52 UTC

Build Information
Release ID: 1706070417
Git revision: 179aa48a5702754e41a8218d0403ddc3be46706f
Build date: 2023-11-10 12:18:09+00
Build branch: release-17.6
Build lane: release-17.6

Operating System
Mac OS X 14.2.0
Darwin 23.2.0 Darwin Kernel Version 23.2.0
Wed Nov 15 21:55:06 PST 2023
root:xnu-10002.61.3~2/RELEASE_ARM64_T6020 arm64

Enabled user installed extensions
Project System Tools 0.13


</details>

### Build Logs

<!--
1. How to get a build log: https://github.com/xamarin/xamarin-macios/wiki/Diagnosis#build-logs
2. Place the cursor below this comment block.
3. Drag and drop the build log.
-->

### Example Project (If Possible)

<!--
1. Place cursor below this comment block.
2. Drag and drop the compressed project or files needed to reproduce.
-->
[NativeLib_Debug_Build_2023-12-13T04_04_13.5060410Z.msbuild.log](https://github.com/xamarin/xamarin-macios/files/13655816/NativeLib_Debug_Build_2023-12-13T04_04_13.5060410Z.msbuild.log)

<!--
Switch to the "Preview" tab to ensure your issue renders correctly.
-->


_Copied from original issue xamarin/xamarin-macios#19626_

<table>
  <tr>
    <th align="left">Author:</th>
    <td>rolfbjarne</td>
  </tr>
  <tr>
    <th align="left">Assignees:</th>
    <td>-</td>
  </tr>
  <tr>
    <th align="left">Labels:</th>
    <td>

`untriaged`, `os-ios`, `area-NativeAOT-coreclr`, `needs-area-label`

</td>
  </tr>
  <tr>
    <th align="left">Milestone:</th>
    <td>-</td>
  </tr>
</table>
</details>

@jkotas jkotas removed the needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners label Dec 13, 2023
@jkotas
Copy link
Member

jkotas commented Dec 13, 2023

@ivanpovazan Duplicate of #88737 ?

@ivanpovazan
Copy link
Member

@jkotas yes that is correct.
Closing this issues as a duplicate of #88737

@ivanpovazan ivanpovazan closed this as not planned Won't fix, can't repro, duplicate, stale Dec 13, 2023
@ghost ghost removed the untriaged New issue has not been triaged by the area owner label Dec 13, 2023
@github-actions github-actions bot locked and limited conversation to collaborators Jan 13, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
Archived in project
Development

No branches or pull requests

3 participants