aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortwinaphex2017-12-25 06:37:52 +0100
committertwinaphex2017-12-25 06:37:52 +0100
commit844bddc4f2203fbbf56834c27de24a54cb3674a3 (patch)
tree653edb05bba1552b9fea361a9228c3f5145dad32
parent00fd30fcf789ea5d0eb55092c56d123d3a475aeb (diff)
downloadsnes9x2005-844bddc4f2203fbbf56834c27de24a54cb3674a3.tar.gz
snes9x2005-844bddc4f2203fbbf56834c27de24a54cb3674a3.tar.bz2
snes9x2005-844bddc4f2203fbbf56834c27de24a54cb3674a3.zip
Cleanups
-rw-r--r--Makefile22
-rw-r--r--libretro.c11
-rw-r--r--source/getset.h14
3 files changed, 29 insertions, 18 deletions
diff --git a/Makefile b/Makefile
index 186d36a..64960bb 100644
--- a/Makefile
+++ b/Makefile
@@ -230,6 +230,28 @@ TARGET := $(TARGET_NAME)_libretro.dll
PSS_STYLE :=2
LDFLAGS += -DLL
OLD_GCC = 1
+
+# Windows MSVC 2003 x86
+else ifeq ($(platform), windows_msvc2003_x86)
+ CC = cl.exe
+ CXX = cl.exe
+
+PATH := $(shell IFS=$$'\n'; cygpath "$(VS71COMNTOOLS)../../Vc7/bin"):$(PATH)
+PATH := $(PATH):$(shell IFS=$$'\n'; cygpath "$(VS71COMNTOOLS)../IDE")
+INCLUDE := $(shell IFS=$$'\n'; cygpath "$(VS71COMNTOOLS)../../Vc7/include")
+LIB := $(shell IFS=$$'\n'; cygpath -w "$(VS71COMNTOOLS)../../Vc7/lib")
+BIN := $(shell IFS=$$'\n'; cygpath "$(VS71COMNTOOLS)../../Vc7/bin")
+
+WindowsSdkDir := $(INETSDK)
+
+export INCLUDE := $(INCLUDE);$(INETSDK)/Include;libretro-common/include/compat/msvc
+export LIB := $(LIB);$(WindowsSdkDir);$(INETSDK)/Lib
+TARGET := $(TARGET_NAME)_libretro.dll
+PSS_STYLE :=2
+LDFLAGS += -DLL
+CFLAGS += -D_CRT_SECURE_NO_DEPRECATE
+NO_GCC = 1
+
else
TARGET := $(TARGET_NAME)_libretro.dll
CC = gcc
diff --git a/libretro.c b/libretro.c
index 5b31eac..0114559 100644
--- a/libretro.c
+++ b/libretro.c
@@ -245,17 +245,6 @@ const char* S9xGetFilename(const char* in)
return filename;
}
-void GetBaseName(const char* ex)
-{
- char drive [_MAX_DRIVE + 1];
- char dir [_MAX_DIR + 1];
- char fname [_MAX_FNAME + 1];
- char ext [_MAX_EXT + 1];
- (void) ex;
- _splitpath(Memory.ROMFilename, drive, dir, fname, ext);
- snprintf(retro_base_name,sizeof(retro_base_name),"%s",fname);
-}
-
void init_sfc_setting(void)
{
memset(&Settings, 0, sizeof(Settings));
diff --git a/source/getset.h b/source/getset.h
index a5fd6f3..6c4142a 100644
--- a/source/getset.h
+++ b/source/getset.h
@@ -15,7 +15,7 @@
extern uint8_t OpenBus;
-INLINE uint8_t S9xGetByte(uint32_t Address)
+static INLINE uint8_t S9xGetByte(uint32_t Address)
{
int32_t block;
uint8_t* GetAddress = Memory.Map [block = (Address >> MEMMAP_SHIFT) & MEMMAP_MASK];
@@ -67,7 +67,7 @@ INLINE uint8_t S9xGetByte(uint32_t Address)
}
}
-INLINE uint16_t S9xGetWord(uint32_t Address)
+static INLINE uint16_t S9xGetWord(uint32_t Address)
{
int32_t block;
uint8_t* GetAddress;
@@ -138,7 +138,7 @@ INLINE uint16_t S9xGetWord(uint32_t Address)
}
}
-INLINE void S9xSetByte(uint8_t Byte, uint32_t Address)
+static INLINE void S9xSetByte(uint8_t Byte, uint32_t Address)
{
int32_t block;
uint8_t* SetAddress = Memory.WriteMap [block = ((Address >> MEMMAP_SHIFT) & MEMMAP_MASK)];
@@ -209,7 +209,7 @@ INLINE void S9xSetByte(uint8_t Byte, uint32_t Address)
}
}
-INLINE void S9xSetWord(uint16_t Word, uint32_t Address)
+static INLINE void S9xSetWord(uint16_t Word, uint32_t Address)
{
int32_t block;
uint8_t* SetAddress;
@@ -313,7 +313,7 @@ INLINE void S9xSetWord(uint16_t Word, uint32_t Address)
}
}
-INLINE uint8_t* GetBasePointer(uint32_t Address)
+static INLINE uint8_t* GetBasePointer(uint32_t Address)
{
uint8_t* GetAddress = Memory.Map [(Address >> MEMMAP_SHIFT) & MEMMAP_MASK];
if (GetAddress >= (uint8_t*) MAP_LAST)
@@ -347,7 +347,7 @@ INLINE uint8_t* GetBasePointer(uint32_t Address)
}
}
-INLINE uint8_t* S9xGetMemPointer(uint32_t Address)
+static INLINE uint8_t* S9xGetMemPointer(uint32_t Address)
{
uint8_t* GetAddress = Memory.Map [(Address >> MEMMAP_SHIFT) & MEMMAP_MASK];
if (GetAddress >= (uint8_t*) MAP_LAST)
@@ -384,7 +384,7 @@ INLINE uint8_t* S9xGetMemPointer(uint32_t Address)
}
}
-INLINE void S9xSetPCBase(uint32_t Address)
+static INLINE void S9xSetPCBase(uint32_t Address)
{
int32_t block;
uint8_t* GetAddress = Memory.Map [block = (Address >> MEMMAP_SHIFT) & MEMMAP_MASK];