summary refs log tree commit diff
diff options
context:
space:
mode:
authorWill Dietz <w@wdtz.org>2018-10-30 17:11:18 -0500
committerWill Dietz <w@wdtz.org>2018-10-30 17:36:19 -0500
commit5d616900ec910afa369f57139c64edb97d99fecd (patch)
tree0140b62fd4597b774702e643bcea96169371bbc9
parent5e5e57c5728722450091160b2b0dbf53a311b230 (diff)
downloadnixpkgs-5d616900ec910afa369f57139c64edb97d99fecd.tar
nixpkgs-5d616900ec910afa369f57139c64edb97d99fecd.tar.gz
nixpkgs-5d616900ec910afa369f57139c64edb97d99fecd.tar.bz2
nixpkgs-5d616900ec910afa369f57139c64edb97d99fecd.tar.lz
nixpkgs-5d616900ec910afa369f57139c64edb97d99fecd.tar.xz
nixpkgs-5d616900ec910afa369f57139c64edb97d99fecd.tar.zst
nixpkgs-5d616900ec910afa369f57139c64edb97d99fecd.zip
thunderbolt: cleanup
-rw-r--r--pkgs/os-specific/linux/thunderbolt/default.nix21
1 files changed, 6 insertions, 15 deletions
diff --git a/pkgs/os-specific/linux/thunderbolt/default.nix b/pkgs/os-specific/linux/thunderbolt/default.nix
index ac687de8c9a..faf47c96a5e 100644
--- a/pkgs/os-specific/linux/thunderbolt/default.nix
+++ b/pkgs/os-specific/linux/thunderbolt/default.nix
@@ -16,22 +16,13 @@ stdenv.mkDerivation rec {
     sha256 = "02w1bfm7xvq0dzkhwqiq0camkzz9kvciyhnsis61c8vzp39cwx0x";
   };
 
-  buildInputs = [
-    boost
-    cmake
-    pkgconfig
-    txt2tags
-  ];
+  nativeBuildInputs = [ cmake pkgconfig txt2tags ];
+  buildInputs = [ boost ];
 
-  # These can't go in the normal nix cmakeFlags because $out needs to be
-  # expanded by the shell, not by cmake or nix.  $ENV{out} doesn't work right
-  # either; it results in /build/source/build//nix/store/blahblahblahblah/bin/
-  # TODO: use ${placeholder "out"} when possible.
-  #       See https://github.com/NixOS/nixpkgs/pull/37693
-  preConfigure = ''
-    cmakeFlags+=" -DUDEV_BIN_DIR=$out/bin"
-    cmakeFlags+=" -DUDEV_RULES_DIR=$out/etc/udev/rules.d"
-  '';
+  cmakeFlags = [
+    "-DUDEV_BIN_DIR=${placeholder "out"}/bin"
+    "-DUDEV_RULES_DIR=${placeholder "out"}/etc/udev/rules.d"
+  ];
 
   meta = {
     description = "Thunderbolt(TM) user-space components";