From e3030a2908ca212dd9e6307695effb8bbcaf23af Mon Sep 17 00:00:00 2001 From: Will Dietz Date: Wed, 19 Sep 2018 08:36:40 -0500 Subject: [PATCH] libc++7: prefer 'optional' as suggested by comment --- pkgs/development/compilers/llvm/7/libc++/default.nix | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/pkgs/development/compilers/llvm/7/libc++/default.nix b/pkgs/development/compilers/llvm/7/libc++/default.nix index 992794f38e54..76bfb34975e6 100644 --- a/pkgs/development/compilers/llvm/7/libc++/default.nix +++ b/pkgs/development/compilers/llvm/7/libc++/default.nix @@ -10,11 +10,7 @@ stdenv.mkDerivation rec { export LIBCXXABI_INCLUDE_DIR="$PWD/$(ls -d libcxxabi-${version}*)/include" ''; - # on next rebuild, this can be replaced with optionals; for now set to null to avoid - # patches = stdenv.lib.optionals stdenv.hostPlatform.isMusl [ - patches = if stdenv.hostPlatform.isMusl then [ - ../../libcxx-0001-musl-hacks.patch - ] else null; + patches = stdenv.lib.optional stdenv.hostPlatform.isMusl ../../libcxx-0001-musl-hacks.patch; prePatch = '' substituteInPlace lib/CMakeLists.txt --replace "/usr/lib/libc++" "\''${LIBCXX_LIBCXXABI_LIB_PATH}/libc++"