|
|
1.1 root 1: /*
2: Hatari - compat.h
3:
1.1.1.2 root 4: This file is distributed under the GNU General Public License, version 2
5: or at your option any later version. Read the file gpl.txt for details.
1.1 root 6:
1.1.1.2 root 7: This file contains all the includes and defines specific to windows (such as
8: TCHAR) needed by WinUAE CPU core.
9: The aim is to have minimum changes in WinUae CPU core for next updates.
1.1 root 10: */
11:
12: #ifndef HATARI_COMPAT_H
13: #define HATARI_COMPAT_H
14:
15: #include <stdbool.h>
16:
17: #include "sysconfig.h"
18:
19: /* This define is here to remove some Amiga specific code when compiling */
20: /* It results in ' #if 0 ' code in newcpu.c code */
21: #define AMIGA_ONLY 0
22:
1.1.1.4 ! root 23:
! 24: #define WINUAE_FOR_HATARI
! 25:
! 26:
1.1 root 27: /* this defione is here for newcpu.c compatibility.
28: * In WinUae, it's defined in debug.h" */
29: #ifndef MAX_LINEWIDTH
30: #define MAX_LINEWIDTH 100
31: #endif
32:
33: #define RTAREA_DEFAULT 0xf00000
34:
35: /* Laurent */
36: /* here only to allow newcpu.c to compile */
37: /* Should be removed when newcpu.c 'll be relooked for hatari only*/
1.1.1.2 root 38: extern int vpos;
39: extern int quit_program; // declared as "int quit_program = 0;" in main.c
1.1 root 40: //WinUae ChangeLog: Improve quitting/resetting behaviour: Move quit_program from GUI
41: //WinUae ChangeLog: quit_program is now handled in vsync_handler() and m68k_go().
42:
43: #ifndef REGPARAM
44: #define REGPARAM
45: #endif
46:
47: #ifndef REGPARAM2
48: #define REGPARAM2
49: #endif
50:
51: #ifndef REGPARAM3
52: #define REGPARAM3
53: #endif
54:
55: #ifndef TCHAR
56: #define TCHAR char
57: #endif
58:
1.1.1.4 ! root 59: //#ifndef STATIC_INLINE
! 60: //#define STATIC_INLINE static inline
! 61: //#endif
1.1 root 62:
63: #define _vsnprintf vsnprintf
64: #define _tcsncmp strncmp
65: #define _istspace isspace
66: #define _tcscmp strcmp
67: #define _tcslen strlen
68: #define _tcsstr strstr
69: #define _tcscpy strcpy
70: #define _tcsncpy strncpy
71: #define _tcscat strcat
72: #define _stprintf sprintf
1.1.1.4 ! root 73: #define strnicmp strncasecmp
! 74: #define _T(x) x
1.1 root 75:
76: #define _vsntprintf printf
77:
78: #define f_out fprintf
1.1.1.4 ! root 79: #define console_out printf
! 80: //#define console_out_f printf
! 81: #define console_out_f(...) { if ( console_out_FILE ) fprintf ( console_out_FILE , __VA_ARGS__ ); else printf ( __VA_ARGS__ ); }
! 82: #define error_log printf
! 83: #define gui_message console_out_f
1.1 root 84:
85: #endif
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.