Closed MaYiLagann closed 1 year ago
I am not familiar with Unity, but what comes to my mind, that what's happening is something similar to JavaScript tree shaking, where the compiler remove methods with no reference, and since CompileBasicCondition
is called via reflection so there is no direct reference.
I am not sure what would be the solution here, but I am pretty sure that directly referencing the CompileBasicCondition
method in your code, will do the trick
From their doc, I found this
Enable Strip Engine Code in the Unity Editor Player settings (go to Edit > Project Settings , then select the Player category). This option statically analyzes the managed code in the Project, and removes any unused code.
https://docs.unity3d.com/2020.3/Documentation/Manual/dotnetProfileLimitations.html
so maybe disabling this option will help in your case
thanks for quick response!
i solved this problem just writing link.xml
<!-- link.xml -->
<linker>
<assembly fullname="SqlKata" preserve="all"/>
</linker>
unity build with il2cpp will always stripping unused codes, so it should be preserved manually.
Summary
hi, i'm using SqlKata on Unity game engine (Unity-2020.3.40f1) i launched app on editor and it was fine, but app crashed after build. can i get some help here?
Error logs
How to reproduce
new Query
andSqliteCompiler.Compile
IL2CPP
.NET 4.x
(Unity 2020 dotnet support documentation)ARMv7
,ARM64
Others
i test some logics in
ConditionsCompilerProvider.FindMethodInfo
, but it was not working for expected.here the script i tested: