Skip to content

Commit f4ca387

Browse files
committed
use static bins for stage1 and stage2
1 parent a54c848 commit f4ca387

File tree

1 file changed

+20
-8
lines changed

1 file changed

+20
-8
lines changed

default.nix

+20-8
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
with builtins;
22
{
3-
bubblewrap,
4-
nix,
3+
bubblewrapStatic ? pkgsStatic.bubblewrap,
4+
# fix: builder failed to produce output path for output 'man'
5+
# https://github.com/milahu/nixpkgs/issues/83
6+
#nixStatic ? pkgsStatic.nix,
7+
nixStatic ? pkgsStatic.nixVersions.nixComponents_git.nix-everything,
58
unzip,
69
zip,
710
unixtools,
@@ -12,14 +15,14 @@ with builtins;
1215
patchelf,
1316
cacert,
1417
pkgs,
15-
# no. pkgsStatic.nix and pkgsStatic.proot are not cached
16-
# still an issue: https://github.com/NixOS/nixpkgs/issues/81137
17-
# pkgsStatic,
18-
busybox,
18+
pkgsStatic,
19+
busyboxStatic ? pkgsStatic.busybox,
1920
gnutar,
2021
xz,
21-
zstd,
22-
proot,
22+
zstdStatic ? pkgsStatic.zstd,
23+
# FIXME ld: attempted static link of dynamic object
24+
# https://gitlab.com/ita1024/waf/-/issues/2467
25+
prootStatic ? pkgsStatic.proot,
2326
compression ? "zstd -3 -T1",
2427
buildSystem ? builtins.currentSystem,
2528
# # tar crashed on emulated aarch64 system
@@ -32,6 +35,15 @@ with builtins;
3235
with lib;
3336
let
3437

38+
# stage1 bins
39+
busybox = busyboxStatic;
40+
zstd = zstdStatic;
41+
42+
# stage2 bins
43+
nix = nixStatic;
44+
bubblewrap = bubblewrapStatic;
45+
proot = prootStatic;
46+
3547
pname =
3648
if bundledPackage == null
3749
then "nix-portable"

0 commit comments

Comments
 (0)