File tree Expand file tree Collapse file tree
.github/actions/build-linux-native-package Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2626 nix build .#ccusage-static --print-build-logs
2727 fi
2828
29- # Pin the deps-only artifacts with a GC root that lives on the mounted Nix
30- # store (the Blacksmith sticky disk). Without a root the crane cargoArtifacts
31- # path is unreferenced once the binary is built, so the sticky disk drops it
32- # and the next run rebuilds all dependencies (~190s). The root persists with
33- # the disk, keeping the deps warm across runs.
34- - name : Pin dependency cache root
35- shell : bash
36- env :
37- NIX_GITHUB_TOKEN : ${{ inputs.nix-github-token }}
38- run : |
39- mkdir -p /nix/ccusage-ci-gcroots
40- if [ "$NIX_GITHUB_TOKEN" = "false" ]; then
41- NIX_CONFIG="access-tokens =" nix build '.#ccusage-static.cargoArtifacts' --out-link /nix/ccusage-ci-gcroots/deps
42- else
43- nix build '.#ccusage-static.cargoArtifacts' --out-link /nix/ccusage-ci-gcroots/deps
44- fi
45-
4629 - name : Verify Linux binary is static
4730 shell : bash
4831 env :
Original file line number Diff line number Diff line change 7272 staticCommonArgs
7373 // {
7474 cargoArtifacts = staticCargoArtifacts ;
75- # Expose the deps-only artifacts so CI can pin them with a GC root and
76- # keep them on the Blacksmith sticky disk across runs; otherwise the
77- # store path is unreferenced once the binary is built and gets pruned,
78- # forcing a full ~190s dependency rebuild on every run.
79- passthru = {
80- cargoArtifacts = staticCargoArtifacts ;
81- } ;
8275 # A PT_INTERP header means the binary requests a dynamic loader,
8376 # so it would not run on end-user machines without the build-time
8477 # loader path. READELF is exported by the cross bintools wrapper.
You can’t perform that action at this time.
0 commit comments