[gnome-bluetooth] Mono Binding Bug
heat sink
heatxsink at gmail.com
Sat Dec 10 05:38:41 GMT 2005
Hi All,
I downloaded and compiled the libbtcrl 0.6, re-ran some sample code, that
worked with 0.5, and I get the following error...
./BluetoothTest.exe
=================================================================
Got a SIGSEGV while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries
used by your application.
=================================================================
Stacktrace:
in <0x4> (wrapper managed-to-native) Btctl.Controller:btctl_controller_new()
in <0xffffeb4d> (wrapper managed-to-native)
Btctl.Controller:btctl_controller_new ()
in <0x55> Btctl.Controller:.ctor ()
in <0x21> Btctl.Test.TestApp:Main (string[])
in <0x50c6ae69> (wrapper runtime-invoke)
System.Object:runtime_invoke_void_string[] (object,intptr,intptr,intptr)
Native stacktrace:
/usr/bin/cli(mono_handle_native_sigsegv+0x7c) [0x81444ac]
/usr/bin/cli [0x81174eb]
[0xffffe440]
/usr/lib/libgobject-2.0.so [0xb732b93f]
/usr/lib/libgobject-2.0.so(g_object_new_valist+0x244) [0xb730e599]
/usr/lib/libgobject-2.0.so(g_object_new+0x3c) [0xb730e712]
/usr/lib/libbtctl.so(btctl_controller_new+0x30) [0xb722cc90]
[0xb746320f]
[0xb7461d36]
[0xb7461b6a]
[0xb7461813]
/usr/bin/cli(mono_runtime_exec_main+0x52) [0x80cc652]
/usr/bin/cli(mono_runtime_run_main+0x12f) [0x80cf05f]
/usr/bin/cli(mono_main+0xeff) [0x805d3ff]
/lib/tls/i686/cmov/libc.so.6(__libc_start_main+0xd2) [0xb7d04ea2]
/usr/bin/cli [0x805bfa1]
Aborted
The following is the sample code I compiled then ran.
using System;
using System.Runtime.InteropServices;
using Btctl;
using BtctlSharp;
namespace Btctl.Test {
public class TestApp {
[DllImport("libgobject-2.0.so")]
static extern void g_type_init ();
public static void Main (string[] args)
{
g_type_init ();
Controller ctl = new Controller ();
ctl.AddDevice += new AddDeviceHandler (Add_Device);
ctl.DiscoverDevices ();
}
static void Add_Device (object obj, AddDeviceArgs args)
{
Console.WriteLine ("Device {0} Class {1}",
args.Addr, args.Clsid);
}
}
}
Here's the command I ran in the terminal to compile the code above.
mcs -debug+ -out:BluetoothTest.exe -target:exe
main.cs-r:/usr/lib/mono/libbtctl/btctl.dll
I would like to help fix these bindings, I just need an idea of what I would
have to do to get it working. I'd also like to get the automake fu working
such that it also creates monodoc documentation.
Thanks,
Nick
--
Nick Granado
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.gnomehack.com/pipermail/gnome-bluetooth/attachments/20051209/f079a544/attachment.htm
More information about the gnome-bluetooth
mailing list