On 27-12-10 15:04, Dru Moore wrote:
On 27 December 2010 13:49, Geert Jordaens<[email protected]> wrote:
hello,
any idea how to compile code below?
/* valac --pkg libusb-1.0 TestLibUsb.vala */
using LibUSB;
namespace TestLibUSb
{
public static class TestLibUSb
{
static int main (string[] args)
{
Context context = null;
Device[] devices = null;
Context.init (out context);
context.get_device_list(out devices);
return 0;
}
}
}
If the following (from the comments) doesn't work, assuming you have
saved the file as TestLibUsb.vala and are in that working directory):
valac --pkg libusb-1.0 TestLibUsb.vala
what output does it give? You may need to install libusb-1.0.0-dev to
get the headers etc.
dru
I have following components installed.
installed :
libusb1-devel-doc-1.0.8-3.fc15.noarch
libusb1-static-1.0.8-3.fc15.x86_64
libusb1-devel-1.0.8-3.fc15.x86_64
libusb1-1.0.8-3.fc15.x86_64
valac --version
Vala 0.11.2.73-6b38f-dirty
Output :
[ge...@obelix testlibusb]$ ls
TestLibUsb.vala
[ge...@obelix testlibusb]$ valac -v -g --pkg libusb-1.0 TestLibUsb.vala
Segmentation fault
[ge...@obelix testlibusb]$
Bug 638094 contains more info
Geert
_______________________________________________
vala-list mailing list
[email protected]
http://mail.gnome.org/mailman/listinfo/vala-list