Bug 132126 - emulators/{qemu,qemu-devel} doesnt compile on the CURRENT after USB stack changes
Summary: emulators/{qemu,qemu-devel} doesnt compile on the CURRENT after USB stack cha...
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Juergen Lock
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-02-26 13:10 UTC by Oleg Ginzburg
Modified: 2009-02-28 17:00 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Oleg Ginzburg 2009-02-26 13:10:01 UTC
After recompile kernel/world and "cd /usr/src ; yes |make delete-old ; yes | make delete-old-libs" port of QEMU failed to compile with some errors:
---
gcc34 -O2 -pipe -fno-strict-aliasing -Wall -O2 -g -fno-strict-aliasing -I. -I/usr/ports/emulators/qemu/work/qemu-0.9.1 -MMD -MP -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -I/usr/ports/emulators/qemu/work/qemu-0.9.1/slirp    -c -o usb-bsd.o usb-bsd.c                                                                                               
usb-bsd.c:55: error: `USB_MAX_ENDPOINTS' undeclared here (not in a function)                                                                                                       
usb-bsd.c: In function `usb_host_handle_control':                                                                                                                                  
usb-bsd.c:128: error: storage size of 'req' isn't known                                                                                                                            
usb-bsd.c:129: error: storage size of 'aiface' isn't known                                                                                                                         
usb-bsd.c:143: error: `USB_SET_CONFIG' undeclared (first use in this function)                                                                                                     
usb-bsd.c:143: error: (Each undeclared identifier is reported only once                                                                                                            
usb-bsd.c:143: error: for each function it appears in.)                                                                                                                            
usb-bsd.c:160: error: `USB_SET_ALTINTERFACE' undeclared (first use in this function)                                                                                               
usb-bsd.c:177: error: `USBD_SHORT_XFER_OK' undeclared (first use in this function)                                                                                                 
usb-bsd.c:179: error: `USB_SET_TIMEOUT' undeclared (first use in this function)
usb-bsd.c:191: error: `USB_DO_REQUEST' undeclared (first use in this function)
usb-bsd.c:128: warning: unused variable `req'
usb-bsd.c:129: warning: unused variable `aiface'
usb-bsd.c: In function `usb_host_handle_data':
usb-bsd.c:233: error: `USB_SET_TIMEOUT' undeclared (first use in this function)
usb-bsd.c:241: error: `USB_SET_SHORT_XFER' undeclared (first use in this function)
usb-bsd.c: In function `usb_host_device_open':
usb-bsd.c:293: error: storage size of 'bus_info' isn't known
usb-bsd.c:293: error: storage size of 'dev_info' isn't known
usb-bsd.c:315: error: `USB_DEVICEINFO' undeclared (first use in this function)
usb-bsd.c:346: error: `USB_GET_DEVICEINFO' undeclared (first use in this function)
usb-bsd.c:355: error: `USB_SPEED_LOW' undeclared (first use in this function)
usb-bsd.c:357: error: `USB_SPEED_FULL' undeclared (first use in this function)
usb-bsd.c:380: error: `USB_SETDEBUG' undeclared (first use in this function)
usb-bsd.c:293: warning: unused variable `bus_info'
usb-bsd.c:293: warning: unused variable `dev_info'
usb-bsd.c: In function `usb_host_scan':
usb-bsd.c:391: error: storage size of 'bus_info' isn't known
usb-bsd.c:392: error: storage size of 'dev_info' isn't known
usb-bsd.c:408: error: `USB_DEVICEINFO' undeclared (first use in this function)
usb-bsd.c:430: error: `USB_GET_DEVICEINFO' undeclared (first use in this function)
usb-bsd.c:391: warning: unused variable `bus_info'
usb-bsd.c:392: warning: unused variable `dev_info'
usb-bsd.c: In function `usb_info_device':
usb-bsd.c:560: error: `USB_SPEED_LOW' undeclared (first use in this function)
usb-bsd.c:563: error: `USB_SPEED_FULL' undeclared (first use in this function)
usb-bsd.c:566: error: `USB_SPEED_HIGH' undeclared (first use in this function)
usb-bsd.c:574: warning: implicit declaration of function `term_printf'
gmake: *** [usb-bsd.o] Error 1
*** Error code 2

Stop in /usr/ports/emulators/qemu.
*** Error code 1
---

How-To-Repeat: //update to latest src tree
1) (on 8-CURRENT) csup or `svn checkout svn://svn.freebsd.org/base/head /usr/src` for update SRC tree for fresh sources.
2) cd /usr/src; make buildworld && make kernel=GENERIC;
3) shutdown -r now
4) (after boot) cd /usr/src && make installworld
// delete deprecated files & libs 
5) cd /usr/src
6) yes |make delete-old
7) yes |make delete-old-libs
// update ports tree
8) portsnap fetch update
9) cd /usr/ports/emulators/qemu; make
Comment 1 Mark Linimon freebsd_committer freebsd_triage 2009-02-26 16:01:57 UTC
Responsible Changed
From-To: freebsd-ports-bugs->nox

Over to maintainer.
Comment 2 Jedrzej Kalinowski 2009-02-26 23:44:13 UTC
Hi, the following patch helped for me. Legacy usb headers were moved. It's
a quick fix however, it doesn't switch qemu to use new usb stack of course.

Hope the way I'm posting this patch is OK..


--- usb-bsd.c.orig	2009-02-26 21:45:27.000000000 +0100
+++ usb-bsd.c	2009-02-26 21:31:33.000000000 +0100
@@ -34,7 +34,7 @@
 #undef USB_SPEED_LOW
 
 #include <sys/ioctl.h>
-#include <dev/usb/usb.h>
+#include <legacy/dev/usb/usb.h>
 #include <signal.h>
 
 /* This value has maximum potential at 16.
Comment 3 Oleg Ginzburg 2009-02-27 09:34:22 UTC
Hello. This work-around helped for me too. Thanks a lot!

On Friday 27 February 2009 02:44:13 J=C4=99drzej Kalinowski wrote:
> Hi, the following patch helped for me. Legacy usb headers were moved. It's
> a quick fix however, it doesn't switch qemu to use new usb stack of cours=
e.
>
> Hope the way I'm posting this patch is OK..
>
>
> --- usb-bsd.c.orig	2009-02-26 21:45:27.000000000 +0100
> +++ usb-bsd.c	2009-02-26 21:31:33.000000000 +0100
> @@ -34,7 +34,7 @@
>  #undef USB_SPEED_LOW
>
>  #include <sys/ioctl.h>
> -#include <dev/usb/usb.h>
> +#include <legacy/dev/usb/usb.h>
>  #include <signal.h>
>
>  /* This value has maximum potential at 16.

=2D-=20
 =D0=A1 =D1=83=D0=B2=D0=B0=D0=B6=D0=B5=D0=BD=D0=B8=D0=B5=D0=BC, With respec=
t,
 =D0=9E=D0=BB=D0=B5=D0=B3 =D0=93=D0=B8=D0=BD=D0=B7=D0=B1=D1=83=D1=80=D0=B3 =
Oleg Ginzburg
 =D0=A1=D0=B8=D1=81=D1=82=D0=B5=D0=BC=D0=BD=D1=8B=D0=B9 =D0=90=D0=B4=D0=BC=
=D0=B8=D0=BD=D0=B8=D1=81=D1=82=D1=80=D0=B0=D1=82=D0=BE=D1=80 System  Admini=
strator
 =D0=9D=D0=B5=D0=B2=D0=BE=D0=A1=D0=BE=D1=84=D1=82 NevoSoft
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
 Work tel: +7(812)347-89-33
 E-mail: mailto: oleg.ginzburg@nevosoft.ru
 ICQ UIN: 168422614
 Skype: olegginzburg
 Jabber: oleg.ginzburg@nevosoft.ru
 URL: http://www.nevosoft.ru
Comment 4 dfilter service freebsd_committer freebsd_triage 2009-02-28 16:50:54 UTC
nox         2009-02-28 16:50:44 UTC

  FreeBSD ports repository

  Added files:
    emulators/qemu/files patch-bandaid-usb-current 
    emulators/qemu-devel/files patch-bandaid-usb-current 
  Log:
  Add band-aid build fix for -current (usb host support still wont work with
  the new stack - helpful hands wanted there!)
  
  PR:             ports/132126
  Submitted by:   Oleg Ginzburg <oleg.ginzburg@nevosoft.ru>
  
  Revision  Changes    Path
  1.1       +14 -0     ports/emulators/qemu-devel/files/patch-bandaid-usb-current (new)
  1.1       +14 -0     ports/emulators/qemu/files/patch-bandaid-usb-current (new)
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 5 Juergen Lock freebsd_committer freebsd_triage 2009-02-28 16:51:26 UTC
State Changed
From-To: open->closed

Band-aid fix committed. Thanks!