lib/Tools/makeall
author kleing
Fri, 21 Jun 2002 12:35:33 +0200
changeset 13235 c26fc3baeffc
parent 13229 a2b09d99e5cf
child 13834 4d50cf8ea3d7
permissions -rwxr-xr-x
fail not so early, but produce correct exit code in the end

#!/usr/bin/env bash
#
# $Id$
# Author: Markus Wenzel, TU Muenchen
# License: GPL (GNU GENERAL PUBLIC LICENSE)
#
# DESCRIPTION: apply make utility to all logics

## global settings

ALL_LOGICS="CCL CTT Cube FOL FOLP HOL HOLCF LCF Pure Sequents ZF"


## diagnostics

PRG="$(basename "$0")"

function usage()
{
  echo
  echo "Usage: $PRG [ARGS ...]"
  echo
  echo "  Apply isatool make to all logics (passing ARGS)."
  echo
  exit 1
}

function fail()
{
  echo "$1" >&2
  exit 2
}

## main

[ "$1" = "-?" ] && usage

FAIL=""

echo "Started at $(date) ($ML_IDENTIFIER on $(hostname))"

for L in $ALL_LOGICS
do
  ( cd "$ISABELLE_HOME/src/$L"; "$ISATOOL" make "$@" ) || FAIL="$FAIL$L "
done

echo -n "Finished at "; date

ELAPSED=$("$ISABELLE_HOME/lib/scripts/showtime" "$SECONDS")
echo "$ELAPSED total elapsed time"

[ "$FAIL" == "" ] || fail "Logics ${FAIL}FAILED!"