OSDN Git Service

Update configure.in/configure.
[pf3gnuchains/gcc-fork.git] / contrib / test_installed
index e7814d2..7a363d6 100755 (executable)
@@ -1,17 +1,17 @@
 #! /bin/sh
 
-# (C) 1998 Free Software Foundation
+# (C) 1998, 2000, 2002, 2003 Free Software Foundation
 # Originally by Alexandre Oliva <oliva@dcc.unicamp.br>
 
 # This script is Free Software, and it can be copied, distributed and
 # modified as defined in the GNU General Public License.  A copy of
 # its license can be downloaded from http://www.gnu.org/copyleft/gpl.html
 
-# This scripts assumes it lives in the contrib directory of the egcs
+# This scripts assumes it lives in the contrib directory of the GCC
 # source tree, so it will find the testsuite tree from its location.
 # If you move it elsewhere, or want to use another testsuite tree, you
-# can override the defaults with --srcdir=/some/dir/egcs or
-# --testsuite=/some/dir/egcs/gcc/testsuite.  If you specify
+# can override the defaults with --srcdir=/some/dir/GCC or
+# --testsuite=/some/dir/GCC/gcc/testsuite.  If you specify
 # --testsuite, --srcdir will be ignored; otherwise, `/gcc/testsuite'
 # will be appended to the srcdir.
 
@@ -54,11 +54,12 @@ while true; do
   --without-gcc) GCC_UNDER_TEST=no; shift;;
   --without-g++) GXX_UNDER_TEST=no; shift;;
   --without-g77) G77_UNDER_TEST=no; shift;;
+  --without-objc) OBJC_UNDER_TEST=no; shift;;
 
   --tmpdir=*) tmpdir=`echo "$1" | sed 's/[^=]*=//'`; shift;;
 
   --help) cat <<\EOF
-Runs the testsuite for an installed version of gcc/g++/g77
+Runs the testsuite for an installed version of gcc/g++/g77/objc
 Copyright (C) 1998  Free Software Foundation
 by Alexandre Oliva <oliva@dcc.unicamp.br>
 
@@ -77,6 +78,7 @@ Supported arguments:
 --without-gcc                 do not run gcc testsuite
 --without-g++                 do not run g++ testsuite
 --without-g77                 do not run g77 testsuite
+--without-objc                do not run objc testsuite
 
 --tmpdir=/some/dir            create temporaries and leave failed programs
                               at specified directory [.]
@@ -96,19 +98,24 @@ if test x"${testsuite+set}" != x"set" && test x"${srcdir+set}" != x"set"; then
   while [ -h $file ]; do
     file=`ls -l $file | sed s/'.* -> '//`
   done
-  srcdir=`CDPATH=. && cd \`echo "$file" | sed 's,/*[^/]*$,,;s,^$,.,'\`/.. >/dev/null && pwd`
+  srcdir=`CDPATH=. && cd \`echo "$file" | sed 's,/*[^/]*$,,;s,^$,.,'\`/.. >/dev/null && ${PWDCMD-pwd}`
 fi
 
 cat >site.exp <<EOF
-set tmpdir "${tmpdir-`pwd`}"
+set rootme "."
+set tmpdir "${tmpdir-`${PWDCMD-pwd}`}"
 set srcdir "${testsuite-${srcdir}/gcc/testsuite}"
+set CFLAGS ""
+set CXXFLAGS ""
 set GCC_UNDER_TEST "${GCC_UNDER_TEST-${prefix}${prefix+/bin/}gcc}"
 set GXX_UNDER_TEST "${GXX_UNDER_TEST-${prefix}${prefix+/bin/}g++}"
 set G77_UNDER_TEST "${G77_UNDER_TEST-${prefix}${prefix+/bin/}g77}"
+set OBJC_UNDER_TEST "${OBJC_UNDER_TEST-${prefix}${prefix+/bin/}gcc}"
 EOF
 
 test x"${GCC_UNDER_TEST}" = x"no" || runtest --tool gcc ${1+"$@"}
 test x"${GXX_UNDER_TEST}" = x"no" || runtest --tool g++ ${1+"$@"}
 test x"${G77_UNDER_TEST}" = x"no" || runtest --tool g77 ${1+"$@"}
+test x"${OBJC_UNDER_TEST}" = x"no" || runtest --tool objc ${1+"$@"}
 
 exit 0