/[pcsx2_0.9.7]/trunk/pcsx2/PrecompiledHeader.h
ViewVC logotype

Contents of /trunk/pcsx2/PrecompiledHeader.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 62 - (show annotations) (download)
Tue Sep 7 11:08:22 2010 UTC (10 years, 1 month ago) by william
File MIME type: text/plain
File size: 4184 byte(s)
Auto Commited Import of: pcsx2-0.9.7-r3738-debug in ./trunk
1 /* PCSX2 - PS2 Emulator for PCs
2 * Copyright (C) 2002-2010 PCSX2 Dev Team
3 *
4 * PCSX2 is free software: you can redistribute it and/or modify it under the terms
5 * of the GNU Lesser General Public License as published by the Free Software Found-
6 * ation, either version 3 of the License, or (at your option) any later version.
7 *
8 * PCSX2 is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
9 * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
10 * PURPOSE. See the GNU General Public License for more details.
11 *
12 * You should have received a copy of the GNU General Public License along with PCSX2.
13 * If not, see <http://www.gnu.org/licenses/>.
14 */
15
16 #ifndef PCSX2_PRECOMPILED_HEADER
17 #define PCSX2_PRECOMPILED_HEADER
18
19 //#pragma once // no dice, causes problems in GCC PCH (which doesn't really work very well
20
21 // Disable some pointless warnings...
22 #ifdef _MSC_VER
23 # pragma warning(disable:4250) //'class' inherits 'method' via dominance
24 # pragma warning(disable:4996) //ignore the stricmp deprecated warning
25 #endif
26
27 //////////////////////////////////////////////////////////////////////////////////////////
28 // Define PCSX2's own i18n helpers. These override the wxWidgets helpers and provide
29 // additional functionality.
30 //
31 #define WXINTL_NO_GETTEXT_MACRO
32 #undef _
33 #define _(s) pxGetTranslation(_T(s))
34
35 // macro provided for tagging translation strings, without actually running them through the
36 // translator (which the _() does automatically, and sometimes we don't want that). This is
37 // a shorthand replacement for wxTRANSLATE.
38 #ifndef wxLt
39 # define wxLt(a) wxT(a)
40 #endif
41
42 #define NOMINMAX // Disables other libs inclusion of their own min/max macros (we use std instead)
43
44 //////////////////////////////////////////////////////////////////////////////////////////
45 // Welcome wxWidgets to the party!
46
47 #include <wx/string.h>
48 #include <wx/tokenzr.h>
49 #include <wx/intl.h>
50 #include <wx/log.h>
51 #include <wx/filename.h>
52
53 //////////////////////////////////////////////////////////////////////////////////////////
54 // Include the STL junk that's actually handy.
55
56 #include <stdexcept>
57 #include <vector>
58 #include <list>
59 #include <cstring> // string.h under c++
60 #include <cstdio> // stdio.h under c++
61 #include <cstdlib>
62
63 // ... and include some ANSI/POSIX C libs that are useful too, just for good measure.
64 // (these compile lightning fast with or without PCH, but they never change so
65 // might as well add them here)
66
67 #include <stddef.h>
68 #include <sys/stat.h>
69 #include <pthread.h>
70
71 using std::min;
72 using std::max;
73
74 typedef int BOOL;
75
76 #undef TRUE
77 #undef FALSE
78 #define TRUE 1
79 #define FALSE 0
80
81
82 //////////////////////////////////////////////////////////////////////////////////////////
83 // Begin Pcsx2 Includes: Add items here that are local to Pcsx2 but stay relatively
84 // unchanged for long periods of time, or happen to be used by almost everything, so they
85 // need a full recompile anyway, when modified (etc)
86
87 #include "zlib.h"
88 #include "Pcsx2Defs.h"
89 #include "i18n.h"
90
91 #include "Utilities/Assertions.h"
92 #include "Utilities/FixedPointTypes.h"
93 #include "Utilities/wxBaseTools.h"
94 #include "Utilities/ScopedPtr.h"
95 #include "Utilities/Path.h"
96 #include "Utilities/Console.h"
97 #include "Utilities/Exceptions.h"
98 #include "Utilities/MemcpyFast.h"
99 #include "Utilities/General.h"
100 #include "x86emitter/tools.h"
101
102 #include "Config.h"
103
104 typedef void FnType_Void();
105 typedef FnType_Void* Fnptr_Void;
106
107 static const s64 _1mb = 0x100000;
108 static const s64 _8mb = _1mb * 8;
109 static const s64 _16mb = _1mb * 16;
110 static const s64 _256mb = _1mb * 256;
111 static const s64 _1gb = _256mb * 4;
112
113 //////////////////////////////////////////////////////////////////////////////////////////
114 // Compiler/OS specific macros and defines -- Begin Section
115
116 // Linux isn't set up for svn version numbers yet.
117 #ifdef __LINUX__
118 # define SVN_REV 0
119 # define SVN_MODS 0
120 #endif
121
122 #if defined(_MSC_VER)
123
124 # define strnicmp _strnicmp
125 # define stricmp _stricmp
126
127 #else // must be GCC...
128
129 # include <sys/types.h>
130 # include <sys/timeb.h>
131
132 // Definitions added Feb 16, 2006 by efp
133 # ifndef __declspec
134 # define __declspec(x)
135 # endif
136
137 #endif // end GCC/Linux stuff
138
139 #endif

  ViewVC Help
Powered by ViewVC 1.1.22