annotate Resources/CMake/BoostConfiguration.cmake @ 2781:13038d638097

primitives for android ndk
author Sebastien Jodogne <s.jodogne@gmail.com>
date Fri, 20 Jul 2018 11:01:33 +0200
parents ee9a6cd63891
children 64e3d4ab158d
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
735
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
1 if (STATIC_BUILD OR NOT USE_SYSTEM_BOOST)
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
2 set(BOOST_STATIC 1)
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
3 else()
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
4 include(FindBoost)
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
5
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
6 set(BOOST_STATIC 0)
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
7 #set(Boost_DEBUG 1)
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
8 #set(Boost_USE_STATIC_LIBS ON)
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
9
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
10 if (ENABLE_LOCALE)
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
11 list(APPEND ORTHANC_BOOST_COMPONENTS locale)
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
12 endif()
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
13
2468
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2455
diff changeset
14 list(APPEND ORTHANC_BOOST_COMPONENTS filesystem thread system date_time regex)
2469
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2468
diff changeset
15 find_package(Boost COMPONENTS "${ORTHANC_BOOST_COMPONENTS}")
735
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
16
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
17 if (NOT Boost_FOUND)
2469
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2468
diff changeset
18 foreach (item ${ORTHANC_BOOST_COMPONENTS})
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2468
diff changeset
19 string(TOUPPER ${item} tmp)
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2468
diff changeset
20
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2468
diff changeset
21 if (Boost_${tmp}_FOUND)
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2468
diff changeset
22 set(tmp2 "found")
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2468
diff changeset
23 else()
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2468
diff changeset
24 set(tmp2 "missing")
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2468
diff changeset
25 endif()
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2468
diff changeset
26
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2468
diff changeset
27 message("Boost component ${item} - ${tmp2}")
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2468
diff changeset
28 endforeach()
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2468
diff changeset
29
735
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
30 message(FATAL_ERROR "Unable to locate Boost on this system")
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
31 endif()
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
32
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
33 # Boost releases 1.44 through 1.47 supply both V2 and V3 filesystem
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
34 # http://www.boost.org/doc/libs/1_46_1/libs/filesystem/v3/doc/index.htm
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
35 if (${Boost_VERSION} LESS 104400)
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
36 add_definitions(
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
37 -DBOOST_HAS_FILESYSTEM_V3=0
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
38 )
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
39 else()
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
40 add_definitions(
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
41 -DBOOST_HAS_FILESYSTEM_V3=1
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
42 -DBOOST_FILESYSTEM_VERSION=3
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
43 )
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
44 endif()
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
45
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
46 include_directories(${Boost_INCLUDE_DIRS})
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
47 link_libraries(${Boost_LIBRARIES})
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
48 endif()
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
49
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
50
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
51 if (BOOST_STATIC)
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
52 ##
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
53 ## Parameters for static compilation of Boost
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
54 ##
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
55
2679
ee9a6cd63891 boost 1.67.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2527
diff changeset
56 set(BOOST_NAME boost_1_67_0)
ee9a6cd63891 boost 1.67.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2527
diff changeset
57 set(BOOST_VERSION 1.67.0)
ee9a6cd63891 boost 1.67.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2527
diff changeset
58 set(BOOST_BCP_SUFFIX bcpdigest-1.4.0)
ee9a6cd63891 boost 1.67.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2527
diff changeset
59 set(BOOST_MD5 "fb3535a88e72c3d4c4d06b047b8e57fe")
2384
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2383
diff changeset
60 set(BOOST_URL "http://www.orthanc-server.com/downloads/third-party/${BOOST_NAME}_${BOOST_BCP_SUFFIX}.tar.gz")
735
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
61 set(BOOST_SOURCES_DIR ${CMAKE_BINARY_DIR}/${BOOST_NAME})
1537
fbf763bb1fa3 error detection in patches
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1473
diff changeset
62
2455
6b3c0d5f65af improved e2fsprogs
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2454
diff changeset
63 if (IS_DIRECTORY "${BOOST_SOURCES_DIR}")
6b3c0d5f65af improved e2fsprogs
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2454
diff changeset
64 set(FirstRun OFF)
6b3c0d5f65af improved e2fsprogs
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2454
diff changeset
65 else()
6b3c0d5f65af improved e2fsprogs
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2454
diff changeset
66 set(FirstRun ON)
6b3c0d5f65af improved e2fsprogs
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2454
diff changeset
67 endif()
6b3c0d5f65af improved e2fsprogs
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2454
diff changeset
68
1537
fbf763bb1fa3 error detection in patches
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1473
diff changeset
69 DownloadPackage(${BOOST_MD5} ${BOOST_URL} "${BOOST_SOURCES_DIR}")
735
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
70
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
71
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
72 ##
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
73 ## Generic configuration of Boost
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
74 ##
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
75
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
76 if (CMAKE_COMPILER_IS_GNUCXX)
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
77 add_definitions(-isystem ${BOOST_SOURCES_DIR})
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
78 endif()
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
79
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
80 include_directories(
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
81 ${BOOST_SOURCES_DIR}
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
82 )
927
ff1812962f30 fix DOS EOL
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 921
diff changeset
83
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
84 add_definitions(
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
85 # Static build of Boost
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
86 -DBOOST_ALL_NO_LIB
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
87 -DBOOST_ALL_NOLIB
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
88 -DBOOST_DATE_TIME_NO_LIB
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
89 -DBOOST_THREAD_BUILD_LIB
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
90 -DBOOST_PROGRAM_OPTIONS_NO_LIB
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
91 -DBOOST_REGEX_NO_LIB
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
92 -DBOOST_SYSTEM_NO_LIB
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
93 -DBOOST_LOCALE_NO_LIB
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
94 )
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
95
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
96 set(BOOST_SOURCES
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
97 ${BOOST_SOURCES_DIR}/libs/system/src/error_code.cpp
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
98 )
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
99
2781
13038d638097 primitives for android ndk
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2679
diff changeset
100 if ("${CMAKE_SYSTEM_VERSION}" STREQUAL "LinuxStandardBase" OR
13038d638097 primitives for android ndk
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2679
diff changeset
101 "${CMAKE_SYSTEM_NAME}" STREQUAL "Android")
2525
94423976888e boost 1.66.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2515
diff changeset
102 add_definitions(
94423976888e boost 1.66.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2515
diff changeset
103 -DBOOST_SYSTEM_USE_STRERROR=1
94423976888e boost 1.66.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2515
diff changeset
104 )
2448
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
105
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
106 execute_process(
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
107 COMMAND ${PATCH_EXECUTABLE} -p0 -N -i
2679
ee9a6cd63891 boost 1.67.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2527
diff changeset
108 ${ORTHANC_ROOT}/Resources/Patches/boost-${BOOST_VERSION}-linux-standard-base.patch
2448
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
109 WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
110 RESULT_VARIABLE Failure
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
111 )
2369
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
112
2448
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
113 if (FirstRun AND Failure)
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
114 message(FATAL_ERROR "Error while patching a file")
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
115 endif()
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
116 endif()
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
117
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
118
2369
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
119 ##
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
120 ## Configuration of boost::thread
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
121 ##
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
122
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
123 if (CMAKE_SYSTEM_NAME STREQUAL "Linux" OR
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
124 CMAKE_SYSTEM_NAME STREQUAL "Darwin" OR
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
125 CMAKE_SYSTEM_NAME STREQUAL "FreeBSD" OR
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
126 CMAKE_SYSTEM_NAME STREQUAL "kFreeBSD" OR
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
127 CMAKE_SYSTEM_NAME STREQUAL "OpenBSD" OR
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
128 CMAKE_SYSTEM_NAME STREQUAL "PNaCl" OR
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
129 CMAKE_SYSTEM_NAME STREQUAL "NaCl32" OR
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
130 CMAKE_SYSTEM_NAME STREQUAL "NaCl64")
735
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
131 list(APPEND BOOST_SOURCES
2063
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2057
diff changeset
132 ${BOOST_SOURCES_DIR}/libs/atomic/src/lockpool.cpp
735
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
133 ${BOOST_SOURCES_DIR}/libs/thread/src/pthread/once.cpp
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
134 ${BOOST_SOURCES_DIR}/libs/thread/src/pthread/thread.cpp
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
135 )
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
136
2057
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2018
diff changeset
137 if ("${CMAKE_SYSTEM_VERSION}" STREQUAL "LinuxStandardBase" OR
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
138 CMAKE_SYSTEM_NAME STREQUAL "PNaCl" OR
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
139 CMAKE_SYSTEM_NAME STREQUAL "NaCl32" OR
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
140 CMAKE_SYSTEM_NAME STREQUAL "NaCl64")
735
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
141 add_definitions(-DBOOST_HAS_SCHED_YIELD=1)
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
142 endif()
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
143
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
144 elseif(CMAKE_SYSTEM_NAME STREQUAL "Windows")
735
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
145 list(APPEND BOOST_SOURCES
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
146 ${BOOST_SOURCES_DIR}/libs/thread/src/win32/tss_dll.cpp
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
147 ${BOOST_SOURCES_DIR}/libs/thread/src/win32/thread.cpp
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
148 ${BOOST_SOURCES_DIR}/libs/thread/src/win32/tss_pe.cpp
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
149 )
1094
1b905ad6c913 Replace wconv by iconv under Windows
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 930
diff changeset
150
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
151 elseif (CMAKE_SYSTEM_NAME STREQUAL "Emscripten")
2781
13038d638097 primitives for android ndk
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2679
diff changeset
152 # No support for threads in asm.js/WebAssembly
13038d638097 primitives for android ndk
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2679
diff changeset
153
13038d638097 primitives for android ndk
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2679
diff changeset
154 elseif (CMAKE_SYSTEM_NAME STREQUAL "Android")
13038d638097 primitives for android ndk
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2679
diff changeset
155 # No support for threads in Android
2242
4e8e0ad2001c move USleep() in SystemToolbox
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2186
diff changeset
156
735
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
157 else()
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
158 message(FATAL_ERROR "Support your platform here")
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
159 endif()
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
160
927
ff1812962f30 fix DOS EOL
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 921
diff changeset
161
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
162 ##
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
163 ## Configuration of boost::regex
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
164 ##
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
165
735
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
166 aux_source_directory(${BOOST_SOURCES_DIR}/libs/regex/src BOOST_REGEX_SOURCES)
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
167
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
168 list(APPEND BOOST_SOURCES
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
169 ${BOOST_REGEX_SOURCES}
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
170 )
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
171
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
172
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
173 ##
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
174 ## Configuration of boost::datetime
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
175 ##
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
176
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
177 list(APPEND BOOST_SOURCES
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
178 ${BOOST_SOURCES_DIR}/libs/date_time/src/gregorian/greg_month.cpp
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
179 )
2242
4e8e0ad2001c move USleep() in SystemToolbox
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2186
diff changeset
180
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
181
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
182 ##
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
183 ## Configuration of boost::filesystem
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
184 ##
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
185
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
186 if (CMAKE_SYSTEM_NAME STREQUAL "PNaCl" OR
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
187 CMAKE_SYSTEM_NAME STREQUAL "NaCl32" OR
2781
13038d638097 primitives for android ndk
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2679
diff changeset
188 CMAKE_SYSTEM_NAME STREQUAL "NaCl64" OR
13038d638097 primitives for android ndk
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2679
diff changeset
189 CMAKE_SYSTEM_NAME STREQUAL "Android")
2063
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2057
diff changeset
190 # boost::filesystem is not available on PNaCl
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2057
diff changeset
191 add_definitions(
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2057
diff changeset
192 -DBOOST_HAS_FILESYSTEM_V3=0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2057
diff changeset
193 -D__INTEGRITY=1
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2057
diff changeset
194 )
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2057
diff changeset
195 else()
2143
fd5875662670 creation of namespace SystemToolbox
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2113
diff changeset
196 add_definitions(
fd5875662670 creation of namespace SystemToolbox
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2113
diff changeset
197 -DBOOST_HAS_FILESYSTEM_V3=1
fd5875662670 creation of namespace SystemToolbox
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2113
diff changeset
198 )
2063
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2057
diff changeset
199 list(APPEND BOOST_SOURCES
2369
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
200 ${BOOST_NAME}/libs/filesystem/src/codecvt_error_category.cpp
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
201 ${BOOST_NAME}/libs/filesystem/src/operations.cpp
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
202 ${BOOST_NAME}/libs/filesystem/src/path.cpp
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
203 ${BOOST_NAME}/libs/filesystem/src/path_traits.cpp
2063
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2057
diff changeset
204 )
2368
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2367
diff changeset
205
2369
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
206 if (CMAKE_SYSTEM_NAME STREQUAL "Darwin" OR
2374
7087141c74b9 fix for FreeBSD
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2371
diff changeset
207 CMAKE_SYSTEM_NAME STREQUAL "OpenBSD" OR
7087141c74b9 fix for FreeBSD
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2371
diff changeset
208 CMAKE_SYSTEM_NAME STREQUAL "FreeBSD")
2369
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
209 list(APPEND BOOST_SOURCES
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
210 ${BOOST_SOURCES_DIR}/libs/filesystem/src/utf8_codecvt_facet.cpp
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
211 )
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
212
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
213 elseif (CMAKE_SYSTEM_NAME STREQUAL "Windows")
2368
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2367
diff changeset
214 list(APPEND BOOST_SOURCES
2369
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
215 ${BOOST_NAME}/libs/filesystem/src/windows_file_codecvt.cpp
2368
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2367
diff changeset
216 )
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2367
diff changeset
217 endif()
2063
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2057
diff changeset
218 endif()
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2057
diff changeset
219
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
220
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
221 ##
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
222 ## Configuration of boost::locale
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
223 ##
2018
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
224
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
225 if (NOT ENABLE_LOCALE)
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
226 message("boost::locale is disabled")
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
227 else()
2018
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
228 list(APPEND BOOST_SOURCES
2369
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
229 ${BOOST_SOURCES_DIR}/libs/locale/src/encoding/codepage.cpp
2018
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
230 ${BOOST_SOURCES_DIR}/libs/locale/src/shared/generator.cpp
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
231 ${BOOST_SOURCES_DIR}/libs/locale/src/shared/date_time.cpp
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
232 ${BOOST_SOURCES_DIR}/libs/locale/src/shared/formatting.cpp
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
233 ${BOOST_SOURCES_DIR}/libs/locale/src/shared/ids.cpp
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
234 ${BOOST_SOURCES_DIR}/libs/locale/src/shared/localization_backend.cpp
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
235 ${BOOST_SOURCES_DIR}/libs/locale/src/shared/message.cpp
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
236 ${BOOST_SOURCES_DIR}/libs/locale/src/shared/mo_lambda.cpp
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
237 ${BOOST_SOURCES_DIR}/libs/locale/src/util/codecvt_converter.cpp
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
238 ${BOOST_SOURCES_DIR}/libs/locale/src/util/default_locale.cpp
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
239 ${BOOST_SOURCES_DIR}/libs/locale/src/util/gregorian.cpp
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
240 ${BOOST_SOURCES_DIR}/libs/locale/src/util/info.cpp
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
241 ${BOOST_SOURCES_DIR}/libs/locale/src/util/locale_data.cpp
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
242 )
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
243
2448
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
244 if (CMAKE_SYSTEM_NAME STREQUAL "OpenBSD" OR
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
245 CMAKE_SYSTEM_VERSION STREQUAL "LinuxStandardBase")
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
246 list(APPEND BOOST_SOURCES
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
247 ${BOOST_SOURCES_DIR}/libs/locale/src/std/codecvt.cpp
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
248 ${BOOST_SOURCES_DIR}/libs/locale/src/std/collate.cpp
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
249 ${BOOST_SOURCES_DIR}/libs/locale/src/std/converter.cpp
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
250 ${BOOST_SOURCES_DIR}/libs/locale/src/std/numeric.cpp
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
251 ${BOOST_SOURCES_DIR}/libs/locale/src/std/std_backend.cpp
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
252 )
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
253
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
254 add_definitions(
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
255 -DBOOST_LOCALE_WITH_ICONV=1
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
256 -DBOOST_LOCALE_NO_WINAPI_BACKEND=1
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
257 -DBOOST_LOCALE_NO_POSIX_BACKEND=1
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
258 )
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
259
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
260 elseif (CMAKE_SYSTEM_NAME STREQUAL "Linux" OR
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
261 CMAKE_SYSTEM_NAME STREQUAL "Darwin" OR
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
262 CMAKE_SYSTEM_NAME STREQUAL "FreeBSD" OR
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
263 CMAKE_SYSTEM_NAME STREQUAL "kFreeBSD" OR
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
264 CMAKE_SYSTEM_NAME STREQUAL "PNaCl" OR
862d943115f9 working on linux standard base
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2432
diff changeset
265 CMAKE_SYSTEM_NAME STREQUAL "NaCl32" OR
2513
97a74f0eac7a loading DICOM dictionaries in sandboxed environments
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2512
diff changeset
266 CMAKE_SYSTEM_NAME STREQUAL "NaCl64" OR
97a74f0eac7a loading DICOM dictionaries in sandboxed environments
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2512
diff changeset
267 CMAKE_SYSTEM_NAME STREQUAL "Emscripten") # For WebAssembly or asm.js
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
268 list(APPEND BOOST_SOURCES
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
269 ${BOOST_SOURCES_DIR}/libs/locale/src/posix/codecvt.cpp
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
270 ${BOOST_SOURCES_DIR}/libs/locale/src/posix/collate.cpp
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
271 ${BOOST_SOURCES_DIR}/libs/locale/src/posix/converter.cpp
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
272 ${BOOST_SOURCES_DIR}/libs/locale/src/posix/numeric.cpp
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
273 ${BOOST_SOURCES_DIR}/libs/locale/src/posix/posix_backend.cpp
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
274 )
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
275
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
276 add_definitions(
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
277 -DBOOST_LOCALE_WITH_ICONV=1
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
278 -DBOOST_LOCALE_NO_WINAPI_BACKEND=1
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
279 -DBOOST_LOCALE_NO_STD_BACKEND=1
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
280 )
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
281
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
282 elseif (CMAKE_SYSTEM_NAME STREQUAL "Windows")
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
283 list(APPEND BOOST_SOURCES
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
284 ${BOOST_SOURCES_DIR}/libs/locale/src/win32/collate.cpp
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
285 ${BOOST_SOURCES_DIR}/libs/locale/src/win32/converter.cpp
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
286 ${BOOST_SOURCES_DIR}/libs/locale/src/win32/lcid.cpp
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
287 ${BOOST_SOURCES_DIR}/libs/locale/src/win32/numeric.cpp
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
288 ${BOOST_SOURCES_DIR}/libs/locale/src/win32/win_backend.cpp
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
289 )
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
290
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
291 add_definitions(
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
292 -DBOOST_LOCALE_NO_POSIX_BACKEND=1
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
293 -DBOOST_LOCALE_NO_STD_BACKEND=1
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
294 )
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
295
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
296 # Starting with release 0.8.2, Orthanc statically links against
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
297 # libiconv, even on Windows. Indeed, the "WCONV" library of
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
298 # Windows XP seems not to support properly several codepages
2369
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
299 # (notably "Latin3", "Hebrew", and "Arabic"). Set
61371420f383 improvements
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2368
diff changeset
300 # "USE_BOOST_ICONV" to "OFF" to use WCONV anyway.
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
301
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
302 if (USE_BOOST_ICONV)
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
303 add_definitions(-DBOOST_LOCALE_WITH_ICONV=1)
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
304 else()
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
305 add_definitions(-DBOOST_LOCALE_WITH_WCONV=1)
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
306 endif()
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
307
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
308 else()
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
309 message(FATAL_ERROR "Support your platform here")
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
310 endif()
2018
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
311 endif()
300599489cab USE_BOOST_LOCALE_BACKENDS
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 1991
diff changeset
312
2367
2aff870c2c58 refactoring of BoostConfiguration.cmake
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2366
diff changeset
313
2113
0108ac01fc8e added source_group directives for MSVC
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2065
diff changeset
314 source_group(ThirdParty\\boost REGULAR_EXPRESSION ${BOOST_SOURCES_DIR}/.*)
0108ac01fc8e added source_group directives for MSVC
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2065
diff changeset
315
735
ee0d5abf7958 dos2unix
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 626
diff changeset
316 endif()