From b92b1280a44102f9bd17502a4910a2da279f8e17 Mon Sep 17 00:00:00 2001 From: Chris Warren-Smith Date: Wed, 12 Sep 2018 20:43:48 +1000 Subject: [PATCH] COMMON: fix problem with windows editor F8 --- configure.ac | 2 +- src/platform/sdl/syswm.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index 3a3701f5..9929192e 100644 --- a/configure.ac +++ b/configure.ac @@ -269,7 +269,7 @@ function buildConsole() { TARGET="Building Cygwin MinGW console version." AC_DEFINE(__MINGW32__, 1, [as above]) AC_DEFINE(_UnixOS, 1, [Building under Unix like systems.]) - PACKAGE_LIBS="${PACKAGE_LIBS} -mconsole -lmingw32 -lwsock32" + PACKAGE_LIBS="${PACKAGE_LIBS} -mconsole -lmingw32 -lwsock32 -lws2_32 -static-libgcc" BUILD_SUBDIRS="src/common src/platform/console" fi AC_DEFINE(_Win32, 1, [Windows build]) diff --git a/src/platform/sdl/syswm.cpp b/src/platform/sdl/syswm.cpp index 6f7ab7d2..30189bc6 100644 --- a/src/platform/sdl/syswm.cpp +++ b/src/platform/sdl/syswm.cpp @@ -62,7 +62,7 @@ void launchExec(const char *file) { STARTUPINFO info = {sizeof(info)}; PROCESS_INFORMATION processInfo; char cmd[1024]; - sprintf(cmd, "-x %s", file); + sprintf(cmd, "%s -x %s", g_appPath, file); if (!CreateProcess(g_appPath, cmd, NULL, NULL, TRUE, 0, NULL, NULL, &info, &processInfo)) { appLog("failed to start %d %s %s\n", GetLastError(), g_appPath, cmd); }