diff --git a/appveyor.yml b/appveyor.yml index c840d7db53..36da1ff2f9 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -1,4 +1,4 @@ -image: Visual Studio 2013 +image: Visual Studio 2015 # This is the default location, but we put it here for safety reasons, since we use it in our test script clone_folder: c:\projects\rathena # We do not need the git history for our integration tests @@ -8,10 +8,8 @@ pull_requests: do_not_increment_build_number: true environment: matrix: - - VisualStudioVersion: 14.0 - Defines: "\"BUILDBOT\"" - - VisualStudioVersion: 14.0 - Defines: "\"BUILDBOT;PRERE\"" + - Defines: "\"BUILDBOT\"" + - Defines: "\"BUILDBOT;PRERE\"" platform: - Win32 - x64 diff --git a/src/common/core.cpp b/src/common/core.cpp index 4d10857aee..5982b43938 100644 --- a/src/common/core.cpp +++ b/src/common/core.cpp @@ -3,6 +3,8 @@ #include "core.hpp" +#include "../config/core.hpp" + #ifndef MINICORE #include "ers.hpp" #include "socket.hpp" @@ -24,6 +26,16 @@ #include "showmsg.hpp" #include "strlib.hpp" +#ifndef DEPRECATED_COMPILER_SUPPORT + #if defined( _MSC_VER ) && _MSC_VER < 1900 + #error "Visual Studio versions older than Visual Studio 2015 are not officially supported anymore" + #elif defined( __clang__ ) && __clang_major__ < 4 && !( __clang_major__ == 3 && __clang_minor__ >= 7 ) + #error "clang versions older than clang 3.7 are not officially supported anymore" + #elif !defined( __clang__ ) && defined( __GNUC__ ) && __GNUC__ < 5 + #error "GCC versions older than GCC 5 are not officially supported anymore" + #endif +#endif + /// Called when a terminate signal is received. void (*shutdown_callback)(void) = NULL; diff --git a/src/config/core.hpp b/src/config/core.hpp index 9020de4696..783b8e13de 100644 --- a/src/config/core.hpp +++ b/src/config/core.hpp @@ -74,6 +74,13 @@ // overflows, which is approximately every ~49 days. //#define DEPRECATED_WINDOWS_SUPPORT +// Uncomment to enable compilation for unsupported compilers +// Note: +// Compilation might work on these compilers, but they might not fully follow newer C++ rules and +// cause unexpected behavior. +// Do NOT create any issues or ask for help with these compilers. +//#define DEPRECATED_COMPILER_SUPPORT + /** * No settings past this point **/ diff --git a/tools/serv.bat b/tools/serv.bat index f19f7140ad..fa3053f675 100644 --- a/tools/serv.bat +++ b/tools/serv.bat @@ -36,10 +36,10 @@ PING -n 15 127.0.0.1 > NUL :START_RA %1 ECHO. -REM Return value > 1 is exception&~0xC0000000 -IF ERRORLEVEL 2 GOTO CRASHED REM Return value 1 is EXIT_FAILURE IF ERRORLEVEL 1 GOTO EXIT1 +REM Return value is not 0 the process has crashed +IF NOT ERRORLEVEL 0 GOTO CRASHED REM Return value 0 is EXIT_SUCCESS ECHO %2 has shutdown successfully. GOTO RESTART_NT