pineapple-src/externals/vcpkg/packages/boost-build_x64-windows/tools/boost-build/example/time
2022-11-05 15:35:56 +01:00
..
hello.cpp early-access version 3088 2022-11-05 15:35:56 +01:00
jamroot.jam early-access version 3088 2022-11-05 15:35:56 +01:00
readme.qbk early-access version 3088 2022-11-05 15:35:56 +01:00

[/
Copyright 2017 Rene Rivera
Distributed under the Boost Software License, Version 1.0.
(See accompanying file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt)
]

[section Time Action]

This example shows how to use the `testing.time` utility to show time
information for building a target.

Files:

* [@../../example/time/jamroot.jam jamroot.jam]
* [@../../example/time/hello.cpp hello.cpp]

Our `jamroot.jam` specifies the target we build and the `time`
declaration to time the target we build:

[import jamroot.jam]

[jamroot]

Building the example yields:

[teletype]
```
> cd /example/time
> b2
...found 9 targets...
...updating 6 targets...
common.mkdir bin
common.mkdir bin/clang-darwin-4.2.1
common.mkdir bin/clang-darwin-4.2.1/debug
clang-darwin.compile.c++ bin/clang-darwin-4.2.1/debug/hello.o
clang-darwin.link bin/clang-darwin-4.2.1/debug/hello
testing.time bin/clang-darwin-4.2.1/debug/hello.time
user: [hello] 0.013509
system: [hello] 0.045641
clock: [hello] 0.000000
...updated 6 targets...
```

[note The actual paths in the `bin` sub-directory will depend on your
toolset.]

[endsect]