diff --git a/Makefile.wii b/Makefile.wii index fa448bd..34b74aa 100644 --- a/Makefile.wii +++ b/Makefile.wii @@ -27,7 +27,7 @@ INCLUDES := PCFLAGS = -DPRECISE_CPU_CYCLES=1 -DPRECISE_CIA_CYCLES=1 -DPC_IS_POINTER=0 SCFLAGS = $(PCFLAGS) -DFRODO_SC -CFLAGS = -O3 -g -Wall $(MACHDEP) $(INCLUDE) -U__unix -DHAVE_SDL $(SCFLAGS) -I$(LIBOGC_INC)/SDL +CFLAGS = -O3 -g -Wall $(MACHDEP) $(INCLUDE) -U__unix -DHAVE_SDL $(SCFLAGS) -I$(LIBOGC_INC)/SDL -I$(PWD)/Src/ CXXFLAGS = $(CFLAGS) LDFLAGS = -g $(MACHDEP) -Wl,-Map,$(notdir $@).map @@ -35,7 +35,7 @@ LDFLAGS = -g $(MACHDEP) -Wl,-Map,$(notdir $@).map #--------------------------------------------------------------------------------- # any extra libraries we wish to link with the project #--------------------------------------------------------------------------------- -LIBS := -lSDL_ttf -lz -lSDL -lfreetype -lfat -lwiiuse -lbte -logc -lm -lwiikeyboard +LIBS := -lSDL_ttf -lSDL_image -lpng -ljpeg -lz -lSDL -lfreetype -lfat -lwiiuse -lbte -logc -lm -lwiikeyboard #--------------------------------------------------------------------------------- # list of directories containing libraries, this must be the top level containing @@ -60,11 +60,15 @@ export DEPSDIR := $(CURDIR)/$(BUILD) #--------------------------------------------------------------------------------- # automatically build a list of object files for our project #--------------------------------------------------------------------------------- -CFILES := gcaudio.c menutexts.c d64-read.c +CFILES := gcaudio.c d64-read.c CPPFILES := Display.cpp main.cpp Prefs.cpp SID.cpp REU.cpp IEC.cpp 1541fs.cpp \ 1541d64.cpp 1541t64.cpp 1541job.cpp C64_SC.cpp CPUC64_SC.cpp VIC_SC.cpp \ - CIA_SC.cpp CPU1541_SC.cpp menu.cpp CPU_common.cpp VirtualKeyboard.cpp \ - Network.cpp + CIA_SC.cpp CPU1541_SC.cpp CPU_common.cpp \ + Network.cpp gui/dialogue_box.cpp gui/widget.cpp utils.cpp \ + gui/game_info.cpp gui/status_bar.cpp gui/gui.cpp gui/listener.cpp \ + timer.cpp utils.cpp gui/virtual_keyboard.cpp gui/menu.cpp \ + gui/file_browser.cpp data_store.cpp gui/menu_messages.cpp + sFILES := SFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.S))) BINFILES := $(foreach dir,$(DATA),$(notdir $(wildcard $(dir)/*.*))) @@ -101,8 +105,8 @@ export OUTPUT := $(CURDIR)/$(TARGET) #--------------------------------------------------------------------------------- $(BUILD): - @[ -d $@ ] || mkdir -p $@ - @make --no-print-directory -C $(BUILD) -f $(CURDIR)/Makefile + @[ -d $@ ] || mkdir -p $@ $@/gui + @make --no-print-directory -C $(BUILD) -f $(CURDIR)/Makefile.wii #--------------------------------------------------------------------------------- clean: @@ -116,6 +120,7 @@ dist: $(BUILD) install -d $@/apps/frodo/saves install -d $@/apps/frodo/tmp cp $(TARGET).dol $@/apps/frodo/boot.dol + cp -rap themes $@/apps/frodo/themes cp meta.xml $@/apps/frodo/ cp icon.png $@/apps/frodo/ cp FreeMono.ttf $@/apps/frodo/ diff --git a/Src/gui/gui.cpp b/Src/gui/gui.cpp index 052eee3..3ed13da 100644 --- a/Src/gui/gui.cpp +++ b/Src/gui/gui.cpp @@ -1,6 +1,10 @@ #include #include -#include +#if defined(GEKKO) +# include +#else +# include +#endif #include diff --git a/Src/main_wii.h b/Src/main_wii.h index 4b6f2dc..605c915 100644 --- a/Src/main_wii.h +++ b/Src/main_wii.h @@ -7,10 +7,13 @@ #include "Version.h" #include +#include #include #include #include +#include "gui/gui.hh" + extern int init_graphics(void); /* @@ -47,7 +50,6 @@ extern "C" int main(int argc, char **argv) fprintf(stderr, "Unable to init TTF: %s\n", TTF_GetError() ); return 0; } - menu_init(); if (WPAD_Init() != WPAD_ERR_NONE) { @@ -97,6 +99,7 @@ void Frodo::ReadyToRun(void) // Create and start C64 TheC64 = new C64; + Gui::init(); load_rom_files(); TheC64->Run(); delete TheC64; diff --git a/Src/sysdeps.h b/Src/sysdeps.h index 1c346d9..889b91d 100644 --- a/Src/sysdeps.h +++ b/Src/sysdeps.h @@ -19,7 +19,11 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -#include "sysconfig.h" +#if defined(GEKKO) +# include "sysconfig.h.Wii" +#else +# include "sysconfig.h" +#endif #include #include