Skip to content

Commit

Permalink
llvmPackages_15.libcxx: fix the generated linker script
Browse files Browse the repository at this point in the history
See:
 - #214524 (comment)
 - llvm/llvm-project@57c7bb3
 - https://reviews.llvm.org/D133566

We can drop this patch in `llvmPackages_16`.

Fixes #214524.
  • Loading branch information
rrbutani authored and Artturin committed Sep 8, 2023
1 parent 306de1a commit 0251e26
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
11 changes: 10 additions & 1 deletion pkgs/development/compilers/llvm/15/libcxx/default.nix
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{ lib, stdenv, llvm_meta
, monorepoSrc, runCommand
, monorepoSrc, runCommand, fetchpatch
, cmake, ninja, python3, fixDarwinDylibNames, version
, cxxabi ? if stdenv.hostPlatform.isFreeBSD then libcxxrt else libcxxabi
, libcxxabi, libcxxrt, libunwind
Expand Down Expand Up @@ -47,6 +47,15 @@ stdenv.mkDerivation rec {

patches = [
./gnu-install-dirs.patch
# See:
# - https://reviews.llvm.org/D133566
# - https://github.com/NixOS/nixpkgs/issues/214524#issuecomment-1429146432
# !!! Drop in LLVM 16+
(fetchpatch {
url = "https://github.com/llvm/llvm-project/commit/57c7bb3ec89565c68f858d316504668f9d214d59.patch";
hash = "sha256-AaM9A6tQ4YAw7uDqCIV4VaiUyLZv+unwcOqbakwW9/k=";
relative = "libcxx";
})
] ++ lib.optionals stdenv.hostPlatform.isMusl [
../../libcxx-0001-musl-hacks.patch
];
Expand Down
1 change: 0 additions & 1 deletion pkgs/test/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@ with pkgs;

# libcxxStdenv broken
# fix in https://github.com/NixOS/nixpkgs/pull/216273
(filter (n: n != "llvmPackages_15"))
] ++ lib.optionals (stdenv.hostPlatform.isLinux && stdenv.hostPlatform.isAarch64) [
# libcxx does not build for some reason on aarch64-linux
(filter (n: n != "llvmPackages_7"))
Expand Down

0 comments on commit 0251e26

Please sign in to comment.