-----BEGIN PGP SIGNED MESSAGE-----

Here's a diff patch that is necessary for a MESS compile on OpenVMS.

===========================================================================
- --- ./xmame-0.77.1/mess/machine/lynx.c        Sun Sep  7 13:05:27 2003
+++ lynx.c      Sat Dec 20 16:05:53 2003
@@ -1,6 +1,13 @@
 /******************************************************************************
  PeT [EMAIL PROTECTED] 2000,2001
 ******************************************************************************/
+
+/*
+ * Modifications For OpenVMS By:  Robert Alan Byer
+ *                                [EMAIL PROTECTED]
+ *                                Dec. 8, 2003
+ */
+
 #include <assert.h>
 #include "includes/lynx.h"
 #include "cpu/m6502/m6502.h"
@@ -899,7 +906,15 @@
                This->timer_active = 0;
 }
 
+/*
+ * OpenVMS has "times" defined in <times.h> which conflicts with this
+ * definition.  So for OpenVMS we just rename it to "lynx_times".
+ */
+#if defined(__DECC) && defined(VMS)
+static double lynx_times[]= { 1e-6, 2e-6, 4e-6, 8e-6, 16e-6, 32e-6, 64e-6 };
+#else
 static double times[]= { 1e-6, 2e-6, 4e-6, 8e-6, 16e-6, 32e-6, 64e-6 };
+#endif
 
 static UINT8 lynx_timer_read(LYNX_TIMER *This, int offset)
 {
@@ -913,7 +928,15 @@
                else
                {
                        if (This->timer_active)
+/*
+ * OpenVMS has "times" defined in <times.h> which conflicts with this
+ * definition.  So for OpenVMS we just rename it to "lynx_times".
+ */
+#if defined(__DECC) && defined(VMS)
+                               
data=(UINT8)(This->u.s.bakup-timer_timeleft(This->timer)/lynx_times[This->u.s.cntrl1&7]);
+#else
                                
data=(UINT8)(This->u.s.bakup-timer_timeleft(This->timer)/times[This->u.s.cntrl1&7]);
+#endif
                }
                break;
 
@@ -958,9 +981,21 @@
                        {
                                t=This->u.s.bakup+1;
                                if (This->u.s.cntrl1&0x10)
+/*
+ * OpenVMS has "times" defined in <times.h> which conflicts with this
+ * definition.  So for OpenVMS we just rename it to "lynx_times".
+ */
+#if defined(__DECC) && defined(VMS)
+                                       timer_adjust(This->timer, 0, This->nr, 
t*lynx_times[This->u.s.cntrl1&7]);
+#else
                                        timer_adjust(This->timer, 0, This->nr, 
t*times[This->u.s.cntrl1&7]);
+#endif
                                else
+#if defined(__DECC) && defined(VMS)
+                                       timer_adjust(This->timer, 
t*lynx_times[This->u.s.cntrl1&7], This->nr, 0);
+#else
                                        timer_adjust(This->timer, 
t*times[This->u.s.cntrl1&7], This->nr, 0);
+#endif
                                This->timer_active = 1;
                        }
                }

===========================================================================


 +------------------+--------------------------+---------------+
 | Robert Alan Byer | [EMAIL PROTECTED] | ICQ #65926579 |
 +------------------+--------------------------+---------------+
 | Send an E-mail request to obtain a copy of my PGP key.      |
 +-------------------------------------------------------------+
 | "It is by caffeine alone I set my mind in motion.  It is by |
 |  cans of cola the thoughts aquire speed, the hands acquire  |
 |  shakes, the shakes become a warning.  It is by caffeine    |
 |  alone I set my mind in motion."                            |
 +-------------------------------------------------------------+


-----BEGIN PGP SIGNATURE-----
Version: 2.6.3ia
Charset: noconv

iQEVAwUBP+S+KqVSqzlBVJbBAQG+Jgf9Ficu9UVruqB7nUPKsbgAbV5Uvv0F9c0W
SFqSMcfpquRqTy2jlkU+iJRfyTxN55L1/NeTMOyhsHRa+NtYKGqhMI4ZtwkCPrMW
yCCpWkihOHUFgIbuAx6u2RkLZT9iWmWcRAivez4Q46oa5mNMjB/HjgXAwNf43ATR
ffy/1iVKCfK3Afgj+0z1LVvIvSwSoun3eLynnR9U8Z8maJ+m83rEOk1WFzNI9ruq
6Jn/qO4No7n3mM4MAFhewAAyN7TqYBiYfOq/LyC27g55n6vQ0wr1tIFBCAW/QIad
yWfszUk260cqpqnUvQmxrag3pbq1ZXEg0WySQ7DPBVdxGfTWE5RyAw==
=Qe3H
-----END PGP SIGNATURE-----

_______________________________________________
Xmame mailing list
[EMAIL PROTECTED]
http://toybox.twisted.org.uk/mailman/listinfo/xmame

Reply via email to