Kaydet (Commit) 9d665739 authored tarafından Jan Holesovsky's avatar Jan Holesovsky

Don't override CC and CXX on Windows when set, handle ccache.

This is to allow use of ccache by specifying something like:

  export CC="ccache C:/path/to/cl.exe"
  export CXX="ccache C:/patch/to/cl.exe"

before running ./autogen.sh
üst 15a1260b
......@@ -2131,7 +2131,7 @@ if test "$_os" = "WINNT"; then
else
with_cl_home=`cygpath -u "$with_cl_home"`
fi
AC_MSG_RESULT([done])
AC_MSG_RESULT([$with_cl_home])
dnl ===========================================================
dnl Check for mspdb80.dll/mspdb100.dll
......@@ -2172,27 +2172,29 @@ if test "$_os" = "WINNT"; then
PATH="$MSPDB_PATH:$PATH"
AC_MSG_CHECKING([the Microsoft C/C++ Compiler])
if test "$CL_X64" = ""; then
if test -x "$with_cl_home/bin/cl.exe"; then
CC="$with_cl_home/bin/cl.exe"
if test -z "$CC"; then
if test "$CL_X64" = ""; then
if test -x "$with_cl_home/bin/cl.exe"; then
CC="$with_cl_home/bin/cl.exe"
fi
else
if test -x "$with_cl_home/bin/amd64/cl.exe"; then
CC="$with_cl_home/bin/amd64/cl.exe"
fi
fi
else
if test -x "$with_cl_home/bin/amd64/cl.exe"; then
CC="$with_cl_home/bin/amd64/cl.exe"
if test -z "$CC"; then
AC_PATH_PROG(CC, cl.exe)
fi
fi
if test -z "$CC"; then
AC_PATH_PROG(CC, cl.exe)
fi
if test -e "$CC"; then
# This gives us a posix path with 8.3 filename restrictions
CC=`cygpath -d "$CC"`
CC=`cygpath -u "$CC"`
fi
if test -n "$CC"; then
# Remove /cl.exe from CC case insensitive
AC_MSG_RESULT([found ($CC)])
if test "$CL_X64" = ""; then
COMPATH=`echo $CC | $SED 's@\/[[Bb]][[Ii]][[Nn]]\/[[cC]][[lL]]\.[[eE]][[xX]][[eE]]@@'`
COMPATH=`echo $CC | $SED -e 's@\/[[Bb]][[Ii]][[Nn]]\/[[cC]][[lL]]\.[[eE]][[xX]][[eE]].*@@' -e 's@^.* @@'`
else
if test -n "$with_cl_home"; then
COMPATH=`echo $with_cl_home`
......@@ -2427,7 +2429,7 @@ dnl ===================================================================
dnl Testing for c++ compiler and version...
dnl ===================================================================
if test "$_os" = "WINNT" -a "$WITH_MINGW" != "yes"; then
if test -e "$CC"; then
if test -n "$CC" -a -z "$CXX"; then
CXX="$CC"
fi
fi
......
......@@ -125,12 +125,8 @@ $JDK = '@JDK@';
$JAVAFLAGS = '@JAVAFLAGS@';
$MINGW = '@WITH_MINGW@'; # use MinGW for Windows build
$USE_MINGW = '@USE_MINGW@'; # use MinGW in cygwin or pure-mingw
if ( $MINGW eq "yes" )
{ $CC = '@CC@'; # C compiler
$CXX = '@CXX@'; } # C++ compiler
else
{ $CC = PathFormat('@CC@'); # C compiler
$CXX = PathFormat('@CXX@'); } # C++ compiler
$CC = '@CC@'; # C compiler
$CXX = '@CXX@'; # C++ compiler
$MOZILLA_VERSION = '@MOZILLA_VERSION@'; # mozilla version to use to build mozilla
$MOZILLA_TOOLKIT = '@MOZILLA_TOOLKIT@'; # GUI toolkit to use to build mozilla
$FLIPCMD = ""; # Flip '/' to '\' wrapper (only for winnt)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment