Mercurial > hg > orthanc
comparison Resources/CMake/GoogleLogConfiguration.cmake @ 4686:d28eab3994f9 Orthanc-0.8.6
hotpatch to make Orthanc 0.8.6 compile on Ubuntu 18.04
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Wed, 09 Jun 2021 14:57:16 +0200 |
parents | 6784a119484d |
children |
comparison
equal
deleted
inserted
replaced
4251:6784a119484d | 4686:d28eab3994f9 |
---|---|
1 if (STATIC_BUILD OR NOT USE_SYSTEM_GOOGLE_LOG) | 1 if (STATIC_BUILD OR NOT USE_SYSTEM_GOOGLE_LOG) |
2 SET(GOOGLE_LOG_SOURCES_DIR ${CMAKE_BINARY_DIR}/glog-0.3.2) | 2 SET(GOOGLE_LOG_SOURCES_DIR ${CMAKE_BINARY_DIR}/glog-0.3.2) |
3 | |
4 if (IS_DIRECTORY "${GOOGLE_LOG_SOURCES_DIR}") | |
5 set(FirstRun OFF) | |
6 else() | |
7 set(FirstRun ON) | |
8 endif() | |
9 | |
3 DownloadPackage( | 10 DownloadPackage( |
4 "897fbff90d91ea2b6d6e78c8cea641cc" | 11 "897fbff90d91ea2b6d6e78c8cea641cc" |
5 "http://www.orthanc-server.com/downloads/third-party/glog-0.3.2.tar.gz" | 12 "http://www.orthanc-server.com/downloads/third-party/glog-0.3.2.tar.gz" |
6 "${GOOGLE_LOG_SOURCES_DIR}") | 13 "${GOOGLE_LOG_SOURCES_DIR}") |
7 | 14 |
15 if (FirstRun) | |
16 find_program(PATCH_EXECUTABLE patch) | |
17 execute_process( | |
18 COMMAND ${PATCH_EXECUTABLE} -p0 -N -i | |
19 ${CMAKE_CURRENT_LIST_DIR}/../Patches/glog-ubuntu-18.04.diff | |
20 WORKING_DIRECTORY ${CMAKE_BINARY_DIR} | |
21 RESULT_VARIABLE Failure | |
22 ) | |
23 | |
24 if (Failure) | |
25 message(FATAL_ERROR "Error while patching a file") | |
26 endif() | |
27 endif() | |
8 | 28 |
9 # Glog 0.3.3 fails to build with old versions of MinGW, such as the | 29 # Glog 0.3.3 fails to build with old versions of MinGW, such as the |
10 # one installed on our Continuous Integration Server that runs | 30 # one installed on our Continuous Integration Server that runs |
11 # Debian Squeeze. We thus stick to Glog 0.3.2 for the time being. | 31 # Debian Squeeze. We thus stick to Glog 0.3.2 for the time being. |
12 | 32 |