reordered events in init to get everything working

master
Allen Webster 2017-07-19 16:23:39 -04:00
parent 1148347105
commit 14adfea27c
2 changed files with 36 additions and 16 deletions

View File

@ -1583,6 +1583,16 @@ LinuxHandleX11Events(void)
int
main(int argc, char **argv){
//
// System Linkage
//
link_system_code();
//
// Memory init
//
memset(&linuxvars, 0, sizeof(linuxvars));
memset(&target, 0, sizeof(target));
memset(&memory_vars, 0, sizeof(memory_vars));
@ -1592,13 +1602,19 @@ main(int argc, char **argv){
memset(&app, 0, sizeof(app));
memset(&custom_api, 0, sizeof(custom_api));
memory_init();
//
// HACK(allen):
// Previously zipped stuff is here, it should be zipped in the new pattern now.
//
init_shared_vars();
//
// Linkage
// Dynamic Linkage
//
link_system_code();
load_app_code();
link_rendering();
#if defined(FRED_SUPER)
@ -1607,12 +1623,6 @@ main(int argc, char **argv){
custom_api.get_bindings = get_bindings;
#endif
//
// Memory init
//
memory_init();
//
// Read command line
//

View File

@ -1019,6 +1019,16 @@ WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdS
i32 argc = __argc;
char **argv = __argv;
//
// System Linkage
//
link_system_code();
//
// Memory init
//
memset(&win32vars, 0, sizeof(win32vars));
memset(&target, 0, sizeof(target));
memset(&memory_vars, 0, sizeof(memory_vars));
@ -1028,13 +1038,19 @@ WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdS
memset(&app, 0, sizeof(app));
memset(&custom_api, 0, sizeof(custom_api));
memory_init();
//
// HACK(allen):
// Previously zipped stuff is here, it should be zipped in the new pattern now.
//
init_shared_vars();
//
// Linkage
// Dynamic Linkage
//
link_system_code();
load_app_code();
link_rendering();
#if defined(FRED_SUPER)
@ -1043,12 +1059,6 @@ WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdS
custom_api.get_bindings = get_bindings;
#endif
//
// Memory init
//
memory_init();
//
// Read Command Line
//