Skip to content

Commit 5e9f8c0

Browse files
authored
Merge pull request swiftlang#36453 from porglezomp-misc/keep-the-sccache-warm
[build-script] Ensure the sccache server is started before building
2 parents 6f4b62a + ae66a94 commit 5e9f8c0

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

utils/build-script

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1319,6 +1319,12 @@ def main_normal():
13191319
toolchain.libtool = args.host_libtool
13201320
if args.cmake is not None:
13211321
toolchain.cmake = args.cmake
1322+
if args.sccache:
1323+
print("Ensuring the sccache server is running...")
1324+
# Use --show-stats to ensure the server is started, because using
1325+
# --start-server will fail if the server is already running.
1326+
# Capture the output because we don't want to see the stats.
1327+
shell.capture([toolchain.sccache, "--show-stats"])
13221328

13231329
cmake = CMake(args=args, toolchain=toolchain)
13241330
# Check the CMake version is sufficient on Linux and build from source

0 commit comments

Comments
 (0)