mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-09-22 04:57:56 +03:00
runit: optionally build static runit{,-init}
May be useful in initrd along with statically linked busybox.
This commit is contained in:
parent
1cabee5973
commit
525b250052
@ -1,4 +1,6 @@
|
||||
{ stdenv, fetchurl }:
|
||||
{ stdenv, fetchurl
|
||||
, static ? false
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "runit-${version}";
|
||||
@ -15,7 +17,9 @@ stdenv.mkDerivation rec {
|
||||
|
||||
doCheck = true;
|
||||
|
||||
postPatch = ''
|
||||
buildInputs = stdenv.lib.optionals static [ stdenv.cc.libc stdenv.cc.libc.static ];
|
||||
|
||||
postPatch = stdenv.lib.optionalString (!static) ''
|
||||
sed -i 's,-static,,g' src/Makefile
|
||||
'';
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user