about summary refs log tree commit diff
path: root/pkgs/development/compilers/llvm/8/bintools/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/compilers/llvm/8/bintools/default.nix')
-rw-r--r--pkgs/development/compilers/llvm/8/bintools/default.nix7
1 files changed, 2 insertions, 5 deletions
diff --git a/pkgs/development/compilers/llvm/8/bintools/default.nix b/pkgs/development/compilers/llvm/8/bintools/default.nix
index 1eb7215c00856..38002439c205d 100644
--- a/pkgs/development/compilers/llvm/8/bintools/default.nix
+++ b/pkgs/development/compilers/llvm/8/bintools/default.nix
@@ -1,10 +1,7 @@
-{ runCommand, stdenv, llvm, lld, version }:
+{ lib, runCommand, stdenv, llvm, lld, version }:
 
 let
-  prefix =
-    if stdenv.hostPlatform != stdenv.targetPlatform
-    then "${stdenv.targetPlatform.config}-"
-    else "";
+  prefix = lib.optionalString (stdenv.hostPlatform != stdenv.targetPlatform) "${stdenv.targetPlatform.config}-";
 in runCommand "llvm-binutils-${version}" {
   preferLocalBuild = true;
   passthru = {