Commit a865342c authored by MJaoune's avatar MJaoune
Browse files

Fixes for Windows and Android

parent 7c35f272
......@@ -112,7 +112,7 @@ else
CFLAGS += -O3
endif
OBJECTS := *.cpp
SRC := *.cpp
CFLAGS += -Wall -pedantic $(fpic)
ifneq (,$(findstring qnx,$(platform)))
......@@ -123,18 +123,16 @@ endif
all: $(TARGET)
$(TARGET): $(OBJECTS)
$(TARGET): $(SRC)
ifeq ($(STATIC_LINKING), 1)
$(AR) rcs $@ $(OBJECTS)
$(AR) rcs $@ $(SRC)
else
$(CC) $(fpic) $(SHARED) $(INCLUDES) -o $@ $(OBJECTS) $(LDFLAGS)
$(CC) $(fpic) $(SHARED) $(SRC) $(LDFLAGS) -o $@
endif
%.o: %.cpp
$(CC) $(CFLAGS) $(fpic) -c -o $@ $<
clean:
rm -f *.so *.o
rm -f *.so *.o *.a
rm -r libs obj
.PHONY: clean
radius - Today at 3:31 PM
set_environment, set_init, load, run
and the audio, video, input callbacks
the rest need to be there too though
just stubbed
MJaoune - Today at 3:31 PM
yeah sure to prevent "Undefined" errors
the system is a Dreamcast VMU
radius - Today at 3:31 PM
retro_api_version too
and get_system_info
MJaoune - Today at 3:32 PM
as for the audio, it generates square waves, how do I implement that?
radius - Today at 3:32 PM
I think that's all
MJaoune - Today at 3:32 PM
video is just a framebuffer with pixels, how is that implemented too?
radius - Today at 3:32 PM
get_system_av_info
don't forget that
......@@ -2,24 +2,23 @@ LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
APP_DIR := ../../src
LOCAL_MODULE := vemulator
LOCAL_CFLAGS :=
ifeq ($(TARGET_ARCH),arm)
LOCAL_CFLAGS += -DANDROID_ARM
LOCAL_CPPFLAGS += -DANDROID_ARM
endif
ifeq ($(TARGET_ARCH),x86)
LOCAL_CFLAGS += -DANDROID_X86
LOCAL_CPPFLAGS += -DANDROID_X86
endif
ifeq ($(TARGET_ARCH),mips)
LOCAL_CFLAGS += -DANDROID_MIPS -D__mips__ -D__MIPSEL__
LOCAL_CPPFLAGS += -DANDROID_MIPS -D__mips__ -D__MIPSEL__
endif
LOCAL_SRC_FILES += ../*.cpp
LOCAL_CFLAGS += -O3 -std=gnu++99 -ffast-math -funroll-loops
LOCAL_SRC_FILES = ../audio.cpp ../cpu.cpp ../vmu.cpp ../main.cpp ../video.cpp ../t0.cpp ../t1.cpp ../basetimer.cpp ../bitwisemath.cpp ../flashfile.cpp ../flash.cpp ../rom.cpp ../ram.cpp ../interrupts.cpp
LOCAL_CPPFLAGS += -O3 -std=c++98 -ffast-math -funroll-loops
include $(BUILD_SHARED_LIBRARY)
APP_ABI := all
APP_STL := c++_static
......@@ -38,8 +38,11 @@ RETRO_API void retro_set_environment(retro_environment_t env)
environment_cb = env;
//Set variables (Options)
options[0] = { "enable_flash_write", "Enable flash write (.bin, requires restart); enabled|disabled"};
options[1] = {NULL, NULL};
options[0].key = "enable_flash_write";
options[0].value = "Enable flash write (.bin, requires restart); enabled|disabled";
options[1].key = NULL;
options[1].value = NULL;
env(RETRO_ENVIRONMENT_SET_VARIABLES, options);
}
......@@ -205,9 +208,9 @@ RETRO_API void retro_run(void)
processInput();
//Cycles passed since last screen refresh
uint cyclesPassed = vmu->cpu->getCurrentFrequency() / FPS;
size_t cyclesPassed = vmu->cpu->getCurrentFrequency() / FPS;
for(uint i = 0; i < cyclesPassed; i++)
for(size_t i = 0; i < cyclesPassed; i++)
vmu->runCycle();
//Video
......
cpu => Done
bitwisemath => Done
flash => Done
flashfile => Done
interrupts => Done
ram => Done
rom => Done
t0 => Done
t1 => Done
basetimer => Done
video => Done
audio => Done
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment