busybox-sandbox-shell: replace pkgsStatic with useMusl

This commit is contained in:
Simon Žlender 2024-05-26 14:46:17 +02:00
parent 47dc5232ba
commit 11472f0d1b
2 changed files with 5 additions and 7 deletions

View File

@ -1,9 +1,12 @@
{ busybox}:
{ lib, stdenv, busybox, musl }:
# Minimal shell for use as basic /bin/sh in sandbox builds
busybox.override {
enableStatic = true;
enableMinimal = true;
useMusl = stdenv.hostPlatform.isGnu && lib.meta.availableOn stdenv.hostPlatform musl;
extraConfig = ''
CONFIG_FEATURE_FANCY_ECHO y
CONFIG_FEATURE_SH_MATH y

View File

@ -12328,12 +12328,7 @@ with pkgs;
overrideCC stdenv buildPackages.llvmPackages.clangNoLibcxx
else stdenv;
};
busybox-sandbox-shell = callPackage ../os-specific/linux/busybox/sandbox-shell.nix {
# musl roadmap has RISC-V support projected for 1.1.20
busybox = if !stdenv.hostPlatform.isRiscV && !stdenv.hostPlatform.isLoongArch64 && stdenv.hostPlatform.libc != "bionic"
then pkgsStatic.busybox
else busybox;
};
busybox-sandbox-shell = callPackage ../os-specific/linux/busybox/sandbox-shell.nix { };
cm-rgb = python3Packages.callPackage ../tools/system/cm-rgb { };