Remove redundant #ifndef conditionals for includes

This commit is contained in:
Allofich
2021-08-22 15:13:27 +09:00
parent 4f34372930
commit 4d7be1c15b
18 changed files with 1 additions and 43 deletions

View File

@@ -19,9 +19,7 @@
#ifndef DOSBOX_BIOS_DISK_H #ifndef DOSBOX_BIOS_DISK_H
#define DOSBOX_BIOS_DISK_H #define DOSBOX_BIOS_DISK_H
#ifndef DOSBOX_DOS_INC_H
#include "dos_inc.h" #include "dos_inc.h"
#endif
#include "logging.h" #include "logging.h"
#include "../src/dos/cdrom.h" #include "../src/dos/cdrom.h"

View File

@@ -20,9 +20,7 @@
#ifndef DOSBOX_CALLBACK_H #ifndef DOSBOX_CALLBACK_H
#define DOSBOX_CALLBACK_H #define DOSBOX_CALLBACK_H
#ifndef DOSBOX_MEM_H
#include "mem.h" #include "mem.h"
#endif
typedef Bitu (*CallBack_Handler)(void); typedef Bitu (*CallBack_Handler)(void);
extern CallBack_Handler CallBack_Handlers[]; extern CallBack_Handler CallBack_Handlers[];

View File

@@ -25,9 +25,7 @@
//#pragma warning ( disable : 4290 ) //#pragma warning ( disable : 4290 )
#endif #endif
#ifndef DOSBOX_PROGRAMS_H
#include "programs.h" #include "programs.h"
#endif
#include "setup.h" #include "setup.h"
class Config{ class Config{

View File

@@ -20,9 +20,7 @@
#ifndef DOSBOX_CPU_H #ifndef DOSBOX_CPU_H
#define DOSBOX_CPU_H #define DOSBOX_CPU_H
#ifndef DOSBOX_REGS_H
#include "regs.h" #include "regs.h"
#endif
#define CPU_AUTODETERMINE_NONE 0x00 #define CPU_AUTODETERMINE_NONE 0x00
#define CPU_AUTODETERMINE_CORE 0x01 #define CPU_AUTODETERMINE_CORE 0x01

View File

@@ -22,9 +22,7 @@
#define CTBUF 127 #define CTBUF 127
#ifndef DOSBOX_DOS_SYSTEM_H #include "dos_system.h"
#include "dos_system.h"
#endif
#include <list> #include <list>
#include <stddef.h> //for offsetof #include <stddef.h> //for offsetof

View File

@@ -20,16 +20,10 @@
#ifndef DOSBOX_DOS_SYSTEM_H #ifndef DOSBOX_DOS_SYSTEM_H
#define DOSBOX_DOS_SYSTEM_H #define DOSBOX_DOS_SYSTEM_H
#ifndef DOSBOX_CROSS_H
#include "cross.h" #include "cross.h"
#endif
#include "string.h" #include "string.h"
#ifndef DOSBOX_SUPPORT_H
#include "support.h" #include "support.h"
#endif
#ifndef DOSBOX_MEM_H
#include "mem.h" #include "mem.h"
#endif
#define DOS_NAMELENGTH 12u #define DOS_NAMELENGTH 12u
#define DOS_NAMELENGTH_ASCII (DOS_NAMELENGTH+1) #define DOS_NAMELENGTH_ASCII (DOS_NAMELENGTH+1)

View File

@@ -33,9 +33,7 @@
#endif #endif
#endif #endif
#ifndef DOSBOX_MEM_H
#include "mem.h" #include "mem.h"
#endif
// In Use Flag codes // In Use Flag codes
#define USEFLAG_AVAILABLE 0x00 #define USEFLAG_AVAILABLE 0x00

View File

@@ -19,9 +19,7 @@
#ifndef DOSBOX_MEM_H #ifndef DOSBOX_MEM_H
#define DOSBOX_MEM_H #define DOSBOX_MEM_H
#ifndef DOSBOX_DOSBOX_H
#include "dosbox.h" #include "dosbox.h"
#endif
#include "byteorder.h" #include "byteorder.h"

View File

@@ -20,9 +20,7 @@
#ifndef DOSBOX_MIDI_H #ifndef DOSBOX_MIDI_H
#define DOSBOX_MIDI_H #define DOSBOX_MIDI_H
#ifndef DOSBOX_PROGRAMS_H
#include "programs.h" #include "programs.h"
#endif
class MidiHandler { class MidiHandler {
public: public:

View File

@@ -20,9 +20,7 @@
#ifndef DOSBOX_PAGING_H #ifndef DOSBOX_PAGING_H
#define DOSBOX_PAGING_H #define DOSBOX_PAGING_H
#ifndef DOSBOX_MEM_H
#include "mem.h" #include "mem.h"
#endif
// disable this to reduce the size of the TLB // disable this to reduce the size of the TLB
// NOTE: does not work with the dynamic core (dynrec is fine) // NOTE: does not work with the dynamic core (dynrec is fine)

View File

@@ -22,9 +22,7 @@
// set to 1 for debug messages and debugging log: // set to 1 for debug messages and debugging log:
#define PARALLEL_DEBUG 0 #define PARALLEL_DEBUG 0
#ifndef DOSBOX_INOUT_H
#include "inout.h" #include "inout.h"
#endif
#include "programs.h" #include "programs.h"

View File

@@ -20,9 +20,7 @@
#ifndef DOSBOX_PROGRAMS_H #ifndef DOSBOX_PROGRAMS_H
#define DOSBOX_PROGRAMS_H #define DOSBOX_PROGRAMS_H
#ifndef DOSBOX_DOS_INC_H
#include "dos_inc.h" #include "dos_inc.h"
#endif
class CommandLine { class CommandLine {
public: public:

View File

@@ -19,9 +19,7 @@
#ifndef DOSBOX_REGS_H #ifndef DOSBOX_REGS_H
#define DOSBOX_REGS_H #define DOSBOX_REGS_H
#ifndef DOSBOX_MEM_H
#include "mem.h" #include "mem.h"
#endif
#define FLAG_CF 0x00000001U #define FLAG_CF 0x00000001U
#define FLAG_PF 0x00000004U #define FLAG_PF 0x00000004U

View File

@@ -20,12 +20,8 @@
#ifndef DOSBOX_SERIALPORT_H #ifndef DOSBOX_SERIALPORT_H
#define DOSBOX_SERIALPORT_H #define DOSBOX_SERIALPORT_H
#ifndef DOSBOX_INOUT_H
#include "inout.h" #include "inout.h"
#endif
#ifndef DOSBOX_PROGRAMS_H
#include "programs.h" #include "programs.h"
#endif
// set this to 1 for serial debugging in release mode // set this to 1 for serial debugging in release mode
#define SERIAL_DBG_FORCED 1 #define SERIAL_DBG_FORCED 1

View File

@@ -20,9 +20,7 @@
#ifndef DOSBOX_SHELL_H #ifndef DOSBOX_SHELL_H
#define DOSBOX_SHELL_H #define DOSBOX_SHELL_H
#ifndef DOSBOX_PROGRAMS_H
#include "programs.h" #include "programs.h"
#endif
#include <SDL.h> #include <SDL.h>
#if SDL_VERSION_ATLEAST(2, 0, 0) #if SDL_VERSION_ATLEAST(2, 0, 0)

View File

@@ -20,9 +20,7 @@
#ifndef DOSBOX_SUPPORT_H #ifndef DOSBOX_SUPPORT_H
#define DOSBOX_SUPPORT_H #define DOSBOX_SUPPORT_H
#ifndef DOSBOX_DOSBOX_H
#include "dosbox.h" #include "dosbox.h"
#endif
#if defined (_MSC_VER) /* MS Visual C++ */ #if defined (_MSC_VER) /* MS Visual C++ */
#define strcasecmp(a,b) stricmp(a,b) #define strcasecmp(a,b) stricmp(a,b)

View File

@@ -46,9 +46,7 @@ extern "C" {
//#define HAVE_BZIP2 //#define HAVE_BZIP2
#ifndef _ZLIB_H
#include "zlib.h" #include "zlib.h"
#endif
#ifndef _ZLIBIOAPI_H #ifndef _ZLIBIOAPI_H
#include "ioapi.h" #include "ioapi.h"

View File

@@ -31,9 +31,7 @@ Bitu FillFlags(void);
void FillFlagsNoCFOF(void); void FillFlagsNoCFOF(void);
void DestroyConditionFlags(void); void DestroyConditionFlags(void);
#ifndef DOSBOX_REGS_H
#include "regs.h" #include "regs.h"
#endif
struct LazyFlags { struct LazyFlags {
GenReg32 var1,var2,res; GenReg32 var1,var2,res;