A bit more cleaning of precompiled headers for Windows builds. Comment on why things are done as they are. Also move a few headers only used in single files out of the precompiled header and into the places they're actually used.

Originally committed to SVN as r3519.
This commit is contained in:
Niels Martin Hansen 2009-09-10 23:08:38 +00:00
parent 88276ed1f4
commit 6cc37d3f0b
4 changed files with 9 additions and 17 deletions

View file

@ -89,16 +89,15 @@
#include <wchar.h> #include <wchar.h>
#ifdef _WIN32 #ifdef _WIN32
// "Lean and mean" causes windows.h to include less stuff, mostly rarely-used things.
// We can't build without being "lean and mean", some of the things included by it has
// macros that clash with variable names around Aegisub causing strange build errors.
#define WIN32_LEAN_AND_MEAN #define WIN32_LEAN_AND_MEAN
// Windows.h must always be the first one, it defines a load of important things
#include <windows.h> #include <windows.h>
#include <objbase.h>
#include <mmsystem.h> #include <mmsystem.h>
#include <dsound.h> //#include <process.h> // Currently only used in audio_player_dsound2.cpp
#include <process.h>
//#include <objbase.h>
#include <shlobj.h>
#include <tchar.h>
#include <vfw.h>
//#include <windef.h>
#else #else

View file

@ -42,10 +42,10 @@
#ifdef WITH_DIRECTSOUND #ifdef WITH_DIRECTSOUND
#ifndef AGI_PRE #ifndef AGI_PRE
#include <dsound.h>
#include <mmsystem.h> #include <mmsystem.h>
#include <process.h>
#endif #endif
#include <process.h>
#include <dsound.h>
#include "audio_player_dsound2.h" #include "audio_player_dsound2.h"
#include "frame_main.h" #include "frame_main.h"

View file

@ -43,13 +43,10 @@
#ifdef WITH_FREETYPE2 #ifdef WITH_FREETYPE2
#ifndef AGI_PRE #ifndef AGI_PRE
#ifdef __WINDOWS__
#include <shlobj.h>
#endif
#include <wx/dir.h> #include <wx/dir.h>
#endif #endif
#include <shlobj.h>
#include <ft2build.h> #include <ft2build.h>
#include FT_FREETYPE_H #include FT_FREETYPE_H
#include FT_GLYPH_H #include FT_GLYPH_H

View file

@ -42,11 +42,7 @@
// Headers // Headers
#include "config.h" #include "config.h"
#ifndef AGI_PRE
#ifdef __WINDOWS__
#include <vfw.h> #include <vfw.h>
#endif
#endif
#include "vfw_wrap.h" #include "vfw_wrap.h"