diff options
| author | 2013-09-08 13:17:27 -0400 | |
|---|---|---|
| committer | 2013-09-08 13:17:27 -0400 | |
| commit | 6847033b27cb07c566d75fb291131910a4296702 (patch) | |
| tree | 83675e98f19a6dc597c90a139c70b0a18d713c9b /src | |
| parent | start of 3DS memory map (diff) | |
| download | yuzu-6847033b27cb07c566d75fb291131910a4296702.tar.gz yuzu-6847033b27cb07c566d75fb291131910a4296702.tar.xz yuzu-6847033b27cb07c566d75fb291131910a4296702.zip | |
updated common paths
Diffstat (limited to 'src')
| -rw-r--r-- | src/akiru/src/akiru.cpp | 16 | ||||
| -rw-r--r-- | src/common/src/common.h | 1 | ||||
| -rw-r--r-- | src/common/src/common_paths.h | 10 | ||||
| -rw-r--r-- | src/core/src/core.cpp | 2 |
4 files changed, 13 insertions, 16 deletions
diff --git a/src/akiru/src/akiru.cpp b/src/akiru/src/akiru.cpp index bb69cf1b1..3185c2f95 100644 --- a/src/akiru/src/akiru.cpp +++ b/src/akiru/src/akiru.cpp | |||
| @@ -23,6 +23,7 @@ | |||
| 23 | */ | 23 | */ |
| 24 | 24 | ||
| 25 | #include "common.h" | 25 | #include "common.h" |
| 26 | #include "file_util.h" | ||
| 26 | 27 | ||
| 27 | //#if EMU_PLATFORM == PLATFORM_LINUX | 28 | //#if EMU_PLATFORM == PLATFORM_LINUX |
| 28 | //#include <unistd.h> | 29 | //#include <unistd.h> |
| @@ -40,18 +41,9 @@ int __cdecl main(int argc, char **argv) { | |||
| 40 | 41 | ||
| 41 | printf("akiru starting...\n"); | 42 | printf("akiru starting...\n"); |
| 42 | 43 | ||
| 43 | //char program_dir[MAX_PATH]; | 44 | std::string program_dir = File::GetCurrentDir(); |
| 44 | //_getcwd(program_dir, MAX_PATH-1); | ||
| 45 | //size_t cwd_len = strlen(program_dir); | ||
| 46 | //program_dir[cwd_len] = '/'; | ||
| 47 | //program_dir[cwd_len+1] = '\0'; | ||
| 48 | 45 | ||
| 49 | //common::ConfigManager config_manager; | 46 | //EmuWindow_GLFW* emu_window = new EmuWindow_GLFW; |
| 50 | //config_manager.set_program_dir(program_dir, MAX_PATH); | ||
| 51 | //config_manager.ReloadConfig(NULL); | ||
| 52 | //core::SetConfigManager(&config_manager); | ||
| 53 | |||
| 54 | EmuWindow_GLFW* emu_window = new EmuWindow_GLFW; | ||
| 55 | 47 | ||
| 56 | //if (E_OK != core::Init(emu_window)) { | 48 | //if (E_OK != core::Init(emu_window)) { |
| 57 | // LOG_ERROR(TMASTER, "core initialization failed, exiting..."); | 49 | // LOG_ERROR(TMASTER, "core initialization failed, exiting..."); |
| @@ -89,7 +81,7 @@ int __cdecl main(int argc, char **argv) { | |||
| 89 | while (1) { | 81 | while (1) { |
| 90 | } | 82 | } |
| 91 | 83 | ||
| 92 | delete emu_window; | 84 | //delete emu_window; |
| 93 | 85 | ||
| 94 | return 0; | 86 | return 0; |
| 95 | } | 87 | } |
diff --git a/src/common/src/common.h b/src/common/src/common.h index f95d58074..b61e77686 100644 --- a/src/common/src/common.h +++ b/src/common/src/common.h | |||
| @@ -47,6 +47,7 @@ private: | |||
| 47 | #include "common_types.h" | 47 | #include "common_types.h" |
| 48 | #include "msg_handler.h" | 48 | #include "msg_handler.h" |
| 49 | #include "common_funcs.h" | 49 | #include "common_funcs.h" |
| 50 | #include "common_paths.h" | ||
| 50 | 51 | ||
| 51 | #ifdef __APPLE__ | 52 | #ifdef __APPLE__ |
| 52 | // The Darwin ABI requires that stack frames be aligned to 16-byte boundaries. | 53 | // The Darwin ABI requires that stack frames be aligned to 16-byte boundaries. |
diff --git a/src/common/src/common_paths.h b/src/common/src/common_paths.h index 9af93ab74..b38ae6903 100644 --- a/src/common/src/common_paths.h +++ b/src/common/src/common_paths.h | |||
| @@ -12,17 +12,19 @@ | |||
| 12 | #define DIR_SEP "/" | 12 | #define DIR_SEP "/" |
| 13 | #define DIR_SEP_CHR '/' | 13 | #define DIR_SEP_CHR '/' |
| 14 | 14 | ||
| 15 | #define MAX_PATH 255 | ||
| 16 | |||
| 15 | // The user data dir | 17 | // The user data dir |
| 16 | #define ROOT_DIR "." | 18 | #define ROOT_DIR "." |
| 17 | #ifdef _WIN32 | 19 | #ifdef _WIN32 |
| 18 | #define USERDATA_DIR "user" | 20 | #define USERDATA_DIR "user" |
| 19 | #define DOLPHIN_DATA_DIR "akiru" | 21 | #define EMU_DATA_DIR "emu" |
| 20 | #else | 22 | #else |
| 21 | #define USERDATA_DIR "user" | 23 | #define USERDATA_DIR "user" |
| 22 | #ifdef USER_DIR | 24 | #ifdef USER_DIR |
| 23 | #define DOLPHIN_DATA_DIR USER_DIR | 25 | #define EMU_DATA_DIR USER_DIR |
| 24 | #else | 26 | #else |
| 25 | #define DOLPHIN_DATA_DIR ".akiru" | 27 | #define EMU_DATA_DIR ".akiru" |
| 26 | #endif | 28 | #endif |
| 27 | #endif | 29 | #endif |
| 28 | 30 | ||
| @@ -61,7 +63,7 @@ | |||
| 61 | 63 | ||
| 62 | // Filenames | 64 | // Filenames |
| 63 | // Files in the directory returned by GetUserPath(D_CONFIG_IDX) | 65 | // Files in the directory returned by GetUserPath(D_CONFIG_IDX) |
| 64 | #define AKIRU_CONFIG "akiru.ini" | 66 | #define EMU_CONFIG "emu.ini" |
| 65 | #define DEBUGGER_CONFIG "debugger.ini" | 67 | #define DEBUGGER_CONFIG "debugger.ini" |
| 66 | #define LOGGER_CONFIG "logger.ini" | 68 | #define LOGGER_CONFIG "logger.ini" |
| 67 | 69 | ||
diff --git a/src/core/src/core.cpp b/src/core/src/core.cpp index 4e956fde3..61e3a8df4 100644 --- a/src/core/src/core.cpp +++ b/src/core/src/core.cpp | |||
| @@ -23,6 +23,7 @@ | |||
| 23 | */ | 23 | */ |
| 24 | 24 | ||
| 25 | #include "core.h" | 25 | #include "core.h" |
| 26 | #include "mem_map.h" | ||
| 26 | 27 | ||
| 27 | namespace Core { | 28 | namespace Core { |
| 28 | 29 | ||
| @@ -40,6 +41,7 @@ void Stop() { | |||
| 40 | 41 | ||
| 41 | /// Initialize the core | 42 | /// Initialize the core |
| 42 | int Init(EmuWindow* emu_window) { | 43 | int Init(EmuWindow* emu_window) { |
| 44 | Memory::Init(); | ||
| 43 | return 0; | 45 | return 0; |
| 44 | } | 46 | } |
| 45 | 47 | ||