#!/bin/sh
set -C -e -f -u
TOP_SOURCE_DIR="`pwd`"
cd "$ADTTMP"

SOURCES="$TOP_SOURCE_DIR/Examples/ASU_Example_3_6"
MAIN=asu_example_3_6-run

cat > p.gpr <<EOF
with "opentoken";
project P is
   for Source_Dirs use ("$SOURCES");
   for Main use ("$MAIN.adb");
end P;
EOF
gnatmake -q -P p.gpr
# Name of the input file is hard-coded.
cp "$SOURCES/asu.txt" .
./$MAIN
