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
17 <target-os>freebsd:<linkflags>"-lrt"
18 <target-os>linux:<linkflags>"-lrt -lpthread"
19 <toolset>clang/<target-os>linux:<linkflags>"-lpthread"
20 <toolset>pgi:<linkflags>"-lrt"
21 #<threading>single:<define>BOOST_CHRONO_THREAD_DISABLED
22 <toolset>msvc:<asynch-exceptions>on
23 <define>BOOST_CHRONO_USES_MPL_ASSERT
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>clang:<warnings>on
31 <toolset>gcc:<cxxflags>-Wno-long-long
32 <toolset>gcc:<cxxflags>-Wno-variadic-macros
33 <toolset>darwin:<cxxflags>-Wextra
34 <toolset>darwin:<cxxflags>-pedantic
35 <toolset>darwin:<cxxflags>-Wno-long-long
36 <toolset>darwin:<cxxflags>-Wno-variadic-macros
37 #<toolset>pathscale:<cxxflags>-Wextra
38 <toolset>pathscale:<cxxflags>-Wno-long-long
39 <toolset>pathscale:<cxxflags>-pedantic
40 <toolset>clang:<cxxflags>-Wextra
41 <toolset>clang:<cxxflags>-pedantic
42 <toolset>clang:<cxxflags>-Wno-long-long
43 <toolset>clang:<cxxflags>-Wno-variadic-macros
44 <toolset>gcc-4.5.0,<target-os>windows:<cxxflags>-Wno-missing-field-initializers
45 <toolset>gcc-4.5.0,<target-os>windows:<cxxflags>-fdiagnostics-show-option
46 <toolset>msvc:<cxxflags>/wd4127
47 <toolset>msvc:<cxxflags>/wd4512
48 # Note: Some of the remarks from the Intel compiler are disabled
49 # remark #193: zero used for undefined preprocessing identifier "XXX"
50 # remark #304: access control not specified ("public" by default)
51 # remark #383: value copied to temporary, reference to temporary used
52 # remark #444: destructor for base class "XXX" (declared at line YYY") is not virtual
53 # remark #593: variable "XXX" was set but never used
54 # remark #981: operands are evaluated in unspecified order
55 # remark #1418: external function definition with no prior declaration
56 # remark #2415: variable "XXX" of static storage duration was declared but never referenced
58 <toolset>intel:<cxxflags>-wd193,304,383,444
59 <toolset>intel:<cxxflags>-wd593,981
60 <toolset>intel:<cxxflags>-wd1418
61 <toolset>intel:<cxxflags>-wd2415
64 rule chrono-run ( sources )
67 [ run $(sources) ../build//boost_chrono
70 <define>BOOST_CHRONO_VERSION=2
72 #[ run $(sources) ../build//boost_chrono/<link>static
75 # : $(sources[1]:B)_s ]
78 : <define>BOOST_CHRONO_HEADER_ONLY
79 <define>BOOST_ERROR_CODE_HEADER_ONLY
80 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
81 <define>BOOST_CHRONO_VERSION=2
86 rule chrono-runXXX ( sources )
89 [ run $(sources) ../build//boost_chrono
92 <define>BOOST_CHRONO_VERSION=2
94 #[ run $(sources) ../build//boost_chrono/<link>static
97 # : $(sources[1]:B)_s ]
100 : <define>BOOST_CHRONO_HEADER_ONLY
101 <define>BOOST_ERROR_CODE_HEADER_ONLY
102 <define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
103 <define>BOOST_CHRONO_VERSION=2
104 : $(sources[1]:B)_h ]
109 rule chrono-v1-v2-run ( sources )
112 [ run $(sources) ../build//boost_chrono
115 <define>BOOST_CHRONO_VERSION=2
116 : $(sources[1]:B)_d ]
117 [ run $(sources) ../build//boost_chrono/<link>static
120 : v1_$(sources[1]:B)_s ]
123 : <define>BOOST_CHRONO_HEADER_ONLY
124 <define>BOOST_ERROR_CODE_HEADER_ONLY
125 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
126 <define>BOOST_CHRONO_VERSION=2
127 : $(sources[1]:B)_h ]
130 : <define>BOOST_CHRONO_HEADER_ONLY
131 <define>BOOST_ERROR_CODE_HEADER_ONLY
132 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
133 #<define>BOOST_CHRONO_VERSION=1
134 : v1_$(sources[1]:B)_h ]
138 rule chrono-run2 ( sources : name )
141 [ run $(sources) ../build//boost_chrono
144 <define>BOOST_CHRONO_VERSION=2
146 #[ run $(sources) ../build//boost_chrono/<link>static
152 : <define>BOOST_CHRONO_HEADER_ONLY
153 <define>BOOST_ERROR_CODE_HEADER_ONLY
154 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
155 <define>BOOST_CHRONO_VERSION=2
160 rule date-run ( sources + )
163 [ run $(sources) ../build//boost_chrono
166 <define>BOOST_CHRONO_VERSION=2
167 : $(sources[1]:B)_d ]
171 rule date-run-2 ( sources + : name )
174 [ run $(sources) ../build//boost_chrono
177 <define>BOOST_CHRONO_VERSION=2
183 rule chrono-run-mt ( sources )
186 [ run $(sources) ../build//boost_chrono
189 <define>BOOST_CHRONO_VERSION=2
190 : $(sources[1]:B)_d ]
191 #[ run $(sources) ../build//boost_chrono/<link>static
194 # : $(sources[1]:B)_s ]
197 : <define>BOOST_CHRONO_HEADER_ONLY
198 <define>BOOST_ERROR_CODE_HEADER_ONLY
199 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
200 <define>BOOST_CHRONO_VERSION=2
201 : $(sources[1]:B)_h ]
204 rule chrono-run2-mt ( sources * : name )
207 [ run $(sources) ../build//boost_chrono
210 <define>BOOST_CHRONO_VERSION=2
212 #[ run $(sources) ../build//boost_chrono/<link>static
218 : <define>BOOST_CHRONO_HEADER_ONLY
219 <define>BOOST_ERROR_CODE_HEADER_ONLY
220 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
221 <define>BOOST_CHRONO_VERSION=2
226 rule chrono-run-check ( sources )
232 <define>BOOST_CHRONO_VERSION=2
233 : $(sources[1]:B)_d ]
237 <define>BOOST_CHRONO_VERSION=2
238 : $(sources[1]:B)_s ]
241 : <define>BOOST_CHRONO_HEADER_ONLY
242 <define>BOOST_ERROR_CODE_HEADER_ONLY
243 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
244 <define>BOOST_CHRONO_VERSION=2
245 : $(sources[1]:B)_h ]
249 rule chrono-run-check2 ( sources : name )
255 <define>BOOST_CHRONO_VERSION=2
260 <define>BOOST_CHRONO_VERSION=2
264 : <define>BOOST_CHRONO_HEADER_ONLY
265 <define>BOOST_ERROR_CODE_HEADER_ONLY
266 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
267 <define>BOOST_CHRONO_VERSION=2
272 rule chrono-run-header ( sources )
277 : <define>BOOST_CHRONO_HEADER_ONLY
278 <define>BOOST_ERROR_CODE_HEADER_ONLY
279 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
280 <define>BOOST_CHRONO_VERSION=2
281 : $(sources[1]:B)_h ]
285 rule chrono-v1-v2-run-header ( sources )
290 : <define>BOOST_CHRONO_HEADER_ONLY
291 <define>BOOST_ERROR_CODE_HEADER_ONLY
292 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
293 <define>BOOST_CHRONO_VERSION=2
294 : $(sources[1]:B)_h ]
297 : <define>BOOST_CHRONO_HEADER_ONLY
298 <define>BOOST_ERROR_CODE_HEADER_ONLY
299 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
300 : v1_$(sources[1]:B)_h ]
304 rule chrono-run-header2 ( sources : name )
309 : <define>BOOST_CHRONO_HEADER_ONLY
310 <define>BOOST_ERROR_CODE_HEADER_ONLY
311 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
312 <define>BOOST_CHRONO_VERSION=2
317 rule chrono-compile ( sources )
322 <define>BOOST_CHRONO_VERSION=2
323 : $(sources[1]:B)_l ]
325 : <define>BOOST_CHRONO_HEADER_ONLY
326 <define>BOOST_ERROR_CODE_HEADER_ONLY
327 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
328 <define>BOOST_CHRONO_VERSION=2
329 : $(sources[1]:B)_h ]
333 rule chrono-compile2 ( sources : name )
338 <define>BOOST_CHRONO_VERSION=2
341 : <define>BOOST_CHRONO_HEADER_ONLY
342 <define>BOOST_ERROR_CODE_HEADER_ONLY
343 #<define>BOOST_CHRONO_DONT_PROVIDE_HYBRID_ERROR_HANDLING
344 <define>BOOST_CHRONO_VERSION=2
350 test-suite "examples"
352 [ chrono-run-header ../example/cycle_count.cpp ]
353 [ chrono-run-header ../example/runtime_resolution.cpp ]
354 [ chrono-run-header ../example/xtime.cpp ]
355 [ chrono-run-header ../example/saturating.cpp ]
356 [ chrono-run ../example/min_time_point.cpp ]
357 [ chrono-run-header ../example/i_dont_like_the_default_duration_behavior.cpp ]
358 [ chrono-run ../example/simulated_thread_interface_demo.cpp ]
359 [ chrono-run-header ../example/timeval_demo.cpp ]
360 [ chrono-run ../example/chrono_unit_test.cpp ]
361 [ chrono-run-header ../example/explore_limits.cpp ]
362 [ chrono-run-header ../example/test_duration.cpp ]
363 [ chrono-run ../example/test_clock.cpp ]
364 [ chrono-run-header ../example/miscellaneous.cpp ]
365 [ chrono-run-header ../example/test_special_values.cpp ]
366 [ chrono-run ../example/manipulate_clock_object.cpp ]
367 [ chrono-run-mt ../example/test_thread_clock.cpp ]
368 [ chrono-run-header ../example/rounding.cpp ]
369 #[ chrono-run ../example/await_keystroke.cpp ]
374 [ chrono-compile2 traits/common_type_duration_pass.cpp : traits_common_type_duration_p ]
375 [ chrono-compile2 traits/common_type_time_point_pass.cpp : traits_common_type_time_point_p ]
376 [ chrono-compile2 traits/treat_as_floating_point_pass.cpp : traits_treat_as_floating_point_p ]
377 [ chrono-run-header2 traits/duration_values_pass.cpp : traits_duration_values_p ]
380 test-suite "duration"
382 [ compile-fail duration/duration_duration_fail.cpp ]
383 [ compile-fail duration/ratio_fail.cpp ]
384 [ compile-fail duration/positive_num_fail.cpp ]
385 [ chrono-compile duration/default_ratio_pass.cpp ]
386 [ chrono-compile duration/types_pass.cpp ]
387 [ chrono-compile duration/ratio_alias_pass.cpp ]
388 [ chrono-compile duration/typedefs_pass.cpp ]
389 [ chrono-run-header duration/arithmetic_pass.cpp ]
390 [ chrono-run-header duration/duration_cast_pass.cpp ]
391 [ compile-fail duration/duration_cast_int_fail.cpp ]
392 [ chrono-run-header duration/comparisons_pass.cpp ]
393 [ chrono-run-header duration/constructor_pass.cpp ]
394 [ compile-fail duration/cons/convert_float_to_int_fail.cpp ]
395 [ compile-fail duration/cons/convert_inexact_fail.cpp ]
396 [ compile-fail duration/cons/implicit_constructot_fail.cpp ]
397 [ compile-fail duration/cons/non_implicit_convertible_rep_fail.cpp ]
398 [ compile-fail duration/cons/treat_as_floating_point_Rep2_true_fail.cpp ]
399 [ compile-fail duration/nonmember/divide_rep2_fail.cpp ]
400 [ compile-fail duration/nonmember/modulus_rep2_fail.cpp ]
401 [ compile-fail duration/nonmember/times_rep2_lhs_fail.cpp ]
402 [ compile-fail duration/nonmember/times_rep2_rhs_fail.cpp ]
403 [ chrono-run-header duration/duration_values_pass.cpp ]
404 [ chrono-run-header duration/rounding_pass.cpp ]
407 test-suite "time_point"
409 [ chrono-compile2 time_point/default_duration_pass.cpp : time_point_default_duration_p ]
410 [ compile-fail time_point/not_duration_fail.cpp : : time_point_not_duration_f ]
411 [ chrono-run-header2 time_point/arithmetic_pass.cpp : time_point_arithmetic_p ]
412 [ chrono-run-header2 time_point/arithmetic_ext_pass.cpp : time_point_arithmetic_ext_p ]
413 [ chrono-run-header2 time_point/time_point_cast_pass.cpp : time_point_time_point_cast_p ]
414 [ compile-fail time_point/time_point_cast_int_fail.cpp : : time_point_time_point_cast_int_f ]
415 [ chrono-run-header2 time_point/comparisons_pass.cpp : time_point_comparisons_p ]
416 [ compile-fail time_point/comparisons/equal_fail.cpp : : time_point_equal_f ]
417 [ compile-fail time_point/comparisons/less_fail.cpp : : time_point_less_f ]
418 [ chrono-run-header2 time_point/constructor_pass.cpp : time_point_constructor_p ]
419 [ compile-fail time_point/cons/implicit_fail.cpp : : time_point_implicit_f ]
420 [ compile-fail time_point/cons/non_implicit_convertible_duration_fail.cpp : : time_point_non_implicit_convertible_duration_f ]
421 [ chrono-run-header2 time_point/min_max_pass.cpp : time_point_min_max_p ]
426 [ chrono-run2-mt clock/clock_pass.cpp : clock_clock_p ]
427 [ chrono-run2-mt one_obj.cpp another_obj.cpp : two_obj_p ]
432 [ chrono-v1-v2-run ../example/io_ex1.cpp ]
433 [ chrono-v1-v2-run-header ../example/io_ex2.cpp ]
434 [ chrono-v1-v2-run ../example/io_ex3.cpp ]
435 [ chrono-v1-v2-run ../example/io_ex4.cpp ]
436 [ chrono-v1-v2-run ../example/io_ex5.cpp ]
437 [ chrono-v1-v2-run ../example/french.cpp ]
442 [ chrono-v1-v2-run-header io/duration_input.cpp ]
443 [ chrono-v1-v2-run-header io/duration_output.cpp ]
444 [ chrono-v1-v2-run-header io/time_point_input.cpp ]
445 [ chrono-v1-v2-run-header io/time_point_output.cpp ]
446 [ chrono-run test_7868.cpp ]
447 [ chrono-run test_11006.cpp ]
448 [ chrono-run test_11012.cpp ]
449 [ chrono-runXXX test_12176.cpp ]
454 [ chrono-run win32_test.cpp ]
460 #[ chrono-run test_7868.cpp ]
461 #[ chrono-run test_9337.cpp ]
462 #[ chrono-run test_10778.cpp ]
463 [ chrono-run test_10631.cpp ]