[Plib-cvs] plib/src/js js.h,1.19,1.20
Brought to you by:
sjbaker
From: Sebastian U. <ud...@us...> - 2002-06-22 02:46:57
|
Update of /cvsroot/plib/plib/src/js In directory usw-pr-cvs1:/tmp/cvs-serv20289 Modified Files: js.h Log Message: Aargh - this time for real Index: js.h =================================================================== RCS file: /cvsroot/plib/plib/src/js/js.h,v retrieving revision 1.19 retrieving revision 1.20 diff -u -d -r1.19 -r1.20 --- js.h 22 Jun 2002 02:45:18 -0000 1.19 +++ js.h 22 Jun 2002 02:46:54 -0000 1.20 @@ -66,18 +66,18 @@ # include <machine/joystick.h> # define JS_DATA_TYPE joystick # define JS_RETURN (sizeof(struct JS_DATA_TYPE)) -/*# elif defined(__linux__) +# elif defined(__linux__) # include <sys/ioctl.h> # include <linux/joystick.h> # include <errno.h> -*/ + /* check the joystick driver version */ -/* + # ifdef JS_VERSION # if JS_VERSION >= 0x010000 # define JS_NEW # endif -# endif*/ +# endif # else # ifndef JS_DATA_TYPE @@ -497,10 +497,12 @@ # if defined(__FreeBSD__) || defined(__NetBSD__) //id = ident; sprintf ( fname, "/dev/joy%d", ident ) ; -# else +# elif defined(__linux__) sprintf ( fname, "/dev/input/js%d", ident ) ; if ( access ( fname, F_OK ) != 0 ) sprintf ( fname, "/dev/js%d", ident ) ; +# else + sprintf ( fname, "/dev/js%d", ident ) ; /* FIXME */ # endif open () ; #endif |