From a4bf68b613a443538a54e77ff2863c88c1c8a86a Mon Sep 17 00:00:00 2001 From: Stefan Boberg Date: Thu, 2 May 2024 17:50:27 +0200 Subject: added logic to change default HTTP server implementation when running on Wine (#71) * added logic to change default HTTP server implementation when running on Wine * added log message to inform user about potential problems when running under Wine --- src/zenserver/config.cpp | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'src/zenserver/config.cpp') diff --git a/src/zenserver/config.cpp b/src/zenserver/config.cpp index e33b6caf3..ce1b21926 100644 --- a/src/zenserver/config.cpp +++ b/src/zenserver/config.cpp @@ -35,6 +35,8 @@ ZEN_THIRD_PARTY_INCLUDES_END #if ZEN_PLATFORM_WINDOWS +# include + // Used for getting My Documents for default data directory # include # pragma comment(lib, "shell32.lib") @@ -550,10 +552,13 @@ ParseConfigFile(const std::filesystem::path& Path, void ParseCliOptions(int argc, char* argv[], ZenServerOptions& ServerOptions) { -#if ZEN_WITH_HTTPSYS - const char* DefaultHttp = "httpsys"; -#else const char* DefaultHttp = "asio"; + +#if ZEN_WITH_HTTPSYS + if (!zen::windows::IsRunningOnWine()) + { + DefaultHttp = "httpsys"; + } #endif // Note to those adding future options; std::filesystem::path-type options -- cgit v1.2.3