From e3ac73af1149ff92e4e9ed9de80a65b673bdb9c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20=C4=8Cun=C3=A1t?= Date: Sun, 19 Apr 2015 15:22:26 +0200 Subject: [PATCH] systemd.libudev: don't depend on the main output Also fix some references, and drop unused makeFlags: https://github.com/NixOS/nixpkgs/commit/3300479c#commitcomment-10790021 --- pkgs/os-specific/linux/systemd/default.nix | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/pkgs/os-specific/linux/systemd/default.nix b/pkgs/os-specific/linux/systemd/default.nix index c10d53c5c75e..d193270e8ea2 100644 --- a/pkgs/os-specific/linux/systemd/default.nix +++ b/pkgs/os-specific/linux/systemd/default.nix @@ -90,9 +90,17 @@ stdenv.mkDerivation rec { export NIX_CFLAGS_LINK+=" -Wl,-rpath,$libudev/lib" ''; + makeFlags = [ + "udevlibexecdir=$(libudev)/lib" + # udev rules refer to $out, and anything but libs should probably go to $out + "udevrulesdir=$(out)/lib" + "udevhomedir=$(out)/lib" + "udevhwdbdir=$(out)/lib" + ]; + # This is needed because systemd uses the gold linker, which doesn't # yet have the wrapper script to add rpath flags automatically. - NIX_LDFLAGS = "-rpath ${pam}/lib -rpath ${libcap}/lib -rpath ${acl}/lib -rpath ${stdenv.cc.cc}/lib"; + NIX_LDFLAGS = "-rpath ${pam.out}/lib -rpath ${libcap.out}/lib -rpath ${acl.out}/lib -rpath ${stdenv.cc.cc}/lib"; PYTHON_BINARY = "${coreutils}/bin/env python"; # don't want a build time dependency on Python @@ -110,13 +118,6 @@ stdenv.mkDerivation rec { "-USYSTEMD_BINARY_PATH" "-DSYSTEMD_BINARY_PATH=\"/run/current-system/systemd/lib/systemd/systemd\"" ]; - # Use /var/lib/udev rather than /etc/udev for the generated hardware - # database. Upstream doesn't want this (see commit - # 1e1954f53386cb773e2a152748dd31c4d36aa2d8) because using /var is - # forbidden in early boot, but in NixOS the initrd guarantees that - # /var is mounted. - makeFlags = "hwdb_bin=/var/lib/udev/hwdb.bin"; - enableParallelBuilding = true; installFlags =