|
@@ -32,20 +32,25 @@ ExternalProject_Add(YAML-CPP
|
32
|
32
|
PREFIX ${CMAKE_CURRENT_BINARY_DIR}/external/yaml-cpp
|
33
|
33
|
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
|
34
|
34
|
)
|
|
35
|
+add_compile_options(-DHAVE_YAMLCPP)
|
35
|
36
|
|
36
|
37
|
# tinyxml2, this library is used for XML IO
|
37
|
|
-ExternalProject_Add(TINYXML2
|
38
|
|
- GIT_REPOSITORY "https://github.com/leethomason/tinyxml2.git"
|
39
|
|
- GIT_TAG "master"
|
40
|
|
- UPDATE_COMMAND ""
|
41
|
|
- PATCH_COMMAND ""
|
42
|
|
- PREFIX ${CMAKE_CURRENT_BINARY_DIR}/external/tinyxml2
|
43
|
|
- CMAKE_ARGS -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
|
44
|
|
-)
|
45
|
|
-
|
46
|
|
-option(MATIO_SUPPORT "MATIO library support for MATLAB .mat files" ON)
|
|
38
|
+option(TINYXML_SUPPORT "MATIO library support for MATLAB .mat files" OFF)
|
|
39
|
+if ( TINYXML_SUPPORT )
|
|
40
|
+ ExternalProject_Add(TINYXML2
|
|
41
|
+ GIT_REPOSITORY "https://github.com/leethomason/tinyxml2.git"
|
|
42
|
+ GIT_TAG "master"
|
|
43
|
+ UPDATE_COMMAND ""
|
|
44
|
+ PATCH_COMMAND ""
|
|
45
|
+ PREFIX ${CMAKE_CURRENT_BINARY_DIR}/external/tinyxml2
|
|
46
|
+ CMAKE_ARGS -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
|
|
47
|
+ )
|
|
48
|
+ add_compile_options(-DTINYXMLSUPPORT)
|
|
49
|
+endif()
|
47
|
50
|
|
|
51
|
+option(MATIO_SUPPORT "MATIO library support for MATLAB .mat files" OFF)
|
48
|
52
|
if ( MATIO_SUPPORT )
|
|
53
|
+ add_compile_options(-DHAVE_MATIO)
|
49
|
54
|
# matio, this library is used for MATLAB file IO
|
50
|
55
|
ExternalProject_ADD(MATIO
|
51
|
56
|
GIT_REPOSITORY "git://git.code.sf.net/p/matio/matio"
|
|
@@ -65,9 +70,15 @@ endif()
|
65
|
70
|
#####################
|
66
|
71
|
project(LEMMA_CXX)
|
67
|
72
|
|
68
|
|
-# We don't Build VTK, it is too much.
|
69
|
|
-find_package(VTK 6 REQUIRED NO_MODULE)
|
70
|
|
-include(${VTK_USE_FILE})
|
|
73
|
+# We don't Build VTK, it is too much.
|
|
74
|
+option (VTK_SUPPORT "VTK library for visualisation and grids" OFF)
|
|
75
|
+if (VTK_SUPPORT)
|
|
76
|
+ find_package(VTK 6 REQUIRED NO_MODULE)
|
|
77
|
+ include(${VTK_USE_FILE})
|
|
78
|
+ add_compile_options(-DLEMMAUSEVTK)
|
|
79
|
+endif()
|
|
80
|
+
|
|
81
|
+add_compile_options(-std=c++11)
|
71
|
82
|
|
72
|
83
|
set(LEMMA_VERSION_MAJOR "0")
|
73
|
84
|
set(LEMMA_VERSION_MINOR "0")
|
|
@@ -87,7 +98,7 @@ link_directories ("${CMAKE_INSTALL_PREFIX}/lib/")
|
87
|
98
|
add_subdirectory (LemmaCore)
|
88
|
99
|
|
89
|
100
|
# TODO add compiler specific instructions
|
90
|
|
-add_compile_options(-std=c++11)
|
|
101
|
+
|
91
|
102
|
|
92
|
103
|
include_directories(${CMAKE_INSTALL_PREFIX}/include)
|
93
|
104
|
add_executable(Hello "${PROJECT_SOURCE_DIR}/src/test.cpp")
|