From e8368853d3363d60de84fefd8cb5b199745859ef Mon Sep 17 00:00:00 2001 From: bgk Date: Thu, 1 Jan 2009 16:11:02 +0000 Subject: [PATCH] Moved more GBA specific code to the gba folder. git-svn-id: https://svn.code.sf.net/p/vbam/code/trunk@841 a31d4220-a93d-0410-bf67-fe4944624d44 --- CMakeLists.txt | 35 +++++++++++++++++------------------ src/Util.cpp | 6 +++--- src/gb/gbSound.cpp | 2 +- src/{ => gba}/CheatSearch.cpp | 0 src/{ => gba}/CheatSearch.h | 2 +- src/{ => gba}/Cheats.cpp | 8 ++++---- src/{ => gba}/Cheats.h | 0 src/{ => gba}/EEprom.cpp | 4 ++-- src/{ => gba}/EEprom.h | 0 src/{ => gba}/Flash.cpp | 4 ++-- src/{ => gba}/Flash.h | 0 src/gba/GBA-arm.cpp | 16 ++++++++-------- src/gba/GBA-thumb.cpp | 16 ++++++++-------- src/gba/GBA.cpp | 16 ++++++++-------- src/gba/GBA.h | 8 ++++---- src/gba/GBAGfx.h | 2 +- src/gba/GBAinline.h | 4 ++-- src/{ => gba}/Globals.cpp | 2 +- src/{ => gba}/Globals.h | 2 +- src/{ => gba}/Mode0.cpp | 4 ++-- src/{ => gba}/Mode1.cpp | 4 ++-- src/{ => gba}/Mode2.cpp | 4 ++-- src/{ => gba}/Mode3.cpp | 4 ++-- src/{ => gba}/Mode4.cpp | 4 ++-- src/{ => gba}/Mode5.cpp | 4 ++-- src/{ => gba}/RTC.cpp | 10 +++++----- src/{ => gba}/RTC.h | 0 src/{ => gba}/Sound.cpp | 12 ++++++------ src/{ => gba}/Sound.h | 2 +- src/{ => gba}/Sram.cpp | 2 +- src/{ => gba}/Sram.h | 0 src/gba/agbprint.cpp | 2 +- src/{ => gba}/armdis.cpp | 6 +++--- src/{ => gba}/armdis.h | 0 src/{ => gba}/bios.cpp | 4 ++-- src/{ => gba}/bios.h | 0 src/{ => gba}/elf.cpp | 6 +++--- src/{ => gba}/elf.h | 0 src/{ => gba}/remote.cpp | 2 +- src/gtk/system.cpp | 2 +- src/gtk/window.cpp | 2 +- src/gtk/windowcallbacks.cpp | 2 +- src/sdl/SDL.cpp | 12 ++++++------ src/sdl/debugger.cpp | 6 +++--- src/sdl/expr.cpp | 34 +++++++++++++++++----------------- src/sdl/{expr.y => expr.ypp} | 2 +- src/sdl/exprNode.cpp | 2 +- 47 files changed, 129 insertions(+), 130 deletions(-) rename src/{ => gba}/CheatSearch.cpp (100%) rename src/{ => gba}/CheatSearch.h (98%) rename src/{ => gba}/Cheats.cpp (99%) rename src/{ => gba}/Cheats.h (100%) rename src/{ => gba}/EEprom.cpp (99%) rename src/{ => gba}/EEprom.h (100%) rename src/{ => gba}/Flash.cpp (99%) rename src/{ => gba}/Flash.h (100%) rename src/{ => gba}/Globals.cpp (99%) rename src/{ => gba}/Globals.h (99%) rename src/{ => gba}/Mode0.cpp (99%) rename src/{ => gba}/Mode1.cpp (99%) rename src/{ => gba}/Mode2.cpp (99%) rename src/{ => gba}/Mode3.cpp (99%) rename src/{ => gba}/Mode4.cpp (99%) rename src/{ => gba}/Mode5.cpp (99%) rename src/{ => gba}/RTC.cpp (98%) rename src/{ => gba}/RTC.h (100%) rename src/{ => gba}/Sound.cpp (99%) rename src/{ => gba}/Sound.h (98%) rename src/{ => gba}/Sram.cpp (94%) rename src/{ => gba}/Sram.h (100%) rename src/{ => gba}/armdis.cpp (99%) rename src/{ => gba}/armdis.h (100%) rename src/{ => gba}/bios.cpp (99%) rename src/{ => gba}/bios.h (100%) rename src/{ => gba}/elf.cpp (99%) rename src/{ => gba}/elf.h (100%) rename src/{ => gba}/remote.cpp (99%) rename src/sdl/{expr.y => expr.ypp} (98%) diff --git a/CMakeLists.txt b/CMakeLists.txt index bb01db62..513c90af 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -118,21 +118,6 @@ SET( CMAKE_CXX_FLAGS "-O3 -Wall") # Source files definition SET(SRC_MAIN - src/bios.cpp - src/Cheats.cpp - src/CheatSearch.cpp - src/EEprom.cpp - src/Flash.cpp - src/Globals.cpp - src/Mode0.cpp - src/Mode1.cpp - src/Mode2.cpp - src/Mode3.cpp - src/Mode4.cpp - src/Mode5.cpp - src/RTC.cpp - src/Sound.cpp - src/Sram.cpp src/Util.cpp src/common/Patch.cpp src/common/memgzio.c @@ -140,10 +125,24 @@ SET(SRC_MAIN SET(SRC_GBA src/gba/agbprint.cpp + src/gba/bios.cpp + src/gba/Cheats.cpp + src/gba/EEprom.cpp + src/gba/Flash.cpp src/gba/GBA.cpp src/gba/GBAGfx.cpp src/gba/GBA-thumb.cpp src/gba/GBA-arm.cpp + src/gba/Globals.cpp + src/gba/Mode0.cpp + src/gba/Mode1.cpp + src/gba/Mode2.cpp + src/gba/Mode3.cpp + src/gba/Mode4.cpp + src/gba/Mode5.cpp + src/gba/RTC.cpp + src/gba/Sound.cpp + src/gba/Sram.cpp ) SET(SRC_GB @@ -228,9 +227,9 @@ SET(SRC_GTK IF( NOT NO_DEBUGGER ) SET(SRC_DEBUGGER - src/armdis.cpp - src/elf.cpp - src/remote.cpp + src/gba/armdis.cpp + src/gba/elf.cpp + src/gba/remote.cpp ) ENDIF( NOT NO_DEBUGGER ) diff --git a/src/Util.cpp b/src/Util.cpp index 3c8fcf30..c3bcd8b3 100644 --- a/src/Util.cpp +++ b/src/Util.cpp @@ -12,10 +12,10 @@ extern "C" { #include "System.h" #include "NLS.h" #include "Util.h" -#include "Flash.h" +#include "gba/Flash.h" #include "gba/GBA.h" -#include "Globals.h" -#include "RTC.h" +#include "gba/Globals.h" +#include "gba/RTC.h" #include "common/Port.h" #include "common/fex.h" diff --git a/src/gb/gbSound.cpp b/src/gb/gbSound.cpp index e10412c2..bd8d5170 100644 --- a/src/gb/gbSound.cpp +++ b/src/gb/gbSound.cpp @@ -1,6 +1,6 @@ #include -#include "../Sound.h" +#include "../gba/Sound.h" #include "../Util.h" #include "gbGlobals.h" #include "gbSound.h" diff --git a/src/CheatSearch.cpp b/src/gba/CheatSearch.cpp similarity index 100% rename from src/CheatSearch.cpp rename to src/gba/CheatSearch.cpp diff --git a/src/CheatSearch.h b/src/gba/CheatSearch.h similarity index 98% rename from src/CheatSearch.h rename to src/gba/CheatSearch.h index dc9d9e09..4f6cccd5 100644 --- a/src/CheatSearch.h +++ b/src/gba/CheatSearch.h @@ -1,7 +1,7 @@ #ifndef CHEATSEARCH_H #define CHEATSEARCH_H -#include "System.h" +#include "../System.h" struct CheatSearchBlock { int size; diff --git a/src/Cheats.cpp b/src/gba/Cheats.cpp similarity index 99% rename from src/Cheats.cpp rename to src/gba/Cheats.cpp index 036168ef..8f32071e 100644 --- a/src/Cheats.cpp +++ b/src/gba/Cheats.cpp @@ -3,12 +3,12 @@ #include #include -#include "gba/GBA.h" -#include "gba/GBAinline.h" +#include "GBA.h" +#include "GBAinline.h" #include "Cheats.h" #include "Globals.h" -#include "NLS.h" -#include "Util.h" +#include "../NLS.h" +#include "../Util.h" /** * Gameshark code types: (based on AR v1.0) diff --git a/src/Cheats.h b/src/gba/Cheats.h similarity index 100% rename from src/Cheats.h rename to src/gba/Cheats.h diff --git a/src/EEprom.cpp b/src/gba/EEprom.cpp similarity index 99% rename from src/EEprom.cpp rename to src/gba/EEprom.cpp index 512cebb9..2d0a259f 100644 --- a/src/EEprom.cpp +++ b/src/gba/EEprom.cpp @@ -1,7 +1,7 @@ #include -#include "gba/GBA.h" +#include "GBA.h" #include "EEprom.h" -#include "Util.h" +#include "../Util.h" extern int cpuDmaCount; diff --git a/src/EEprom.h b/src/gba/EEprom.h similarity index 100% rename from src/EEprom.h rename to src/gba/EEprom.h diff --git a/src/Flash.cpp b/src/gba/Flash.cpp similarity index 99% rename from src/Flash.cpp rename to src/gba/Flash.cpp index 019bfc45..50c443e3 100644 --- a/src/Flash.cpp +++ b/src/gba/Flash.cpp @@ -1,10 +1,10 @@ #include #include -#include "gba/GBA.h" +#include "GBA.h" #include "Globals.h" #include "Flash.h" #include "Sram.h" -#include "Util.h" +#include "../Util.h" #define FLASH_READ_ARRAY 0 #define FLASH_CMD_1 1 diff --git a/src/Flash.h b/src/gba/Flash.h similarity index 100% rename from src/Flash.h rename to src/gba/Flash.h diff --git a/src/gba/GBA-arm.cpp b/src/gba/GBA-arm.cpp index 667d6918..489056c6 100644 --- a/src/gba/GBA-arm.cpp +++ b/src/gba/GBA-arm.cpp @@ -7,15 +7,15 @@ #include "GBA.h" #include "GBAcpu.h" #include "GBAinline.h" -#include "../Globals.h" -#include "../EEprom.h" -#include "../Flash.h" -#include "../Sound.h" -#include "../Sram.h" -#include "../bios.h" -#include "../Cheats.h" +#include "Globals.h" +#include "EEprom.h" +#include "Flash.h" +#include "Sound.h" +#include "Sram.h" +#include "bios.h" +#include "Cheats.h" #include "../NLS.h" -#include "../elf.h" +#include "elf.h" #include "../Util.h" #include "../System.h" #include "agbprint.h" diff --git a/src/gba/GBA-thumb.cpp b/src/gba/GBA-thumb.cpp index 97c7c21e..d18c7a29 100644 --- a/src/gba/GBA-thumb.cpp +++ b/src/gba/GBA-thumb.cpp @@ -7,15 +7,15 @@ #include "GBA.h" #include "GBAcpu.h" #include "GBAinline.h" -#include "../Globals.h" -#include "../EEprom.h" -#include "../Flash.h" -#include "../Sound.h" -#include "../Sram.h" -#include "../bios.h" -#include "../Cheats.h" +#include "Globals.h" +#include "EEprom.h" +#include "Flash.h" +#include "Sound.h" +#include "Sram.h" +#include "bios.h" +#include "Cheats.h" #include "../NLS.h" -#include "../elf.h" +#include "elf.h" #include "../Util.h" #include "../System.h" #include "agbprint.h" diff --git a/src/gba/GBA.cpp b/src/gba/GBA.cpp index d57f4344..db56ae11 100644 --- a/src/gba/GBA.cpp +++ b/src/gba/GBA.cpp @@ -6,16 +6,16 @@ #include "GBA.h" #include "GBAcpu.h" #include "GBAinline.h" -#include "../Globals.h" +#include "Globals.h" #include "GBAGfx.h" -#include "../EEprom.h" -#include "../Flash.h" -#include "../Sound.h" -#include "../Sram.h" -#include "../bios.h" -#include "../Cheats.h" +#include "EEprom.h" +#include "Flash.h" +#include "Sound.h" +#include "Sram.h" +#include "bios.h" +#include "Cheats.h" #include "../NLS.h" -#include "../elf.h" +#include "elf.h" #include "../Util.h" #include "../common/Port.h" #include "../System.h" diff --git a/src/gba/GBA.h b/src/gba/GBA.h index e4a0e111..f4da5c63 100644 --- a/src/gba/GBA.h +++ b/src/gba/GBA.h @@ -133,9 +133,9 @@ extern struct EmulatedSystem GBASystem; #define R14_FIQ 43 #define SPSR_FIQ 44 -#include "../Cheats.h" -#include "../Globals.h" -#include "../EEprom.h" -#include "../Flash.h" +#include "Cheats.h" +#include "Globals.h" +#include "EEprom.h" +#include "Flash.h" #endif // GBA_H diff --git a/src/gba/GBAGfx.h b/src/gba/GBAGfx.h index 069ff0b6..de0b04bc 100644 --- a/src/gba/GBAGfx.h +++ b/src/gba/GBAGfx.h @@ -2,7 +2,7 @@ #define GFX_H #include "GBA.h" -#include "../Globals.h" +#include "Globals.h" #include "../common/Port.h" diff --git a/src/gba/GBAinline.h b/src/gba/GBAinline.h index 7183e05f..f065006a 100644 --- a/src/gba/GBAinline.h +++ b/src/gba/GBAinline.h @@ -3,8 +3,8 @@ #include "../System.h" #include "../common/Port.h" -#include "../RTC.h" -#include "../Sound.h" +#include "RTC.h" +#include "Sound.h" #include "agbprint.h" extern const u32 objTilesAddress[3]; diff --git a/src/Globals.cpp b/src/gba/Globals.cpp similarity index 99% rename from src/Globals.cpp rename to src/gba/Globals.cpp index f7a9d6d1..925fd6fd 100644 --- a/src/Globals.cpp +++ b/src/gba/Globals.cpp @@ -1,4 +1,4 @@ -#include "gba/GBA.h" +#include "GBA.h" #ifdef BKPT_SUPPORT int oldreg[17]; diff --git a/src/Globals.h b/src/gba/Globals.h similarity index 99% rename from src/Globals.h rename to src/gba/Globals.h index be96b36c..630451bd 100644 --- a/src/Globals.h +++ b/src/gba/Globals.h @@ -1,7 +1,7 @@ #ifndef GLOBALS_H #define GLOBALS_H -#include "common/Types.h" +#include "../common/Types.h" #define VERBOSE_SWI 1 #define VERBOSE_UNALIGNED_MEMORY 2 diff --git a/src/Mode0.cpp b/src/gba/Mode0.cpp similarity index 99% rename from src/Mode0.cpp rename to src/gba/Mode0.cpp index d0ea46ac..da02f8df 100644 --- a/src/Mode0.cpp +++ b/src/gba/Mode0.cpp @@ -1,6 +1,6 @@ -#include "gba/GBA.h" +#include "GBA.h" #include "Globals.h" -#include "gba/GBAGfx.h" +#include "GBAGfx.h" void mode0RenderLine() { diff --git a/src/Mode1.cpp b/src/gba/Mode1.cpp similarity index 99% rename from src/Mode1.cpp rename to src/gba/Mode1.cpp index 7907ccf2..4d49a94f 100644 --- a/src/Mode1.cpp +++ b/src/gba/Mode1.cpp @@ -1,6 +1,6 @@ -#include "gba/GBA.h" +#include "GBA.h" #include "Globals.h" -#include "gba/GBAGfx.h" +#include "GBAGfx.h" void mode1RenderLine() { diff --git a/src/Mode2.cpp b/src/gba/Mode2.cpp similarity index 99% rename from src/Mode2.cpp rename to src/gba/Mode2.cpp index 51391936..c5aafd2e 100644 --- a/src/Mode2.cpp +++ b/src/gba/Mode2.cpp @@ -1,6 +1,6 @@ -#include "gba/GBA.h" +#include "GBA.h" #include "Globals.h" -#include "gba/GBAGfx.h" +#include "GBAGfx.h" void mode2RenderLine() { diff --git a/src/Mode3.cpp b/src/gba/Mode3.cpp similarity index 99% rename from src/Mode3.cpp rename to src/gba/Mode3.cpp index 6b98d9da..c7445243 100644 --- a/src/Mode3.cpp +++ b/src/gba/Mode3.cpp @@ -1,6 +1,6 @@ -#include "gba/GBA.h" +#include "GBA.h" #include "Globals.h" -#include "gba/GBAGfx.h" +#include "GBAGfx.h" void mode3RenderLine() { diff --git a/src/Mode4.cpp b/src/gba/Mode4.cpp similarity index 99% rename from src/Mode4.cpp rename to src/gba/Mode4.cpp index 5a233180..01e8b1e5 100644 --- a/src/Mode4.cpp +++ b/src/gba/Mode4.cpp @@ -1,5 +1,5 @@ -#include "gba/GBA.h" -#include "gba/GBAGfx.h" +#include "GBA.h" +#include "GBAGfx.h" #include "Globals.h" void mode4RenderLine() diff --git a/src/Mode5.cpp b/src/gba/Mode5.cpp similarity index 99% rename from src/Mode5.cpp rename to src/gba/Mode5.cpp index febe3fdd..11f49db8 100644 --- a/src/Mode5.cpp +++ b/src/gba/Mode5.cpp @@ -1,6 +1,6 @@ -#include "gba/GBA.h" +#include "GBA.h" #include "Globals.h" -#include "gba/GBAGfx.h" +#include "GBAGfx.h" void mode5RenderLine() { diff --git a/src/RTC.cpp b/src/gba/RTC.cpp similarity index 98% rename from src/RTC.cpp rename to src/gba/RTC.cpp index 2be3a457..21d0a2de 100644 --- a/src/RTC.cpp +++ b/src/gba/RTC.cpp @@ -1,9 +1,9 @@ -#include "System.h" -#include "gba/GBA.h" +#include "../System.h" +#include "GBA.h" #include "Globals.h" -#include "common/Port.h" -#include "Util.h" -#include "NLS.h" +#include "../common/Port.h" +#include "../Util.h" +#include "../NLS.h" #include #include diff --git a/src/RTC.h b/src/gba/RTC.h similarity index 100% rename from src/RTC.h rename to src/gba/RTC.h diff --git a/src/Sound.cpp b/src/gba/Sound.cpp similarity index 99% rename from src/Sound.cpp rename to src/gba/Sound.cpp index 31dff3ed..983fd9e2 100644 --- a/src/Sound.cpp +++ b/src/gba/Sound.cpp @@ -2,15 +2,15 @@ #include "Sound.h" -#include "gba/GBA.h" +#include "GBA.h" #include "Globals.h" -#include "Util.h" -#include "common/Port.h" +#include "../Util.h" +#include "../common/Port.h" -#include "apu/Gb_Apu.h" -#include "apu/Multi_Buffer.h" +#include "../apu/Gb_Apu.h" +#include "../apu/Multi_Buffer.h" -#include "common/SoundDriver.h" +#include "../common/SoundDriver.h" #define NR10 0x60 #define NR11 0x62 diff --git a/src/Sound.h b/src/gba/Sound.h similarity index 98% rename from src/Sound.h rename to src/gba/Sound.h index 7c2ef7a8..063130fc 100644 --- a/src/Sound.h +++ b/src/gba/Sound.h @@ -3,7 +3,7 @@ // Sound emulation setup/options and GBA sound emulation -#include "System.h" +#include "../System.h" //// Setup/options (these affect GBA and GB sound) diff --git a/src/Sram.cpp b/src/gba/Sram.cpp similarity index 94% rename from src/Sram.cpp rename to src/gba/Sram.cpp index 9a8a7f04..7f1d7d2f 100644 --- a/src/Sram.cpp +++ b/src/gba/Sram.cpp @@ -1,4 +1,4 @@ -#include "gba/GBA.h" +#include "GBA.h" #include "Globals.h" #include "Flash.h" #include "Sram.h" diff --git a/src/Sram.h b/src/gba/Sram.h similarity index 100% rename from src/Sram.h rename to src/gba/Sram.h diff --git a/src/gba/agbprint.cpp b/src/gba/agbprint.cpp index f79e6313..290eef79 100644 --- a/src/gba/agbprint.cpp +++ b/src/gba/agbprint.cpp @@ -2,7 +2,7 @@ #include #include "GBA.h" -#include "../Globals.h" +#include "Globals.h" #include "../common/Port.h" #include "../System.h" diff --git a/src/armdis.cpp b/src/gba/armdis.cpp similarity index 99% rename from src/armdis.cpp rename to src/gba/armdis.cpp index 17766684..a40ed0e4 100644 --- a/src/armdis.cpp +++ b/src/gba/armdis.cpp @@ -3,9 +3,9 @@ /************************************************************************/ #include -#include "System.h" -#include "common/Port.h" -#include "gba/GBA.h" +#include "../System.h" +#include "../common/Port.h" +#include "GBA.h" #include "armdis.h" #include "elf.h" diff --git a/src/armdis.h b/src/gba/armdis.h similarity index 100% rename from src/armdis.h rename to src/gba/armdis.h diff --git a/src/bios.cpp b/src/gba/bios.cpp similarity index 99% rename from src/bios.cpp rename to src/gba/bios.cpp index b7622155..3c80aba8 100644 --- a/src/bios.cpp +++ b/src/gba/bios.cpp @@ -2,9 +2,9 @@ #include #include -#include "gba/GBA.h" +#include "GBA.h" #include "bios.h" -#include "gba/GBAinline.h" +#include "GBAinline.h" #include "Globals.h" s16 sineTable[256] = { diff --git a/src/bios.h b/src/gba/bios.h similarity index 100% rename from src/bios.h rename to src/gba/bios.h diff --git a/src/elf.cpp b/src/gba/elf.cpp similarity index 99% rename from src/elf.cpp rename to src/gba/elf.cpp index d4824504..16f25276 100644 --- a/src/elf.cpp +++ b/src/gba/elf.cpp @@ -2,10 +2,10 @@ #include #include -#include "gba/GBA.h" -#include "common/Port.h" +#include "GBA.h" +#include "../common/Port.h" #include "elf.h" -#include "NLS.h" +#include "../NLS.h" #define elfReadMemory(addr) \ READ32LE((&map[(addr)>>24].address[(addr) & map[(addr)>>24].mask])) diff --git a/src/elf.h b/src/gba/elf.h similarity index 100% rename from src/elf.h rename to src/gba/elf.h diff --git a/src/remote.cpp b/src/gba/remote.cpp similarity index 99% rename from src/remote.cpp rename to src/gba/remote.cpp index 8bce2ff3..dbf3d306 100644 --- a/src/remote.cpp +++ b/src/gba/remote.cpp @@ -24,7 +24,7 @@ # define write _write #endif // _WIN32 -#include "gba/GBA.h" +#include "GBA.h" extern bool debugger; extern void CPUUpdateCPSR(); diff --git a/src/gtk/system.cpp b/src/gtk/system.cpp index 4f948631..6160dd42 100644 --- a/src/gtk/system.cpp +++ b/src/gtk/system.cpp @@ -17,7 +17,7 @@ // Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include "../sdl/inputSDL.h" -#include "../Sound.h" +#include "../gba/Sound.h" #include "../common/SoundSDL.h" #include "window.h" diff --git a/src/gtk/window.cpp b/src/gtk/window.cpp index f602d986..c8653ad8 100644 --- a/src/gtk/window.cpp +++ b/src/gtk/window.cpp @@ -27,10 +27,10 @@ #include #include "../gba/GBA.h" +#include "../gba/Sound.h" #include "../gb/gb.h" #include "../gb/gbGlobals.h" #include "../gb/gbSound.h" -#include "../Sound.h" #include "../Util.h" #include "tools.h" diff --git a/src/gtk/windowcallbacks.cpp b/src/gtk/windowcallbacks.cpp index 13b0e27a..971b31b4 100644 --- a/src/gtk/windowcallbacks.cpp +++ b/src/gtk/windowcallbacks.cpp @@ -26,10 +26,10 @@ #include #include "../gba/GBA.h" +#include "../gba/Sound.h" #include "../gb/gb.h" #include "../gb/gbGlobals.h" #include "../gb/gbPrinter.h" -#include "../Sound.h" #include "../Util.h" #include "../sdl/inputSDL.h" diff --git a/src/sdl/SDL.cpp b/src/sdl/SDL.cpp index bcacf97d..d4695d4b 100644 --- a/src/sdl/SDL.cpp +++ b/src/sdl/SDL.cpp @@ -37,18 +37,18 @@ #include +#include "../common/Patch.h" #include "../gba/GBA.h" #include "../gba/agbprint.h" -#include "../Flash.h" -#include "../common/Patch.h" -#include "../RTC.h" -#include "../Sound.h" -#include "../Util.h" +#include "../gba/Flash.h" +#include "../gba/Cheats.h" +#include "../gba/RTC.h" +#include "../gba/Sound.h" #include "../gb/gb.h" #include "../gb/gbGlobals.h" #include "../gb/gbCheats.h" #include "../gb/gbSound.h" -#include "../Cheats.h" +#include "../Util.h" #include "debugger.h" #include "filters.h" diff --git a/src/sdl/debugger.cpp b/src/sdl/debugger.cpp index 59a397bb..e1abfd77 100644 --- a/src/sdl/debugger.cpp +++ b/src/sdl/debugger.cpp @@ -24,10 +24,10 @@ #include #include "../gba/GBA.h" +#include "../gba/Sound.h" +#include "../gba/armdis.h" +#include "../gba/elf.h" #include "../common/Port.h" -#include "../Sound.h" -#include "../armdis.h" -#include "../elf.h" #include "exprNode.h" extern bool debugger; diff --git a/src/sdl/expr.cpp b/src/sdl/expr.cpp index cf84caed..32cc83c5 100644 --- a/src/sdl/expr.cpp +++ b/src/sdl/expr.cpp @@ -88,7 +88,7 @@ /* Copy the first part of user declarations. */ -#line 1 "expr.y" +#line 1 "expr.ypp" namespace std { #include @@ -100,7 +100,7 @@ namespace std { using namespace std; #include "../System.h" -#include "../elf.h" +#include "../gba/elf.h" #include "exprNode.h" extern int yyerror(const char *); @@ -145,7 +145,7 @@ typedef int YYSTYPE; /* Line 216 of yacc.c. */ -#line 149 "expr.tab.c" +#line 149 "expr.tab.cpp" #ifdef short # undef short @@ -1345,68 +1345,68 @@ yyreduce: switch (yyn) { case 2: -#line 32 "expr.y" +#line 32 "expr.ypp" { result = (yyvsp[(1) - (1)]); ;} break; case 3: -#line 36 "expr.y" +#line 36 "expr.ypp" { (yyval) = (yyvsp[(1) - (1)]); ;} break; case 4: -#line 37 "expr.y" +#line 37 "expr.ypp" { (yyval) = (yyvsp[(2) - (3)]); ;} break; case 5: -#line 38 "expr.y" +#line 38 "expr.ypp" { (yyval) = exprNodeDot((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); ;} break; case 6: -#line 39 "expr.y" +#line 39 "expr.ypp" { (yyval) = exprNodeArrow((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)])); ;} break; case 7: -#line 40 "expr.y" +#line 40 "expr.ypp" { (yyval) = exprNodeArray((yyvsp[(1) - (4)]), (yyvsp[(3) - (4)])); ;} break; case 8: -#line 43 "expr.y" +#line 43 "expr.ypp" { (yyval) = (yyvsp[(1) - (1)]); ;} break; case 9: -#line 44 "expr.y" +#line 44 "expr.ypp" { (yyval) = exprNodeStar((yyvsp[(2) - (2)])); ;} break; case 10: -#line 45 "expr.y" +#line 45 "expr.ypp" { (yyval) = exprNodeAddr((yyvsp[(2) - (2)])); ;} break; case 11: -#line 46 "expr.y" +#line 46 "expr.ypp" { (yyval) = exprNodeSizeof((yyvsp[(3) - (4)])); ;} break; case 12: -#line 50 "expr.y" +#line 50 "expr.ypp" { (yyval) = exprNodeNumber(); ;} break; case 13: -#line 54 "expr.y" +#line 54 "expr.ypp" {(yyval) = exprNodeIdentifier(); ;} break; /* Line 1267 of yacc.c. */ -#line 1410 "expr.tab.c" +#line 1410 "expr.tab.cpp" default: break; } YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); @@ -1620,7 +1620,7 @@ yyreturn: } -#line 57 "expr.y" +#line 57 "expr.ypp" int yyerror(const char *s) diff --git a/src/sdl/expr.y b/src/sdl/expr.ypp similarity index 98% rename from src/sdl/expr.y rename to src/sdl/expr.ypp index c0be69da..176cafe7 100644 --- a/src/sdl/expr.y +++ b/src/sdl/expr.ypp @@ -9,7 +9,7 @@ namespace std { using namespace std; #include "../System.h" -#include "../elf.h" +#include "../gba/elf.h" #include "exprNode.h" extern int yyerror(const char *); diff --git a/src/sdl/exprNode.cpp b/src/sdl/exprNode.cpp index acfd6b2d..06a04926 100644 --- a/src/sdl/exprNode.cpp +++ b/src/sdl/exprNode.cpp @@ -21,8 +21,8 @@ #include #include "../gba/GBA.h" +#include "../gba/elf.h" #include "../common/Port.h" -#include "../elf.h" #include "exprNode.h" #ifndef __GNUC__