From 9b090ccbca3f7dd26d91db06e96e8bf8282c37ca Mon Sep 17 00:00:00 2001 From: John Ericson Date: Sun, 24 Nov 2019 17:22:28 +0000 Subject: treewide: Get rid of most `parseDrvName` without breaking compat That is because this commit should be merged to both master and release-19.09. --- pkgs/os-specific/linux/prl-tools/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/os-specific/linux/prl-tools') 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" ]); -- cgit 1.4.1