Manuel Pégourié-Gonnard | 1d552e7 | 2016-01-04 16:49:09 +0100 | [diff] [blame] | 1 | #!/bin/sh |
| 2 | |
| 3 | # Make sure the doxygen documentation builds without warnings |
Bence Szépkúti | 700ee44 | 2020-05-26 00:33:31 +0200 | [diff] [blame^] | 4 | # |
| 5 | # Copyright (C) 2016, Arm Limited, All Rights Reserved |
| 6 | # |
| 7 | # This file is part of Mbed TLS (https://tls.mbed.org) |
Manuel Pégourié-Gonnard | 1d552e7 | 2016-01-04 16:49:09 +0100 | [diff] [blame] | 8 | |
| 9 | # Abort on errors (and uninitiliased variables) |
| 10 | set -eu |
| 11 | |
| 12 | if [ -d library -a -d include -a -d tests ]; then :; else |
| 13 | echo "Must be run from mbed TLS root" >&2 |
| 14 | exit 1 |
| 15 | fi |
| 16 | |
Manuel Pégourié-Gonnard | d091ed1 | 2016-01-12 14:17:52 +0000 | [diff] [blame] | 17 | if scripts/apidoc_full.sh > doc.out 2>doc.err; then :; else |
Manuel Pégourié-Gonnard | 1d552e7 | 2016-01-04 16:49:09 +0100 | [diff] [blame] | 18 | cat doc.err |
| 19 | echo "FAIL" >&2 |
| 20 | exit 1; |
| 21 | fi |
| 22 | |
Manuel Pégourié-Gonnard | de7ae7b | 2016-01-08 16:47:33 +0100 | [diff] [blame] | 23 | cat doc.out doc.err | \ |
| 24 | grep -v "warning: ignoring unsupported tag" \ |
| 25 | > doc.filtered |
| 26 | |
Manuel Pégourié-Gonnard | d091ed1 | 2016-01-12 14:17:52 +0000 | [diff] [blame] | 27 | if egrep "(warning|error):" doc.filtered; then |
Manuel Pégourié-Gonnard | 1d552e7 | 2016-01-04 16:49:09 +0100 | [diff] [blame] | 28 | echo "FAIL" >&2 |
| 29 | exit 1; |
| 30 | fi |
| 31 | |
| 32 | make apidoc_clean |
Manuel Pégourié-Gonnard | de7ae7b | 2016-01-08 16:47:33 +0100 | [diff] [blame] | 33 | rm -f doc.out doc.err doc.filtered |