LCDproc development and user support list

Text archives Help


[Lcdproc] Fwd: lcdproc 0.5.8 release candidate 1


Chronological Thread 
  • From: ethan.dicks at gmail.com (Ethan Dicks)
  • Subject: [Lcdproc] Fwd: lcdproc 0.5.8 release candidate 1
  • Date: Wed, 4 Jan 2017 17:43:57 -0500

On Wed, Jan 4, 2017 at 3:09 PM, Dominique Dumont <domi.dumont at free.fr>
wrote:
> I'm using rc1 to build a new Debian package for lcdproc.

I'm curious about your configure line... --enable-drivers=all or some subset?

> Unfortunately, compilation fails:
>
> gcc -DHAVE_CONFIG_H -I. -I../.. -I../.. -Wdate-time -D_FORTIFY_SOURCE=2
> -fPIC -Wall -g -O2
> -fdebug-prefix-map=/home/domi/debian-dev/build-area/lcdproc-0.5.8~rc1=.
> -fstack-protector-strong -Wformat -Werror=format-security
> -Wno-unused-function -c -o futaba-futaba.o `test -f 'futaba.c' || echo
> './'`futaba.c
> futaba.c: In function ‘futaba_start_driver’:
> futaba.c:435:26: error: ‘my_driver’ undeclared (first use in this
> function)
> if (usb_claim_interface(my_driver->my_handle, 0) < 0) {
> ^~~~~~~~~
> futaba.c:435:26: note: each undeclared identifier is reported only once for
> each function it appears in

That looks wrapped in an #ifdef HAVE_LIBUSB_1_0 block in the "#else"
section meaning HAVE_LIBUSB_1_0 is false. The identifier 'my_driver'
only appears in this block instead of 'p' which it is everywhere else
in the code.

I would suspect this is old code that hasn't been compiled by anyone
in a long time because libusb 0.1 is somewhat ancient. I'm guessing
you don't have libusb 1.0 dev package installed? I tried enabling the
futaba driver, but I got:

"configure: WARNING: The futaba driver needs the libusb library."

... and I know this (temporary) environment does not have libusb of
any version installed.

If you really are testing with libusb 0.1, then it likely fix is...

--- futaba.c 2017-01-04 17:42:53.947195041 -0500
+++ futaba-dist.c 2016-12-27 19:21:10.000000000 -0500
@@ -432,7 +432,7 @@

#else /* HAVE_LIBUSB_1_0 */
/* USB 0.1 code */
- if (usb_claim_interface(p->my_handle, 0) < 0) {
+ if (usb_claim_interface(my_driver->my_handle, 0) < 0) {
report(RPT_ERR, "USB0.1: [%s] cannot claim
interface!", drvthis->name);
futaba_shutdown(drvthis);
return -1;

I have not tested this, but it looks legit.

-ethan




Archive powered by MHonArc 2.6.18.

Top of page