From 9044f57d183dcf2443df52ccc58911970171584d Mon Sep 17 00:00:00 2001 From: John Ericson Date: Wed, 17 Apr 2019 00:16:36 -0400 Subject: compiler-rt: Don't try to build a test executable Got this trick from stack overflow to avoid needing compiler-rt to link the test exe before building compiler-rt. a static lib isn't linked at all, and so breaks the cycle. --- pkgs/development/compilers/llvm/8/compiler-rt.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pkgs/development/compilers/llvm') diff --git a/pkgs/development/compilers/llvm/8/compiler-rt.nix b/pkgs/development/compilers/llvm/8/compiler-rt.nix index 33eef4358256..2b591cc94aff 100644 --- a/pkgs/development/compilers/llvm/8/compiler-rt.nix +++ b/pkgs/development/compilers/llvm/8/compiler-rt.nix @@ -19,6 +19,8 @@ stdenv.mkDerivation rec { "-DCOMPILER_RT_BUILD_LIBFUZZER=OFF" "-DCOMPILER_RT_BUILD_PROFILE=OFF" "-DCOMPILER_RT_BAREMETAL_BUILD=ON" + #https://stackoverflow.com/questions/53633705/cmake-the-c-compiler-is-not-able-to-compile-a-simple-test-program + "-DCMAKE_TRY_COMPILE_TARGET_TYPE=STATIC_LIBRARY" "-DCMAKE_SIZEOF_VOID_P=${toString (stdenv.hostPlatform.parsed.cpu.bits / 8)}" ] ++ stdenv.lib.optionals stdenv.hostPlatform.isMusl [ "-DCOMPILER_RT_BUILD_SANITIZERS=OFF" @@ -62,7 +64,5 @@ stdenv.mkDerivation rec { ln -s $out/lib/*/clang_rt.crtend_shared-*.o $out/lib/crtendS.o ''; - NIX_LDFLAGS = stdenv.lib.optionalString stdenv.hostPlatform.isWasm "--allow-undefined --no-entry"; - enableParallelBuilding = true; } -- cgit 1.4.1