phase1: use ccache wrappers for all HOSTCC/HOSTCXX uses
authorThibaut VARÈNE <hacks@slashdirt.org>
Tue, 24 Jul 2018 10:41:16 +0000 (12:41 +0200)
committerJo-Philipp Wich <jo@mein.io>
Tue, 25 Sep 2018 13:13:40 +0000 (15:13 +0200)
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org>
phase1/master.cfg

index e58209ddc8c2a50d1ca340044bdb7547412b2bfb..f06ade2498b9a464bad5c5e95e7dc8c7f8201fd1 100644 (file)
@@ -598,12 +598,26 @@ for target in targets:
                description = "Remove feed symlinks",
                command=["rm", "-rf", "package/feeds/"]))
 
+       factory.addStep(StringDownload(
+               name = "ccachecc",
+               s = '#!/bin/sh\nexec ${CCACHE} ${CCC} "$@"\n',
+               slavedest = "../ccache_cc.sh",
+               mode = 0755,
+       ))
+
+       factory.addStep(StringDownload(
+               name = "ccachecxx",
+               s = '#!/bin/sh\nexec ${CCACHE} ${CCXX} "$@"\n',
+               slavedest = "../ccache_cxx.sh",
+               mode = 0755,
+       ))
+
        # feed
        factory.addStep(ShellCommand(
                name = "updatefeeds",
                description = "Updating feeds",
                command=["./scripts/feeds", "update"],
-               env = MakeEnv(),
+               env = MakeEnv(tryccache=True),
        ))
 
        # feed
@@ -611,7 +625,7 @@ for target in targets:
                name = "installfeeds",
                description = "Installing feeds",
                command=["./scripts/feeds", "install", "-a"],
-               env = MakeEnv()))
+               env = MakeEnv(tryccache=True)))
 
        # seed config
        factory.addStep(FileDownload(
@@ -672,20 +686,6 @@ for target in targets:
                want_stdout = False
        ))
 
-       factory.addStep(StringDownload(
-               name = "ccachecc",
-               s = '#!/bin/sh\nexec ${CCACHE} ${CCC} "$@"\n',
-               slavedest = "../ccache_cc.sh",
-               mode = 0755,
-       ))
-
-       factory.addStep(StringDownload(
-               name = "ccachecxx",
-               s = '#!/bin/sh\nexec ${CCACHE} ${CCXX} "$@"\n',
-               slavedest = "../ccache_cxx.sh",
-               mode = 0755,
-       ))
-
        # prepare tar
        factory.addStep(ShellCommand(
                name = "dltar",
@@ -724,7 +724,7 @@ for target in targets:
                name = "toolchain",
                description = "Building and installing toolchain",
                command=["make", Interpolate("-j%(kw:jobs)s", jobs=GetNumJobs), "toolchain/install", "V=s"],
-               env = MakeEnv(),
+               env = MakeEnv(tryccache=True),
                haltOnFailure = True
        ))