From 5049d472d70e9b8324a07b821c4c173f65a21402 Mon Sep 17 00:00:00 2001 From: notaz Date: Wed, 2 Jun 2010 09:44:51 +0000 Subject: [PATCH] allow compiling without 32x and sms code git-svn-id: file:///home/notaz/opt/svn/PicoDrive/platform@877 be3aeb3a-fb24-0410-a615-afba39da0efa --- common/common.mak | 18 +++++++++++++++--- common/emu.c | 7 +++++-- 2 files changed, 20 insertions(+), 5 deletions(-) diff --git a/common/common.mak b/common/common.mak index 2a240b0..2a0354b 100644 --- a/common/common.mak +++ b/common/common.mak @@ -26,14 +26,24 @@ endif # === Pico core === # Pico OBJS += pico/state.o pico/cart.o pico/memory.o pico/pico.o pico/sek.o pico/z80if.o \ - pico/videoport.o pico/draw2.o pico/draw.o pico/mode4.o pico/sms.o \ + pico/videoport.o pico/draw2.o pico/draw.o pico/mode4.o \ pico/misc.o pico/eeprom.o pico/patch.o pico/debug.o +# SMS +ifneq "$(no_sms)" "1" +OBJS += pico/sms.o +else +DEFINES += NO_SMS +endif # CD OBJS += pico/cd/pico.o pico/cd/memory.o pico/cd/sek.o pico/cd/LC89510.o \ pico/cd/cd_sys.o pico/cd/cd_file.o pico/cd/cue.o pico/cd/gfx_cd.o \ pico/cd/misc.o pico/cd/pcm.o pico/cd/buffering.o # 32X +ifneq "$(no_32x)" "1" OBJS += pico/32x/32x.o pico/32x/memory.o pico/32x/draw.o pico/32x/pwm.o +else +DEFINES += NO_32X +endif # Pico OBJS += pico/pico/pico.o pico/pico/memory.o pico/pico/xpcm.o # carthw @@ -73,8 +83,9 @@ OBJS += cpu/cz80/cz80.o endif # --- SH2 --- -OBJS += cpu/sh2/sh2.o OBJS += cpu/drc/cmn.o +ifneq "$(no_32x)" "1" +OBJS += cpu/sh2/sh2.o # ifeq "$(use_sh2drc)" "1" DEFINES += DRC_SH2 @@ -89,11 +100,12 @@ ifeq "$(drc_debug_interp)" "1" DEFINES += DRC_DEBUG_INTERP use_sh2mame = 1 endif -endif +endif # use_sh2drc # ifeq "$(use_sh2mame)" "1" OBJS += cpu/sh2/mame/sh2pico.o endif +endif # !no_32x DIRS += platform platform/common pico pico/cd pico/pico pico/32x pico/sound pico/carthw/svp \ diff --git a/common/emu.c b/common/emu.c index b1927c1..618eb70 100644 --- a/common/emu.c +++ b/common/emu.c @@ -453,11 +453,14 @@ static void shutdown_MCD(void) static void system_announce(void) { - const char *sys_name, *tv_standard; + const char *sys_name, *tv_standard, *extra = ""; int fps; if (PicoAHW & PAHW_SMS) { sys_name = "Master System"; +#ifdef NO_SMS + extra = " [no support]"; +#endif } else if (PicoAHW & PAHW_PICO) { sys_name = "Pico"; } else if (PicoAHW & PAHW_MCD) { @@ -474,7 +477,7 @@ static void system_announce(void) tv_standard = Pico.m.pal ? "PAL" : "NTSC"; fps = Pico.m.pal ? 50 : 60; - emu_status_msg("%s %s / %dFPS", tv_standard, sys_name, fps); + emu_status_msg("%s %s / %dFPS%s", tv_standard, sys_name, fps, extra); } // note: this function might mangle rom_fname -- 2.39.5