File: check-guile.in

package info (click to toggle)
guile-2.2 2.2.7%2B1-6
  • links: PTS
  • area: main
  • in suites: bullseye
  • size: 22,844 kB
  • sloc: ansic: 134,153; lisp: 86,182; sh: 4,472; makefile: 2,101; perl: 243; awk: 37; javascript: 9
file content (51 lines) | stat: -rw-r--r-- 1,231 bytes parent folder | download | duplicates (10)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#! /bin/sh
# Usage: check-guile [-i GUILE-INTERPRETER] [GUILE-TEST-ARGS]
# If `-i GUILE-INTERPRETER' is omitted, use ${top_builddir}/meta/guile.
# See ${top_srcdir}/test-suite/guile-test for documentation on GUILE-TEST-ARGS.
#
# Example invocations:
# ./check-guile
# ./check-guile numbers.test
# ./check-guile -i /usr/local/bin/guile
# ./check-guile -i /usr/local/bin/guile numbers.test

set -e

top_builddir=@top_builddir_absolute@
top_srcdir=@top_srcdir_absolute@

TEST_SUITE_DIR=${top_srcdir}/test-suite
export TEST_SUITE_DIR

if [ x"$1" = x-i ] ; then
    guile=$2
    shift
    shift
else
    guile=${top_builddir}/meta/guile
fi

GUILE_LOAD_PATH=$TEST_SUITE_DIR
export GUILE_LOAD_PATH

if [ -f "$guile" -a -x "$guile" ] ; then
    echo Testing $guile ... "$@"
    echo with GUILE_LOAD_PATH=$GUILE_LOAD_PATH
else
    echo ERROR: Cannot execute $guile
    exit 1
fi

# documentation searching ignores GUILE_LOAD_PATH.
if [ ! -f guile-procedures.txt ] ; then
   @LN_S@ libguile/guile-procedures.txt .
fi

exec $guile \
    --debug \
    -L "$TEST_SUITE_DIR" \
    --no-auto-compile -e main -s "$TEST_SUITE_DIR/guile-test" \
    --test-suite "$TEST_SUITE_DIR/tests" \
    --log-file check-guile.log "$@"

# check-guile ends here