diff options
author | Kieran Bingham <kieran.bingham@ideasonboard.com> | 2021-08-09 13:18:20 +0100 |
---|---|---|
committer | Kieran Bingham <kieran.bingham@ideasonboard.com> | 2021-08-09 13:18:20 +0100 |
commit | e2bc66cdfe7e6ecd7f3ec78d9ff0933f90a8b535 (patch) | |
tree | ab72546babd153316b3b49f64a4a93b6abdd5c36 | |
parent | 710a46470ce2a55458a14534826adffc30da46b9 (diff) |
ci: unit-tests: Add IWYU
Provide an 'include what you use' report on the
unit-tests build
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
-rwxr-xr-x | 55-include-what-you-use.sh | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/55-include-what-you-use.sh b/55-include-what-you-use.sh new file mode 100755 index 0000000..f4a392a --- /dev/null +++ b/55-include-what-you-use.sh @@ -0,0 +1,23 @@ +#!/bin/bash + +# SPDX-License-Identifier: GPL-2.0-or-later +# + +source ./common.sh + +ID=$0 +logfile=$(log_filename $ID) + +BUILDDIR=${1:-$(builddir unit-tests)} +LIBCAMERA=$BUILDDIR/source/ + +check_version "$LIBCAMERA" "$ID" + +iwyu_tool \ + -p "$BUILDDIR" \ + -o iwyu \ + -j$(nproc) > $BUILDDIR/iwyu.report.log + +pass_fail $? "Include-what-you-use" + +completed $ID |