Subject: ExecutionEngineException in iOS build
Hi
Building a facebook chat client for iOS using Unity/MonoDevelop/C# I get the following error when running:
Originating from the line:
which is mandatory for connect to facebook according to http://www.ag-software.net/matrix-xmpp-sdk/matrix-develope…
The custom delegate method is declared as:
According to http://forum.unity3d.com/threads/113750-ExecutionEngineExc… "it is not possible to hook up a C# event handler on iOS if that event resides in a 3rd party C# DLL" which is what I am trying to do. They post a workaround on the page but get the feeling that you need to modify the library code to get it working.
It is working fine in Unity, but once deployed on a iOS device it fails.
Any ideas anyone?
Building a facebook chat client for iOS using Unity/MonoDevelop/C# I get the following error when running:
ExecutionEngineException: Attempting to JIT compile method '(wrapper managed-to-native)
System.Threading.Interlocked:CompareExchange
(System.EventHandler`1<Matrix.EventArgs>&,System.EventHandler`1<Matrix.EventArgs>,
System.Eve ntHandler`1<Matrix.EventArgs>)' while running with --aot-only.
at Matrix.Net.BaseSocket.add_OnConnect (System.EventHandler`1 value) [0x00000]
in <filename unknown>:0
at Matrix.XmppStream..ctor (StreamType type) [0x00000] in <filename unknown>:0
at Matrix.Xmpp.Client.XmppClient..ctor () [0x00000] in <filename unknown>:0
at TestFacebook.setup () [0x00000] in <filename unknown>:0
at TestFacebook.Start () [0x00000] in <filename unknown>:0
(Filename: Line: -1)
System.Threading.Interlocked:CompareExchange
(System.EventHandler`1<Matrix.EventArgs>&,System.EventHandler`1<Matrix.EventArgs>,
System.Eve ntHandler`1<Matrix.EventArgs>)' while running with --aot-only.
at Matrix.Net.BaseSocket.add_OnConnect (System.EventHandler`1 value) [0x00000]
in <filename unknown>:0
at Matrix.XmppStream..ctor (StreamType type) [0x00000] in <filename unknown>:0
at Matrix.Xmpp.Client.XmppClient..ctor () [0x00000] in <filename unknown>:0
at TestFacebook.setup () [0x00000] in <filename unknown>:0
at TestFacebook.Start () [0x00000] in <filename unknown>:0
(Filename: Line: -1)
Originating from the line:
xmppClient.OnBeforeSasl += this.xmppClient_OnBeforeSasl;
which is mandatory for connect to facebook according to http://www.ag-software.net/matrix-xmpp-sdk/matrix-develope…
The custom delegate method is declared as:
public void xmppClient_OnBeforeSasl(object sender, Matrix.Xmpp.Sasl.SaslEventArgs e)
{ ... }
{ ... }
According to http://forum.unity3d.com/threads/113750-ExecutionEngineExc… "it is not possible to hook up a C# event handler on iOS if that event resides in a 3rd party C# DLL" which is what I am trying to do. They post a workaround on the page but get the feeling that you need to modify the library code to get it working.
It is working fine in Unity, but once deployed on a iOS device it fails.
Any ideas anyone?
sunkas85
Show profile
Link to this post