summaryrefslogtreecommitdiff
path: root/gnu/egcs/libstdc++/tests/configure.in
blob: 06c56192beb5d93bab246d8ba1f241e0e435a707 (plain)
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# This file is a shell script fragment that supplies the information
# necessary for a configure script to process the program in
# this directory.  For more information, look at ../../configure.

configdirs=
srctrigger=tcomplex.cc
srcname="tests for ANSI C++ library"
package_makefile_frag=Make.pack
package_makefile_rules_frag=Make.pack.r

# per-host:

# per-target:

target_makefile_frag=../target-mkfrag

TO_TOPDIR=../../
ALL=' '
XCXXINCLUDES="-I${srcdir}/.. -I${srcdir}/../stl -I${TO_TOPDIR}libio -I${srcdir}/${TO_TOPDIR}libio"
SIMPLE_TESTS='tstring tlist tmap tvector'
TESTS="tcomplex ${SIMPLE_TESTS}"
MOSTLYCLEAN="*.o core ${TESTS} *.out"
(. ${srcdir}/${TO_TOPDIR}libio/config.shared) >${package_makefile_frag} 2>${package_makefile_rules_frag}

# post-target:

CHECK=""

for TEST in ${SIMPLE_TESTS} ; do
  echo "${TEST}: ${TEST}.o" '$(DEPLIBS)
	$(CXX) $(CXXFLAGS) -o' "${TEST} ${TEST}.o" '$(LDLIBS)
' >> Makefile
done

for TEST in ${TESTS} ; do
  echo ".PHONY: check-${TEST}" >>Makefile
  if [ -f ${srcdir}/${TEST}.inp ] ; then
    echo "check-${TEST}: ${TEST}" '$(srcdir)'"/${TEST}.inp
	./${TEST} < "'$(srcdir)'"/${TEST}.inp > ${TEST}.out 2>&1" >>Makefile
  else
    echo "check-${TEST}: ${TEST}
	./${TEST} > ${TEST}.out 2>&1"  >>Makefile
  fi
  echo '	diff -c $(srcdir)/'"${TEST}.exp ${TEST}.out"  >>Makefile
  CHECK="${CHECK} check-${TEST}"
done

if [ "${srcdir}" = "." ] ; then
  if [ "${with_target_subdir}" != "." ] ; then
    topsrcdir=${with_multisrctop}../../..
  else
    topsrcdir=${with_multisrctop}../..
  fi
else
  topsrcdir=${srcdir}/../..
fi

if [ -d ${topsrcdir}/gcc ] ; then
  echo "
check:
check-old: ${CHECK}" >>Makefile
else
  echo "
check: ${CHECK}" >>Makefile
fi