updated common paths

This commit is contained in:
ShizZy 2013-09-08 13:17:27 -04:00
parent 62d873da3e
commit 6847033b27
4 changed files with 13 additions and 16 deletions

View File

@ -23,6 +23,7 @@
*/
#include "common.h"
#include "file_util.h"
//#if EMU_PLATFORM == PLATFORM_LINUX
//#include <unistd.h>
@ -40,18 +41,9 @@ int __cdecl main(int argc, char **argv) {
printf("akiru starting...\n");
//char program_dir[MAX_PATH];
//_getcwd(program_dir, MAX_PATH-1);
//size_t cwd_len = strlen(program_dir);
//program_dir[cwd_len] = '/';
//program_dir[cwd_len+1] = '\0';
std::string program_dir = File::GetCurrentDir();
//common::ConfigManager config_manager;
//config_manager.set_program_dir(program_dir, MAX_PATH);
//config_manager.ReloadConfig(NULL);
//core::SetConfigManager(&config_manager);
EmuWindow_GLFW* emu_window = new EmuWindow_GLFW;
//EmuWindow_GLFW* emu_window = new EmuWindow_GLFW;
//if (E_OK != core::Init(emu_window)) {
// LOG_ERROR(TMASTER, "core initialization failed, exiting...");
@ -89,7 +81,7 @@ int __cdecl main(int argc, char **argv) {
while (1) {
}
delete emu_window;
//delete emu_window;
return 0;
}

View File

@ -47,6 +47,7 @@ private:
#include "common_types.h"
#include "msg_handler.h"
#include "common_funcs.h"
#include "common_paths.h"
#ifdef __APPLE__
// The Darwin ABI requires that stack frames be aligned to 16-byte boundaries.

View File

@ -12,17 +12,19 @@
#define DIR_SEP "/"
#define DIR_SEP_CHR '/'
#define MAX_PATH 255
// The user data dir
#define ROOT_DIR "."
#ifdef _WIN32
#define USERDATA_DIR "user"
#define DOLPHIN_DATA_DIR "akiru"
#define EMU_DATA_DIR "emu"
#else
#define USERDATA_DIR "user"
#ifdef USER_DIR
#define DOLPHIN_DATA_DIR USER_DIR
#define EMU_DATA_DIR USER_DIR
#else
#define DOLPHIN_DATA_DIR ".akiru"
#define EMU_DATA_DIR ".akiru"
#endif
#endif
@ -61,7 +63,7 @@
// Filenames
// Files in the directory returned by GetUserPath(D_CONFIG_IDX)
#define AKIRU_CONFIG "akiru.ini"
#define EMU_CONFIG "emu.ini"
#define DEBUGGER_CONFIG "debugger.ini"
#define LOGGER_CONFIG "logger.ini"

View File

@ -23,6 +23,7 @@
*/
#include "core.h"
#include "mem_map.h"
namespace Core {
@ -40,6 +41,7 @@ void Stop() {
/// Initialize the core
int Init(EmuWindow* emu_window) {
Memory::Init();
return 0;
}