Skip to content

Hybrid AOT no longer works in VS2022? #7290

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

Closed
simon10says opened this issue Aug 21, 2022 · 1 comment
Closed

Hybrid AOT no longer works in VS2022? #7290

simon10says opened this issue Aug 21, 2022 · 1 comment
Assignees
Labels
Area: App Runtime Issues in `libmonodroid.so`. needs-triage Issues that need to be assigned.

Comments

@simon10says
Copy link

Android application type

Classic Xamarin.Android (MonoAndroid12.0, etc.)

Affected platform version

VS2022 17.3.1

Description

Previously with VS2019, I'm able to release my classic xamarin form android app in hybrid aot using the following:

<AotAssemblies>true</AotAssemblies>
<AndroidAotMode>Hybrid</AndroidAotMode>
<AndroidAotAdditionalArguments>no-write-symbols,nodebug</AndroidAotAdditionalArguments>

However, after upgrade to VS2022 17.3.1, I'm still able to build and deploy to device, but the app just display a white blank screen

When I disable the hybrid aot (in above) in the csproj and enable profile aot (as shown below), it works fine.

<AndroidEnableProfiledAot>true</AndroidEnableProfiledAot>  
<AndroidUseDefaultAotProfile>false</AndroidUseDefaultAotProfile>  

There is no error or warning in the build logs; except, the Android NDK is showing truncated path. My NDK is at C:\Program ...\android-sdk\ndk-bundle\ but not sure why it's showing as shown below.
image

build_log.txt

Steps to Reproduce

Sample Code:
App4.zip

  1. Open the solution
  2. Change to Release configuration
  3. Deploy to device or emulator
  4. Launch the app

Did you find any workaround?

No response

Relevant log output

No response

@simon10says simon10says added Area: App Runtime Issues in `libmonodroid.so`. needs-triage Issues that need to be assigned. labels Aug 21, 2022
@simon10says
Copy link
Author

simon10says commented Aug 22, 2022

There is a regression where <AndroidAotMode>Hybrid</AndroidAotMode> no longer works. See the following post for solution.
#7088 (comment)

@ghost ghost locked as resolved and limited conversation to collaborators Sep 21, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Area: App Runtime Issues in `libmonodroid.so`. needs-triage Issues that need to be assigned.
Projects
None yet
Development

No branches or pull requests

2 participants