• Home
Name Date Size #Lines LOC

..--

hello.cppD12-May-2024311 176

jamroot.jamD12-May-2024406 1713

readme.qbkD12-May-20241.1 KiB4836

readme.qbk

1[/
2Copyright 2017 Rene Rivera
3Distributed under the Boost Software License, Version 1.0.
4(See accompanying file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt)
5]
6
7[section Time Action]
8
9This example shows how to use the `testing.time` utility to show time
10information for building a target.
11
12Files:
13
14* [@../../example/time/jamroot.jam jamroot.jam]
15* [@../../example/time/hello.cpp hello.cpp]
16
17Our `jamroot.jam` specifies the target we build and the `time`
18declaration to time the target we build:
19
20[import jamroot.jam]
21
22[jamroot]
23
24Building the example yields:
25
26[teletype]
27```
28> cd /example/time
29> b2
30...found 9 targets...
31...updating 6 targets...
32common.mkdir bin
33common.mkdir bin/clang-darwin-4.2.1
34common.mkdir bin/clang-darwin-4.2.1/debug
35clang-darwin.compile.c++ bin/clang-darwin-4.2.1/debug/hello.o
36clang-darwin.link bin/clang-darwin-4.2.1/debug/hello
37testing.time bin/clang-darwin-4.2.1/debug/hello.time
38user: [hello] 0.013509
39system: [hello] 0.045641
40clock: [hello] 0.000000
41...updated 6 targets...
42```
43
44[note The actual paths in the `bin` sub-directory will depend on your
45toolset.]
46
47[endsect]
48