[Libreoffice-commits] .: configure.in set_soenv.in solenv/inc

Norbert Thiebaud nthiebaud at kemper.freedesktop.org
Sun Aug 7 18:09:51 PDT 2011


 configure.in          |  102 +++++++++++++++++++++++++-------------------------
 set_soenv.in          |    1 
 solenv/inc/unxiosr.mk |    6 --
 solenv/inc/unxmacx.mk |    6 --
 4 files changed, 57 insertions(+), 58 deletions(-)

New commits:
commit 49fa5b039d1c89db367f7c71eb1e421467181d8e
Author: Norbert Thiebaud <nthiebaud at gmail.com>
Date:   Sun Aug 7 20:09:24 2011 -0500

    remove obsolete USE_CCACHE env. prefix ccache after C[C|XX] final eval

diff --git a/configure.in b/configure.in
index 04a774b..2164117 100755
--- a/configure.in
+++ b/configure.in
@@ -1703,7 +1703,6 @@ if test "$enable_ccache" = "yes" ; then
                     CCACHE_NUMVER=`echo $CCACHE_VERSION | $AWK -F. '{ print \$1*10000+\$2*100+\$3 }'`
                     if test "$CCACHE_VERSION" = "2.4_OOo" -o "$CCACHE_NUMVER" -ge "030100"; then
                         AC_MSG_RESULT([yes])
-                        AC_SUBST([USE_CCACHE], [YES])
                     else
                         AC_MSG_RESULT([no])
                         AC_MSG_NOTICE([ccache version $CCACHE_VERSION not accepted. ccache will not be used.])
@@ -1755,25 +1754,6 @@ fi
 dnl The following checks for gcc, cc and then cl (if it weren't guarded for win32)
 if test "$_os" != "WINNT" -o "$WITH_MINGW" = "yes"; then
     AC_PROG_CC
-    if test "$CCACHE" != "" ; then
-        AC_MSG_CHECKING([whether $CC is already ccached])
-
-
-        AC_LANG_PUSH([C])
-        save_CFLAGS=$CFLAGS
-        CFLAGS="$CFLAGS --ccache-skip -O2"
-        dnl an empty program will do, we're checking the compiler flags
-        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([],[])],
-                          [use_ccache=yes], [use_ccache=no])
-        if test $use_ccache = yes ; then
-            AC_MSG_RESULT([yes])
-        else
-            CC="$CCACHE $CC"
-            AC_MSG_RESULT([no])
-        fi
-        CFLAGS=$save_CFLAGS
-        AC_LANG_POP([C])
-    fi
 fi
 
 COMPATH=`dirname "$CC"`
@@ -1922,12 +1902,8 @@ if test \( "$_os" != "WINNT" -o "$WITH_MINGW" = "yes" \) -a "$GCC" = "yes"; then
 
     if test "$_os" = "Darwin" -a "$with_macosx_sdk" = "10.4" -a "$GCCVER" -ge "040100" ; then
         if test -z "$save_CC" -a -x "$GCC_HOME/bin/gcc-4.0" ; then
-            if test -z "$CCACHE" ; then
-                export CC="$GCC_HOME/bin/gcc-4.0"
-            else
-                export CC="$CCACHE $GCC_HOME/bin/gcc-4.0"
-            fi
-            dnl  export CC to have it available in set_soenv -> config.guess
+            export CC="$GCC_HOME/bin/gcc-4.0"
+            #  export CC to have it available in set_soenv -> config.guess
             GCCVER2=`$CC -dumpversion | $AWK -F. '{ print \$1*10000+\$2*100+\$3 }'`
             if test "$GCCVER2" -ge "040000" -a "$GCCVER2" -lt "040100" ; then
                 GCCVER=$GCCVER2
@@ -1943,6 +1919,33 @@ if test \( "$_os" != "WINNT" -o "$WITH_MINGW" = "yes" \) -a "$GCC" = "yes"; then
     fi
 fi
 
+
+#
+# prefix C with ccache if needed
+#
+if test "$_os" != "WINNT" -o "$WITH_MINGW" = "yes" ; then
+    if test "$CCACHE" != "" ; then
+        AC_MSG_CHECKING([whether $CC is already ccached])
+
+
+        AC_LANG_PUSH([C])
+        save_CFLAGS=$CFLAGS
+        CFLAGS="$CFLAGS --ccache-skip -O2"
+        dnl an empty program will do, we're checking the compiler flags
+        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([],[])],
+                          [use_ccache=yes], [use_ccache=no])
+        if test $use_ccache = yes ; then
+            AC_MSG_RESULT([yes])
+        else
+            CC="$CCACHE $CC"
+            AC_MSG_RESULT([no])
+        fi
+        CFLAGS=$save_CFLAGS
+        AC_LANG_POP([C])
+    fi
+
+fi
+
 HAVE_LD_BSYMBOLIC_FUNCTIONS=
 if test "$GCC" = "yes"; then
     AC_MSG_CHECKING( for -Bsymbolic-functions linker support )
@@ -2865,26 +2868,8 @@ dnl ===================================================================
 dnl Testing for C++ compiler and version...
 dnl ===================================================================
 
-dnl Autoconf 2.53 can do this test for cl.exe, 2.13 can't!
 if test "$_os" != "WINNT" -o "$WITH_MINGW" = "yes"; then
     AC_PROG_CXX
-    if test "$CCACHE" != "" ; then
-        AC_MSG_CHECKING([whether $CXX is already ccached])
-        AC_LANG_PUSH([C++])
-        save_CXXFLAGS=$CXXFLAGS
-        CXXFLAGS="$CXXFLAGS --ccache-skip -O2"
-        dnl an empty program will do, we're checking the compiler flags
-        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([],[])],
-                          [use_ccache=yes], [use_ccache=no])
-        if test $use_ccache = yes ; then
-            AC_MSG_RESULT([yes])
-        else
-            CXX="$CCACHE $CXX"
-            AC_MSG_RESULT([no])
-        fi
-        CXXFLAGS=$save_CXXFLAGS
-        AC_LANG_POP([C++])
-    fi
 else
     if test -n "$CC" -a -z "$CXX"; then
         CXX="$CC"
@@ -2900,11 +2885,7 @@ if test "$GXX" = "yes"; then
 
     if test "$_os" = "Darwin" -a "$with_macosx_sdk" = "10.4" -a "$_gpp_majmin" -ge "401" ; then
         if test -z "$save_CXX" -a -x "$GCC_HOME/bin/g++-4.0" ; then
-            if test -z "$CCACHE" ; then
-                export CXX="$GCC_HOME/bin/g++-4.0"
-            else
-                export CXX="$CCACHE $GCC_HOME/bin/g++-4.0"
-            fi
+            export CXX="$GCC_HOME/bin/g++-4.0"
             _gpp_majmin_2=`$CXX -dumpversion | $AWK -F. '{ print \$1*100+\$2 }'`
             if test "$_gpp_majmin_2" -ge "400" -a "$_gpp_majmin_2" -lt "401" ; then
                 _gpp_majmin=$_gpp_majmin_2
@@ -2945,6 +2926,29 @@ if test "$GXX" = "yes"; then
     fi
 fi
 
+#
+# prefx CXX with ccache if needed
+#
+if test "$_os" != "WINNT" -o "$WITH_MINGW" = "yes"; then
+    if test "$CCACHE" != "" ; then
+        AC_MSG_CHECKING([whether $CXX is already ccached])
+        AC_LANG_PUSH([C++])
+        save_CXXFLAGS=$CXXFLAGS
+        CXXFLAGS="$CXXFLAGS --ccache-skip -O2"
+        dnl an empty program will do, we're checking the compiler flags
+        AC_COMPILE_IFELSE([AC_LANG_PROGRAM([],[])],
+                          [use_ccache=yes], [use_ccache=no])
+        if test $use_ccache = yes ; then
+            AC_MSG_RESULT([yes])
+        else
+            CXX="$CCACHE $CXX"
+            AC_MSG_RESULT([no])
+        fi
+        CXXFLAGS=$save_CXXFLAGS
+        AC_LANG_POP([C++])
+    fi
+fi
+
 dnl ===================================================================
 dnl Find pre-processors.(should do that _after_ messing with CC/CXX)
 dnl ===================================================================
diff --git a/set_soenv.in b/set_soenv.in
index e7906b7..cf802b3 100755
--- a/set_soenv.in
+++ b/set_soenv.in
@@ -1836,7 +1836,6 @@ ToFile( "HAVE_LD_BSYMBOLIC_FUNCTIONS",
 		"@HAVE_LD_BSYMBOLIC_FUNCTIONS@","e" );
 ToFile( "HAVE_CXX0X",        "@HAVE_CXX0X@",     "e" );
 ToFile( "CXX",               $CXX,               "e" );
-ToFile( "USE_CCACHE",        "@USE_CCACHE@",     "e" );
 ToFile( "MINGWCXX",          "@MINGWCXX@",       "e" );
 ToFile( "MINGWSTRIP",        "@MINGWSTRIP@",     "e" );
 ToFile( "WITH_STLPORT",      "@WITH_STLPORT@", "e" );
diff --git a/solenv/inc/unxiosr.mk b/solenv/inc/unxiosr.mk
index 5532560..07e6e06 100644
--- a/solenv/inc/unxiosr.mk
+++ b/solenv/inc/unxiosr.mk
@@ -53,10 +53,8 @@ CFLAGSCC=-pipe -fsigned-char $(ARCH_FLAGS)
 
 # Normal Objective C compilation flags
 OBJCFLAGS=-fexceptions -fobjc-abi-version=2 -fobjc-legacy-dispatch -D__IPHONE_OS_VERSION_MIN_REQUIRED=40300
-# -x options generally ignored by ccache, tell it that it can cache
-# the result nevertheless
-CCACHE_SKIP:=$(eq,$(USE_CCACHE),YES --ccache-skip $(NULL))
-OBJCXXFLAGS:=$(CCACHE_SKIP) -x $(CCACHE_SKIP) objective-c++ $(OBJCFLAGS)
+
+OBJCXXFLAGS:=$(OBJCFLAGS)
 
 # Comp Flags for files that need exceptions enabled (C and C++)
 CFLAGSEXCEPTIONS=-fexceptions -fno-enforce-eh-specs
diff --git a/solenv/inc/unxmacx.mk b/solenv/inc/unxmacx.mk
index cbd30ca..0f03b1c 100644
--- a/solenv/inc/unxmacx.mk
+++ b/solenv/inc/unxmacx.mk
@@ -99,10 +99,8 @@ CFLAGSCC=-pipe -fsigned-char -malign-natural $(ARCH_FLAGS)
 # Normal Objective C compilation flags
 #OBJCFLAGS=-no-precomp
 OBJCFLAGS=-fobjc-exceptions
-# -x options generally ignored by ccache, tell it that it can cache
-# the result nevertheless
-CCACHE_SKIP:=$(eq,$(USE_CCACHE),YES --ccache-skip $(NULL))
-OBJCXXFLAGS:=$(CCACHE_SKIP) -x $(CCACHE_SKIP) objective-c++ -fobjc-exceptions
+
+OBJCXXFLAGS=-fobjc-exceptions
 
 # Comp Flags for files that need exceptions enabled (C and C++)
 CFLAGSEXCEPTIONS=-fexceptions -fno-enforce-eh-specs


More information about the Libreoffice-commits mailing list