Mercurial > hg > orthanc
changeset 1111:929bf8c2123d
Fixes for Visual Studio 2013 64bit
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Mon, 01 Sep 2014 11:23:13 +0200 |
parents | becde5351e47 |
children | a119f9ae3640 |
files | Core/Toolbox.cpp Resources/CMake/DownloadPackage.cmake Resources/Patches/glog-visual-studio-port.h |
diffstat | 3 files changed, 14 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/Core/Toolbox.cpp Mon Sep 01 11:11:00 2014 +0200 +++ b/Core/Toolbox.cpp Mon Sep 01 11:23:13 2014 +0200 @@ -75,8 +75,8 @@ #include "../Resources/ThirdParty/base64/base64.h" -#ifdef _MSC_VER -// Patch for the missing "_strtoll" symbol when compiling with Visual Studio +#if defined(_MSC_VER) && (_MSC_VER < 1800) +// Patch for the missing "_strtoll" symbol when compiling with Visual Studio < 2013 extern "C" { int64_t _strtoi64(const char *nptr, char **endptr, int base);
--- a/Resources/CMake/DownloadPackage.cmake Mon Sep 01 11:11:00 2014 +0200 +++ b/Resources/CMake/DownloadPackage.cmake Mon Sep 01 11:23:13 2014 +0200 @@ -15,7 +15,12 @@ ## if ("${CMAKE_HOST_SYSTEM_NAME}" STREQUAL "Windows") - find_program(ZIP_EXECUTABLE 7z PATHS "$ENV{ProgramFiles}/7-Zip") + find_program(ZIP_EXECUTABLE 7z + PATHS + "$ENV{ProgramFiles}/7-Zip" + "$ENV{ProgramW6432}/7-Zip" + ) + if (${ZIP_EXECUTABLE} MATCHES "ZIP_EXECUTABLE-NOTFOUND") message(FATAL_ERROR "Please install the '7-zip' software (http://www.7-zip.org/)") endif()
--- a/Resources/Patches/glog-visual-studio-port.h Mon Sep 01 11:11:00 2014 +0200 +++ b/Resources/Patches/glog-visual-studio-port.h Mon Sep 01 11:23:13 2014 +0200 @@ -59,6 +59,12 @@ * used by both C and C++ code, so we put all the C++ together. */ +// Fix by Sebastien Jodogne for Visual Studio 2013 +// https://code.google.com/p/google-glog/issues/detail?id=212 +#if defined(_MSC_VER) && (_MSC_VER >= 1800) +#include <algorithm> +#endif + /* 4244: otherwise we get problems when substracting two size_t's to an int * 4251: it's complaining about a private struct I've chosen not to dllexport * 4355: we use this in a constructor, but we do it safely