summary refs log tree commit diff
path: root/pkgs/os-specific/linux/prl-tools
diff options
context:
space:
mode:
authorJohn Ericson <John.Ericson@Obsidian.Systems>2019-11-24 17:22:28 +0000
committerJohn Ericson <John.Ericson@Obsidian.Systems>2019-11-24 17:22:28 +0000
commit9b090ccbca3f7dd26d91db06e96e8bf8282c37ca (patch)
tree1654f2f0cb883fa4cb95def306a933475d065431 /pkgs/os-specific/linux/prl-tools
parent99537e994f09e8e5499d3d877df0e16da8452ca7 (diff)
downloadnixpkgs-9b090ccbca3f7dd26d91db06e96e8bf8282c37ca.tar
nixpkgs-9b090ccbca3f7dd26d91db06e96e8bf8282c37ca.tar.gz
nixpkgs-9b090ccbca3f7dd26d91db06e96e8bf8282c37ca.tar.bz2
nixpkgs-9b090ccbca3f7dd26d91db06e96e8bf8282c37ca.tar.lz
nixpkgs-9b090ccbca3f7dd26d91db06e96e8bf8282c37ca.tar.xz
nixpkgs-9b090ccbca3f7dd26d91db06e96e8bf8282c37ca.tar.zst
nixpkgs-9b090ccbca3f7dd26d91db06e96e8bf8282c37ca.zip
treewide: Get rid of most `parseDrvName` without breaking compat
That is because this commit should be merged to both master and
release-19.09.
Diffstat (limited to 'pkgs/os-specific/linux/prl-tools')
-rw-r--r--pkgs/os-specific/linux/prl-tools/default.nix4
1 files changed, 2 insertions, 2 deletions
diff --git a/pkgs/os-specific/linux/prl-tools/default.nix b/pkgs/os-specific/linux/prl-tools/default.nix
index 3daab3917e8..78aa5abdf30 100644
--- a/pkgs/os-specific/linux/prl-tools/default.nix
+++ b/pkgs/os-specific/linux/prl-tools/default.nix
@@ -8,7 +8,7 @@ assert (!libsOnly) -> kernel != null;
 # Disable for kernels 4.15 and above due to compatibility issues
 assert kernel != null -> stdenv.lib.versionOlder kernel.version "4.15";
 
-let xorgFullVer = (builtins.parseDrvName xorg.xorgserver.name).version;
+let xorgFullVer = lib.getVersion xorg.xorgserver;
     xorgVer = lib.concatStringsSep "." (lib.take 2 (lib.splitString "." xorgFullVer));
     x64 = if stdenv.hostPlatform.system == "x86_64-linux" then true
           else if stdenv.hostPlatform.system == "i686-linux" then false
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     ( cd $sourceRoot/tools; tar -xaf prltools${if x64 then ".x64" else ""}.tar.gz )
   '';
 
-  kernelVersion = if libsOnly then "" else (builtins.parseDrvName kernel.name).version;
+  kernelVersion = if libsOnly then "" else lib.getName kernel.name;
   kernelDir = if libsOnly then "" else "${kernel.dev}/lib/modules/${kernelVersion}";
   scriptPath = lib.concatStringsSep ":" (lib.optionals (!libsOnly) [ "${utillinux}/bin" "${gawk}/bin" ]);