[Libreoffice-commits] core.git: configure.ac

Rene Engelhard (via logerrit) logerrit at kemper.freedesktop.org
Mon Sep 13 13:03:47 UTC 2021


 configure.ac |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit 5979076a14098f6887b61e937cfc9059ff7f2506
Author:     Rene Engelhard <rene at debian.org>
AuthorDate: Mon Aug 23 22:37:54 2021 +0200
Commit:     Christian Lohmaier <lohmaier+LibreOffice at googlemail.com>
CommitDate: Mon Sep 13 15:03:12 2021 +0200

    fix ccache size detection with ccache 4.4
    
    which changed format. but ccache -p has the same format in 4.2 and 4.4
    so use that one
    
    Change-Id: I4de0241109c580becb96ce0c1b461c2642a4631e
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120928
    Tested-by: Christian Lohmaier <lohmaier+LibreOffice at googlemail.com>
    Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice at googlemail.com>

diff --git a/configure.ac b/configure.ac
index 45d19327d19d..a2dd5dc5eeb9 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3127,7 +3127,9 @@ AC_SUBST(CCACHE_DEPEND_MODE)
 
 # skip on windows - sccache defaults are good enough
 if test "$CCACHE" != "" -a "$_os" != "WINNT"; then
-    ccache_size_msg=$([ccache -s | tail -n 1 | sed 's/^[^0-9]*//' | sed -e 's/\.[0-9]*//'])
+    # e.g. (/home/rene/.config/ccache/ccache.conf) max_size = 20.0G
+    # -p works with both 4.2 and 4.4
+    ccache_size_msg=$([ccache -p | $AWK /max_size/'{ print $4 }' | sed -e 's/\.[0-9]*//'])
     ccache_size=$(echo "$ccache_size_msg" | grep "G" | sed -e 's/G.*$//')
     if test "$ccache_size" = ""; then
         ccache_size=$(echo "$ccache_size_msg" | grep "M" | sed -e 's/\ M.*$//')


More information about the Libreoffice-commits mailing list