From: Ian Lance Taylor Date: Wed, 13 Sep 1995 20:35:17 +0000 (+0000) Subject: * Makefile.in (EXPECT): New variable. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=5f757edc84fb6d5db2e2b91c342b14c3d96ef92f;p=binutils-gdb.git * Makefile.in (EXPECT): New variable. (CHECKFLAGS): Remove. (site.exp): New target. (check): Rewrite to invoke runtest directly, rather than recurring down into testsuite. (clean-here): Remove testsuite directory. (clean, distclean): Don't recur into testsuite. * configure.in: Don't call AC_CONFIG_SUBDIRS(testsuite). * configure: Rebuild. --- diff --git a/gas/ChangeLog b/gas/ChangeLog index 08065c0e8ba..894c4fa83af 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,5 +1,15 @@ Wed Sep 13 12:33:03 1995 Ian Lance Taylor + * Makefile.in (EXPECT): New variable. + (CHECKFLAGS): Remove. + (site.exp): New target. + (check): Rewrite to invoke runtest directly, rather than recurring + down into testsuite. + (clean-here): Remove testsuite directory. + (clean, distclean): Don't recur into testsuite. + * configure.in: Don't call AC_CONFIG_SUBDIRS(testsuite). + * configure: Rebuild. + * write.c (relax_and_size_seg): Change to the segment we are relaxing, in case md_convert_frag, called by cvt_frag_to_fill, wants to call fix_new. diff --git a/gas/Makefile.in b/gas/Makefile.in index 88dbabfb740..2fd03391567 100644 --- a/gas/Makefile.in +++ b/gas/Makefile.in @@ -76,6 +76,10 @@ CFLAGS = -g MAKEOVERRIDES= +EXPECT = `if [ -f $${rootme}/../expect/expect ] ; then \ + echo $${rootme}/../expect/expect ; \ + else echo expect ; fi` + FLAGS_TO_PASS = \ "prefix=$(prefix)" \ "exec_prefix=$(exec_prefix)" \ @@ -98,9 +102,6 @@ RUNTEST = `if [ -f ${srcdir}/../dejagnu/runtest ] ; then \ echo ${srcdir}/../dejagnu/runtest ; else echo runtest; \ fi` RUNTESTFLAGS= -CHECKFLAGS= \ - "RUNTESTFLAGS=$(RUNTESTFLAGS)" \ - "RUNTEST=$(RUNTEST)" # Lists of files for various purposes. @@ -261,9 +262,48 @@ gasp.new: $(GASPOBJS) ../libiberty/libiberty.a installcheck: @echo No installcheck target is available yet for the GNU assembler. -check: - @(here=`pwd` ; export here ; \ - cd testsuite ; $(MAKE) $(FLAGS_TO_PASS) $(CHECKFLAGS) check) +site.exp: ./Makefile + @echo "Making a new config file..." + -@rm -f ./tmp? + @touch site.exp + -@mv site.exp site.bak + @echo "## these variables are automatically generated by make ##" > ./tmp0 + @echo "# Do not edit here. If you wish to override these values," >> ./tmp0 + @echo "# do so in the last section." >> ./tmp0 + @echo set host_os @host_os@ >> ./tmp0 + @echo set host_alias @host_alias@ >> ./tmp0 + @echo set host_cpu @host_cpu@ >> ./tmp0 + @echo set host_vendor @host_vendor@ >> ./tmp0 + @echo set target_os @target_os@ >> ./tmp0 + @echo set target_alias @target_alias@ >> ./tmp0 + @echo set target_cpu @target_cpu@ >> ./tmp0 + @echo set target_vendor @target_vendor@ >> ./tmp0 + @echo set host_triplet @host@ >> ./tmp0 + @echo set target_triplet @target@ >> ./tmp0 + @echo set target_canonical @target@ >> ./tmp0 + @echo set srcdir ${srcdir} >> ./tmp0 + @echo set exec_prefix ${exec_prefix} >> ./tmp0 + @echo set objdir `pwd` >> ./tmp0 + @echo "## All variables above are generated by configure. Do Not Edit ##" >> ./tmp0 + @sed -e '1,/^## All variables above are.*##/ d' < site.bak >> ./tmp0 + @mv -f ./tmp0 site.exp + +check: site.exp + if [ -d testsuite ]; then \ + true; \ + else \ + mkdir testsuite; \ + fi + rm -f testsuite/site.exp + cp site.exp testsuite/site.exp + rootme=`pwd`; export rootme; \ + srcdir=`cd ${srcdir}; pwd` ; export srcdir ; \ + cd testsuite; \ + EXPECT=${EXPECT} ; export EXPECT ; \ + if [ -f $${rootme}/../expect/expect ] ; then \ + TCL_LIBRARY=$${srcdir}/../tcl/library ; \ + export TCL_LIBRARY ; fi ; \ + $(RUNTEST) --tool gas --srcdir $${srcdir}/testsuite $(RUNTESTFLAGS) config.status: configure if [ -r config.status ]; then \ @@ -379,19 +419,14 @@ diststuff: $(DISTSTUFF) clean-here: -rm -f $(STAGESTUFF) core stamp-mk.com + -rm -rf testsuite clean mostlyclean: clean-here @cd doc ; $(MAKE) $(FLAGS_TO_PASS) $@ - @if [ -d testsuite ] ; then \ - cd testsuite ; $(MAKE) $(FLAGS_TO_PASS) $@ ; \ - else true; fi # Like clean but also delete the links made to configure gas. distclean: clean-here @cd doc ; $(MAKE) $(FLAGS_TO_PASS) $@ - @if [ -d testsuite ] ; then \ - cd testsuite ; $(MAKE) $(FLAGS_TO_PASS) $@ ; \ - else true; fi -rm -f config.status Makefile targ-env.h targ-cpu.h \ targ-cpu.c obj-format.h obj-format.c atof-targ.c TAGS \ config-stamp config.h conf config.log config.cache .gdbinit diff --git a/gas/configure b/gas/configure index 91d61dc825c..34064ced12a 100755 --- a/gas/configure +++ b/gas/configure @@ -775,8 +775,8 @@ for this_target in $target $canon_targets ; do rce-*-aout) fmt=aout ;; # end-sanitize-rce - ns32k-pc532-mach*) fmt=aout em=pc532mach ;; - ns32k-pc532-netbsd*) fmt=aout em=nbsd532 ;; + ns32k-pc532-mach* | ns32k-pc532-ux*) fmt=aout em=pc532mach ;; + ns32k-pc532-netbsd* | ns32k-pc532-lites*) fmt=aout em=nbsd532 ;; sparc-*-sunos4*) fmt=aout em=sun3 ;; sparc-*-aout | sparc*-*-vxworks) @@ -827,6 +827,17 @@ for this_target in $target $canon_targets ; do *) ;; esac +# Other random stuff. + + test -n "$want_sparcv9" && cat >> confdefs.h <<\EOF +#define sparcv9 1 +EOF + + + case ${cpu_type} in + m68k) extra_objects="$extra_objects m68k-parse.o" ;; + esac + # See if we really can support this configuration with the emulation code. if test $this_target = $target ; then @@ -860,17 +871,6 @@ for this_target in $target $canon_targets ; do emulations="$emulations $emulation" -# Other random stuff. - - test -n "$want_sparcv9" && cat >> confdefs.h <<\EOF -#define sparcv9 1 -EOF - - - case ${cpu_type} in - m68k) extra_objects="$extra_objects m68k-parse.o" ;; - esac - done # Assign floating point type. Most processors with FP support @@ -1809,7 +1809,7 @@ $gas_test_headers int main() { return 0; } int t() { -typedef int f; +typedef void (*f)(); f x; x = (f) free; @@ -1877,9 +1877,6 @@ EOF } -subdirs="testsuite" - - trap '' 1 2 15 cat > confcache <<\EOF # This file is a shell script that caches the results of configure @@ -2012,7 +2009,6 @@ s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g s%@INSTALL_DATA@%$INSTALL_DATA%g s%@CPP@%$CPP%g s%@ALLOCA@%$ALLOCA%g -s%@subdirs@%$subdirs%g CEOF EOF @@ -2223,99 +2219,3 @@ chmod +x $CONFIG_STATUS rm -fr confdefs* $ac_clean_files test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 -if test "$no_recursion" != yes; then - - # Remove --cache-file and --srcdir arguments so they do not pile up. - ac_sub_configure_args= - ac_prev= - for ac_arg in $ac_configure_args; do - if test -n "$ac_prev"; then - ac_prev= - continue - fi - case "$ac_arg" in - -cache-file | --cache-file | --cache-fil | --cache-fi \ - | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) - ac_prev=cache_file ;; - -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ - | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) - ;; - -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) - ac_prev=srcdir ;; - -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) - ;; - *) ac_sub_configure_args="$ac_sub_configure_args $ac_arg" ;; - esac - done - - for ac_config_dir in testsuite; do - - # Do not complain, so a configure script can configure whichever - # parts of a large source tree are present. - if test ! -d $srcdir/$ac_config_dir; then - continue - fi - - echo configuring in $ac_config_dir - - case "$srcdir" in - .) ;; - *) - if test -d ./$ac_config_dir || mkdir ./$ac_config_dir; then :; - else - { echo "configure: error: can not create `pwd`/$ac_config_dir" 1>&2; exit 1; } - fi - ;; - esac - - ac_popdir=`pwd` - cd $ac_config_dir - - case "$srcdir" in - .) # No --srcdir option. We are building in place. - ac_sub_srcdir=$srcdir ;; - /*) # Absolute path. - ac_sub_srcdir=$srcdir/$ac_config_dir ;; - *) # Relative path. - ac_sub_srcdir=../$srcdir/$ac_config_dir ;; - esac - - # Check for guested configure; otherwise get Cygnus style configure. - if test -f $ac_sub_srcdir/configure; then - ac_sub_configure=$ac_sub_srcdir/configure - elif test -f $ac_sub_srcdir/configure.in; then - ac_sub_configure=$ac_configure - else - echo "configure: warning: no configuration information is in $ac_config_dir" 1>&2 - ac_sub_configure= - fi - - # The recursion is here. - if test -n "$ac_sub_configure"; then - - # Make the cache file name correct relative to the subdirectory. - # A "../" for each directory in /$ac_config_dir. - ac_dots=`echo $ac_config_dir|sed -e 's%^\./%%' -e 's%[^/]$%&/%' -e 's%[^/]*/%../%g'` - case "$cache_file" in - /*) ac_sub_cache_file=$cache_file ;; - *) # Relative path. - ac_sub_cache_file="$ac_dots$cache_file" ;; - esac - case "$ac_given_INSTALL" in - [/$]*) INSTALL="$ac_given_INSTALL" ;; - *) INSTALL="$ac_dots$ac_given_INSTALL" ;; - esac - - echo "running ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir" - # The eval makes quoting arguments work. - if eval ${CONFIG_SHELL-/bin/sh} $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_sub_srcdir - then : - else - { echo "configure: error: $ac_sub_configure failed for $ac_config_dir" 1>&2; exit 1; } - fi - fi - - cd $ac_popdir - done -fi - diff --git a/gas/configure.in b/gas/configure.in index bb9034981db..e1fa002cb18 100644 --- a/gas/configure.in +++ b/gas/configure.in @@ -248,8 +248,8 @@ changequote([,])dnl rce-*-aout) fmt=aout ;; # end-sanitize-rce - ns32k-pc532-mach*) fmt=aout em=pc532mach ;; - ns32k-pc532-netbsd*) fmt=aout em=nbsd532 ;; + ns32k-pc532-mach* | ns32k-pc532-ux*) fmt=aout em=pc532mach ;; + ns32k-pc532-netbsd* | ns32k-pc532-lites*) fmt=aout em=nbsd532 ;; sparc-*-sunos4*) fmt=aout em=sun3 ;; sparc-*-aout | sparc*-*-vxworks) @@ -300,6 +300,14 @@ changequote([,])dnl *) ;; esac +# Other random stuff. + + test -n "$want_sparcv9" && AC_DEFINE(sparcv9) + + case ${cpu_type} in + m68k) extra_objects="$extra_objects m68k-parse.o" ;; + esac + # See if we really can support this configuration with the emulation code. if test $this_target = $target ; then @@ -333,14 +341,6 @@ changequote([,])dnl emulations="$emulations $emulation" -# Other random stuff. - - test -n "$want_sparcv9" && AC_DEFINE(sparcv9) - - case ${cpu_type} in - m68k) extra_objects="$extra_objects m68k-parse.o" ;; - esac - done # Assign floating point type. Most processors with FP support @@ -562,7 +562,7 @@ gas_test_headers=" #endif " GAS_CHECK_DECL_NEEDED(malloc, f, char *(*f)(), $gas_test_headers) -GAS_CHECK_DECL_NEEDED(free, f, int f, $gas_test_headers) +GAS_CHECK_DECL_NEEDED(free, f, void (*f)(), $gas_test_headers) # Does errno.h declare errno, or do we have to add a separate declaration # for it? @@ -572,7 +572,5 @@ GAS_CHECK_DECL_NEEDED(errno, f, int f, [ #endif ]) -AC_CONFIG_SUBDIRS(testsuite) - dnl This must come last. AC_OUTPUT(Makefile doc/Makefile .gdbinit:gdbinit.in)