CMakeLists.txt 3.55 KB
Newer Older
1
2
3
4
5
#
# This is a CMake makefile.  You can find the cmake utility and
# information about it at http://www.cmake.org
#

6
cmake_minimum_required(VERSION 2.8.4)
7

Davis King's avatar
Davis King committed
8
9
10
11
12
13
# create a variable called target_name and set it to the string "dtest"
set (target_name dtest)
PROJECT(${target_name})

include(../cmake)

14
15
16
# This variable contains a list of all the tests we are building
# into the regression test suite.
set (tests
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
   example.cpp
   active_learning.cpp
   any.cpp
   any_function.cpp
   array2d.cpp
   array.cpp
   assignment_learning.cpp
   base64.cpp
   bayes_nets.cpp
   bigint.cpp
   binary_search_tree_kernel_1a.cpp
   binary_search_tree_kernel_2a.cpp
   binary_search_tree_mm1.cpp
   binary_search_tree_mm2.cpp
   bridge.cpp
   bsp.cpp
   byte_orderer.cpp
   cca.cpp
   clustering.cpp
   cmd_line_parser.cpp
   cmd_line_parser_wchar_t.cpp
   compress_stream.cpp
   conditioning_class_c.cpp
   conditioning_class.cpp
   config_reader.cpp
Davis King's avatar
Davis King committed
42
   correlation_tracker.cpp
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
   crc32.cpp
   create_iris_datafile.cpp
   data_io.cpp
   directed_graph.cpp
   discriminant_pca.cpp
   disjoint_subsets.cpp
   ekm_and_lisf.cpp
   empirical_kernel_map.cpp
   entropy_coder.cpp
   entropy_encoder_model.cpp
   example_args.cpp
   face.cpp
   fft.cpp
   fhog.cpp
   filtering.cpp
   find_max_factor_graph_nmplp.cpp
   find_max_factor_graph_viterbi.cpp
   geometry.cpp
   graph.cpp
   graph_cuts.cpp
   graph_labeler.cpp
   hash.cpp
   hash_map.cpp
   hash_set.cpp
   hash_table.cpp
   hog_image.cpp
   image.cpp
   iosockstream.cpp
   is_same_object.cpp
   kcentroid.cpp
   kernel_matrix.cpp
   kmeans.cpp
   learning_to_track.cpp
   least_squares.cpp
   linear_manifold_regularizer.cpp
   lspi.cpp
   lz77_buffer.cpp
   map.cpp
   matrix2.cpp
   matrix3.cpp
   matrix4.cpp
   matrix_chol.cpp
   matrix.cpp
   matrix_eig.cpp
   matrix_lu.cpp
   matrix_qr.cpp
   max_cost_assignment.cpp
   max_sum_submatrix.cpp
   md5.cpp
   member_function_pointer.cpp
   metaprogramming.cpp
   mpc.cpp
   multithreaded_object.cpp
   numerical_integration.cpp
   object_detector.cpp
   oca.cpp
   one_vs_all_trainer.cpp
   one_vs_one_trainer.cpp
   optimization.cpp
   optimization_test_functions.cpp
   opt_qp_solver.cpp
   parallel_for.cpp
   parse.cpp
   pipe.cpp
   pixel.cpp
   probabilistic.cpp
   pyramid_down.cpp
   queue.cpp
   rand.cpp
   ranking.cpp
   read_write_mutex.cpp
   reference_counter.cpp
   rls.cpp
   sammon.cpp
   scan_image.cpp
   sequence.cpp
   sequence_labeler.cpp
   sequence_segmenter.cpp
   serialize.cpp
   set.cpp
   sldf.cpp
   sliding_buffer.cpp
   smart_pointers.cpp
   sockets2.cpp
   sockets.cpp
   sockstreambuf.cpp
   sparse_vector.cpp
   stack.cpp
   static_map.cpp
   static_set.cpp
   statistics.cpp
   std_vector_c.cpp
   string.cpp
   svm_c_linear.cpp
   svm_c_linear_dcd.cpp
   svm.cpp
   svm_multiclass_linear.cpp
   svm_struct.cpp
   svr_linear_trainer.cpp
   symmetric_matrix_cache.cpp
   thread_pool.cpp
   threads.cpp
   timer.cpp
   tokenizer.cpp
   trust_region.cpp
   tuple.cpp
   type_safe_union.cpp
   vectorstream.cpp
151
152
   )

Davis King's avatar
Davis King committed
153
154
155
156
# Tests that require C++11 support
if (COMPILER_CAN_DO_CPP_11)
   set(tests ${tests}
      dnn.cpp
157
      cublas.cpp
Davis King's avatar
Davis King committed
158
159
      )
endif()
160
161
162


# add all the cpp files we want to compile to this list.  This tells
163
# cmake that they are part of our target (which is the executable named dtest)
164
165
ADD_EXECUTABLE(${target_name} main.cpp tester.cpp ${tests})

166
167
168
169
170
# Turn on all warnings when using gcc.
if (CMAKE_COMPILER_IS_GNUCXX)
   add_definitions("-W -Wall")
endif()

Davis King's avatar
Davis King committed
171
172
173

TARGET_LINK_LIBRARIES(${target_name} dlib )

174

175
176
177
178
179
180
if (NOT DLIB_NO_GUI_SUPPORT)
   add_subdirectory(gui)
   add_subdirectory(examples)
endif()