ports/132150: [PATCH] devel/sdl: fix build with new usb stack

Yuri Pankov yuri.pankov at gmail.com
Fri Feb 27 03:50:02 UTC 2009


>Number:         132150
>Category:       ports
>Synopsis:       [PATCH] devel/sdl: fix build with new usb stack
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Fri Feb 27 03:50:01 UTC 2009
>Closed-Date:
>Last-Modified:
>Originator:     Yuri Pankov
>Release:        FreeBSD 8.0-CURRENT amd64
>Organization:
>Environment:
System: FreeBSD darklight.homeunix.org 8.0-CURRENT FreeBSD 8.0-CURRENT #0: Wed Feb 25 13:03:56 MSK 2009
>Description:
Fix build with new usb stack.

Added file(s):
- files/usb2

Port maintainer (mva at FreeBSD.org) is cc'd.

Generated with FreeBSD Port Tools 0.77
>How-To-Repeat:
>Fix:

--- sdl-1.2.13_3,2.patch begins here ---
Index: Makefile
===================================================================
RCS file: /home/ncvs/ports/devel/sdl12/Makefile,v
retrieving revision 1.115
diff -u -r1.115 Makefile
--- Makefile	19 Feb 2009 21:45:39 -0000	1.115
+++ Makefile	27 Feb 2009 03:44:45 -0000
@@ -7,7 +7,7 @@
 
 PORTNAME=	sdl
 PORTVERSION=	1.2.13
-PORTREVISION=	2
+PORTREVISION=	3
 PORTEPOCH=	2
 CATEGORIES=	devel
 MASTER_SITES=	http://www.libsdl.org/release/
@@ -62,6 +62,11 @@
 
 .include <bsd.port.pre.mk>
 
+.if ${OSVERSION} >= 800064
+CFLAGS+=	-DUSBHID_UCR_DATA
+EXTRA_PATCHES+=	${FILESDIR}/usb2
+.endif
+
 MAN3!=		${CAT} ${FILESDIR}/man3
 
 .if defined(WITHOUT_AALIB)
Index: files/usb2
===================================================================
RCS file: files/usb2
diff -N files/usb2
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ files/usb2	27 Feb 2009 03:44:45 -0000
@@ -0,0 +1,22 @@
+--- src/joystick/bsd/SDL_sysjoystick.c.orig	2007-12-31 07:47:55.000000000 +0300
++++ src/joystick/bsd/SDL_sysjoystick.c	2009-02-27 06:12:54.503954886 +0300
+@@ -45,6 +45,7 @@
+ #else
+ #include <dev/usb/usb.h>
+ #include <dev/usb/usbhid.h>
++#include <dev/usb/usb_ioctl.h>
+ #endif
+ 
+ #if defined(HAVE_USBHID_H)
+@@ -74,6 +75,11 @@
+ #define MAX_JOY_JOYS	2
+ #define MAX_JOYS	(MAX_UHID_JOYS + MAX_JOY_JOYS)
+ 
++struct usb_ctl_report {
++        int     ucr_report;
++        u_char  ucr_data[1024]; /* filled data size will vary */
++};
++
+ struct report {
+ 	struct	usb_ctl_report *buf;	/* Buffer */
+ 	size_t	size;			/* Buffer size */
--- sdl-1.2.13_3,2.patch ends here ---

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



More information about the freebsd-ports-bugs mailing list