Travis - don't use ccache with cross compiles
authorRichard Levitte <levitte@openssl.org>
Thu, 10 Mar 2016 01:14:55 +0000 (02:14 +0100)
committerRichard Levitte <levitte@openssl.org>
Thu, 10 Mar 2016 01:53:41 +0000 (02:53 +0100)
Although theoretically possible, Configure doesn't treat CC variable
set like this very well: CC="ccache i686-w64-mingw32-gcc"
Also, this Travis script doesn't recognise the possibility either.

Reviewed-by: Rich Salz <rsalz@openssl.org>
.travis.yml

index 332254371f4e1876250e11fe9a09a0a748a6ef8c..750db1f437c341d11326660fd77136ea4ed41d00 100644 (file)
@@ -67,9 +67,6 @@ before_script:
           srcdir=../_srcdist;
           mkdir _build;
           cd _build;
           srcdir=../_srcdist;
           mkdir _build;
           cd _build;
-          if which ccache >/dev/null; then
-              CC="ccache $CC";
-          fi
       fi
     - if [ "$CC" == i686-w64-mingw32-gcc ]; then
           export CROSS_COMPILE=${CC%%gcc}; unset CC;
       fi
     - if [ "$CC" == i686-w64-mingw32-gcc ]; then
           export CROSS_COMPILE=${CC%%gcc}; unset CC;
@@ -78,6 +75,9 @@ before_script:
           export CROSS_COMPILE=${CC%%gcc}; unset CC;
           $srcdir/Configure mingw64 $CONFIG_OPTS -Wno-pedantic-ms-format;
       else
           export CROSS_COMPILE=${CC%%gcc}; unset CC;
           $srcdir/Configure mingw64 $CONFIG_OPTS -Wno-pedantic-ms-format;
       else
+          if which ccache >/dev/null; then
+              CC="ccache $CC";
+          fi
           $srcdir/config $CONFIG_OPTS;
       fi
     - cd ..
           $srcdir/config $CONFIG_OPTS;
       fi
     - cd ..