mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-18 07:46:09 +01:00
util-linux: improve purity by using login from shadow
replacing shutdown in postPatch phase is not necessary as rtcwake was already patched to use the search path (the only user of shutdown)
This commit is contained in:
parent
4b9b1fa945
commit
104a37a9fb
1 changed files with 2 additions and 5 deletions
|
@ -1,4 +1,4 @@
|
|||
{ lib, stdenv, fetchurl, pkgconfig, zlib, fetchpatch
|
||||
{ lib, stdenv, fetchurl, pkgconfig, zlib, fetchpatch, shadow
|
||||
, ncurses ? null, perl ? null, pam, systemd, minimal ? false }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
|
@ -17,12 +17,9 @@ stdenv.mkDerivation rec {
|
|||
|
||||
outputs = [ "bin" "dev" "out" "man" ];
|
||||
|
||||
#FIXME: make it also work on non-nixos?
|
||||
postPatch = ''
|
||||
# Substituting store paths would create a circular dependency on systemd
|
||||
substituteInPlace include/pathnames.h \
|
||||
--replace "/bin/login" "/run/current-system/sw/bin/login" \
|
||||
--replace "/sbin/shutdown" "/run/current-system/sw/bin/shutdown"
|
||||
--replace "/bin/login" "${shadow}/bin/login"
|
||||
'';
|
||||
|
||||
crossAttrs = {
|
||||
|
|
Loading…
Reference in a new issue