Skip to content

ci: Cache the dependencies that Windows CI builds from source - #2188

Merged
lgritz merged 1 commit into
AcademySoftwareFoundation:mainfrom
lgritz:lg-wincache
Oct 21, 2026
Merged

lgritz merged 1 commit into
AcademySoftwareFoundation:mainfrom
lgritz:lg-wincache

Conversation

@lgritz

@lgritz lgritz commented Oct 17, 2026

Copy link
Copy Markdown
Collaborator

This brings the Windows CI jobs down from around 30m to around 10m (for the 2nd and subsequent build on the same branch or PR).

TL;DR:

On Linux and Mac, our CI uses GHA cache action in conjunction with ccache to save and restore the ccache area, thus making recompiles (including run to run on the same branch and with the same flags) much less expensive, both for OSL itself and also for any dependencies that we rebuild from scratch.

CMake's Visual Studio generator ignores CMAKE_CXX_COMPILER_LAUNCHER, so ccache isn't used for our Windows CI. We could switch to Ninja and use ccache, but then there would be a testing gap where we wouldn't be building in the way that most Windows users will. So we don't cache, and thus have long build times.

This PR caches the installed results of our dependency builds on Windows, saving about 2/3 of the total time. The dependencies we build in Windows CI (and now cache for most runs) are zlib, libpng, pybind11, OpenEXR, pugixml, OpenColorIO, and OpenImageIO.

Assisted-by: Claude Code / Claude Opus 5.5

This brings the Windows CI jobs down from around 30m to around 10m
(for the 2nd and subsequent build on the same branch or PR).

TL;DR:

On Linux and Mac, our CI uses GHA cache action, in conjunction with
ccache, to save and restore the ccache area, thus making recompiles
(including run to run on the same branch and with the same flags) much
less expensive, both for OSL itself and also for any dependencies that
we rebuild from scratch.

CMake's Visual Studio generator ignores CMAKE_CXX_COMPILER_LAUNCHER,
so ccache isn't used for our Windows CI. We could switch to Ninja and
use ccache, but then there is a testing gap where we aren't building
in the way that most Windows users will. So we don't cache, and thus
have long build times.

This PR caches the installed results of our dependency builds on
Windows, saving about 2/3 of the total time.  The dependencies we
build in Windows CI (and now cache for most runs) are zlib, libpng,
pybind11, OpenEXR, pugixml, OpenColorIO, and OpenImageIO.

Assisted-by: Claude Code / Claude Opus 5.5

Signed-off-by: Larry Gritz <lg@larrygritz.com>
@lgritz

lgritz commented Oct 21, 2026

Copy link
Copy Markdown
Collaborator Author

No bites, CI only change -> merging

@lgritz
lgritz merged commit ac77609 into AcademySoftwareFoundation:main Oct 21, 2026
23 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant