diff --git a/desmume/src/NDSSystem.h b/desmume/src/NDSSystem.h
index 9c2cc6cae..f2af566d4 100644
--- a/desmume/src/NDSSystem.h
+++ b/desmume/src/NDSSystem.h
@@ -1,6 +1,6 @@
/*
Copyright (C) 2006 yopyop
- Copyright (C) 2008-2021 DeSmuME team
+ Copyright (C) 2008-2022 DeSmuME team
This file is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -26,8 +26,6 @@
#include "types.h"
#include "ROMReader.h"
#include "firmware.h"
-#include "render3D.h"
-#include "wifi.h"
class CFIRMWARE;
class EMUFILE;
diff --git a/desmume/src/ROMReader.h b/desmume/src/ROMReader.h
index b6bb656a0..505fbf772 100644
--- a/desmume/src/ROMReader.h
+++ b/desmume/src/ROMReader.h
@@ -1,6 +1,6 @@
/*
Copyright (C) 2007 Guillaume Duhamel
- Copyright (C) 2007-20017 DeSmuME team
+ Copyright (C) 2007-2022 DeSmuME team
This file is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -16,6 +16,9 @@
along with the this software. If not, see .
*/
+#ifndef _ROMREADER_H_
+#define _ROMREADER_H_
+
#ifdef HAVE_LIBZ
#include
#endif
@@ -51,3 +54,5 @@ extern ROMReader_struct ZIPROMReader;
ROMReader_struct * ROMReaderInit(char ** filename);
ROMReader_struct * MemROMReaderRead_TrueInit(void* buf, int length);
+
+#endif // _ROMREADER_H_
diff --git a/desmume/src/cheatSystem.cpp b/desmume/src/cheatSystem.cpp
index 00d50e5e5..cf888c275 100644
--- a/desmume/src/cheatSystem.cpp
+++ b/desmume/src/cheatSystem.cpp
@@ -1,5 +1,5 @@
/*
- Copyright (C) 2009-2021 DeSmuME team
+ Copyright (C) 2009-2022 DeSmuME team
This file is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -22,6 +22,7 @@
#include "mem.h"
#include "MMU.h"
#include "debug.h"
+#include "emufile.h"
#ifndef _MSC_VER
#include
diff --git a/desmume/src/frontend/cocoa/ClientExecutionControl.cpp b/desmume/src/frontend/cocoa/ClientExecutionControl.cpp
index 87950cdde..e80e92d49 100644
--- a/desmume/src/frontend/cocoa/ClientExecutionControl.cpp
+++ b/desmume/src/frontend/cocoa/ClientExecutionControl.cpp
@@ -1,5 +1,5 @@
/*
- Copyright (C) 2017-2021 DeSmuME team
+ Copyright (C) 2017-2022 DeSmuME team
This file is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -24,6 +24,7 @@
#include "../../NDSSystem.h"
#include "../../gdbstub.h"
#include "../../rtc.h"
+#include "../../wifi.h"
#include "ClientAVCaptureObject.h"
#include "ClientExecutionControl.h"
diff --git a/desmume/src/wifi.cpp b/desmume/src/wifi.cpp
index aabb6e0f6..f6fc7ac0d 100644
--- a/desmume/src/wifi.cpp
+++ b/desmume/src/wifi.cpp
@@ -20,6 +20,7 @@
#include "wifi.h"
#include "armcpu.h"
#include "NDSSystem.h"
+#include "emufile.h"
#include "debug.h"
#include "utils/bits.h"
#include "utils/task.h"
diff --git a/desmume/src/wifi.h b/desmume/src/wifi.h
index b0fe8c497..94c1a568b 100644
--- a/desmume/src/wifi.h
+++ b/desmume/src/wifi.h
@@ -29,7 +29,6 @@
#include
#include
#include
-#include "emufile.h"
#if defined(__cplusplus) && (__cplusplus < 201103L)
#define DESMUME_ENUM(type,name) enum name
@@ -212,6 +211,7 @@
class WifiHandler;
class Task;
+class EMUFILE;
struct slock;
typedef slock slock_t;