1 # Boost Chrono Library test Jamfile
3 # Copyright Beman Dawes 2008
4 # Copyright Vicente J. Botet Escriba 2009-2010
6 # Distributed under the Boost Software License, Version 1.0.
7 # See accompanying file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt
9 # See library home page at http://www.boost.org/libs/chrono
16 <target-os>freebsd:<linkflags>"-lrt"
17 <target-os>linux:<linkflags>"-lrt"
18 <toolset>clang/<target-os>linux:<linkflags>"-lpthread"
19 <toolset>pgi:<linkflags>"-lrt"
20 #<threading>single:<define>BOOST_CHRONO_THREAD_DISABLED
21 <toolset>msvc:<asynch-exceptions>on
22 <define>BOOST_CHRONO_USES_MPL_ASSERT
23 <define>BOOST_SYSTEM_NO_DEPRECATED
24 #<toolset>sun:<define>BOOST_COMMON_TYPE_DONT_USE_TYPEOF
25 #<toolset>sun:<define>BOOST_TYPEOF_EMULATION
26 <toolset>sun:<define>__typeof__=__typeof__
28 <toolset>gcc:<cxxflags>-Wextra
29 <toolset>gcc:<cxxflags>-pedantic
30 <toolset>gcc:<cxxflags>-Wno-long-long
31 <toolset>darwin:<cxxflags>-Wextra
32 <toolset>darwin:<cxxflags>-pedantic
33 <toolset>darwin:<cxxflags>-Wno-long-long
34 #<toolset>pathscale:<cxxflags>-Wextra
35 <toolset>pathscale:<cxxflags>-Wno-long-long
36 <toolset>pathscale:<cxxflags>-pedantic
37 <toolset>clang:<cxxflags>-Wextra
38 <toolset>clang:<cxxflags>-pedantic
39 <toolset>clang:<cxxflags>-Wno-long-long
40 <toolset>gcc-mingw-4.5.0:<cxxflags>-Wno-missing-field-initializers
41 <toolset>gcc-mingw-4.5.0:<cxxflags>-fdiagnostics-show-option
42 <toolset>msvc:<cxxflags>/wd4127
43 # Note: Some of the remarks from the Intel compiler are disabled
44 # remark #304: access control not specified ("public" by default)
45 # remark #383: value copied to temporary, reference to temporary used
46 # remark #1418: external function definition with no prior declaration
47 <toolset>intel:<cxxflags>-wd304,383,1418
50 rule chrono-run ( sources )
53 [ run $(sources) ../build//boost_chrono
56 <library>/boost/system//boost_system
57 : $(sources[1]:B)_shared ]
58 #[ run $(sources) ../build//boost_chrono/<link>static
61 # <library>/boost/system//boost_system
62 # : $(sources[1]:B)_static ]
65 : <define>BOOST_CHRONO_HEADER_ONLY
66 <define>BOOST_ERROR_CODE_HEADER_ONLY
67 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
68 : $(sources[1]:B)_header ]
71 rule chrono-run2 ( sources : name )
74 [ run $(sources) ../build//boost_chrono
77 <library>/boost/system//boost_system
79 #[ run $(sources) ../build//boost_chrono/<link>static
82 # <library>/boost/system//boost_system
86 : <define>BOOST_CHRONO_HEADER_ONLY
87 <define>BOOST_ERROR_CODE_HEADER_ONLY
88 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
94 rule chrono-run-mt ( sources )
97 [ run $(sources) ../build//boost_chrono
100 <library>/boost/system//boost_system
101 : $(sources[1]:B)_shared ]
102 #[ run $(sources) ../build//boost_chrono/<link>static
105 # <library>/boost/system//boost_system
106 # : $(sources[1]:B)_static ]
109 : <define>BOOST_CHRONO_HEADER_ONLY
110 <define>BOOST_ERROR_CODE_HEADER_ONLY
111 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
112 : $(sources[1]:B)_header ]
115 rule chrono-run2-mt ( sources : name )
118 [ run $(sources) ../build//boost_chrono
121 <library>/boost/system//boost_system
123 #[ run $(sources) ../build//boost_chrono/<link>static
126 # <library>/boost/system//boost_system
130 : <define>BOOST_CHRONO_HEADER_ONLY
131 <define>BOOST_ERROR_CODE_HEADER_ONLY
132 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
137 rule chrono-run-check ( sources )
143 <library>/boost/system//boost_system
144 : $(sources[1]:B)_shared ]
148 <library>/boost/system//boost_system
149 : $(sources[1]:B)_static ]
152 : <define>BOOST_CHRONO_HEADER_ONLY
153 <define>BOOST_ERROR_CODE_HEADER_ONLY
154 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
155 : $(sources[1]:B)_header ]
159 rule chrono-run-check2 ( sources : name )
165 <library>/boost/system//boost_system
170 <library>/boost/system//boost_system
174 : <define>BOOST_CHRONO_HEADER_ONLY
175 <define>BOOST_ERROR_CODE_HEADER_ONLY
176 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
181 rule chrono-run-header ( sources )
186 : <define>BOOST_CHRONO_HEADER_ONLY
187 <define>BOOST_ERROR_CODE_HEADER_ONLY
188 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
189 : $(sources[1]:B)_header ]
193 rule chrono-run-header2 ( sources : name )
198 : <define>BOOST_CHRONO_HEADER_ONLY
199 <define>BOOST_ERROR_CODE_HEADER_ONLY
200 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
205 rule chrono-compile ( sources )
210 : $(sources[1]:B)_lib ]
212 : <define>BOOST_CHRONO_HEADER_ONLY
213 <define>BOOST_ERROR_CODE_HEADER_ONLY
214 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
215 : $(sources[1]:B)_header ]
219 rule chrono-compile2 ( sources : name )
226 : <define>BOOST_CHRONO_HEADER_ONLY
227 <define>BOOST_ERROR_CODE_HEADER_ONLY
228 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
234 test-suite "examples"
236 [ chrono-run-header ../example/cycle_count.cpp ]
237 [ chrono-run-header ../example/runtime_resolution.cpp ]
238 [ chrono-run-header ../example/xtime.cpp ]
239 [ chrono-run-header ../example/saturating.cpp ]
240 [ chrono-run ../example/min_time_point.cpp ]
241 [ chrono-run-header ../example/i_dont_like_the_default_duration_behavior.cpp ]
242 [ chrono-run ../example/simulated_thread_interface_demo.cpp ]
243 [ chrono-run-header ../example/timeval_demo.cpp ]
244 [ chrono-run ../example/chrono_unit_test.cpp ]
245 [ chrono-run-header ../example/explore_limits.cpp ]
246 [ chrono-run-header ../example/test_duration.cpp ]
247 [ chrono-run ../example/test_clock.cpp ]
248 [ chrono-run-header ../example/miscellaneous.cpp ]
249 [ chrono-run-header ../example/test_special_values.cpp ]
250 [ chrono-run ../example/manipulate_clock_object.cpp ]
251 #[ chrono-run ../example/chrono_accuracy_test.cpp ]
252 [ chrono-run-mt ../example/test_thread_clock.cpp ]
253 [ chrono-run-header ../example/rounding.cpp ]
254 #[ chrono-run ../example/await_keystroke.cpp ]
259 [ chrono-compile2 traits/common_type_duration_pass.cpp : traits_common_type_duration_pass ]
260 [ chrono-compile2 traits/common_type_time_point_pass.cpp : traits_common_type_time_point_pass ]
261 [ chrono-compile2 traits/treat_as_floating_point_pass.cpp : traits_treat_as_floating_point_pass ]
262 [ chrono-run-header2 traits/duration_values_pass.cpp : traits_duration_values_pass ]
265 test-suite "duration"
267 [ compile-fail duration/duration_duration_fail.cpp ]
268 [ compile-fail duration/ratio_fail.cpp ]
269 [ compile-fail duration/positive_num_fail.cpp ]
270 [ chrono-compile duration/default_ratio_pass.cpp ]
271 [ chrono-compile duration/types_pass.cpp ]
272 [ chrono-compile duration/ratio_alias_pass.cpp ]
273 [ chrono-compile duration/typedefs_pass.cpp ]
274 [ chrono-run-header duration/arithmetic_pass.cpp ]
275 [ chrono-run-header duration/duration_cast_pass.cpp ]
276 [ compile-fail duration/duration_cast_int_fail.cpp ]
277 [ chrono-run-header duration/comparisons_pass.cpp ]
278 [ chrono-run-header duration/constructor_pass.cpp ]
279 [ compile-fail duration/cons/convert_float_to_int_fail.cpp ]
280 [ compile-fail duration/cons/convert_inexact_fail.cpp ]
281 [ compile-fail duration/cons/implicit_constructot_fail.cpp ]
282 [ compile-fail duration/cons/non_implicit_convertible_rep_fail.cpp ]
283 [ compile-fail duration/cons/treat_as_floating_point_Rep2_true_fail.cpp ]
284 [ compile-fail duration/nonmember/divide_rep2_fail.cpp ]
285 [ compile-fail duration/nonmember/modulus_rep2_fail.cpp ]
286 [ compile-fail duration/nonmember/times_rep2_lhs_fail.cpp ]
287 [ compile-fail duration/nonmember/times_rep2_rhs_fail.cpp ]
288 [ chrono-run-header duration/duration_values_pass.cpp ]
291 test-suite "time_point"
293 [ chrono-compile2 time_point/default_duration_pass.cpp : time_point_default_duration_pass ]
294 [ compile-fail time_point/not_duration_fail.cpp : : time_point_not_duration_fail ]
295 [ chrono-run-header2 time_point/arithmetic_pass.cpp : time_point_arithmetic_pass ]
296 [ chrono-run-header2 time_point/arithmetic_ext_pass.cpp : time_point_arithmetic_ext_pass ]
297 [ chrono-run-header2 time_point/time_point_cast_pass.cpp : time_point_time_point_cast_pass ]
298 [ compile-fail time_point/time_point_cast_int_fail.cpp : : time_point_time_point_cast_int_fail ]
299 [ chrono-run-header2 time_point/comparisons_pass.cpp : time_point_comparisons_pass ]
300 [ compile-fail time_point/comparisons/equal_fail.cpp : : time_point_equal_fail ]
301 [ compile-fail time_point/comparisons/less_fail.cpp : : time_point_less_fail ]
302 [ chrono-run-header2 time_point/constructor_pass.cpp : time_point_constructor_pass ]
303 [ compile-fail time_point/cons/implicit_fail.cpp : : time_point_implicit_fail ]
304 [ compile-fail time_point/cons/non_implicit_convertible_duration_fail.cpp : : time_point_non_implicit_convertible_duration_fail ]
305 [ chrono-run-header2 time_point/min_max_pass.cpp : time_point_min_max_pass ]
310 [ chrono-run2-mt clock/clock_pass.cpp : clock_clock_pass ]
313 #test-suite "stopwatch"
315 # [ chrono-run2 stopwatch/simple_stopwatch_pass.cpp : simple_stopwatch_pass ]
316 # [ chrono-run2 stopwatch/basic_stopwatch_pass.cpp : basic_stopwatch_pass ]
317 # [ chrono-run2 stopwatch/basic_stopwatch_last_lap_pass.cpp : basic_stopwatch_last_lap_pass ]
318 # [ chrono-run2 stopwatch/basic_stopwatch_laps_accumulator_set_pass.cpp : basic_stopwatch_laps_accumulator_set_pass ]
319 # [ chrono-run2 stopwatch/basic_stopwatch_laps_container_pass.cpp : basic_stopwatch_laps_container_pass ]
320 # [ chrono-run2 stopwatch/suspendable_stopwatch_pass.cpp : suspendable_stopwatch_pass ]
323 #test-suite "stopwatch_ex"
325 # [ chrono-run ../example/stopwatch_example.cpp ]
328 #test-suite "stopclock"
330 # [ chrono-run2 stopwatch/simple_stopwatch_reporter_pass.cpp : simple_stopwatch_reporter_pass ]
331 # [ chrono-run2 stopwatch/basic_stopwatch_reporter_pass.cpp : basic_stopwatch_reporter_pass ]
332 # [ chrono-run2 stopwatch/basic_stopwatch_reporter_laps_accumulator_set_pass.cpp : basic_stopwatch_reporter_laps_accumulator_set_pass ]
335 #test-suite "stopclock_ex"
337 # [ chrono-run2-mt ../example/stopwatch_reporter_example.cpp : stopwatch_reporter_example ]
342 [ chrono-run-mt ../example/io_ex1.cpp ]
343 [ chrono-run-header ../example/io_ex2.cpp ]
344 [ chrono-run ../example/io_ex3.cpp ]
345 [ chrono-run ../example/io_ex4.cpp ]
346 [ chrono-run ../example/io_ex5.cpp ]
347 [ chrono-run ../example/french.cpp ]
352 [ chrono-run-header io/duration_input.cpp ]
353 [ chrono-run-header io/duration_output.cpp ]
354 [ chrono-run-header io/time_point_input.cpp ]
355 [ chrono-run-header io/time_point_output.cpp ]
360 [ chrono-run win32_test.cpp ]