3
0
Fork 0
forked from mirrors/nixpkgs

libc++7: prefer 'optional' as suggested by comment

This commit is contained in:
Will Dietz 2018-09-19 08:36:40 -05:00
parent 167e799d81
commit e3030a2908

View file

@ -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++"