1
# Orthanc - A Lightweight, RESTful DICOM Store
2
# Copyright (C) 2012-2015 Sebastien Jodogne, Medical Physics
3
# Department, University Hospital of Liege, Belgium
5
# This program is free software: you can redistribute it and/or
6
# modify it under the terms of the GNU Affero General Public License
7
# as published by the Free Software Foundation, either version 3 of
8
# the License, or (at your option) any later version.
10
# This program is distributed in the hope that it will be useful, but
11
# WITHOUT ANY WARRANTY; without even the implied warranty of
12
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
# Affero General Public License for more details.
15
# You should have received a copy of the GNU Affero General Public License
16
# along with this program. If not, see <http://www.gnu.org/licenses/>.
19
if (STATIC_BUILD OR NOT USE_SYSTEM_BOOST)
24
find_package(Boost COMPONENTS system)
27
message(FATAL_ERROR "Unable to locate Boost on this system")
30
include_directories(${Boost_INCLUDE_DIRS})
31
link_libraries(${Boost_LIBRARIES})
36
# Parameters for Boost 1.55.0
37
set(BOOST_NAME boost_1_55_0)
38
set(BOOST_BCP_SUFFIX bcpdigest-0.7.4)
39
set(BOOST_MD5 "409f7a0e4fb1f5659d07114f3133b67b")
40
set(BOOST_FILESYSTEM_SOURCES_DIR "${BOOST_NAME}/libs/filesystem/src")
42
set(BOOST_SOURCES_DIR ${CMAKE_BINARY_DIR}/${BOOST_NAME})
45
"http://www.montefiore.ulg.ac.be/~jodogne/Orthanc/ThirdPartyDownloads/${BOOST_NAME}_${BOOST_BCP_SUFFIX}.tar.gz"
46
"${BOOST_SOURCES_DIR}"
50
# Static build of Boost
53
-DBOOST_DATE_TIME_NO_LIB
54
-DBOOST_THREAD_BUILD_LIB
55
-DBOOST_PROGRAM_OPTIONS_NO_LIB
61
if (${CMAKE_COMPILER_IS_GNUCXX})
62
add_definitions(-isystem ${BOOST_SOURCES_DIR})
69
list(APPEND BOOST_SOURCES
70
${BOOST_SOURCES_DIR}/libs/system/src/error_code.cpp
73
source_group(ThirdParty\\Boost REGULAR_EXPRESSION ${BOOST_SOURCES_DIR}/.*)