util-linux: create -Minimal and utillinux (full)

Close #12952. Now the full version is used by default,
supporting systemd and curses.
This commit is contained in:
Kevin Cox
2016-02-25 08:52:05 +01:00
committed by Vladimír Čunát
parent 30b7bd8d01
commit eead3bc536
5 changed files with 24 additions and 18 deletions
@@ -1,4 +1,6 @@
{ stdenv, fetchurl, zlib, ncurses ? null, perl ? null, pam }:
{ stdenv, fetchurl, zlib, ncurses ? null, perl ? null, pam, systemd ? null
, pkgconfig
}:
stdenv.mkDerivation rec {
name = "util-linux-2.27.1";
@@ -38,11 +40,16 @@ stdenv.mkDerivation rec {
--disable-use-tty-group
--enable-fs-paths-default=/var/setuid-wrappers:/var/run/current-system/sw/bin:/sbin
${if ncurses == null then "--without-ncurses" else ""}
${if systemd == null then "" else ''
--with-systemd
--with-systemdsystemunitdir=$out/lib/systemd/system/
''}
'';
buildInputs =
[ zlib pam ]
++ stdenv.lib.optional (ncurses != null) ncurses
++ stdenv.lib.optional (systemd != null) [ systemd pkgconfig ]
++ stdenv.lib.optional (perl != null) perl;
postInstall = ''