Mercurial > hg > orthanc
annotate Resources/CMake/PugixmlConfiguration.cmake @ 2538:c53f1d015b06
fix
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Tue, 17 Apr 2018 14:50:34 +0200 |
parents | 74d0953a3681 |
children | 0c2a8d5e0097 |
rev | line source |
---|---|
2379
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
1 if (STATIC_BUILD OR NOT USE_SYSTEM_PUGIXML) |
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
2 set(PUGIXML_SOURCES_DIR ${CMAKE_BINARY_DIR}/pugixml-1.4) |
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
3 set(PUGIXML_MD5 "7c56c91cfe3ecdee248a8e4892ef5781") |
2384 | 4 set(PUGIXML_URL "http://www.orthanc-server.com/downloads/third-party/pugixml-1.4.tar.gz") |
1045
0bfeeb6d340f
json to xml conversion with pugixml
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
5 |
2379
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
6 DownloadPackage(${PUGIXML_MD5} ${PUGIXML_URL} "${PUGIXML_SOURCES_DIR}") |
1045
0bfeeb6d340f
json to xml conversion with pugixml
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
7 |
2379
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
8 include_directories( |
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
9 ${PUGIXML_SOURCES_DIR}/src |
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
10 ) |
1045
0bfeeb6d340f
json to xml conversion with pugixml
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
11 |
2379
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
12 set(PUGIXML_SOURCES |
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
13 #${PUGIXML_SOURCES_DIR}/src/vlog_is_on.cc |
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
14 ${PUGIXML_SOURCES_DIR}/src/pugixml.cpp |
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
15 ) |
1045
0bfeeb6d340f
json to xml conversion with pugixml
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
16 |
2113
0108ac01fc8e
added source_group directives for MSVC
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1537
diff
changeset
|
17 source_group(ThirdParty\\pugixml REGULAR_EXPRESSION ${PUGIXML_SOURCES_DIR}/.*) |
0108ac01fc8e
added source_group directives for MSVC
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
1537
diff
changeset
|
18 |
1045
0bfeeb6d340f
json to xml conversion with pugixml
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
19 else() |
2379
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
20 CHECK_INCLUDE_FILE_CXX(pugixml.hpp HAVE_PUGIXML_H) |
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
21 if (NOT HAVE_PUGIXML_H) |
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
22 message(FATAL_ERROR "Please install the libpugixml-dev package") |
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
23 endif() |
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
24 |
4900688827a8
reorganization in CMake
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
2186
diff
changeset
|
25 link_libraries(pugixml) |
1045
0bfeeb6d340f
json to xml conversion with pugixml
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
26 endif() |