diff --git a/src/d_main.cpp b/src/d_main.cpp index 869dce80b..23fd6eba7 100644 --- a/src/d_main.cpp +++ b/src/d_main.cpp @@ -2286,6 +2286,7 @@ void D_DoomMain (void) const char *batchout = Args->CheckValue("-errorlog"); C_InitConsole(80*8, 25*8, false); + I_DetectOS(); // +logfile gets checked too late to catch the full startup log in the logfile so do some extra check for it here. FString logfile = Args->TakeValue("+logfile"); diff --git a/src/posix/cocoa/i_main.mm b/src/posix/cocoa/i_main.mm index bcf1088a5..c873c1091 100644 --- a/src/posix/cocoa/i_main.mm +++ b/src/posix/cocoa/i_main.mm @@ -90,7 +90,7 @@ struct NSOperatingSystemVersion #endif // before 10.10 -static void I_DetectOS() +void I_DetectOS() { NSOperatingSystemVersion version = {}; NSProcessInfo* const processInfo = [NSProcessInfo processInfo]; @@ -172,7 +172,6 @@ void OriginalMainTry(int argc, char** argv) progdir = [[exePath stringByDeletingLastPathComponent] UTF8String]; progdir += "/"; - I_DetectOS(); D_DoomMain(); } diff --git a/src/posix/sdl/i_main.cpp b/src/posix/sdl/i_main.cpp index 9de36729e..448215958 100644 --- a/src/posix/sdl/i_main.cpp +++ b/src/posix/sdl/i_main.cpp @@ -149,6 +149,11 @@ static int DoomSpecificInfo (char *buffer, char *end) return p; } +void I_DetectOS() +{ + // The POSIX version never implemented this. +} + void I_StartupJoysticks(); void I_ShutdownJoysticks(); diff --git a/src/win32/i_main.cpp b/src/win32/i_main.cpp index da686e53f..af9d63164 100644 --- a/src/win32/i_main.cpp +++ b/src/win32/i_main.cpp @@ -979,7 +979,6 @@ void DoMain (HINSTANCE hInstance) CoInitialize (NULL); atexit (UnCOM); - I_DetectOS (); D_DoomMain (); } catch (class CNoRunExit &)