Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 11 Mar 2009 15:35:49 GMT
From:      Ben Kelly <ben@wanderview.com>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/132548: [newusb] apcupsd compile broken with USB support
Message-ID:  <200903111535.n2BFZnZL052563@www.freebsd.org>
Resent-Message-ID: <200903111540.n2BFe1BY019431@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         132548
>Category:       ports
>Synopsis:       [newusb] apcupsd compile broken with USB support
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Mar 11 15:40:01 UTC 2009
>Closed-Date:
>Last-Modified:
>Originator:     Ben Kelly
>Release:        8.0-CURRENT
>Organization:
>Environment:
FreeBSD vmfbsd.localdomain 8.0-CURRENT FreeBSD 8.0-CURRENT #0 r179:183: Wed Mar 11 13:53:21 GMT 2009     root@vmfbsd.localdomain:/usr/obj/usr/src/sys/VMWARE  i386

>Description:
Building apcupsd on a recent CURRENT using the new USB stack results in the following error:


  CXX   src/drivers/usb/bsd/bsd-usb.c
bsd-usb.c: In function 'int init_device(UPSINFO*, const char*)':
bsd-usb.c:101: error: aggregate 'usb_device_info devinfo' has incomplete type and cannot be defined
bsd-usb.c:104: error: 'MAXDEVNAMELEN' was not declared in this scopebsd-usb.c:111: error: 'USB_GET_DEVICEINFO' was not declared in this scope
bsd-usb.c:163: error: 'intdevname' was not declared in this scope
bsd-usb.c: In function 'int open_usb_device(UPSINFO*)':bsd-usb.c:197: error: 'MAXDEVNAMELEN' was not declared in this scope
bsd-usb.c:198: error: aggregate 'usb_device_info devinfo' has incomplete type and cannot be definedbsd-usb.c:259: error: 'USB_DEVICEINFO' was not declared in this scope
bsd-usb.c:264: error: 'MAXDEVNAMES' was not declared in this scope
bsd-usb.c:268: error: 'MAXDEVNAMES' was not declared in this scope
bsd-usb.c:269: error: ISO C++ forbids applying 'sizeof' to an expression of function type
bsd-usb.c:269: error: cannot convert 'char* (*)(__dev_t, __mode_t)' to 'char*' for argument '1' to '
char* astrncpy(char*, const char*, int)'
bsd-usb.c:270: error: ISO C++ forbids applying 'sizeof' to an expression of function type
bsd-usb.c:275: error: cannot convert 'char* (*)(__dev_t, __mode_t)' to 'const char*' for argument '2
' to 'int init_device(UPSINFO*, const char*)'
bsd-usb.c:276: error: cannot convert 'char* (*)(__dev_t, __mode_t)' to 'const char*' for argument '2
' to 'char* astrncpy(char*, const char*, int)'
gmake[5]: *** [.obj/bsd-usb.o] Error 1


I tried adding --with-generic-usb as discussed in this mail thread:

  http://docs.freebsd.org/cgi/getmsg.cgi?fetch=412215+0+archive/2009/freebsd-usb/20090215.freebsd-usb

This did not work, however, because the apcupsd configure script looks for libusb-config.  Unfortunately, the libusb port can no longer be installed when the new USB stack is in use.

Should the base system provide a libusb-config binary?
>How-To-Repeat:

>Fix:


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200903111535.n2BFZnZL052563>