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

Unable to bind native iOS framework that uses Async/Await in iOS 14 #17572

Closed
jslew opened this issue Feb 18, 2023 · 3 comments
Closed

Unable to bind native iOS framework that uses Async/Await in iOS 14 #17572

jslew opened this issue Feb 18, 2023 · 3 comments

Comments

@jslew
Copy link

jslew commented Feb 18, 2023

Having exactly the same problem as #13605, except now trying to back-deploy to iOS 14 (not 13, which was originaly reported). Adding a reference to Xamarin.iOS.SwiftRuntimeSupport does not fix this with the current toollchain. Perhaps the package needs to be updated again?
@chamons or @rolfbjarne, any idea?

Thanks.

Expected Behavior

Xamarin.iOS app which references a native framework that (internally) uses swift concurrency should run without issue.

Actual Behavior

App crashes as soon as native code using swift concurrency is run.

Environment

Version information
Visual Studio Community 2022 for Mac Preview
Version 17.5 Preview (17.5 build 1766)
Installation UUID: 74672fca-f2f0-4664-b502-6ecf39ba23f4

Runtime
.NET 7.0.1 (64-bit)
Architecture: Arm64
Microsoft.macOS.Sdk 12.3.2372; git-rev-head:754abbf6a3563f6267e5717ae832b4ac25b1f2fb; git-branch:release/7.0.1xx-xcode13.3

Roslyn (Language Service)
4.5.0-3.23056.2+97881342e427ff5cdcba8f12b12ff8e6f3564431

NuGet
Version: 6.4.0.117

.NET SDK (Arm64)
SDK: /usr/local/share/dotnet/sdk/7.0.200-preview.22628.1/Sdks
SDK Versions:
	7.0.200-preview.22628.1
	7.0.100
	6.0.405
	6.0.403
	6.0.402
	6.0.401
	6.0.400
	6.0.301
	6.0.300
	6.0.202
	6.0.201
MSBuild SDKs: /Applications/Visual Studio (Preview).app/Contents/MonoBundle/MSBuild/Current/bin/Sdks

.NET SDK (x64)
SDK Versions:
	6.0.403
	6.0.402
	6.0.401
	6.0.400
	6.0.301
	6.0.300
	6.0.105
	6.0.103
	5.0.408
	5.0.406
	3.1.425
	3.1.424
	3.1.423
	3.1.422
	3.1.420
	3.1.419
	3.1.418
	3.1.417

.NET Runtime (Arm64)
Runtime: /usr/local/share/dotnet/dotnet
Runtime Versions:
	7.0.0
	6.0.13
	6.0.11
	6.0.10
	6.0.9
	6.0.8
	6.0.6
	6.0.5
	6.0.4
	6.0.3
	3.1.32 (x64 – Unsupported)

.NET Runtime (x64)
Runtime: /usr/local/share/dotnet/x64/dotnet
Runtime Versions:
	6.0.11
	6.0.10
	6.0.9
	6.0.8
	6.0.6
	6.0.5
	6.0.3
	5.0.17
	5.0.15
	3.1.31
	3.1.30
	3.1.29
	3.1.28
	3.1.26
	3.1.25
	3.1.24
	3.1.23

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

Updater
Version: 11

Xamarin.Android
Version: 13.2.0.0 (Visual Studio Community)
Commit: xamarin-android/d17-5/797e2e1
Android SDK: /Users/jlew/Library/Android/sdk
	Supported Android versions:
		12.1 (API level 32)
		12.0 (API level 31)
		11.0 (API level 30)
		13.0 (API level 33)

SDK Command-line Tools Version: 7.0
SDK Platform Tools Version: 33.0.3
SDK Build Tools Version: 33.0.1

Build Information: 
Mono: 6dd9def
Java.Interop: xamarin/java.interop/main@149d70fe
SQLite: xamarin/sqlite/3.40.0@fdc1e34
Xamarin.Android Tools: xamarin/xamarin-android-tools/main@9f02d77

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.5.0.33
Hash: f0c0c52
Branch: remotes/origin/d17-5~1
Build date: 2023-02-02 19:20:19 UTC

Android Device Manager
Version: 0.0.0.1245
Hash: 7f8a990
Branch: 7f8a990
Build date: 2023-02-02 19:20:19 UTC

Xamarin Designer
Version: 17.5.3.47
Hash: e8b5d371c3
Branch: remotes/origin/d17-5
Build date: 2023-02-02 19:20:14 UTC

Apple Developer Tools
Xcode: 14.2 21534
Build: 14C18

Xamarin.Mac
Version: 9.1.0.2 Visual Studio Community
Hash: 956a059ba
Branch: xcode14.2
Build date: 2022-12-15 06:15:43-0500

Xamarin.iOS
Version: 16.2.0.2 Visual Studio Community
Hash: 956a059ba
Branch: xcode14.2
Build date: 2022-12-15 06:15:44-0500

Build Information
Release ID: 1705001766
Git revision: 749808e99f0d0bf8a8eb45fe406840107ffb46b4
Build date: 2023-02-02 19:18:20+00
Build branch: release-17.5
Build lane: release-17.5

Operating System
Mac OS X 13.2.0
Darwin 22.3.0 Darwin Kernel Version 22.3.0
    Thu Jan  5 20:48:54 PST 2023
    root:xnu-8792.81.2~2/RELEASE_ARM64_T6000 arm64

Build Logs

Example Project (If Possible)

will add a minimal repro project shortly.

@jslew jslew changed the title Unable to bind native iOS framework that uses Async/Await in iOS 13 Unable to bind native iOS framework that uses Async/Await in iOS 14 Feb 18, 2023
@jslew
Copy link
Author

jslew commented Feb 19, 2023

I think it may be because of this line from Xamarin.iOS.SwiftRuntimeSupports.targets:
<_SRSMasterAfterTargets>_CodesignNativeLibraries</_SRSMasterAfterTargets>
_CodesignNativeLibraries does not seem to exist anymore, so the targets in this package which copy things are not actually running.

@jslew
Copy link
Author

jslew commented Feb 19, 2023

Yep, that seems to be the problem. Changed to:
<_SRSMasterAfterTargets>AfterCodesign</_SRSMasterAfterTargets>
and all seems well again.

@rolfbjarne
Copy link
Member

This issue was moved to xamarin/XamarinComponents#1423

@ghost ghost locked as resolved and limited conversation to collaborators Mar 22, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants