hansiglaser / pas-libusb

Object Oriented wrapper for LibUSB
18 stars 11 forks source link

libusb-1.0 #1

Closed fredycc closed 11 years ago

fredycc commented 11 years ago

pas-libusb examples compile ok in linux i386 but I have a problem with ARM distribution, specifically: Raspbian: http://www.raspbian.org/. Maybe I have a error in the project configuration.

I do not know if the goal could be this architecture, I appreciate your work.

thanks

log: Options changed, recompiling clean with -B Free Pascal Compiler version 2.7.1 [2012/12/10] for arm Copyright (c) 1993-2012 by Florian Klaempfl and others Target OS: Linux for ARMEL Compiling test1library.pas Compiling /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusb.pas /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusb.pas(1309,13) Hint: Mixing signed expressions and longwords gives a 64bit result /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusb.pas(1327,13) Hint: Mixing signed expressions and longwords gives a 64bit result Assembling libusb Compiling /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(272,5) Warning: Constructor should be public Compiling /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/paslibusbutils.pas /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/paslibusbutils.pas(45,30) Hint: Converting the operands to "Int64" before doing the subtract could prevent overflow errors. Assembling paslibusbutils /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(542,11) Hint: Conversion between ordinals and pointers is not portable /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(543,11) Hint: Conversion between ordinals and pointers is not portable /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(561,72) Hint: Conversion between ordinals and pointers is not portable /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(849,29) Hint: Local variable "Status" does not seem to be initialized /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(919,18) Hint: Conversion between ordinals and pointers is not portable /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(920,18) Hint: Conversion between ordinals and pointers is not portable /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(934,45) Hint: Conversion between ordinals and pointers is not portable /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(1034,24) Hint: Conversion between ordinals and pointers is not portable /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(1047,43) Warning: Conversion between ordinals and pointers is not portable Assembling libusboop Assembling test1library Compiling resource /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/examples/lib/arm-linux/test1library.or Linking test1library /usr/lib/codetyphon/fpc/bin/i386-linux/arm-linux-ld: warning: link.res contains output sections; did you forget -T? /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/examples/lib/arm-linux/libusboop.o: In function ELIBUSB__GETERRORSTR': /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas:1531: undefined reference tolibusb_get_port_number' /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas:1532: undefined reference to libusb_get_port_path' test1library.pas(99) Error: Error while linking /usr/lib/codetyphon/fpc/bin/i386-linux/arm-linux-ld: warning: link.res contains output sections; did you forget -T? /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/examples/lib/arm-linux/libusboop.o: In functionELIBUSB__GETERRORSTR': /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas:1531: undefined reference to libusb_get_port_number' /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas:1532: undefined reference tolibusb_get_port_path' test1library.pas(99) Error: Error while linking test1library.pas(99) Fatal: There were 1 errors compiling module, stopping

hansiglaser commented 11 years ago

Hi Fredy!

Am Montag, den 17.12.2012, 19:41 -0800 schrieb fredycc:

pas-libusb examples compile ok in linux i386 but I have a problem with ARM distribution, specifically: Raspbian: http://www.raspbian.org/. Maybe I have a error in the project configuration.

I do not know if the goal could be this architecture, I appreciate your work.

Great, I appreciate your testing for ARM very much, thanks!

Options changed, recompiling clean with -B Free Pascal Compiler version 2.7.1 [2012/12/10] for arm Copyright (c) 1993-2012 by Florian Klaempfl and others Target OS: Linux for ARMEL Compiling test1library.pas Compiling /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusb.pas /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusb.pas(1309,13) Hint: Mixing signed expressions and longwords gives a 64bit result /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusb.pas(1327,13) Hint: Mixing signed expressions and longwords gives a 64bit result Assembling libusb Compiling /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(272,5) Warning: Constructor should be public Compiling /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/paslibusbutils.pas /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/paslibusbutils.pas(45,30) Hint: Converting the operands to "Int64" before doing the subtract could prevent overflow errors. Assembling paslibusbutils /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(542,11) Hint: Conversion between ordinals and pointers is not portable /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(543,11) Hint: Conversion between ordinals and pointers is not portable /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(561,72) Hint: Conversion between ordinals and pointers is not portable /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(849,29) Hint: Local variable "Status" does not seem to be initialized /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(919,18) Hint: Conversion between ordinals and pointers is not portable /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(920,18) Hint: Conversion between ordinals and pointers is not portable /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(934,45) Hint: Conversion between ordinals and pointers is not portable /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(1034,24) Hint: Conversion between ordinals and pointers is not portable /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas(1047,43) Warning: Conversion between ordinals and pointers is not portable Assembling libusboop Assembling test1library Compiling resource /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/examples/lib/arm-linux/test1library.or Linking test1library /usr/lib/codetyphon/fpc/bin/i386-linux/arm-linux-ld: warning: link.res contains output sections; did you forget -T? /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/examples/lib/arm-linux/libusboop.o: In function ELIBUSBGETERRORSTR': /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas:1531: undefined reference tolibusb_get_port_number' /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas:1532: undefined reference to libusb_get_port_path' test1library.pas(99) Error: Error while linking /usr/lib/codetyphon/fpc/bin/i386-linux/arm-linux-ld: warning: link.res contains output sections; did you forget -T? /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/examples/lib/arm-linux/libusboop.o: In functionELIBUSBGETERRORSTR': /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas:1531: undefined reference to libusb_get_port_number' /home/fredycc/Desktop/pas-libusb-libusb-1.0/src/libusboop.pas:1532: undefined reference tolibusb_get_port_path' test1library.pas(99) Error: Error while linking test1library.pas(99) Fatal: There were 1 errors compiling module, stopping

The logs suggest that the two functions libusb_get_port_number() and libusb_get_port_path() are not available in libusb-1.0. I guess that your distribution uses an older revision of libusb-1.0. Could you please check whether you can update to a newer revision?

Thanks Hansi

fredycc commented 11 years ago

Before test I installed sudo apt-get install libusb-1.0-0-dev, but maybe that distribution uses an older revision, I'll check again.

Thanks Hansi for you fast answer.

fredycc commented 11 years ago

Example 1 works compile and works fine in Raspberry, I'll try test the next examples tomorrow. As you indicated the version on Raspberry is old, I downloaded a most recent version from here http://sourceforge.net/projects/libusbx/?source=dlp.

After sh ./configure, make, make install the version created works :). Thank you very much for supporting

hansiglaser commented 11 years ago

Hi!

Am Dienstag, den 18.12.2012, 21:01 -0800 schrieb fredycc:

Example 1 works compile and works fine in Raspberry, I'll try test the next examples tomorrow. As you indicated the version on Raspberry is old, I downloaded a most recent version from here http://sourceforge.net/projects/libusbx/?source=dlp.

After sh ./configure, make, make install the version created works :). Thank you very much for supporting

Great!

Do you know the version of the libusb-1.0 package of Raspbian? I'd be happy to add a note to the README.

Bye Hansi

fredycc commented 11 years ago

The version that works in Raspbian was 1.0.14 . Thanks

Regards

hansiglaser commented 11 years ago

Hi!

Am Mittwoch, den 19.12.2012, 06:30 -0800 schrieb fredycc:

The version that works in Raspbian was 1.0.14 . Thanks

Thanks!

Could you also please tell me, which version was previously installed, which did not work?

Thanks Hansi

fredycc commented 11 years ago

The version that didn't work in Raspbian was 1.0.9.

Version 1.0.14 is not in the repositories of Raspbian actually.

For Linux Mint i386 version: 1.0.12 works

Regards

hansiglaser commented 11 years ago

Hi!

Am Mittwoch, den 19.12.2012, 07:09 -0800 schrieb fredycc:

The version that didn't work in Raspbian was 1.0.9.

Version 1.0.14 is not in the repositories of Raspbian.

For Linux Mint i386 version: 1.0.12 works

Thanks again for pointing this out! I've added a note to the README.

Bye Hansi