docs(perf): Updated
[para.git] / scripts / checkchain
blob16e02838bf8a9e2fbd617b6739e988e6006c1bf3
1 #!/bin/sh
4 # Check compilers, makes, and shells.
6 # Copyright 2023 Odin Kroeger.
8 # This file is part of Para.
10 # Para is free software: you can redistribute it and/or modify it
11 # under the terms of the GNU Affero General Public License as published
12 # by the Free Software Foundation, either version 3 of the License,
13 # or (at your option) any later version.
15 # Para is distributed in the hope that it will be useful, but WITHOUT
16 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
17 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General
18 # Public License for more details.
20 # You should have received a copy of the GNU Affero General Public
21 # License along with Para. If not, see <https://www.gnu.org/licenses/>.
24 # shellcheck disable=2015
28 # Init
31 set -Ceu
32 scriptsdir="$(cd -P "$(dirname -- "$0")" && pwd)"
33 : "${scriptsdir:?}"
34 readonly scriptsdir
35 # shellcheck disable=1091
36 . "$scriptsdir/../libutil.sh" || exit
37 init || exit
41 # Options
44 OPTARG='' OPTIND=1 opt=''
45 # shellcheck disable=2034
46 while getopts dhqv opt; do
47 # shellcheck disable=2154
48 case $opt in
49 (h) exec cat <<EOF
50 $progname - check compilers, makes, and shells.
52 Usage: $progname [-d]
53 $progname -h
55 Options:
56 -d Enable debugging mode.
57 EOF
59 (d) set -x ;;
60 (*) exit 2
61 esac
62 done
63 shift $((OPTIND - 1))
64 unset opt
68 # Main
71 retval=0
73 "$scriptsdir/checkcomps" || retval=$((retval | $?))
74 "$scriptsdir/checkmakes" || retval=$((retval | $?))
75 "$scriptsdir/checkshells" || retval=$((retval | $?))
77 exit "$retval"