Repository navigation
[Backport staging-26.05] llvmPackages_{18,19,20,21,22}.libllvm: backport Darwin triple parsing; lldb: backport export trie fixes to LLDB 22 and older - #562652
Conversation
This fixes breakage on triples for macOS 27, which aligned the Darwin version with the OS version (darwin26 is macOS 27, but so is darwin27, which will be incorrectly interpreted as macOS 28 without this patch). This is probably harmless in most cases, but it causes a test failure in LLVM’s test suite when running under macOS 27. (cherry picked from commit 6fb7a4d)
There was a problem hiding this comment.
This report is automatically generated by the PR / Check / cherry-pick CI workflow.
Some of the commits in this PR require the author's and reviewer's attention.
Sometimes it is not possible to cherry-pick exactly the same patch.
This most frequently happens when resolving merge conflicts.
The range-diff will help to review the resolution of conflicts.
If you need to merge this PR despite the warnings, please dismiss this review shortly before merging.
Warning
Difference between 3692fe6 and original 6fb7a4d may warrant inspection.
Show diff
@@ Commit message
This is probably harmless in most cases, but it causes a test failure in
LLVM’s test suite when running under macOS 27.
+ (cherry picked from commit 6fb7a4dc0c9ba446ba0968bd046601a2e5903571)
+
## pkgs/development/compilers/llvm/18/llvm/backport-darwin-triple-parsing.patch (new) ##
@@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
@@ -1449,9 +1449,12 @@ bool Triple::getMacOSXVersion(VersionTuple &Version) const {
## pkgs/development/compilers/llvm/common/llvm/default.nix ##
@@ pkgs/development/compilers/llvm/common/llvm/default.nix: stdenv.mkDerivation (
+ hash = "sha256-3hkbYPUVRAtWpo5qBmc2jLZLivURMx8T0GQomvNZesc=";
stripLen = 1;
- hash = "sha256-HHVMVL7ZWiZkbfnD37zYxFWnfvI3LNS0Z2oFHhOaZsU=";
- })
-+ ]
+ }
+- );
++ )
+ ++ lib.optionals (lib.versionOlder release_version "23") [
+ # As of macOS 27 (and iOS 27, etc), the Darwin version number is the same as the OS version number.
+ # This change breaks target parsing because `darwin27` is incorrectly interpreted as macOS 28.
+ # This patch is a backport of the target parsing changes in LLVM 23, which fixes the problem.
+ # Hopefully, Apple does not change the version number scheme again any time soon.
+ (getVersionFile "llvm/backport-darwin-triple-parsing.patch")
- ];
++ ];
nativeBuildInputs = [
+ cmake
## pkgs/development/compilers/llvm/common/patches.nix ##
@@
Warning
Difference between 51db35b and original 53b813b may warrant inspection.
Show diff
@@ Commit message
The fixes from LLVM 23 can’t be cherry-picked due to other changes. They
have been manually backported and squashed into a single patch.
+ (cherry picked from commit 53b813b1660e8ae9f62a5334a7bd89b42c7ea752)
+
## pkgs/development/compilers/llvm/18/lldb/backport-ParseTrieEntries-fixes.patch (new) ##
@@
+diff --git a/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp b/source/Plugins/ObjectFile/Mach-O/ObjectFileMachO.cpp
@@ -2659,9 +2682,8 @@
+
## pkgs/development/compilers/llvm/common/lldb/default.nix ##
-@@
- monorepoSrc ? null,
- enableManpages ? false,
- devExtraCmakeFlags ? [ ],
-+ getVersionFile,
- versionCheckHook,
- }:
-
@@ pkgs/development/compilers/llvm/common/lldb/default.nix: stdenv.mkDerivation (
# Fix build with gcc15
# https://github.com/llvm/llvm-project/commit/bb59f04e7e75dcbe39f1bf952304a157f0035314
Hint: The full diffs are also available in the runner logs with slightly better highlighting.
Older versions of LLDB crash on macOS 27 when starting a debugging session on macOS 27 due to a stack overflow in `ParseExportTries`. The fixes from LLVM 23 can’t be cherry-picked due to other changes. They have been manually backported and squashed into a single patch. (cherry picked from commit 53b813b)
|
|
Fixes llvm builds on macOS 27. Fixed lldb on macOS 27.
Things done
passthru.tests.nixpkgs-reviewon this PR. See nixpkgs-review usage../result/bin/.