Xamarin Android with AOT: some questions reply to config

seal2002seal2002 VNMember ✭✭

Hello guys,
My game is using AOT for better boost and performance. My game has the C#(Gameplay), C++(Engine) & Java for other stuff.

I use Xamarin version 8.0.99.46, my OS is Windows. MSBuild is used to generate APK.

"C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\MSBuild\15.0\Bin\MsBuild.exe" /v:diag /fileLogger /t:SignAndroidPackage /p:JavaOptions="-noverify" /p:Configuration="%CONFIGURATION%" /p:AndroidNdkDirectory="E:/Projects/DHC/trunk/Engine/Tools/AndroidBuild/android-ndk-r15c" /p:JavaSdkDirectory="E:\DevTools\jdk1.8.0" /p:AndroidSdkDirectory="E:\DevTools\android-sdk" /p:AndroidApiLevel=25 /p:AndroidSdkBuildToolsVersion=25.0.0 /p:MonoDroidInstallDirectory="C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\ReferenceAssemblies\Microsoft\Framework" /p:TargetFrameworkRootPath="C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\ReferenceAssemblies\Microsoft\Framework" /p:MonoAndroidToolsDirectory="C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\MSBuild\Xamarin\Android" /p:MonoAndroidBinDirectory="C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\MSBuild\Xamarin\Android" /p:FrameworkPathOverride="C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\ReferenceAssemblies\Microsoft\Framework\MonoAndroid\v1.0" "SanAngeles.csproj"

Here is the options inside my csproject to generate SO libs:

<AotAssemblies>True</AotAssemblies>
<AndroidAotMode>Normal</AndroidAotMode>
<AndroidAotAdditionalArguments>no-write-symbols,nodebug</AndroidAotAdditionalArguments>
<AndroidExtraAotOptions>mtriple="armv7a-none-linux-androideabi -O3 -march=arm -mcpu=cortex-a15 -mattr=+neon -data-sections -function-sections -enable-fp-mad -enable-misched -enable-no-infs-fp-math -enable-no-nans-fp-math -enable-unsafe-fp-math -fp-contract=fast",ld-flags="-march=armv7-a -mcpu=cortex-a15 -mfloat-abi=soft-fp -mfpu=neon" --optimize=all</AndroidExtraAotOptions>
<EnableLLVM>True</EnableLLVM>

My question is:
1/ Can Xamarin Android combine all SO files to on SO inside APK ? If it can be, how to enable it?
2/ <AndroidAotAdditionalArguments> , <AndroidExtraAotOptions> in above effect with Android ? How can I get the log for it?
3/ How can I enable Full statuc compilation as http://xamarinhelp.com/xamarin-android-aot-works

Thank you for your view and support.
Seal

Tagged:

Best Answer

Answers

Sign In or Register to comment.