]> git.ipfire.org Git - thirdparty/automake.git/commitdiff
Merge branch 'master' into testsuite-work
authorStefano Lattarini <stefano.lattarini@gmail.com>
Sun, 15 May 2011 13:38:14 +0000 (15:38 +0200)
committerStefano Lattarini <stefano.lattarini@gmail.com>
Sun, 15 May 2011 13:38:14 +0000 (15:38 +0200)
* master:
  testsuite: be more cross-compile friendly
  tests: fix portability issues in 'repeated-options.test'

1  2 
ChangeLog
tests/defs

diff --cc ChangeLog
index 7859a4e5bcbef7738cff055ff6181586424e9836,b3a1e7e43cc14ee0da2ca7ee5db502b4b9ed7dba..764a99aae8a36002b6d2b294266a10ebc118ec38
+++ b/ChangeLog
@@@ -1,14 -1,19 +1,30 @@@
+ 2011-05-15  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       testsuite: be more cross-compile friendly
+       * tests/defs.in (cross_compiling): New subroutine.
+       (am__tool_prefix): New internal variable.
+       (gcc, g++, gcj): Force the use of the correct "tool prefix"
+       when cross compiling.
+       (gfortran, g77, non-cross): New requirements.
+ 2011-05-15  Stefano Lattarini  <stefano.lattarini@gmail.com>
+       tests: fix portability issues in 'repeated-options.test'
+       * tests/repeated-options.test: Do not assume that object files
+       have `.o' suffix and executables have no default suffix; instead,
+       use `$(OBJEXT)' and `$(EXEEXT)'.
 +2011-05-07  Stefano Lattarini  <stefano.lattarini@gmail.com>
 +
 +      tests: fix spurious failure of extradep.test on FreeBSD
 +      * tests/extradep.test: When using `ls -t' to determine whether a
 +      file has been updated, make sure to use as reference a file whose
 +      timestamp is expected to be *strictly* older that that of the file
 +      being checked.  This is required because at least FreeBSD `ls' do
 +      not sort files with the same timestamp in alphabetical order when
 +      using the `-t' option.
 +      * tests/extradep2.test: Likewise.
 +
  2011-05-07  Stefano Lattarini  <stefano.lattarini@gmail.com>
  
        tests: fix spurious failure of txinfo21.test on FreeBSD
diff --cc tests/defs
index d2f1284661fbbb2da2a171ad54b527df4dfef9f4,3be8eade138374112448e4a90c8058bb55beb90b..e4e3cc1a24a717300a6532b315dbb56a4c3c3e22
        # always use it.  This is important only when the user
        # has defined CC in his environment, otherwise ./configure will
        # prefer gcc to other compilers.
-       CC=gcc
+       CC=${am__tool_prefix}gcc
        export CC
        echo "$me: running $CC --version"
 -      $CC --version || exit 77
 +      $CC --version || skip_ "GNU C compiler not available"
        echo "$me: running $CC -v"
 -      $CC -v || exit 77
 +      $CC -v || skip_ "botched installation for GNU C compiler"
        ;;
      gcj)
-       GCJ=gcj
+       GCJ=${am__tool_prefix}gcj
        export GCJ
        echo "$me: running $GCJ --version"
 -      $GCJ --version || exit 77
 +      $GCJ --version || skip_ "GNU Java compiler not available"
        echo "$me: running $GCJ -v"
 -      $GCJ -v || exit 77
 +      $GCJ -v || skip_ "botched installation for GNU Java compiler"
        ;;
      g++)
-       CXX=g++
+       CXX=${am__tool_prefix}g++
        export CXX
        echo "$me: running $CXX --version"
 -      $CXX --version || exit 77
 +      $CXX --version || skip_ "GNU C++ compiler not available"
        echo "$me: running $CXX -v"
 -      $CXX -v || exit 77
 +      $CXX -v || skip_ "botched installation for GNU C++ compiler"
        ;;
+     gfortran)
+       FC=${am__tool_prefix}gfortran
+       export FC
+       echo "$me: running $FC --version"
+       $FC --version || skip_ "GNU Fortran compiler not available"
+       echo "$me: running $FC -v"
+       $FC -v || skip_ "botched installation for GNU Fortran compiler"
+       case " $required " in
+         *\ g77\ *) ;;
+         *) F77=$FC; export F77;;
+       esac
+       ;;
+     g77)
+       F77=${am__tool_prefix}g77
+       export F77
+       echo "$me: running $F77 --version"
+       $F77 --version || skip_ "GNU Fortran 77 compiler not available"
+       echo "$me: running $F77 -v"
+       $F77 -v || skip_ "botched installation for GNU Fortran 77 compiler"
+       case " $required " in
+         *\ gfortran\ *) ;;
+         *) FC=$F77; export FC;;
+       esac
+       ;;
      icc)
        CC=icc
        export CC
        ;;
      perl-threads)
        if test "$WANT_NO_THREADS" = "yes"; then
 -        echo "$me: skip with Devel::Cover: cannot cope with threads" >&2
 -        exit 77
 +        skip_ "Devel::Cover cannot cope with threads"
        fi
        ;;
+     non-cross)
+       cross_compiling && skip_ "doesn't work in cross-compile mode"
+       ;;
      python)
        # Python doesn't support --version, it has -V
        echo "$me: running python -V"