Hi,

I'm writing this mail as reply to Replicant Digest, Vol 351, Issue 1.


I've been using ccache for several years now and I never had issues,

so based on my experience I can say ccache is reliable.


The only downside is that ccache needs around 10GB of disk space for Replicant 6,

but the speedup that ccache provides is worth it in my opinion.


I didn't know you mirror projects you use, but it makes sense, of course.

The reason why I prefer building ccache from source is that the versions distributed with many GNU/Linux distributions are often not the latest version.


However, the ccache.mk file already provides a mechanism to prefer an installed version of ccache over a custom build,

so we could use that to use the distributions version of ccache if it is provided.


In the attachment you can find two patches:

- one that tracks the ccache mirror from contrib

- one for the build environment that prefers the distributions ccache over a custom build


Yours,

Tobias


>From e3c71e9ff482df01115b38a28d962dad6c0b54e1 Mon Sep 17 00:00:00 2001
From: Tobias Tefke <[email protected]>
Date: Wed, 1 Apr 2020 13:05:18 +0200
Subject: [PATCH] [1/3] Track ccache for toolchain

Change-Id: Iff577363407808aca3b13b6ea8f79d9729287733
Signed-off-by: Tobias Tefke <[email protected]>
---
 default.xml | 1 +
 1 file changed, 1 insertion(+)

diff --git a/default.xml b/default.xml
index a73f12c..18c74a2 100644
--- a/default.xml
+++ b/default.xml
@@ -514,6 +514,7 @@
 <project path="toolchain/src/gcc" name="replicant/toolchain_gcc.git" remote="replicant" revision="master" />
 <project path="toolchain/src/jack" name="replicant/toolchain_jack.git" remote="replicant" />
 <project path="toolchain/src/jill" name="replicant/toolchain_jill.git" remote="replicant" />
+<project path="toolchain/src/ccache" name="ccache-mirror/ccache" revision="3.7-maint" remote="replicant" />
 
 <!-- KERNEL -->
   <project path="kernel/samsung/smdk4412" name="replicant/kernel_samsung_smdk4412.git" remote="replicant" />
-- 
2.17.1


>From 3659f777e309711bda9c57361b99f57d41d895e9 Mon Sep 17 00:00:00 2001
From: Tobias Tefke <[email protected]>
Date: Thu, 2 Apr 2020 13:31:10 +0200
Subject: [PATCH] [2/3] Use our own ccache binary if requested

Signed-off-by: Tobias Tefke <[email protected]>
---
 core/ccache.mk | 9 ++-------
 1 file changed, 2 insertions(+), 7 deletions(-)

diff --git a/core/ccache.mk b/core/ccache.mk
index bd60ebf26..1f5245bc2 100644
--- a/core/ccache.mk
+++ b/core/ccache.mk
@@ -42,13 +42,8 @@ ifneq ($(USE_CCACHE),)
   ccache := $(shell which ccache)
 
   ifeq ($(ccache),)
-    CCACHE_HOST_TAG := $(HOST_PREBUILT_TAG)
-    # If we are cross-compiling Windows binaries on Linux
-    # then use the linux ccache binary instead.
-    ifeq ($(HOST_OS)-$(BUILD_OS),windows-linux)
-      CCACHE_HOST_TAG := linux-$(HOST_PREBUILT_ARCH)
-    endif
-    ccache := prebuilts/misc/$(CCACHE_HOST_TAG)/ccache/ccache
+    # we only build Replicant on GNU/Linux, so we don't need the lines for other operating systems
+    ccache := toolchain/ccache/ccache
   endif
 
   # Check that the executable is here.
-- 
2.17.1


_______________________________________________
Replicant mailing list
[email protected]
https://lists.osuosl.org/mailman/listinfo/replicant

Reply via email to