2020-10-12 21:05:09 +02:00
|
|
|
# Patched lldb for Rust language support.
|
2021-04-20 13:50:04 +02:00
|
|
|
{ lldb_12, fetchFromGitHub }:
|
2020-10-12 21:05:09 +02:00
|
|
|
let
|
|
|
|
llvmSrc = fetchFromGitHub {
|
|
|
|
owner = "vadimcn";
|
|
|
|
repo = "llvm-project";
|
2021-04-20 13:50:04 +02:00
|
|
|
rev = "f2e9ff34256cd8c6feaf14359f88ad3f538ed687";
|
|
|
|
sha256 = "sha256-5UsCBu3rtt+l2HZiCswoQJPPh8T6y471TBF4AypdF9I=";
|
2020-10-12 21:05:09 +02:00
|
|
|
};
|
2021-04-20 13:50:04 +02:00
|
|
|
in lldb_12.overrideAttrs (oldAttrs: {
|
2020-10-12 21:05:09 +02:00
|
|
|
src = "${llvmSrc}/lldb";
|
|
|
|
|
|
|
|
passthru = (oldAttrs.passthru or {}) // {
|
|
|
|
inherit llvmSrc;
|
|
|
|
};
|
|
|
|
|
|
|
|
doInstallCheck = true;
|
|
|
|
postInstallCheck = (oldAttrs.postInstallCheck or "") + ''
|
|
|
|
versionOutput="$($out/bin/lldb --version)"
|
|
|
|
echo "'lldb --version' returns: $versionOutput"
|
|
|
|
echo "$versionOutput" | grep -q 'rust-enabled'
|
|
|
|
'';
|
|
|
|
})
|