I've been running with this diff for a while, and I think its time for it
to be committed.  OK?


On 2009 Mar 12 (Thu) at 20:50:55 +0100 (+0100), Sylvestre Gallon wrote:
:Hi ports@,
:
:You can find in attach an update on plib which permits the use
:of plib (and so tuxkart) on other arch than i386.
:
:I have just tried it on amd64 so if someone can try it with
:tuxkart on i386, sparc64 or another ARCH it would be nice.
:
:Cheers.
:
:-- 
:Sylvestre Gallon (http://devsyl.blogspot.com)
:PMBSD developer (http://pmbsd.sourceforge.net)
:Embedded Software engineer @ Adeno Embedded
:Fifth Grade Student @ Epitech & Researcher @ LSE
:R&D @ Rathaxes (http://www.rathaxes.org)



-- 
Lackland's Laws:
        (1) Never be first.
        (2) Never be last.
        (3) Never volunteer for anything.
Index: Makefile
===================================================================
RCS file: /cvs/openbsd/ports/devel/plib/Makefile,v
retrieving revision 1.3
diff -u -p -u -p -r1.3 Makefile
--- Makefile    10 Apr 2009 08:54:32 -0000      1.3
+++ Makefile    11 Jun 2009 12:33:26 -0000
@@ -1,12 +1,9 @@
 # $OpenBSD: Makefile,v 1.3 2009/04/10 08:54:32 simon Exp $
 
-# needs joystick.h
-ONLY_FOR_ARCHS =       i386
-
 COMMENT =      suite of portable game libraries
 
 DISTNAME =     plib-1.8.5
-PKGNAME =      ${DISTNAME}p0
+PKGNAME =      ${DISTNAME}p1
 CATEGORIES =   devel games
 
 HOMEPAGE =     http://plib.sourceforge.net/
Index: patches/patch-src_js_jsBSD_cxx
===================================================================
RCS file: patches/patch-src_js_jsBSD_cxx
diff -N patches/patch-src_js_jsBSD_cxx
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ patches/patch-src_js_jsBSD_cxx      5 Jun 2009 21:10:20 -0000
@@ -0,0 +1,40 @@
+--- src/js/jsBSD.cxx.orig      Tue Mar 11 03:06:21 2008
++++ src/js/jsBSD.cxx   Thu Mar 12 21:33:03 2009
+@@ -50,8 +50,10 @@
+ #if defined(__FreeBSD__)
+ # include <sys/joystick.h>
+ #else
++#if defined(__i386__)
+ # include <machine/joystick.h>                // For analog joysticks
+ #endif
++#endif
+ #ifdef HAVE_USB_JS
+ #if defined(__NetBSD__)
+ #ifdef HAVE_USBHID_H
+@@ -85,7 +87,9 @@ struct os_specific_s {
+   int              fd;
+   int              is_analog;
+   // The following structure members are specific to analog joysticks
++#if defined(__i386__)
+   struct joystick  ajs;
++#endif
+ #ifdef HAVE_USB_JS
+   // The following structure members are specific to USB joysticks
+   struct hid_item *hids;
+@@ -437,7 +441,7 @@ void jsJoystick::rawRead ( int *buttons, float *axes )
+ 
+     return ;
+   }
+-
++#if defined(__i386__)
+   if ( os->is_analog )
+   {
+     int status = ::read ( os->fd, &os->ajs, sizeof(os->ajs) );
+@@ -462,6 +466,7 @@ void jsJoystick::rawRead ( int *buttons, float *axes )
+ 
+     return;
+   }
++#endif
+ 
+ #ifdef HAVE_USB_JS
+   while ((len = ::read(os->fd, os->hid_data_buf, os->hid_dlen)) == 
os->hid_dlen)

Reply via email to