[Mono-list] mono error: DllNotFoundException when calling from C code
Robert Jordan
robertj at gmx.net
Thu Feb 10 04:39:07 EST 2011
On 10.02.2011 07:12, coolmanu07 wrote:
>
> Hello,
>
> I have developed an application in mono .Net. I call a method of this
> application from C code and that is working fine. Then i included a new
> method in my .net class which is using System.Net dll of .Net.
> now the C code is not able to call that method, however if i call that
> method from another mono.Net code then it works. I have also set the debug
> level for mono and the exception detail is as follows:
>
> Mono-INFO: DllImport attempting to load: 'libc'.
> Mono-INFO: DllImport loading location: 'libc.so'.
> Mono-INFO: DllImport error loading library: '/usr/lib64/libc.so: invalid ELF
> header'.
You're probably not initializing Mono's dll maps with
mono_config_parse(NULL) from the C app that embeds Mono.
Robert.
More information about the Mono-list
mailing list